Skip to content
Commit d453d0e5 authored by David Howells's avatar David Howells Committed by Greg Kroah-Hartman
Browse files

watch_queue: Fix the alloc bitmap size to reflect notes allocated

commit 3b4c0371 upstream.

Currently, watch_queue_set_size() sets the number of notes available in
wqueue->nr_notes according to the number of notes allocated, but sets
the size of the bitmap to the unrounded number of notes originally asked
for.

Fix this by setting the bitmap size to the number of notes we're
actually going to make available (ie. the number allocated).

Fixes: c73be61c

 ("pipe: Add general notification queue support")
Reported-by: default avatarJann Horn <jannh@google.com>
Signed-off-by: default avatarDavid Howells <dhowells@redhat.com>
Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
parent b022b6a0
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