1. 26 12月, 2013 1 次提交
  2. 23 12月, 2013 23 次提交
  3. 08 11月, 2013 1 次提交
  4. 31 10月, 2013 1 次提交
  5. 29 10月, 2013 1 次提交
  6. 25 10月, 2013 4 次提交
  7. 22 10月, 2013 1 次提交
  8. 18 10月, 2013 2 次提交
    • G
      f2fs: avoid wait if IO end up when do_checkpoint for better performance · e2340887
      Gu Zheng 提交于
      Previously, do_checkpoint() will call congestion_wait() for waiting the pages
      (previous submitted node/meta/data pages) to be written back.
      Because congestion_wait() will set a regular period (e.g. HZ / 50 ) for waiting, and
      no additional wake up mechanism was introduced if IO ends up before regular period costed.
      Yuan Zhong found there is a situation that after the pages have been written back,
      but the checkpoint thread still wait for congestion_wait to exit.
      
      So here we store checkpoint task into f2fs_sb when doing checkpoint, it'll wait for IO completes
      if there's IO going on, and in the end IO path, wake up checkpoint task when IO ends up.
      
      Thanks to Yuan Zhong's pre work about this problem.
      Reported-by: NYuan Zhong <yuan.mark.zhong@samsung.com>
      Signed-off-by: NGu Zheng <guz.fnst@cn.fujitsu.com>
      Signed-off-by: NJaegeuk Kim <jaegeuk.kim@samsung.com>
      e2340887
    • J
      f2fs: fix the starvation problem on cp_rwsem · b1838f89
      Jaegeuk Kim 提交于
      This patch removes the logic previously introduced to address the starvation
      on cp_rwsem.
      
      One potential there-in bug is that we should cover the wait.list with spin_lock,
      but the previous code broke this rule.
      
      And, actually current rwsem handles this starvation issue reasonably, so that we
      didn't need to do this before neither.
      Signed-off-by: NJaegeuk Kim <jaegeuk.kim@samsung.com>
      b1838f89
  9. 07 10月, 2013 1 次提交
    • G
      f2fs: use rw_sem instead of fs_lock(locks mutex) · e479556b
      Gu Zheng 提交于
      The fs_locks is used to block other ops(ex, recovery) when doing checkpoint.
      And each other operate routine(besides checkpoint) needs to acquire a fs_lock,
      there is a terrible problem here, if these are too many concurrency threads acquiring
      fs_lock, so that they will block each other and may lead to some performance problem,
      but this is not the phenomenon we want to see.
      Though there are some optimization patches introduced to enhance the usage of fs_lock,
      but the thorough solution is using a *rw_sem* to replace the fs_lock.
      Checkpoint routine takes write_sem, and other ops take read_sem, so that we can block
      other ops(ex, recovery) when doing checkpoint, and other ops will not disturb each other,
      this can avoid the problem described above completely.
      Because of the weakness of rw_sem, the above change may introduce a potential problem
      that the checkpoint thread might get starved if other threads are intensively locking
      the read semaphore for I/O.(Pointed out by Xu Jin)
      In order to avoid this, a wait_list is introduced, the appending read semaphore ops
      will be dropped into the wait_list if checkpoint thread is waiting for write semaphore,
      and will be waked up when checkpoint thread gives up write semaphore.
      Thanks to Kim's previous review and test, and will be very glad to see other guys'
      performance tests about this patch.
      
      V2:
        -fix the potential starvation problem.
        -use more suitable func name suggested by Xu Jin.
      Signed-off-by: NGu Zheng <guz.fnst@cn.fujitsu.com>
      [Jaegeuk Kim: adjust minor coding standard]
      Signed-off-by: NJaegeuk Kim <jaegeuk.kim@samsung.com>
      e479556b
  10. 24 9月, 2013 1 次提交
  11. 26 8月, 2013 4 次提交
    • J
      f2fs: support the inline xattrs · 65985d93
      Jaegeuk Kim 提交于
      0. modified inode structure
      --------------------------------------
      metadata (e.g., i_mtime, i_ctime, etc)
      --------------------------------------
      direct pointers [0 ~ 873]
      
      inline xattrs (200 bytes by default)
      
      indirect pointers [0 ~ 4]
      --------------------------------------
      node footer
      --------------------------------------
      
      1. setxattr flow
       - read_all_xattrs copies all the xattrs from inline and xattr node block.
       - handle xattr entries
       - write_all_xattrs copies modified xattrs into inline and xattr node block.
      
      2. getxattr flow
       - read_all_xattrs copies all the xattrs from inline and xattr node block.
       - check target entries
      
      3. Usage
       # mount -t f2fs -o inline_xattr $DEV $MNT
      
       Once mounted with the inline_xattr option, f2fs marks all the newly created
       files to reserve an amount of inline xattr space explicitly inside the inode
       block. Without the mount option, f2fs will not touch any existing files and
       newly created files as well.
      Signed-off-by: NJaegeuk Kim <jaegeuk.kim@samsung.com>
      65985d93
    • J
      f2fs: add the truncate_xattr_node function · 4f16fb0f
      Jaegeuk Kim 提交于
      The truncate_xattr_node function will be used by inline xattr.
      Signed-off-by: NJaegeuk Kim <jaegeuk.kim@samsung.com>
      4f16fb0f
    • J
      f2fs: reserve the xattr space dynamically · de93653f
      Jaegeuk Kim 提交于
      This patch enables the number of direct pointers inside on-disk inode block to
      be changed dynamically according to the size of inline xattr space.
      
      The number of direct pointers, ADDRS_PER_INODE, can be changed only if the file
      has inline xattr flag.
      
      The number of direct pointers that will be used by inline xattrs is defined as
      F2FS_INLINE_XATTR_ADDRS.
      Current patch assigns F2FS_INLINE_XATTR_ADDRS to 0 temporarily.
      Signed-off-by: NJaegeuk Kim <jaegeuk.kim@samsung.com>
      de93653f
    • J
      f2fs: add flags for inline xattrs · 444c580f
      Jaegeuk Kim 提交于
      This patch adds basic inode flags for inline xattrs, F2FS_INLINE_XATTR,
      and add a mount option, inline_xattr, which is enabled when xattr is set.
      
      If the mount option is enabled, all the files are marked with the inline_xattrs
      flag.
      Signed-off-by: NJaegeuk Kim <jaegeuk.kim@samsung.com>
      444c580f