1. 04 7月, 2017 3 次提交
    • C
      f2fs: measure inode.i_blocks as generic filesystem · 0eb0adad
      Chao Yu 提交于
      Both in memory or on disk, generic filesystems record i_blocks with
      512bytes sized sector count, also VFS sub module such as disk quota
      follows this rule, but f2fs records it with 4096bytes sized block
      count, this difference leads to that once we use dquota's function
      which inc/dec iblocks, it will make i_blocks of f2fs being inconsistent
      between in memory and on disk.
      
      In order to resolve this issue, this patch changes to make in-memory
      i_blocks of f2fs recording sector count instead of block count,
      meanwhile leaving on-disk i_blocks recording block count.
      Signed-off-by: NChao Yu <yuchao0@huawei.com>
      Signed-off-by: NJaegeuk Kim <jaegeuk@kernel.org>
      0eb0adad
    • C
      f2fs: move sysfs code from super.c to fs/f2fs/sysfs.c · 8ceffcb2
      Chao Yu 提交于
      Codes related to sysfs and procfs are dispersive and mixed with sb
      related codes, but actually these codes are independent from others,
      so split them from super.c, and reorgnize and manger them in sysfs.c.
      Signed-off-by: NChao Yu <yuchao0@huawei.com>
      Signed-off-by: NJaegeuk Kim <jaegeuk@kernel.org>
      8ceffcb2
    • Q
      f2fs: dax: fix races between page faults and truncating pages · 5a3a2d83
      Qiuyang Sun 提交于
      Currently in F2FS, page faults and operations that truncate the pagecahe
      or data blocks, are completely unsynchronized. This can result in page
      fault faulting in a page into a range that we are changing after
      truncating, and thus we can end up with a page mapped to disk blocks that
      will be shortly freed. Filesystem corruption will shortly follow.
      
      This patch fixes the problem by creating new rw semaphore i_mmap_sem in
      f2fs_inode_info and grab it for functions removing blocks from extent tree
      and for read over page faults. The mechanism is similar to that in ext4.
      Signed-off-by: NQiuyang Sun <sunqiuyang@huawei.com>
      Reviewed-by: NChao Yu <yuchao0@huawei.com>
      Signed-off-by: NJaegeuk Kim <jaegeuk@kernel.org>
      5a3a2d83
  2. 24 5月, 2017 5 次提交
  3. 04 5月, 2017 5 次提交
  4. 03 5月, 2017 2 次提交
  5. 26 4月, 2017 1 次提交
  6. 25 4月, 2017 3 次提交
  7. 20 4月, 2017 6 次提交
  8. 12 4月, 2017 1 次提交
  9. 11 4月, 2017 4 次提交
  10. 06 4月, 2017 7 次提交
  11. 25 3月, 2017 2 次提交
  12. 22 3月, 2017 1 次提交
    • K
      f2fs: cleanup the disk level filename updating · d03ba4cc
      Kinglong Mee 提交于
      As discuss with Jaegeuk and Chao,
      "Once checkpoint is done, f2fs doesn't need to update there-in filename at all."
      
      The disk-level filename is used only one case,
      1. create a file A under a dir
      2. sync A
      3. godown
      4. umount
      5. mount (roll_forward)
      
      Only the rename/cross_rename changes the filename, if it happens,
      a. between step 1 and 2, the sync A will caused checkpoint, so that,
         the roll_forward at step 5 never happens.
      b. after step 2, the roll_forward happens, file A will roll forward
         to the result as after step 1.
      
      So that, any updating the disk filename is useless, just cleanup it.
      Signed-off-by: NKinglong Mee <kinglongmee@gmail.com>
      Reviewed-by: NChao Yu <yuchao0@huawei.com>
      Signed-off-by: NJaegeuk Kim <jaegeuk@kernel.org>
      d03ba4cc