X-Git-Url: https://err.no/cgi-bin/gitweb.cgi?a=blobdiff_plain;f=fs%2Fpnode.c;h=1d8f5447f3f7c533bc848883694bf7656428a64b;hb=a70e65df8812c52252fa07a2eb92a46451a4427f;hp=56aacead836284b7577ad9146aed46582c592a5f;hpb=cd39301a68f9604854f3543117b01dc73cbe193f;p=linux-2.6 diff --git a/fs/pnode.c b/fs/pnode.c index 56aacead83..1d8f5447f3 100644 --- a/fs/pnode.c +++ b/fs/pnode.c @@ -59,7 +59,7 @@ static int do_make_slave(struct vfsmount *mnt) } else { struct list_head *p = &mnt->mnt_slave_list; while (!list_empty(p)) { - slave_mnt = list_entry(p->next, + slave_mnt = list_first_entry(p, struct vfsmount, mnt_slave); list_del_init(&slave_mnt->mnt_slave); slave_mnt->mnt_master = NULL; @@ -83,6 +83,8 @@ void change_mnt_propagation(struct vfsmount *mnt, int type) mnt->mnt_master = NULL; if (type == MS_UNBINDABLE) mnt->mnt_flags |= MNT_UNBINDABLE; + else + mnt->mnt_flags &= ~MNT_UNBINDABLE; } } @@ -223,7 +225,7 @@ out: */ static inline int do_refcount_check(struct vfsmount *mnt, int count) { - int mycount = atomic_read(&mnt->mnt_count); + int mycount = atomic_read(&mnt->mnt_count) - mnt->mnt_ghosts; return (mycount > count); }