From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 9186 invoked by alias); 11 Jul 2005 11:13:26 -0000 Mailing-List: contact libc-hacker-help@sources.redhat.com; run by ezmlm Precedence: bulk List-Subscribe: List-Archive: List-Post: List-Help: , Sender: libc-hacker-owner@sources.redhat.com Received: (qmail 9170 invoked by uid 22791); 11 Jul 2005 11:13:25 -0000 Received: from mtagate2.de.ibm.com (HELO mtagate2.de.ibm.com) (195.212.29.151) by sourceware.org (qpsmtpd/0.30-dev) with ESMTP; Mon, 11 Jul 2005 11:13:25 +0000 Received: from d12nrmr1607.megacenter.de.ibm.com (d12nrmr1607.megacenter.de.ibm.com [9.149.167.49]) by mtagate2.de.ibm.com (8.12.10/8.12.10) with ESMTP id j6BBDNew224350 for ; Mon, 11 Jul 2005 11:13:23 GMT Received: from d12av02.megacenter.de.ibm.com (d12av02.megacenter.de.ibm.com [9.149.165.228]) by d12nrmr1607.megacenter.de.ibm.com (8.12.10/NCO/VER6.6) with ESMTP id j6BBDNhF155658 for ; Mon, 11 Jul 2005 13:13:23 +0200 Received: from d12av02.megacenter.de.ibm.com (loopback [127.0.0.1]) by d12av02.megacenter.de.ibm.com (8.12.11/8.13.3) with ESMTP id j6BBDNgx009405 for ; Mon, 11 Jul 2005 13:13:23 +0200 Received: from localhost.localdomain (dyn-9-152-216-41.boeblingen.de.ibm.com [9.152.216.41]) by d12av02.megacenter.de.ibm.com (8.12.11/8.12.11) with ESMTP id j6BBDNgX009402 for ; Mon, 11 Jul 2005 13:13:23 +0200 Received: from sky by localhost.localdomain with local (Exim 3.36 #1 (Debian)) id 1DrwDz-0002bq-00 for ; Mon, 11 Jul 2005 13:13:23 +0200 Date: Mon, 11 Jul 2005 11:13:00 -0000 From: Martin Schwidefsky To: libc-hacker@sources.redhat.com Subject: [PATCH] POSIX_FADV_{DONTNEED,NOREUSE} defines on s390-64. Message-ID: <20050711111323.GA9994@localhost.localdomain> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline User-Agent: Mutt/1.5.9i X-SW-Source: 2005-07/txt/msg00005.txt.bz2 Hi, our testers noticed that the definitions of POSIX_FADV_DONTNEED and POSIX_FADV_NOREUSE of the glibc and the linux kernel differ. There are two options to fix this problem: in the glibc or in the kernel. I considered this for a while and came to the conclusion that this is better fixed in the glibc. To fix this in the kernel I'd need to analyse the arguments of the compat fadvise system call and change the 31 bit defines to the 64 bit defines. The 64 bit applications that are currently using DONTNEED and NOREUSE always get -EINVAL. Nobody complained so far. blue skies, Martin. 2005-07-11 sky * sysdeps/unix/sysv/linux/s390/bits/fcntl.h (POSIX_FADV_DONTNEED, POSIX_FADV_NOREUSE): Use correct values for s390-64. diff -urpN libc/sysdeps/unix/sysv/linux/s390/bits/fcntl.h libc-s390/sysdeps/unix/sysv/linux/s390/bits/fcntl.h --- libc/sysdeps/unix/sysv/linux/s390/bits/fcntl.h 2004-08-23 09:28:45.000000000 +0200 +++ libc-s390/sysdeps/unix/sysv/linux/s390/bits/fcntl.h 2005-07-11 12:34:36.000000000 +0200 @@ -190,13 +190,8 @@ struct flock64 # define POSIX_FADV_RANDOM 1 /* Expect random page references. */ # define POSIX_FADV_SEQUENTIAL 2 /* Expect sequential page references. */ # define POSIX_FADV_WILLNEED 3 /* Will need these pages. */ -# if __WORDSIZE == 64 -# define POSIX_FADV_DONTNEED 6 /* Don't need these pages. */ -# define POSIX_FADV_NOREUSE 7 /* Data will be accessed once. */ -# else -# define POSIX_FADV_DONTNEED 4 /* Don't need these pages. */ -# define POSIX_FADV_NOREUSE 5 /* Data will be accessed once. */ -# endif +# define POSIX_FADV_DONTNEED 4 /* Don't need these pages. */ +# define POSIX_FADV_NOREUSE 5 /* Data will be accessed once. */ #endif __BEGIN_DECLS