From patchwork Tue Jul 19 12:54:13 2016 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Riku Voipio X-Patchwork-Id: 72306 Delivered-To: patch@linaro.org Received: by 10.140.29.52 with SMTP id a49csp66138qga; Tue, 19 Jul 2016 06:01:25 -0700 (PDT) X-Received: by 10.55.41.167 with SMTP id p39mr50901793qkp.119.1468933285479; Tue, 19 Jul 2016 06:01:25 -0700 (PDT) Return-Path: Received: from lists.gnu.org (lists.gnu.org. [2001:4830:134:3::11]) by mx.google.com with ESMTPS id n135si13643417qka.61.2016.07.19.06.01.25 for (version=TLS1 cipher=AES128-SHA bits=128/128); Tue, 19 Jul 2016 06:01:25 -0700 (PDT) Received-SPF: pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 2001:4830:134:3::11 as permitted sender) client-ip=2001:4830:134:3::11; Authentication-Results: mx.google.com; dkim=fail header.i=@linaro.org; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 2001:4830:134:3::11 as permitted sender) smtp.mailfrom=qemu-devel-bounces+patch=linaro.org@nongnu.org; dmarc=fail (p=NONE dis=NONE) header.from=linaro.org Received: from localhost ([::1]:55711 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1bPUeL-00053n-4U for patch@linaro.org; Tue, 19 Jul 2016 09:01:25 -0400 Received: from eggs.gnu.org ([2001:4830:134:3::10]:42938) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1bPUXn-0007lp-5q for qemu-devel@nongnu.org; Tue, 19 Jul 2016 08:54:43 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1bPUXl-0003Q4-9G for qemu-devel@nongnu.org; Tue, 19 Jul 2016 08:54:38 -0400 Received: from mail-lf0-x233.google.com ([2a00:1450:4010:c07::233]:35518) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1bPUXl-0003Pz-1d for qemu-devel@nongnu.org; Tue, 19 Jul 2016 08:54:37 -0400 Received: by mail-lf0-x233.google.com with SMTP id f93so13386080lfi.2 for ; Tue, 19 Jul 2016 05:54:36 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=KvHfeCdwCb0O/0wuMcy24Tso72NsCXOLT6dZQN/Rh30=; b=aE2ddBWyv4pjLQN9t3ozEX/AurjORTZe8MSAUAE47g7jPx2J/PSoj2t25mTXregn9/ F51o16I9Aw2e37Tgt1zXWQklNY/n60wWkTo9MShll4GdP1F10JtKuT85tRAfaZZl1mKm n+gQO55Hi+DkH0ibohwbv9S5zHq+VxtKWGUkA= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references; bh=KvHfeCdwCb0O/0wuMcy24Tso72NsCXOLT6dZQN/Rh30=; b=Uox8JWLq5cGQavCTO0JXxuawJpbk+kH/Wupb3g5cORYF9RVdfBpwQYgtkl8hYUsopo GoWWtk3viR7csPlmD69P18MTbScUcnv2GkmHQTWinY6eVhnzLcopxGR40OMJGkKvS5Rn nKdB9PLQD6DbnvjQi6LQNqZiN3BJ/+I6OA7JDf8AuFFLbT5AZWYnFQY9t9VPZQrj0Lpy FN9OQV8kIQdyBGLj46rmQoLl3LF/aJEzIeFAe1kc6YvV2/41ktSPkSDZCeZp2azeER/o u7NbhrTpPoTXLhF+hSyNV5oBaI/E4179WUcbonVT72nn99px2SqD+ujrzHTGcKHvhh+F D9fg== X-Gm-Message-State: ALyK8tKeU/FUkM77DA7yUsg95c8BeaC3xKvKznAYUcm5GzhaFome7iJeefFJagNVOTAh1HNN X-Received: by 10.25.217.146 with SMTP id s18mr15994415lfi.46.1468932876003; Tue, 19 Jul 2016 05:54:36 -0700 (PDT) Received: from beaming.home (91-157-170-157.elisa-laajakaista.fi. [91.157.170.157]) by smtp.gmail.com with ESMTPSA id g3sm2248898lfe.14.2016.07.19.05.54.34 (version=TLS1_2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Tue, 19 Jul 2016 05:54:35 -0700 (PDT) From: riku.voipio@linaro.org To: qemu-devel@nongnu.org Date: Tue, 19 Jul 2016 15:54:13 +0300 Message-Id: <96069eea4bdf15b482e505b70f13548ee6ca0d01.1468932683.git.riku.voipio@linaro.org> X-Mailer: git-send-email 2.1.4 In-Reply-To: References: X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Received-From: 2a00:1450:4010:c07::233 Subject: [Qemu-devel] [PULL 15/16] linux-user: Fix type for SIOCATMARK ioctl X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Peter Maydell Errors-To: qemu-devel-bounces+patch=linaro.org@nongnu.org Sender: "Qemu-devel" From: Peter Maydell The SIOCATMARK ioctl takes an argument which should be a pointer to an integer where the kernel will write the result. We were incorrectly declaring it as TYPE_NULL which would mean it would always fail (with EFAULT) when it should succeed. Correct the type. Signed-off-by: Peter Maydell Signed-off-by: Riku Voipio --- linux-user/ioctls.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) -- 2.1.4 diff --git a/linux-user/ioctls.h b/linux-user/ioctls.h index 4b36baa..7e2c133 100644 --- a/linux-user/ioctls.h +++ b/linux-user/ioctls.h @@ -120,7 +120,7 @@ MK_PTR(MK_STRUCT(STRUCT_fiemap))) #endif - IOCTL(SIOCATMARK, 0, TYPE_NULL) + IOCTL(SIOCATMARK, IOC_R, MK_PTR(TYPE_INT)) IOCTL(SIOCGIFNAME, IOC_RW, MK_PTR(TYPE_INT)) IOCTL(SIOCGIFFLAGS, IOC_W | IOC_R, MK_PTR(MK_STRUCT(STRUCT_short_ifreq))) IOCTL(SIOCSIFFLAGS, IOC_W, MK_PTR(MK_STRUCT(STRUCT_short_ifreq)))