mirror of
https://github.com/versity/scoutfs.git
synced 2026-07-19 06:22:24 +00:00
c8bc42ccdb
A quota check holds the quota cluster lock for READ and marks the cached ruleset EBUSY while loading rules. A quota mod on the same mount holds the lock for WRITE (compatible with the local READ) and calls scoutfs_quota_invalidate(), tripping BUG_ON(rs == ERR_PTR(-EBUSY)). Make invalidate skip EBUSY so the reader's claim is preserved, and have scoutfs_quota_mod_rule wait for the reader to finish before calling invalidate. Without the wait, the in-flight reader would publish its stale ruleset after invalidate runs, leaving the cache stale until the next invalidation. Signed-off-by: Auke Kok <auke.kok@versity.com>