HomeFreeBSD

vfs cache: plug a hypothetical corner case when freeing

Description

vfs cache: plug a hypothetical corner case when freeing

cache_zap_unlocked_bucket is called with a bunch of addresses and
without any locks held, forcing it to revalidate everything from
scratch.

It did not account for a case where the entry is reallocated with
everything the same except for the target vnode.

Should the target use a different lock than the one expected, freeing
would proceed without being properly synchronized.

Note this is almost impossible to happen in practice.

Details

Provenance
mjgAuthored on Sep 23 2023, 2:04 AM
Parents
rG2749c222da8a: vfs cache: sanitize debug counters
Branches
Unknown
Tags
Unknown