Commit d218bee8 authored by Chao Liu's avatar Chao Liu Committed by Jonathan Corbet
Browse files

docs: filesystems: f2fs: fix description about compress ioctl



Since commit c6140415 ("f2fs: introduce FI_COMPRESS_RELEASED
instead of using IMMUTABLE bit"), we no longer use the IMMUTABLE
bit to prevent writing data for compression. Let's correct the
corresponding documentation.

BTW, this patch fixes some alignment issues in the compress
metadata layout.

Signed-off-by: default avatarChao Liu <liuchao@coolpad.com>
Link: https://lore.kernel.org/r/20220613020800.3379482-1-chaoliu719@gmail.com


Signed-off-by: default avatarJonathan Corbet <corbet@lwn.net>
parent 910cb313
Loading
Loading
Loading
Loading
+7 −6
Original line number Diff line number Diff line
@@ -818,10 +818,11 @@ Compression implementation
  Instead, the main goal is to reduce data writes to flash disk as much as
  possible, resulting in extending disk life time as well as relaxing IO
  congestion. Alternatively, we've added ioctl(F2FS_IOC_RELEASE_COMPRESS_BLOCKS)
  interface to reclaim compressed space and show it to user after putting the
  immutable bit. Immutable bit, after release, it doesn't allow writing/mmaping
  on the file, until reserving compressed space via
  ioctl(F2FS_IOC_RESERVE_COMPRESS_BLOCKS) or truncating filesize to zero.
  interface to reclaim compressed space and show it to user after setting a
  special flag to the inode. Once the compressed space is released, the flag
  will block writing data to the file until either the compressed space is
  reserved via ioctl(F2FS_IOC_RESERVE_COMPRESS_BLOCKS) or the file size is
  truncated to zero.

Compress metadata layout::