1. 06 Nov, 2017 5 commits
    • Chao Yu's avatar
      f2fs: support flexible inline xattr size · 6afc662e
      Chao Yu authored
      Now, in product, more and more features based on file encryption were
      introduced, their demand of xattr space is increasing, however, inline
      xattr has fixed-size of 200 bytes, once inline xattr space is full, new
      increased xattr data would occupy additional xattr block which may bring
      us more space usage and performance regression during persisting.
      
      In order to resolve above issue, it's better to expand inline xattr size
      flexibly according to user's requirement.
      
      So this patch introduces new filesystem feature 'flexible inline xattr',
      and new mount option 'inline_xattr_size=%u', once mkfs enables the
      feature, we can use the option to make f2fs supporting flexible inline
      xattr size.
      
      To support this feature, we add extra attribute i_inline_xattr_size in
      inode layout, indicating that how many space inline xattr borrows from
      block address mapping space in inode layout, by this, we can easily
      locate and store flexible-sized inline xattr data in inode.
      
      Inode disk layout:
        +----------------------+
        | .i_mode              |
        | ...                  |
        | .i_ext               |
        +----------------------+
        | .i_extra_isize       |
        | .i_inline_xattr_size |-----------+
        | ...                  |           |
        +----------------------+           |
        | .i_addr              |           |
        |  - block address or  |           |
        |  - inline data       |           |
        +----------------------+<---+      v
        |    inline xattr      |    +---inline xattr range
        +----------------------+<---+
        | .i_nid               |
        +----------------------+
        |   node_footer        |
        | (nid, ino, offset)   |
        +----------------------+
      
      Note that, we have to cnosider backward compatibility which reserved
      inline_data space, 200 bytes, all the time, reported by Sheng Yong.
      
      Previous inline data or directory always reserved 200 bytes in inode layout,
      even if inline_xattr is disabled. In order to keep inline_dentry's structure
      for backward compatibility, we get the space back only from inline_data.
      Signed-off-by: default avatarChao Yu <yuchao0@huawei.com>
      Reported-by: default avatarSheng Yong <shengyong1@huawei.com>
      Signed-off-by: default avatarJaegeuk Kim <jaegeuk@kernel.org>
      6afc662e
    • Jaegeuk Kim's avatar
      f2fs: show current cp state · b4b153f8
      Jaegeuk Kim authored
      This patch shows whether checkpoint met any error case.
      Signed-off-by: default avatarJaegeuk Kim <jaegeuk@kernel.org>
      b4b153f8
    • Jaegeuk Kim's avatar
      f2fs: add missing quota_initialize · d8d1389e
      Jaegeuk Kim authored
      This patch adds to call quota_intialize in f2fs_set_acl, f2fs_unlink,
      and f2fs_rename.
      Reviewed-by: default avatarChao Yu <yuchao0@huawei.com>
      Signed-off-by: default avatarJaegeuk Kim <jaegeuk@kernel.org>
      d8d1389e
    • Jaegeuk Kim's avatar
      f2fs: show # of dirty segments via sysfs · 8f1572f7
      Jaegeuk Kim authored
      This patch adds one sysfs entry to show # of dirty segments which can be
      used for gc timing by user.
      Reviewed-by: default avatarChao Yu <yuchao0@huawei.com>
      Signed-off-by: default avatarJaegeuk Kim <jaegeuk@kernel.org>
      8f1572f7
    • Jaegeuk Kim's avatar
      f2fs: stop all the operations by cp_error flag · 1f227a3e
      Jaegeuk Kim authored
      This patch replaces to use cp_error flag instead of RDONLY for quota off.
      Reviewed-by: default avatarChao Yu <yuchao0@huawei.com>
      Signed-off-by: default avatarJaegeuk Kim <jaegeuk@kernel.org>
      1f227a3e
  2. 26 Oct, 2017 24 commits
  3. 10 Oct, 2017 11 commits