about summary refs log tree commit diff
path: root/ChangeLog
diff options
context:
space:
mode:
authorAurelien Jarno <aurelien@aurel32.net>2018-01-05 20:34:10 +0100
committerAurelien Jarno <aurelien@aurel32.net>2018-01-05 20:34:10 +0100
commit0d0bc784cafcd27f1cf9584b2424fcfbf07b24f6 (patch)
tree1c751d50235ba8acc7e9f6fc368eea3aef6b0bef /ChangeLog
parentf1a844ac6389ea4e111afc019323ca982b5b027d (diff)
downloadglibc-0d0bc784cafcd27f1cf9584b2424fcfbf07b24f6.tar.gz
glibc-0d0bc784cafcd27f1cf9584b2424fcfbf07b24f6.tar.xz
glibc-0d0bc784cafcd27f1cf9584b2424fcfbf07b24f6.zip
Alpha: Add wrappers to get/setrlimit64 to fix RLIM64_INFINITY constant [BZ #22648]
RLIM64_INFINITY was supposed to be a glibc convention rather than
anything seen by the kernel, but it ended being passed to the kernel
through the prlimit64 syscall.

* On the kernel side, the value is defined for the prlimit64 syscall for
  all architectures in include/uapi/linux/resource.h:

  #define RLIM64_INFINITY           (~0ULL)

* On the kernel side, the value is defined for getrlimit and setrlimit
  in arch/alpha/include/uapi/asm/resource.h

  #define RLIM_INFINITY            0x7ffffffffffffffful

* On the GNU libc side, the value is defined in
  sysdeps/unix/sysv/linux/alpha/bits/resource.h:

  # define RLIM64_INFINITY 0x7fffffffffffffffLL

This was not an issue until the getrlimit and setrlimit glibc functions
have been changed in commit 045c13d185 ("Consolidate Linux setrlimit and
getrlimit implementation") to use the prlimit64 syscall instead of the
getrlimit and setrlimit ones.

This patch fixes that by adding a wrapper to fix the value passed to or
received from the kernel, before or after calling the prlimit64 syscall.

Changelog:
	[BZ #22648]
	* sysdeps/unix/sysv/linux/alpha/getrlimit64.c: New file.
	* sysdeps/unix/sysv/linux/alpha/setrlimit64.c: Ditto.
Diffstat (limited to 'ChangeLog')
-rw-r--r--ChangeLog6
1 files changed, 6 insertions, 0 deletions
diff --git a/ChangeLog b/ChangeLog
index ddd49200ed..489cd1fd84 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,9 @@
+2018-01-05  Aurelien Jarno  <aurelien@aurel32.net>
+
+	[BZ #22648]
+	* sysdeps/unix/sysv/linux/alpha/getrlimit64.c: New file.
+	* sysdeps/unix/sysv/linux/alpha/setrlimit64.c: Ditto.
+
 2018-01-04  Joseph Myers  <joseph@codesourcery.com>
 
 	* malloc/tst-malloc-tcache-leak.c (TIMEOUT): Define to 50.