diff options
Diffstat (limited to 'Documentation/filesystems')
| -rw-r--r-- | Documentation/filesystems/f2fs.rst | 70 | ||||
| -rw-r--r-- | Documentation/filesystems/fsverity.rst | 35 | ||||
| -rw-r--r-- | Documentation/filesystems/proc.rst | 92 | ||||
| -rw-r--r-- | Documentation/filesystems/zonefs.rst | 52 | 
4 files changed, 80 insertions, 169 deletions
| diff --git a/Documentation/filesystems/f2fs.rst b/Documentation/filesystems/f2fs.rst index 4a2426f0485a..ad8dc8c040a2 100644 --- a/Documentation/filesystems/f2fs.rst +++ b/Documentation/filesystems/f2fs.rst @@ -235,12 +235,6 @@ offgrpjquota		 Turn off group journalled quota.  offprjjquota		 Turn off project journalled quota.  quota			 Enable plain user disk quota accounting.  noquota			 Disable all plain disk quota option. -whint_mode=%s		 Control which write hints are passed down to block -			 layer. This supports "off", "user-based", and -			 "fs-based".  In "off" mode (default), f2fs does not pass -			 down hints. In "user-based" mode, f2fs tries to pass -			 down hints given by users. And in "fs-based" mode, f2fs -			 passes down hints with its policy.  alloc_mode=%s		 Adjust block allocation policy, which supports "reuse"  			 and "default".  fsync_mode=%s		 Control the policy of fsync. Currently supports "posix", @@ -751,70 +745,6 @@ In order to identify whether the data in the victim segment are valid or not,  F2FS manages a bitmap. Each bit represents the validity of a block, and the  bitmap is composed of a bit stream covering whole blocks in main area. -Write-hint Policy ------------------ - -1) whint_mode=off. F2FS only passes down WRITE_LIFE_NOT_SET. - -2) whint_mode=user-based. F2FS tries to pass down hints given by -users. - -===================== ======================== =================== -User                  F2FS                     Block -===================== ======================== =================== -N/A                   META                     WRITE_LIFE_NOT_SET -N/A                   HOT_NODE                 " -N/A                   WARM_NODE                " -N/A                   COLD_NODE                " -ioctl(COLD)           COLD_DATA                WRITE_LIFE_EXTREME -extension list        "                        " - --- buffered io -WRITE_LIFE_EXTREME    COLD_DATA                WRITE_LIFE_EXTREME -WRITE_LIFE_SHORT      HOT_DATA                 WRITE_LIFE_SHORT -WRITE_LIFE_NOT_SET    WARM_DATA                WRITE_LIFE_NOT_SET -WRITE_LIFE_NONE       "                        " -WRITE_LIFE_MEDIUM     "                        " -WRITE_LIFE_LONG       "                        " - --- direct io -WRITE_LIFE_EXTREME    COLD_DATA                WRITE_LIFE_EXTREME -WRITE_LIFE_SHORT      HOT_DATA                 WRITE_LIFE_SHORT -WRITE_LIFE_NOT_SET    WARM_DATA                WRITE_LIFE_NOT_SET -WRITE_LIFE_NONE       "                        WRITE_LIFE_NONE -WRITE_LIFE_MEDIUM     "                        WRITE_LIFE_MEDIUM -WRITE_LIFE_LONG       "                        WRITE_LIFE_LONG -===================== ======================== =================== - -3) whint_mode=fs-based. F2FS passes down hints with its policy. - -===================== ======================== =================== -User                  F2FS                     Block -===================== ======================== =================== -N/A                   META                     WRITE_LIFE_MEDIUM; -N/A                   HOT_NODE                 WRITE_LIFE_NOT_SET -N/A                   WARM_NODE                " -N/A                   COLD_NODE                WRITE_LIFE_NONE -ioctl(COLD)           COLD_DATA                WRITE_LIFE_EXTREME -extension list        "                        " - --- buffered io -WRITE_LIFE_EXTREME    COLD_DATA                WRITE_LIFE_EXTREME -WRITE_LIFE_SHORT      HOT_DATA                 WRITE_LIFE_SHORT -WRITE_LIFE_NOT_SET    WARM_DATA                WRITE_LIFE_LONG -WRITE_LIFE_NONE       "                        " -WRITE_LIFE_MEDIUM     "                        " -WRITE_LIFE_LONG       "                        " - --- direct io -WRITE_LIFE_EXTREME    COLD_DATA                WRITE_LIFE_EXTREME -WRITE_LIFE_SHORT      HOT_DATA                 WRITE_LIFE_SHORT -WRITE_LIFE_NOT_SET    WARM_DATA                WRITE_LIFE_NOT_SET -WRITE_LIFE_NONE       "                        WRITE_LIFE_NONE -WRITE_LIFE_MEDIUM     "                        WRITE_LIFE_MEDIUM -WRITE_LIFE_LONG       "                        WRITE_LIFE_LONG -===================== ======================== =================== -  Fallocate(2) Policy  ------------------- diff --git a/Documentation/filesystems/fsverity.rst b/Documentation/filesystems/fsverity.rst index 8cc536d08f51..b7d42fd65e9d 100644 --- a/Documentation/filesystems/fsverity.rst +++ b/Documentation/filesystems/fsverity.rst @@ -70,12 +70,23 @@ must live on a read-write filesystem because they are independently  updated and potentially user-installed, so dm-verity cannot be used.  The base fs-verity feature is a hashing mechanism only; actually -authenticating the files is up to userspace.  However, to meet some -users' needs, fs-verity optionally supports a simple signature -verification mechanism where users can configure the kernel to require -that all fs-verity files be signed by a key loaded into a keyring; see -`Built-in signature verification`_.  Support for fs-verity file hashes -in IMA (Integrity Measurement Architecture) policies is also planned. +authenticating the files may be done by: + +* Userspace-only + +* Builtin signature verification + userspace policy + +  fs-verity optionally supports a simple signature verification +  mechanism where users can configure the kernel to require that +  all fs-verity files be signed by a key loaded into a keyring; +  see `Built-in signature verification`_. + +* Integrity Measurement Architecture (IMA) + +  IMA supports including fs-verity file digests and signatures in the +  IMA measurement list and verifying fs-verity based file signatures +  stored as security.ima xattrs, based on policy. +  User API  ======== @@ -653,12 +664,12 @@ weren't already directly answered in other parts of this document.      hashed and what to do with those hashes, such as log them,      authenticate them, or add them to a measurement list. -    IMA is planned to support the fs-verity hashing mechanism as an -    alternative to doing full file hashes, for people who want the -    performance and security benefits of the Merkle tree based hash. -    But it doesn't make sense to force all uses of fs-verity to be -    through IMA.  As a standalone filesystem feature, fs-verity -    already meets many users' needs, and it's testable like other +    IMA supports the fs-verity hashing mechanism as an alternative +    to full file hashes, for those who want the performance and +    security benefits of the Merkle tree based hash.  However, it +    doesn't make sense to force all uses of fs-verity to be through +    IMA.  fs-verity already meets many users' needs even as a +    standalone filesystem feature, and it's testable like other      filesystem features e.g. with xfstests.  :Q: Isn't fs-verity useless because the attacker can just modify the diff --git a/Documentation/filesystems/proc.rst b/Documentation/filesystems/proc.rst index 061744c436d9..6a0dd99786f9 100644 --- a/Documentation/filesystems/proc.rst +++ b/Documentation/filesystems/proc.rst @@ -1183,85 +1183,7 @@ Provides counts of softirq handlers serviced since boot time, for each CPU.      HRTIMER:         0          0          0          0  	RCU:      1678       1769       2178       2250 - -1.3 IDE devices in /proc/ide ----------------------------- - -The subdirectory /proc/ide contains information about all IDE devices of which -the kernel  is  aware.  There is one subdirectory for each IDE controller, the -file drivers  and a link for each IDE device, pointing to the device directory -in the controller specific subtree. - -The file 'drivers' contains general information about the drivers used for the -IDE devices:: - -  > cat /proc/ide/drivers -  ide-cdrom version 4.53 -  ide-disk version 1.08 - -More detailed  information  can  be  found  in  the  controller  specific -subdirectories. These  are  named  ide0,  ide1  and  so  on.  Each  of  these -directories contains the files shown in table 1-6. - - -.. table:: Table 1-6: IDE controller info in  /proc/ide/ide? - - ======= ======================================= - File    Content - ======= ======================================= - channel IDE channel (0 or 1) - config  Configuration (only for PCI/IDE bridge) - mate    Mate name - model   Type/Chipset of IDE controller - ======= ======================================= - -Each device  connected  to  a  controller  has  a separate subdirectory in the -controllers directory.  The  files  listed in table 1-7 are contained in these -directories. - - -.. table:: Table 1-7: IDE device information - - ================ ========================================== - File             Content - ================ ========================================== - cache            The cache - capacity         Capacity of the medium (in 512Byte blocks) - driver           driver and version - geometry         physical and logical geometry - identify         device identify block - media            media type - model            device identifier - settings         device setup - smart_thresholds IDE disk management thresholds - smart_values     IDE disk management values - ================ ========================================== - -The most  interesting  file is ``settings``. This file contains a nice -overview of the drive parameters:: - -  # cat /proc/ide/ide0/hda/settings -  name                    value           min             max             mode -  ----                    -----           ---             ---             ---- -  bios_cyl                526             0               65535           rw -  bios_head               255             0               255             rw -  bios_sect               63              0               63              rw -  breada_readahead        4               0               127             rw -  bswap                   0               0               1               r -  file_readahead          72              0               2097151         rw -  io_32bit                0               0               3               rw -  keepsettings            0               0               1               rw -  max_kb_per_request      122             1               127             rw -  multcount               0               0               8               rw -  nice1                   1               0               1               rw -  nowerr                  0               0               1               rw -  pio_mode                write-only      0               255             w -  slow                    0               0               1               rw -  unmaskirq               0               0               1               rw -  using_dma               0               0               1               rw - - -1.4 Networking info in /proc/net +1.3 Networking info in /proc/net  --------------------------------  The subdirectory  /proc/net  follows  the  usual  pattern. Table 1-8 shows the @@ -1340,7 +1262,7 @@ It will contain information that is specific to that bond, such as the  current slaves of the bond, the link status of the slaves, and how  many times the slaves link has failed. -1.5 SCSI info +1.4 SCSI info  -------------  If you  have  a  SCSI  host adapter in your system, you'll find a subdirectory @@ -1403,7 +1325,7 @@ AHA-2940 SCSI adapter::      Total transfers 0 (0 reads and 0 writes) -1.6 Parallel port info in /proc/parport +1.5 Parallel port info in /proc/parport  ---------------------------------------  The directory  /proc/parport  contains information about the parallel ports of @@ -1428,7 +1350,7 @@ These directories contain the four files shown in Table 1-10.             number or none).   ========= ==================================================================== -1.7 TTY info in /proc/tty +1.6 TTY info in /proc/tty  -------------------------  Information about  the  available  and actually used tty's can be found in the @@ -1463,7 +1385,7 @@ To see  which  tty's  are  currently in use, you can simply look into the file    unknown              /dev/tty        4    1-63 console -1.8 Miscellaneous kernel statistics in /proc/stat +1.7 Miscellaneous kernel statistics in /proc/stat  -------------------------------------------------  Various pieces   of  information about  kernel activity  are  available in the @@ -1536,7 +1458,7 @@ softirqs serviced; each subsequent column is the total for that particular  softirq. -1.9 Ext4 file system parameters +1.8 Ext4 file system parameters  -------------------------------  Information about mounted ext4 file systems can be found in @@ -1552,7 +1474,7 @@ in Table 1-12, below.   mb_groups       details of multiblock allocator buddy cache of free blocks   ==============  ========================================================== -1.10 /proc/consoles +1.9 /proc/consoles  -------------------  Shows registered system console lines. diff --git a/Documentation/filesystems/zonefs.rst b/Documentation/filesystems/zonefs.rst index 6b213fe9a33e..394b9f15dce0 100644 --- a/Documentation/filesystems/zonefs.rst +++ b/Documentation/filesystems/zonefs.rst @@ -306,8 +306,15 @@ Further notes:  Mount options  ------------- -zonefs define the "errors=<behavior>" mount option to allow the user to specify -zonefs behavior in response to I/O errors, inode size inconsistencies or zone +zonefs defines several mount options: +* errors=<behavior> +* explicit-open + +"errors=<behavior>" option +~~~~~~~~~~~~~~~~~~~~~~~~~~ + +The "errors=<behavior>" option mount option allows the user to specify zonefs +behavior in response to I/O errors, inode size inconsistencies or zone  condition changes. The defined behaviors are as follow:  * remount-ro (default) @@ -326,6 +333,9 @@ discover the amount of data that has been written to the zone. In the case of a  read-only zone discovered at run-time, as indicated in the previous section.  The size of the zone file is left unchanged from its last updated value. +"explicit-open" option +~~~~~~~~~~~~~~~~~~~~~~ +  A zoned block device (e.g. an NVMe Zoned Namespace device) may have limits on  the number of zones that can be active, that is, zones that are in the  implicit open, explicit open or closed conditions.  This potential limitation @@ -341,6 +351,44 @@ guaranteed that write requests can be processed. Conversely, the  to the device on the last close() of a zone file if the zone is not full nor  empty. +Runtime sysfs attributes +------------------------ + +zonefs defines several sysfs attributes for mounted devices.  All attributes +are user readable and can be found in the directory /sys/fs/zonefs/<dev>/, +where <dev> is the name of the mounted zoned block device. + +The attributes defined are as follows. + +* **max_wro_seq_files**:  This attribute reports the maximum number of +  sequential zone files that can be open for writing.  This number corresponds +  to the maximum number of explicitly or implicitly open zones that the device +  supports.  A value of 0 means that the device has no limit and that any zone +  (any file) can be open for writing and written at any time, regardless of the +  state of other zones.  When the *explicit-open* mount option is used, zonefs +  will fail any open() system call requesting to open a sequential zone file for +  writing when the number of sequential zone files already open for writing has +  reached the *max_wro_seq_files* limit. +* **nr_wro_seq_files**:  This attribute reports the current number of sequential +  zone files open for writing.  When the "explicit-open" mount option is used, +  this number can never exceed *max_wro_seq_files*.  If the *explicit-open* +  mount option is not used, the reported number can be greater than +  *max_wro_seq_files*.  In such case, it is the responsibility of the +  application to not write simultaneously more than *max_wro_seq_files* +  sequential zone files.  Failure to do so can result in write errors. +* **max_active_seq_files**:  This attribute reports the maximum number of +  sequential zone files that are in an active state, that is, sequential zone +  files that are partially writen (not empty nor full) or that have a zone that +  is explicitly open (which happens only if the *explicit-open* mount option is +  used).  This number is always equal to the maximum number of active zones that +  the device supports.  A value of 0 means that the mounted device has no limit +  on the number of sequential zone files that can be active. +* **nr_active_seq_files**:  This attributes reports the current number of +  sequential zone files that are active. If *max_active_seq_files* is not 0, +  then the value of *nr_active_seq_files* can never exceed the value of +  *nr_active_seq_files*, regardless of the use of the *explicit-open* mount +  option. +  Zonefs User Space Tools  ======================= | 
