Commit 1db3a48e authored by Trond Myklebust's avatar Trond Myklebust
Browse files

NFS: Fix wakeup of __nfs_lookup_revalidate() in unblock_revalidate()



Use store_release_wake_up() to add the appropriate memory barrier before
calling wake_up_var(&dentry->d_fsdata).

Reported-by: default avatarLukáš <Hejtmánek&lt;xhejtman@ics.muni.cz>
Suggested-by: default avatarSantosh Pradhan <santosh.pradhan@gmail.com>
Link: https://lore.kernel.org/all/18945D18-3EDB-4771-B019-0335CE671077@ics.muni.cz/


Fixes: 99bc9f2e ("NFS: add barriers when testing for NFS_FSDATA_BLOCKED")
Signed-off-by: default avatarTrond Myklebust <trond.myklebust@hammerspace.com>
parent f5b3108e
Loading
Loading
Loading
Loading
+1 −3
Original line number Diff line number Diff line
@@ -1828,9 +1828,7 @@ static void block_revalidate(struct dentry *dentry)

static void unblock_revalidate(struct dentry *dentry)
{
	/* store_release ensures wait_var_event() sees the update */
	smp_store_release(&dentry->d_fsdata, NULL);
	wake_up_var(&dentry->d_fsdata);
	store_release_wake_up(&dentry->d_fsdata, NULL);
}

/*