[Acked] [PATCH Trusty SRU] UBUNTU: SAUCE: (no-up) powerpc: 64bit sendfile is capped at 2GB

Andy Whitcroft apw at canonical.com
Tue Jun 10 09:03:50 UTC 2014


On Mon, Jun 09, 2014 at 01:10:19PM -0600, Tim Gardner wrote:
> 
> -- 
> Tim Gardner tim.gardner at canonical.com

> From 8bfe8d32bddc1b1f2c7f9eca4af4e13e72c76bad Mon Sep 17 00:00:00 2001
> From: Anton Blanchard <anton at samba.org>
> Date: Wed, 4 Jun 2014 10:48:48 +1000
> Subject: [PATCH Trusty SRU] UBUNTU: SAUCE: (no-up) powerpc: 64bit sendfile is capped at 2GB
> 
> BugLink: http://bugs.launchpad.net/bugs/1328230
> 
> commit 8f9c0119d7ba (compat: fs: Generic compat_sys_sendfile
> implementation) changed the PowerPC 64bit sendfile call from
> sys_sendile64 to sys_sendfile.
> 
> Unfortunately this broke sendfile of lengths greater than 2G because
> sys_sendfile caps at MAX_NON_LFS. Restore what we had previously which
> fixes the bug.
> 
> Cc: stable at vger.kernel.org
> Signed-off-by: Anton Blanchard <anton at samba.org>
> Signed-off-by: Tim Gardner <tim.gardner at canonical.com>
> ---
>  arch/powerpc/include/asm/systbl.h | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/arch/powerpc/include/asm/systbl.h b/arch/powerpc/include/asm/systbl.h
> index 43523fe..05fcdd8 100644
> --- a/arch/powerpc/include/asm/systbl.h
> +++ b/arch/powerpc/include/asm/systbl.h
> @@ -190,7 +190,7 @@ SYSCALL_SPU(getcwd)
>  SYSCALL_SPU(capget)
>  SYSCALL_SPU(capset)
>  COMPAT_SYS(sigaltstack)
> -COMPAT_SYS_SPU(sendfile)
> +SYSX_SPU(sys_sendfile64,compat_sys_sendfile,sys_sendfile)
>  SYSCALL(ni_syscall)
>  SYSCALL(ni_syscall)
>  PPC_SYS(vfork)

Looks to do something sensible. 

Acked-by: Andy Whitcroft <apw at canonical.com>

-apw




More information about the kernel-team mailing list