lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <1316269758.31335.0.camel@edumazet-laptop>
Date:	Sat, 17 Sep 2011 16:29:18 +0200
From:	Eric Dumazet <eric.dumazet@...il.com>
To:	Thomas Meyer <thomas@...3r.de>
Cc:	Andi Kleen <andi@...stfloor.org>,
	Linux Kernel Mailing List <linux-kernel@...r.kernel.org>
Subject: Re: [PATCH] sys_poll: Fix negative timeout values for x86 userland
 on x86_64 kernels

Le samedi 17 septembre 2011 à 14:30 +0200, Thomas Meyer a écrit :
> sizeof(int/long) differs on x86 and x86_64, so provide a compat_sys_poll().
> 

Please provide a more descriptive Changelog, since this is a stable
candidate patch.



> Signed-off-by: Thomas Meyer <thomas@...3r.de>
> ---
>  arch/x86/ia32/ia32entry.S |    2 +-
>  fs/compat.c               |    6 ++++++
>  include/linux/compat.h    |    2 ++
>  3 files changed, 9 insertions(+), 1 deletions(-)
> 
> diff --git a/arch/x86/ia32/ia32entry.S b/arch/x86/ia32/ia32entry.S
> index 54edb207..30f4116 100644
> --- a/arch/x86/ia32/ia32entry.S
> +++ b/arch/x86/ia32/ia32entry.S
> @@ -671,7 +671,7 @@ ia32_sys_call_table:
>  	.quad sys_getresuid16	/* 165 */
>  	.quad sys32_vm86_warning	/* vm86 */ 
>  	.quad quiet_ni_syscall	/* query_module */
> -	.quad sys_poll
> +	.quad compat_sys_poll
>  	.quad quiet_ni_syscall /* old nfsservctl */
>  	.quad sys_setresgid16	/* 170 */
>  	.quad sys_getresgid16
> diff --git a/fs/compat.c b/fs/compat.c
> index 58b1da4..f176fda 100644
> --- a/fs/compat.c
> +++ b/fs/compat.c
> @@ -1621,6 +1621,12 @@ asmlinkage long compat_sys_pselect6(int n, compat_ulong_t __user *inp,
>  				 sigsetsize);
>  }
>  
> +asmlinkage long compat_sys_poll(struct pollfd __user *ufds, unsigned int nfds,
> +				int timeout)
> +{
> +	return sys_poll(ufds, nfds, timeout);
> +}
> +
>  asmlinkage long compat_sys_ppoll(struct pollfd __user *ufds,
>  	unsigned int nfds, struct compat_timespec __user *tsp,
>  	const compat_sigset_t __user *sigmask, compat_size_t sigsetsize)
> diff --git a/include/linux/compat.h b/include/linux/compat.h
> index c6e7523..3bfb30a 100644
> --- a/include/linux/compat.h
> +++ b/include/linux/compat.h
> @@ -433,6 +433,8 @@ asmlinkage long compat_sys_pselect6(int n, compat_ulong_t __user *inp,
>  				    compat_ulong_t __user *exp,
>  				    struct compat_timespec __user *tsp,
>  				    void __user *sig);
> +asmlinkage long compat_sys_poll(struct pollfd __user *ufds, unsigned int nfds,
> +				int timeout);
>  asmlinkage long compat_sys_ppoll(struct pollfd __user *ufds,
>  				 unsigned int nfds,
>  				 struct compat_timespec __user *tsp,


--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ