Commit aab407fc authored by Al Viro's avatar Al Viro
Browse files

don't bother with vfsmount_lock in mounts_poll()

wake_up_interruptible/poll_wait provide sufficient barriers;
just use ACCESS_ONCE() to fetch ns->event and that's it.
Signed-off-by: default avatarAl Viro <>
parent aba809cf
......@@ -20,15 +20,15 @@ static unsigned mounts_poll(struct file *file, poll_table *wait)
struct proc_mounts *p = proc_mounts(file->private_data);
struct mnt_namespace *ns = p->ns;
unsigned res = POLLIN | POLLRDNORM;
int event;
poll_wait(file, &p->ns->poll, wait);
if (p->m.poll_event != ns->event) {
p->m.poll_event = ns->event;
event = ACCESS_ONCE(ns->event);
if (p->m.poll_event != event) {
p->m.poll_event = event;
return res;
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment