From nobody Mon Feb 9 22:38:33 2026 Delivered-To: importer@patchew.org Received-SPF: pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; envelope-from=qemu-devel-bounces+importer=patchew.org@nongnu.org; helo=lists.gnu.org; Authentication-Results: mx.zohomail.com; dkim=fail; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; dmarc=fail(p=none dis=none) header.from=linaro.org ARC-Seal: i=1; a=rsa-sha256; t=1585941229; cv=none; d=zohomail.com; s=zohoarc; b=bUIPDeA1zkZHz1KtZSRqq+LSXrCuAoGTkpKEd1IUR45o8k147Hb/O0P9gsZJJxjK+bOuP91oOfr/RgYzowoKjt657aj1fjst1/r/hbl8uADjV+9RsVXWeD1MAWW3YVqBcnEre5oKC22WlQaDbrIajrCKxepMxWsZTaoXjrIbQh8= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1585941229; h=Content-Type:Content-Transfer-Encoding:Cc:Date:From:In-Reply-To:List-Subscribe:List-Post:List-Id:List-Archive:List-Help:List-Unsubscribe:MIME-Version:Message-ID:References:Sender:Subject:To; bh=9yYReGEoMkqsfZWblGMzvHlMGSzTNisl1Y211B1bnEY=; b=U7uP0HQbrBeZPtqxn3twkwtSQeRQCGTbPj2lwCjf42/1vM6BT0lqDT5oHsaCydxkc5ARGcsC0XinWI/92lh+5nfw8x9PAOv6KCownFwqMi1Nbv4toMrWWJFpSaf60dWmVFWn+YPRbK9+dUNE8AhVoLI40s/vILs21HEKVAKbER4= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=fail; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; dmarc=fail header.from= (p=none dis=none) header.from= Return-Path: Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mx.zohomail.com with SMTPS id 1585941229408473.3290394798248; Fri, 3 Apr 2020 12:13:49 -0700 (PDT) Received: from localhost ([::1]:60131 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1jKRlC-0005DG-U4 for importer@patchew.org; Fri, 03 Apr 2020 15:13:46 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:40411) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1jKRjT-0003GB-5y for qemu-devel@nongnu.org; Fri, 03 Apr 2020 15:12:00 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1jKRjS-000284-59 for qemu-devel@nongnu.org; Fri, 03 Apr 2020 15:11:59 -0400 Received: from mail-wm1-x342.google.com ([2a00:1450:4864:20::342]:39787) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1jKRjR-00022w-UO for qemu-devel@nongnu.org; Fri, 03 Apr 2020 15:11:58 -0400 Received: by mail-wm1-x342.google.com with SMTP id e9so8904410wme.4 for ; Fri, 03 Apr 2020 12:11:56 -0700 (PDT) Received: from zen.linaroharston ([51.148.130.216]) by smtp.gmail.com with ESMTPSA id w15sm2587012wra.25.2020.04.03.12.11.51 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 03 Apr 2020 12:11:51 -0700 (PDT) Received: from zen.lan (localhost [127.0.0.1]) by zen.linaroharston (Postfix) with ESMTP id C29BC1FF8C; Fri, 3 Apr 2020 20:11:50 +0100 (BST) 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 :mime-version:content-transfer-encoding; bh=9yYReGEoMkqsfZWblGMzvHlMGSzTNisl1Y211B1bnEY=; b=K5NNnLA8kQ8cHlQxExClBCwKnhdlLhBVE/KiPCZLBWC7OV0Ye9YRL4HMB0BNPgkHOk AB+OFaWl6BtYt9R7R9o/ykTr7SU8tykYfVrwo1NebcRsrl3UTeXItTsWo2LlRB6suiR2 8N2hy/ICndn/3hLTMMSkXrm/SeFnMbDWYlotLSrl3V0ccOxbLqJPp6Tlc05gw9i+ijW3 s1aq//oJ1IDWdfjjBftYFlf1bFVA8ixQyRtsdX+wz0o5ZjuAOq/08C5umO15A+UAifec sgADKKoDVtbe6y5XqGlopGhguRyYP62/6Ho6mFIND5iylHj4Kp7Y0YGj4XtmGPT4JqtM 1bww== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=9yYReGEoMkqsfZWblGMzvHlMGSzTNisl1Y211B1bnEY=; b=UuNB7ar7mlv64jOdhjiiY5t0e75LdK6zx4mezRve+ng/ZIfWWxIsHtS7YclEZpt+WF XGa0x5se2i56wEq/o6wIN3rtMnvWub6J9cAVarIw3h55jK9sGf99LpnkASX+qKGWDMAI xrsBTYVygMNQW7FAG8KVuRYlp0kZzy644BYH4aW/L0qHlTiG4DGG/0bSnPrfBYg2unyD CFpA9M/apLPEP3YDAi4c2gdV39/fJt5z1tCqfwTfiVo/NK+uJmsZBfGDP99YcQwmtVWr pvjgcAcQNCiXGWGoNa/SJsjshFW9AC72jGTgf6iIzcDtJzaOuGrjHQ7cg6aCRxjWTHSJ 116Q== X-Gm-Message-State: AGi0PuYo1EPKV2kysy3nOjB+hY2NInkOwq0GDnsc61FhBLIiSEdkPI+B h3W/EFOk8EtboWAPZb+lnv0ZKA== X-Google-Smtp-Source: APiQypKbM8zHCiBvPk7890MlBrTiuB25FciqWLJe8Xw/gZUPyllw8r+X1ESdySjGpOHYtzHc0OOzhw== X-Received: by 2002:a7b:c2a1:: with SMTP id c1mr9774878wmk.138.1585941115898; Fri, 03 Apr 2020 12:11:55 -0700 (PDT) From: =?UTF-8?q?Alex=20Benn=C3=A9e?= To: qemu-devel@nongnu.org Subject: [PATCH v3 02/12] linux-user: protect fcntl64 with an #ifdef Date: Fri, 3 Apr 2020 20:11:40 +0100 Message-Id: <20200403191150.863-3-alex.bennee@linaro.org> X-Mailer: git-send-email 2.20.1 In-Reply-To: <20200403191150.863-1-alex.bennee@linaro.org> References: <20200403191150.863-1-alex.bennee@linaro.org> MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable X-detected-operating-system: by eggs.gnu.org: Genre and OS details not recognized. X-Received-From: 2a00:1450:4864:20::342 X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Richard Henderson , Riku Voipio , =?UTF-8?q?Alex=20Benn=C3=A9e?= , Laurent Vivier Errors-To: qemu-devel-bounces+importer=patchew.org@nongnu.org Sender: "Qemu-devel" X-ZohoMail-DKIM: fail (Header signature does not verify) Checking TARGET_ABI_BITS is sketchy - we should check for the presence of the define to be sure. Also clean up the white space while we are there. Signed-off-by: Alex Benn=C3=A9e Reviewed-by: Laurent Vivier Reviewed-by: Richard Henderson --- linux-user/syscall.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/linux-user/syscall.c b/linux-user/syscall.c index 5af55fca781..b679bc6b136 100644 --- a/linux-user/syscall.c +++ b/linux-user/syscall.c @@ -11331,11 +11331,11 @@ static abi_long do_syscall1(void *cpu_env, int nu= m, abi_long arg1, This is a hint, so ignoring and returning success is ok. */ return 0; #endif -#if TARGET_ABI_BITS =3D=3D 32 +#ifdef TARGET_NR_fcntl64 case TARGET_NR_fcntl64: { - int cmd; - struct flock64 fl; + int cmd; + struct flock64 fl; from_flock64_fn *copyfrom =3D copy_from_user_flock64; to_flock64_fn *copyto =3D copy_to_user_flock64; =20 @@ -11346,7 +11346,7 @@ static abi_long do_syscall1(void *cpu_env, int num,= abi_long arg1, } #endif =20 - cmd =3D target_to_host_fcntl_cmd(arg2); + cmd =3D target_to_host_fcntl_cmd(arg2); if (cmd =3D=3D -TARGET_EINVAL) { return cmd; } --=20 2.20.1