Received: by 2002:a25:8b12:0:0:0:0:0 with SMTP id i18csp3573758ybl; Mon, 12 Aug 2019 02:50:04 -0700 (PDT) X-Google-Smtp-Source: APXvYqy0qCgApkLeblbUPa2332ReVjdTBvcajounlVTa10zRjoNjyA40EfKAk8qrnB0ueMWWDPvl X-Received: by 2002:a17:90a:bb01:: with SMTP id u1mr22114226pjr.92.1565603404115; Mon, 12 Aug 2019 02:50:04 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1565603404; cv=none; d=google.com; s=arc-20160816; b=qrGNvkeUyO2m0j8NgT87MimCVJ8c4/I7amt96FHfL2L/58K2FBsfpRvmORnnBijGat T8a4oMTWeCdgGFauJuIGFMc6zPzFQi1IM89vg7DKorB5VIBwybn/R4yi0I7H52ndzZgu k6mPtyJCw2HR+XKfFawUDdVMUInj8iMRbzeFITBWkj6MPQqTwQ+UZ+rlZEmnPxfU2u5o i1qsxzGWEPcu072br1XtvpYlA6ta4REXXTRDEQ7eNvBPlsyKyTR3+AR+GGc43o/0XxUO UFUQpIhrUn7f6lXIM4YoiQE0WjaDCNEx58T0Av73UX3tUEcUh2tZJmqCQ9jwcoj6lZ/t oY2w== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version; bh=xAybZyOMngteP+D+qSW1GDTJYmxvpwNRj3u8iw1H9iI=; b=pummS6qhxGvySj4S55SfUZxFYvSMNw3IjHw0xuGVOyW+9+keTSL91TwzQC99+qJeXH euyD9db+CX+1eIKJjvXu8ixjEIB/KN8Zk5m9+SpUf2/ZZd2v74Py/cNI09ZlLJEIc2Op OGyCuMXe5TWwWUWjmqCL+8fvbOG1naFswFu6kUCQ80A39DakIYdeolpcW4fQM5QH9kv5 /wx2luEyo2dAWpv0LnS+IKaPpcF/8zJcN84EuHGm+F/lO/2Tg/O7SgmS8CnVWn1zi7j8 GZLy8Kw8MHwA721nAqseIRc5kpYXTKbWHfFef5bxOJvnZukJnlU/jqRk7mMaPynPrDmR u6cg== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id q4si3480477pli.229.2019.08.12.02.49.48; Mon, 12 Aug 2019 02:50:04 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727519AbfHLJtN (ORCPT + 99 others); Mon, 12 Aug 2019 05:49:13 -0400 Received: from mail-qk1-f193.google.com ([209.85.222.193]:43212 "EHLO mail-qk1-f193.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727425AbfHLJtN (ORCPT ); Mon, 12 Aug 2019 05:49:13 -0400 Received: by mail-qk1-f193.google.com with SMTP id m2so12168491qkd.10; Mon, 12 Aug 2019 02:49:12 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=xAybZyOMngteP+D+qSW1GDTJYmxvpwNRj3u8iw1H9iI=; b=rN1aR9JKoiGfcWFGMSnj10dIV201pjpEywckSPKdInPsX53LHC6KaIU/eK+mfRCQBQ jwWi+Q45cwpsV/FHlvG6UTNg6YNKEMBJloJCha2VyarfGHz3SFdTMjmEak7iJHJ5TXen 8nCMFW9ULj2Bvr7F+lDlG/y3LAubOdLwLyPlSN+1qce+kHIbjGCZXc6rKQtrHTlxWLDz D3hZj7fSZl8gl5tW/rGitv1km54YWf39dPwV/fThQaNLPmLJpOfn5kFrm6Ck82bsDdBj cHeBlB55AWuuZXildfVNzEI9ZFw/IQ/7vPd1Ua4FA6DUzknddz5wwqKSiIeWbJLD+9Fq qCfA== X-Gm-Message-State: APjAAAUEnGpXQmHghU84qVzuFNvjkSKi0Fq+4fBNScOPfqjFEyib7E01 CuwZZ9Dyrb02GijKa9kAYzhpiXqhRRPp4MgO5EY= X-Received: by 2002:a37:5f45:: with SMTP id t66mr29267714qkb.286.1565603352161; Mon, 12 Aug 2019 02:49:12 -0700 (PDT) MIME-Version: 1.0 References: <20190810010758.16407-1-alistair.francis@wdc.com> In-Reply-To: <20190810010758.16407-1-alistair.francis@wdc.com> From: Arnd Bergmann Date: Mon, 12 Aug 2019 11:48:55 +0200 Message-ID: Subject: Re: [PATCH] syscalls: Update the syscall #defines to match uapi To: Alistair Francis Cc: Linux Kernel Mailing List , Linux API , Deepa Dinamani , Alistair Francis Content-Type: text/plain; charset="UTF-8" Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Sat, Aug 10, 2019 at 3:11 AM Alistair Francis wrote: > > Update the #defines around sys_fstat64() and sys_fstatat64() to match > the #defines around the __NR3264_fstatat and __NR3264_fstat definitions > in include/uapi/asm-generic/unistd.h. This avoids compiler failures if > one is defined. What is the compiler failure you get? > Signed-off-by: Alistair Francis > --- > include/linux/syscalls.h | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > > diff --git a/include/linux/syscalls.h b/include/linux/syscalls.h > index 2bcef4c70183..e4bf5e480d60 100644 > --- a/include/linux/syscalls.h > +++ b/include/linux/syscalls.h > @@ -512,7 +512,7 @@ asmlinkage long sys_readlinkat(int dfd, const char __user *path, char __user *bu > asmlinkage long sys_newfstatat(int dfd, const char __user *filename, > struct stat __user *statbuf, int flag); > asmlinkage long sys_newfstat(unsigned int fd, struct stat __user *statbuf); > -#if defined(__ARCH_WANT_STAT64) || defined(__ARCH_WANT_COMPAT_STAT64) > +#if defined(__ARCH_WANT_NEW_STAT) || defined(__ARCH_WANT_STAT64) > asmlinkage long sys_fstat64(unsigned long fd, struct stat64 __user *statbuf); > asmlinkage long sys_fstatat64(int dfd, const char __user *filename, > struct stat64 __user *statbuf, int flag); I think this is wrong: when __ARCH_WANT_NEW_STAT is set, we are on a 64-bit architecture and only want the sys_newfstat{,at} system calls, not sys_fstat{,at}64 that gets used on 32-bit machines. The #if check in the syscalls.h file also matches the definition of the function. Arnd