diff options
author | Joseph Myers <joseph@codesourcery.com> | 2018-03-26 21:18:28 +0000 |
---|---|---|
committer | Joseph Myers <joseph@codesourcery.com> | 2018-03-26 21:18:28 +0000 |
commit | 5f45f96ad09d7f80172b45dca16d6ca2baeea2a8 (patch) | |
tree | 93391daa4c42335942f9f9da90fd7a08f0a2760a /sysdeps/unix/sysv/linux/umount.S | |
parent | 3dfd23eb4bdc7707048b115548e2238dacef064e (diff) | |
download | glibc-5f45f96ad09d7f80172b45dca16d6ca2baeea2a8.tar.gz glibc-5f45f96ad09d7f80172b45dca16d6ca2baeea2a8.tar.xz glibc-5f45f96ad09d7f80172b45dca16d6ca2baeea2a8.zip |
Unify umount function implementations (bug 16552).
Linux kernel architectures have various arrangements for umount syscalls. There is a syscall that takes flags, and an older one that does not. Newer architectures have only the one taking flags, under the name umount2 (or under the name umount, in the ia64 case). Older architectures may have both, under the names umount2 and umount (or under the names umount and oldumount, in the alpha case). glibc then has several similar implementations of the umount function (no flags) in terms of either the __umount2 function, or the corresponding syscall, or in terms of the old syscall under either of its names. This patch simplifies the implementations in glibc by always using the __umount2 function to implement the umount function on all systems using the Linux kernel. The linux/generic implementation is moved to sysdeps/unix/sysv/linux (without any changes to code or comments) and all the other variants are removed. (This will have the effect of causing the new syscall to be used in some cases that previously used the old one, but as discussed for previous changes, such a change to the underlying syscalls used is OK.) There remain two variants of how the __umount2 function is implemented, either in umount2.S, or, for ia64, in syscalls.list. Tested with build-many-glibcs.py. [BZ #16552] * sysdeps/unix/sysv/linux/generic/umount.c: Move to .... * sysdeps/unix/sysv/linux/umount.c: ... here. * sysdeps/unix/sysv/linux/arm/umount.c: Remove file. * sysdeps/unix/sysv/linux/hppa/umount.c: Likewise. * sysdeps/unix/sysv/linux/ia64/umount.c: Likewise. * sysdeps/unix/sysv/linux/mips/mips64/umount.c: Likewise. * sysdeps/unix/sysv/linux/powerpc/powerpc64/umount.c: Likewise. * sysdeps/unix/sysv/linux/umount.S: Likewise. * sysdeps/unix/sysv/linux/x86_64/umount.c: Likewise.
Diffstat (limited to 'sysdeps/unix/sysv/linux/umount.S')
-rw-r--r-- | sysdeps/unix/sysv/linux/umount.S | 12 |
1 files changed, 0 insertions, 12 deletions
diff --git a/sysdeps/unix/sysv/linux/umount.S b/sysdeps/unix/sysv/linux/umount.S deleted file mode 100644 index e18463e2e6..0000000000 --- a/sysdeps/unix/sysv/linux/umount.S +++ /dev/null @@ -1,12 +0,0 @@ -/* This hack is necessary since the kernel people are making "strange" - changes. They simply rename old system calls. */ - -#include <sysdep.h> -#ifdef __NR_oldumount -PSEUDO (__umount, oldumount, 1) -#else -PSEUDO (__umount, umount, 1) -#endif - ret -PSEUDO_END(__umount) -weak_alias (__umount, umount) |