[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
09/09: file-systems: Add support for 'strict-atime' and 'lazy-time' flag
From: |
guix-commits |
Subject: |
09/09: file-systems: Add support for 'strict-atime' and 'lazy-time' flags. |
Date: |
Fri, 6 Dec 2019 19:02:38 -0500 (EST) |
civodul pushed a commit to branch master
in repository guix.
commit 0dc5c85638b49d5aed043420346083935ac51435
Author: Guillaume Le Vaillant <address@hidden>
Date: Tue Dec 3 10:31:08 2019 +0100
file-systems: Add support for 'strict-atime' and 'lazy-time' flags.
* guix/build/syscalls.scm (MS_LAZYTIME): New variable.
* gnu/build/file-systems.scm (mount-flags->bit-mask): Add match rules for
'strict-atime' and 'lazy-time'.
* doc/guix.texi (File Systems): Add 'strict-atime' and 'lazy-time' to the
list
of supported flags.
Signed-off-by: Ludovic Courtès <address@hidden>
---
doc/guix.texi | 9 ++++++---
gnu/build/file-systems.scm | 5 +++++
guix/build/syscalls.scm | 3 +++
3 files changed, 14 insertions(+), 3 deletions(-)
diff --git a/doc/guix.texi b/doc/guix.texi
index 84548b1..446534c 100644
--- a/doc/guix.texi
+++ b/doc/guix.texi
@@ -11244,9 +11244,12 @@ corresponding device mapping established.
This is a list of symbols denoting mount flags. Recognized flags
include @code{read-only}, @code{bind-mount}, @code{no-dev} (disallow
access to special files), @code{no-suid} (ignore setuid and setgid
-bits), @code{no-atime} (do not update file access times), and @code{no-exec}
-(disallow program execution). @xref{Mount-Unmount-Remount,,, libc, The GNU C
-Library Reference Manual}, for more information on these flags.
+bits), @code{no-atime} (do not update file access times),
+@code{strict-atime} (update file access time), @code{lazy-time} (only
+update time on the in-memory version of the file inode), and
+@code{no-exec} (disallow program execution).
+@xref{Mount-Unmount-Remount,,, libc, The GNU C Library Reference
+Manual}, for more information on these flags.
@item @code{options} (default: @code{#f})
This is either @code{#f}, or a string denoting mount options passed to the
diff --git a/gnu/build/file-systems.scm b/gnu/build/file-systems.scm
index cb90fa0..13c44aa 100644
--- a/gnu/build/file-systems.scm
+++ b/gnu/build/file-systems.scm
@@ -2,6 +2,7 @@
;;; Copyright © 2014, 2015, 2016, 2017, 2018 Ludovic Courtès <address@hidden>
;;; Copyright © 2016, 2017 David Craven <address@hidden>
;;; Copyright © 2017 Mathieu Othacehe <address@hidden>
+;;; Copyright © 2019 Guillaume Le Vaillant <address@hidden>
;;;
;;; This file is part of GNU Guix.
;;;
@@ -577,6 +578,10 @@ corresponds to the symbols listed in FLAGS."
(logior MS_NOEXEC (loop rest)))
(('no-atime rest ...)
(logior MS_NOATIME (loop rest)))
+ (('strict-atime rest ...)
+ (logior MS_STRICTATIME (loop rest)))
+ (('lazy-time rest ...)
+ (logior MS_LAZYTIME (loop rest)))
(()
0))))
diff --git a/guix/build/syscalls.scm b/guix/build/syscalls.scm
index ce7999b..248d676 100644
--- a/guix/build/syscalls.scm
+++ b/guix/build/syscalls.scm
@@ -3,6 +3,7 @@
;;; Copyright © 2015 David Thompson <address@hidden>
;;; Copyright © 2015 Mark H Weaver <address@hidden>
;;; Copyright © 2017 Mathieu Othacehe <address@hidden>
+;;; Copyright © 2019 Guillaume Le Vaillant <address@hidden>
;;;
;;; This file is part of GNU Guix.
;;;
@@ -43,6 +44,7 @@
MS_BIND
MS_MOVE
MS_STRICTATIME
+ MS_LAZYTIME
MNT_FORCE
MNT_DETACH
MNT_EXPIRE
@@ -451,6 +453,7 @@ the returned procedure is called."
(define MS_BIND 4096)
(define MS_MOVE 8192)
(define MS_STRICTATIME 16777216)
+(define MS_LAZYTIME 33554432)
(define MNT_FORCE 1)
(define MNT_DETACH 2)
- branch master updated (1b3fa12 -> 0dc5c85), guix-commits, 2019/12/06
- 03/09: system: Remove custom 'config-file service from "vm-image.tmpl"., guix-commits, 2019/12/06
- 04/09: services: Add 'provenance-service-type'., guix-commits, 2019/12/06
- 02/09: derivations: Add 'derivation-input-fold'., guix-commits, 2019/12/06
- 01/09: machine: ssh: Deprecate missing 'host-key' field., guix-commits, 2019/12/06
- 07/09: guix system: "list-generations" displays provenance info., guix-commits, 2019/12/06
- 06/09: machine: Add provenance tracking to each machine operating system., guix-commits, 2019/12/06
- 09/09: file-systems: Add support for 'strict-atime' and 'lazy-time' flags.,
guix-commits <=
- 08/09: guix system: Add "describe" action., guix-commits, 2019/12/06
- 05/09: guix system: Use 'provenance-service-type', add "--save-provenance"., guix-commits, 2019/12/06