Re: [PATCH]: Don't force O_LARGEFILE for 32 bit processes on ia64 - 2.6.12-rc3

From: Anton Blanchard (anton_at_samba.org)
Date: 05/10/05

  • Next message: Coywolf Qi Hunt: "Re: kexec?"
    Date:	Tue, 10 May 2005 16:47:17 +1000
    To: Yoav Zach <yoav_zach@yahoo.com>
    
    

    Hi,

    > In ia64 kernel, the O_LARGEFILE flag is forced when
    > opening a file. This is problematic for execution of
    > 32 bit processes, which are not largefile aware, either
    > by SW emulation or by HW execution.
    > For such processes, the problem is two-fold:
    > 1) When trying to open a file that is larger than 4G
    > the operation should fail, but it's not
    > 2) Writing to offset larger than 4G should fail, but
    > it's not
    >
    > The proposed patch takes advantage of the way 32 bit
    > processes are identified in ia64 systems. Such
    > processes have PER_LINUX32 for their personality. With
    > the patch, the ia64 kernel will not enforce the O_LARGEFILE
    > flag if the current process has PER_LINUX32 set.
    > The behavior for all other architectures remains unchanged.

    A 32 bit application should not be using the native open routine.

    Sounds like you have a 64bit emulator running 32bit applications. The
    other 64bit architectures need to be audited to make sure the
    PER_LINUX32 flag is safe to use here.

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


  • Next message: Coywolf Qi Hunt: "Re: kexec?"

    Relevant Pages

    • Re: [PATCH 6/24] make atomic_read() behave consistently on frv
      ... I would assume because we want to waste time efficiently even on non-smp architectures, rather than frying the CPU or draining the battery. ... Certain looping execution patterns can cause the CPU to operate above thermal design power. ...
      (Linux-Kernel)
    • Re: statfs() / statvfs() syscall ballsup...
      ... There have been numerous requests to add a statvfs syscall, ... The problem is that the emulation through statfs cannot be ... The emulation has to get all kinds of additional information ... send the line "unsubscribe linux-kernel" in ...
      (Linux-Kernel)
    • Re: select() for delay.
      ... > three sets empty, n zero, and a non-null timeout as a fairly portable ... > This patch improves the sys_selectexecution when used for delay. ... send the line "unsubscribe linux-kernel" in ...
      (Linux-Kernel)
    • 2.4.23-pre5 crash
      ... Just a quick note to report that my system does not run ... system locks up usually during the execution of the rc ... send the line "unsubscribe linux-kernel" in ...
      (Linux-Kernel)
    • Re: alpha fp-emu vs module refcounting
      ... remove any traces of CONFIG_MATHEMU and modular math emulation? ... * Emulate the floating point instruction at address PC. ... send the line "unsubscribe linux-kernel" in ...
      (Linux-Kernel)