f2fs: update several comments
[GitHub/exynos8895/android_kernel_samsung_universal8895.git] / fs / f2fs / dir.c
index 594fc1bb64ef44f1ea734ec7222b710a670b37fe..28206109a29398df84b01f6ed0b1b54911c43f88 100644 (file)
@@ -190,7 +190,7 @@ struct f2fs_dir_entry *f2fs_find_entry(struct inode *dir,
        unsigned int max_depth;
        unsigned int level;
 
-       if (namelen > F2FS_NAME_LEN)
+       if (unlikely(namelen > F2FS_NAME_LEN))
                return NULL;
 
        if (npages == 0)
@@ -432,8 +432,8 @@ next:
 }
 
 /*
- * Caller should grab and release a mutex by calling mutex_lock_op() and
- * mutex_unlock_op().
+ * Caller should grab and release a rwsem by calling f2fs_lock_op() and
+ * f2fs_unlock_op().
  */
 int __f2fs_add_link(struct inode *dir, const struct qstr *name, struct inode *inode)
 {
@@ -461,7 +461,7 @@ int __f2fs_add_link(struct inode *dir, const struct qstr *name, struct inode *in
        }
 
 start:
-       if (current_depth == MAX_DIR_HASH_DEPTH)
+       if (unlikely(current_depth == MAX_DIR_HASH_DEPTH))
                return -ENOSPC;
 
        /* Increase the depth, if required */