mirror of
https://github.com/versity/scoutfs.git
synced 2026-09-01 13:47:11 +00:00
The client's incoming lock invalidation request handler triggers a BUG_ON if it gets a request for a lock that is already processing a previous invalidation request. The server is supposed to only send one request at a time. The problem is that the batched invalidation request handling will send responses outside of spinlock coverage before reacquirin the lock and finishing processing once the response send has been successful. This gives a window for another invalidation request to arrive after the response was sent but before the invalidation finished processing. This triggers the bug. The fix is to mark the lock such that we can recognize a valid second request arriving after we send the response but before we finish processing. If it arrives we'll continue invalidation processing with the arguments from the new request. Signed-off-by: Zach Brown <zab@versity.com>