This is the mail archive of the libc-ports@sources.redhat.com mailing list for the libc-ports project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: Remove __ASSUME_VFORK_SYSCALL (and some __NR_vfork conditionals)


On Wed, Jul 25, 2012 at 5:19 PM, Joseph S. Myers
<joseph@codesourcery.com> wrote:
> The __ASSUME_VFORK_SYSCALL macro is only used in architecture-specific
> .S sources, and now defined for all kernel versions on the three
> architectures with such sources using the macro (i386, powerpc, m68k).
> Thus it is redundant and can be removed.  Furthermore, the __NR_vfork
> conditionals in those same sources are also redundant relics of old
> kernel support, since the __NR_vfork macro is defined for those
> architectures as of 2.6.19.1 (the earliest kernel headers version now
> supported).
>
> Thus I propose this patch to remove __ASSUME_VFORK_SYSCALL, and the
> redundant __NR_vfork conditionals in the files being changed.  Tested
> x86.  Could powerpc and m68k maintainers review / test the changes to
> their ports?
>
> (The present sequence of patches aims at removing the __ASSUME_* form
> of support for kernels before, in the end, 2.6.16, with __NR_*
> conditionals being removed only incidentally to the __ASSUME_*
> conditionals removal.  But I might look for unnecessary __NR_*
> conditionals later and would certainly encourage port maintainers to
> clean them up in their ports - I've done so myself for ARM and MIPS.
> If the __NR_* macro is present by 2.6.19.1, for all architectures
> using a given file (directly or indirectly), then the conditionals on
> that macro being defined are not needed in that file.)
>
> 2012-07-25  Joseph Myers  <joseph@codesourcery.com>
>
>         * sysdeps/unix/sysv/linux/kernel-features.h
>         (__ASSUME_VFORK_SYSCALL): Remove all definitions.
>         * sysdeps/unix/sysv/linux/i386/vfork.S (__vfork) [__NR_vfork]:
>         Make code unconditional.
>         (__vfork) [__ASSUME_VFORK_SYSCALL]: Likewise.
>         (__vfork) [!__ASSUME_VFORK_SYSCALL]: Remove conditional code.
>         * sysdeps/unix/sysv/linux/powerpc/powerpc32/vfork.S (__vfork)
>         [__NR_vfork]: Make code unconditional.
>         (__vfork) [__ASSUME_VFORK_SYSCALL]: Likewise.
>         (__vfork) [!__ASSUME_VFORK_SYSCALL]: Remove conditional code.
>         * sysdeps/unix/sysv/linux/powerpc/powerpc64/vfork.S (__vfork)
>         [__NR_vfork]: Make code unconditional.
>         (__vfork) [__ASSUME_VFORK_SYSCALL]: Likewise.
>         (__vfork) [!__ASSUME_VFORK_SYSCALL]: Remove conditional code.
>
> ports/ChangeLog.arm:
> 2012-07-25  Joseph Myers  <joseph@codesourcery.com>
>
>         * sysdeps/unix/sysv/linux/arm/kernel-features.h
>         (__ASSUME_VFORK_SYSCALL: Remove.
>
> ports/ChangeLog.m68k:
> 2012-07-25  Joseph Myers  <joseph@codesourcery.com>
>
>         * sysdeps/unix/sysv/linux/m68k/kernel-features.h
>         (__ASSUME_VFORK_SYSCALL): Remove.
>         * sysdeps/unix/sysv/linux/m68k/vfork.S (__vfork) [__NR_vfork]:
>         Make code unconditional.
>         (__vfork) [__ASSUME_VFORK_SYSCALL]: Likewise.
>         (__vfork) [!__ASSUME_VFORK_SYSCALL]: Remove conditional code.

Tested on powerpc32 and powerpc64 and no new regressions were identified.

Ryan S. Arnold


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]