tools headers UAPI: Sync drm/i915_drm.h with the kernel sources
[linux-2.6-microblaze.git] / fs / inode.c
index 6442d97..8742421 100644 (file)
@@ -1493,7 +1493,7 @@ struct inode *find_inode_rcu(struct super_block *sb, unsigned long hashval,
 EXPORT_SYMBOL(find_inode_rcu);
 
 /**
- * find_inode_by_rcu - Find an inode in the inode cache
+ * find_inode_by_ino_rcu - Find an inode in the inode cache
  * @sb:                Super block of file system to search
  * @ino:       The inode number to match
  *
@@ -1743,24 +1743,26 @@ static int relatime_need_update(struct vfsmount *mnt, struct inode *inode,
 
 int generic_update_time(struct inode *inode, struct timespec64 *time, int flags)
 {
-       int iflags = I_DIRTY_TIME;
-       bool dirty = false;
-
-       if (flags & S_ATIME)
-               inode->i_atime = *time;
-       if (flags & S_VERSION)
-               dirty = inode_maybe_inc_iversion(inode, false);
-       if (flags & S_CTIME)
-               inode->i_ctime = *time;
-       if (flags & S_MTIME)
-               inode->i_mtime = *time;
-       if ((flags & (S_ATIME | S_CTIME | S_MTIME)) &&
-           !(inode->i_sb->s_flags & SB_LAZYTIME))
-               dirty = true;
-
-       if (dirty)
-               iflags |= I_DIRTY_SYNC;
-       __mark_inode_dirty(inode, iflags);
+       int dirty_flags = 0;
+
+       if (flags & (S_ATIME | S_CTIME | S_MTIME)) {
+               if (flags & S_ATIME)
+                       inode->i_atime = *time;
+               if (flags & S_CTIME)
+                       inode->i_ctime = *time;
+               if (flags & S_MTIME)
+                       inode->i_mtime = *time;
+
+               if (inode->i_sb->s_flags & SB_LAZYTIME)
+                       dirty_flags |= I_DIRTY_TIME;
+               else
+                       dirty_flags |= I_DIRTY_SYNC;
+       }
+
+       if ((flags & S_VERSION) && inode_maybe_inc_iversion(inode, false))
+               dirty_flags |= I_DIRTY_SYNC;
+
+       __mark_inode_dirty(inode, dirty_flags);
        return 0;
 }
 EXPORT_SYMBOL(generic_update_time);
@@ -1777,7 +1779,7 @@ static int update_time(struct inode *inode, struct timespec64 *time, int flags)
 }
 
 /**
- *     touch_atime     -       update the access time
+ *     atime_needs_update      -       update the access time
  *     @path: the &struct path to update
  *     @inode: inode to update
  *