Skip to content

Commit a7cce09

Browse files
author
Al Viro
committed
statmount_mnt_basic(): simplify the logics for group id
We are holding namespace_sem shared and we have not done any group id allocations since we grabbed it. Therefore IS_MNT_SHARED(m) is equivalent to non-zero m->mnt_group_id. Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
1 parent f6cc2f4 commit a7cce09

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

fs/namespace.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5298,7 +5298,7 @@ static void statmount_mnt_basic(struct kstatmount *s)
52985298
s->sm.mnt_parent_id_old = m->mnt_parent->mnt_id;
52995299
s->sm.mnt_attr = mnt_to_attr_flags(&m->mnt);
53005300
s->sm.mnt_propagation = mnt_to_propagation_flags(m);
5301-
s->sm.mnt_peer_group = IS_MNT_SHARED(m) ? m->mnt_group_id : 0;
5301+
s->sm.mnt_peer_group = m->mnt_group_id;
53025302
s->sm.mnt_master = IS_MNT_SLAVE(m) ? m->mnt_master->mnt_group_id : 0;
53035303
}
53045304

0 commit comments

Comments
 (0)