On Mon, Mar 25, 2019 at 10:22:50AM -0600, Jens Axboe wrote:
> We now wrap sbitmap waitqueues in an active counter, so we can avoid
> iterating wakeups unless we have waiters there. This works as long as
> everyone that's manipulating the waitqueues use the proper helpers. For
> the tag wait case for shared tags, however, we add ourselves to the
> waitqueue without incrementing/decrementing the ->ws_active count. This
> means that wakeups can take a long time to happen.
> 
> Fix this by manually doing the inc/dec as needed for the wait queue
> handling.
> 
> Fixes: 5d2ee7122c73 ("sbitmap: optimize wakeup check")
> Signed-off-by: Jens Axboe <[email protected]>

Can this use the helpers we added in 9f6b7ef6c3eb ("sbitmap: add helpers
for add/del wait queue handling")?

Reply via email to