[Devel] [PATCH hci-8.2 2/4] ms/refcount: provide ops for cases when object's memory can be reused
no-reply at sashiko.virtuozzo.com
no-reply at sashiko.virtuozzo.com
Thu Nov 19 09:38:27 MSK 2026
> From: Suren Baghdasaryan <surenb at google.com>
>
> [ Upstream commit 7f8ceea0c58039dcea3d31b8d5da58aa5f6e12bf ]
>
> For speculative lookups where a successful inc_not_zero() pins the object,
> but where we still need to double check if the object acquired is indeed
> the one we set out to acquire (identity check), needs this validation to
> happen *after* the increment. Similarly, when a new object is initialized
> and its memory might have been previously occupied by another object, all
> stores to initialize the object should happen *before* refcount
> initialization.
>
> Notably SLAB_TYPESAFE_BY_RCU is one such an example when this ordering is
> required for reference counting.
>
> [ ... ]
>
> https://virtuozzo.atlassian.net/browse/VSTOR-155530
> Feature: fix ms/net
>
> Signed-off-by: Eva Kurchatova <eva.kurchatova at virtuozzo.com>
Sashiko has reviewed this patch and found no issues.
Carry the trailer below into the next revision and Sashiko will not review this patch again.
Reviewed-by: Sashiko <no-reply at sashiko.virtuozzo.com>
--
Sashiko AI review · https://sashiko.vzint.dev/#/patchset/20261119063525.1233606-1-eva.kurchatova@virtuozzo.com?part=2
More information about the Devel
mailing list