about summary refs log tree commit diff
diff options
context:
space:
mode:
-rw-r--r--ChangeLog4
-rw-r--r--sysdeps/unix/sysv/linux/bits/statvfs.h6
-rw-r--r--sysdeps/unix/sysv/linux/internal_statvfs.c4
3 files changed, 11 insertions, 3 deletions
diff --git a/ChangeLog b/ChangeLog
index 1cbf7bd20e..53b8f3d8ba 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,5 +1,9 @@
 2006-12-13  Ulrich Drepper  <drepper@redhat.com>
 
+	* sysdeps/unix/sysv/linux/bits/statvfs.h: Define ST_RELATIME.
+	* sysdeps/unix/sysv/linux/internal_statvfs.c (__statvfs_getflags):
+	Handle relatime mount option.
+
 	[BZ #2337]
 	* libio/Makefile (tests): Add tst-setvbuf1.
 	* libio/tst-setvbuf1.c: New file.
diff --git a/sysdeps/unix/sysv/linux/bits/statvfs.h b/sysdeps/unix/sysv/linux/bits/statvfs.h
index cca0871ac0..84717c3d96 100644
--- a/sysdeps/unix/sysv/linux/bits/statvfs.h
+++ b/sysdeps/unix/sysv/linux/bits/statvfs.h
@@ -1,4 +1,4 @@
-/* Copyright (C) 1997, 1998, 2000, 2001, 2002 Free Software Foundation, Inc.
+/* Copyright (C) 1997,1998,2000,2001,2002,2006 Free Software Foundation, Inc.
    This file is part of the GNU C Library.
 
    The GNU C Library is free software; you can redistribute it and/or
@@ -101,7 +101,9 @@ enum
 # define ST_IMMUTABLE	ST_IMMUTABLE
   ST_NOATIME = 1024,		/* Do not update access times.  */
 # define ST_NOATIME	ST_NOATIME
-  ST_NODIRATIME = 2048		/* Do not update directory access times.  */
+  ST_NODIRATIME = 2048,		/* Do not update directory access times.  */
 # define ST_NODIRATIME	ST_NODIRATIME
+  ST_RELATIME = 4096		/* Update atime relative to mtime/ctime.  */
+# define ST_RELATIME	ST_RELATIME
 #endif	/* Use GNU.  */
 };
diff --git a/sysdeps/unix/sysv/linux/internal_statvfs.c b/sysdeps/unix/sysv/linux/internal_statvfs.c
index 73317ecafd..28c1cb691f 100644
--- a/sysdeps/unix/sysv/linux/internal_statvfs.c
+++ b/sysdeps/unix/sysv/linux/internal_statvfs.c
@@ -1,4 +1,4 @@
-/* Copyright (C) 1998-2003, 2004, 2005 Free Software Foundation, Inc.
+/* Copyright (C) 1998-2003, 2004, 2005, 2006 Free Software Foundation, Inc.
    This file is part of the GNU C Library.
    Contributed by Ulrich Drepper <drepper@cygnus.com>, 1998.
 
@@ -156,6 +156,8 @@ __statvfs_getflags (const char *name, int fstype, struct stat64 *st)
 		  result |= ST_NOATIME;
 		else if (strcmp (opt, "nodiratime") == 0)
 		  result |= ST_NODIRATIME;
+		else if (strcmp (opt, "relatime") == 0)
+		  result |= ST_RELATIME;
 
 	      /* We can stop looking for more entries.  */
 	      success = true;