From: Andrew Morton <akpm@linux-foundation.org>
To: Catalin Marinas <catalin.marinas@arm.com>
Cc: linux-arm-kernel@lists.infradead.org,
linux-kernel@vger.kernel.org, Arnd Bergmann <arnd@arndb.de>
Subject: Re: [PATCH 2/5] syscalls: Declare sys_*stat64 prototypes if __ARCH_WANT_(COMPAT_)STAT64
Date: Mon, 26 Jan 2015 13:49:19 -0800 [thread overview]
Message-ID: <20150126134919.ea59b69ae1c0b62188bdbdd0@linux-foundation.org> (raw)
In-Reply-To: <1420819048-3515-3-git-send-email-catalin.marinas@arm.com>
On Fri, 9 Jan 2015 15:57:25 +0000 Catalin Marinas <catalin.marinas@arm.com> wrote:
> Currently, the sys_stat64, sys_fstat64 and sys_lstat64 prototpyes are
> only declared if BITS_PER_LONG == 32. Following commit 0753f70f07fb
> (fs: Build sys_stat64() and friends if __ARCH_WANT_COMPAT_STAT64), the
> implementation of these functions is allowed on 64-bit systems for
> compat support. The patch changes the condition on the prototype
> declaration from BITS_PER_LONG == 32 to defined(__ARCH_WANT_STAT64) ||
> defined(__ARCH_WANT_COMPAT_STAT64).
>
> In addition, it moves the sys_fstatat64 prototype under the same #if
> block
>
> ...
>
> --- a/include/linux/syscalls.h
> +++ b/include/linux/syscalls.h
> @@ -410,12 +410,16 @@ asmlinkage long sys_newlstat(const char __user *filename,
> struct stat __user *statbuf);
> asmlinkage long sys_newfstat(unsigned int fd, struct stat __user *statbuf);
> asmlinkage long sys_ustat(unsigned dev, struct ustat __user *ubuf);
> -#if BITS_PER_LONG == 32
> +#if defined(__ARCH_WANT_STAT64) || defined(__ARCH_WANT_COMPAT_STAT64)
> asmlinkage long sys_stat64(const char __user *filename,
> struct stat64 __user *statbuf);
> asmlinkage long sys_fstat64(unsigned long fd, struct stat64 __user *statbuf);
> asmlinkage long sys_lstat64(const char __user *filename,
> struct stat64 __user *statbuf);
> +asmlinkage long sys_fstatat64(int dfd, const char __user *filename,
> + struct stat64 __user *statbuf, int flag);
> +#endif
> +#if BITS_PER_LONG == 32
> asmlinkage long sys_truncate64(const char __user *path, loff_t length);
> asmlinkage long sys_ftruncate64(unsigned int fd, loff_t length);
ack. sys_stat64() and friends are already conditional on
__ARCH_WANT_STAT64) && __ARCH_WANT_COMPAT_STAT64. I'm a bit
surprised that the current code didn't break.
next prev parent reply other threads:[~2015-01-26 21:49 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-01-09 15:57 [PATCH 0/5] arm64 compat syscall table clean-up Catalin Marinas
2015-01-09 15:57 ` [PATCH 1/5] compat: Declare compat_sys_sigpending and compat_sys_sigprocmask prototypes Catalin Marinas
2015-01-26 17:32 ` Catalin Marinas
2015-01-26 21:48 ` Andrew Morton
2015-01-09 15:57 ` [PATCH 2/5] syscalls: Declare sys_*stat64 prototypes if __ARCH_WANT_(COMPAT_)STAT64 Catalin Marinas
2015-01-26 17:31 ` Catalin Marinas
2015-01-26 21:49 ` Andrew Morton [this message]
2015-01-09 15:57 ` [PATCH 3/5] arm64: Implement the compat_sys_call_table in C Catalin Marinas
2015-01-09 15:57 ` [PATCH 4/5] arm64: Remove asm/syscalls.h Catalin Marinas
2015-01-09 15:57 ` [PATCH 5/5] arm64: make sys_call_table const Catalin Marinas
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20150126134919.ea59b69ae1c0b62188bdbdd0@linux-foundation.org \
--to=akpm@linux-foundation.org \
--cc=arnd@arndb.de \
--cc=catalin.marinas@arm.com \
--cc=linux-arm-kernel@lists.infradead.org \
--cc=linux-kernel@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®