ceph: document what protects i_dirty_item and i_flushing_item
authorJeff Layton <jlayton@kernel.org>
Thu, 19 Mar 2020 19:34:13 +0000 (15:34 -0400)
committerIlya Dryomov <idryomov@gmail.com>
Mon, 1 Jun 2020 11:22:52 +0000 (13:22 +0200)
Signed-off-by: Jeff Layton <jlayton@kernel.org>
Signed-off-by: Ilya Dryomov <idryomov@gmail.com>
fs/ceph/super.h

index 47cfd89..bb37285 100644 (file)
@@ -351,7 +351,9 @@ struct ceph_inode_info {
        struct rb_root i_caps;           /* cap list */
        struct ceph_cap *i_auth_cap;     /* authoritative cap, if any */
        unsigned i_dirty_caps, i_flushing_caps;     /* mask of dirtied fields */
-       struct list_head i_dirty_item, i_flushing_item;
+       struct list_head i_dirty_item, i_flushing_item; /* protected by
+                                                        * mdsc->cap_dirty_lock
+                                                        */
        /* we need to track cap writeback on a per-cap-bit basis, to allow
         * overlapping, pipelined cap flushes to the mds.  we can probably
         * reduce the tid to 8 bits if we're concerned about inode size. */