diff options
| author | Nilay Shroff <nilay@linux.ibm.com> | 2026-07-13 17:24:12 +0530 |
|---|---|---|
| committer | Keith Busch <kbusch@kernel.org> | 2026-07-28 10:37:31 -0700 |
| commit | d1fdf49b5f7fce5f65ae0d11d484bd7e31cedbb1 (patch) | |
| tree | ebd4d75b17ed8fd7ab53560afa479e8bd7e865b2 /tools/perf/scripts/python/bin/stackcollapse-record | |
| parent | 9c65eeeb26b1d614787deec36faec81e45b8f8e8 (diff) | |
nvme: add context annotations for nvme_subsystem::lock
Several helpers access or traverse data structures protected by
nvme_subsystem::lock and therefore require callers to hold the lock.
Annotate nvme_mpath_unfreeze(), nvme_mpath_wait_freeze(),
nvme_mpath_start_freeze(), nvme_find_ns_head(), nvme_alloc_ns_head()
and nvme_subsys_check_duplicate_ids() with __must_hold(&subsys->lock)
so that Clang's lock context analysis can validate the locking
requirements at compile time.
Also annotate nvme_subsystem::nsheads and
nvme_ns_head::delayed_removal_secs with __guarded_by(&subsys->lock),
as both are protected by the subsystem lock.
Annotate nvme_init_subsystem() with __context_unsafe(), as it
initializes these lock-protected members before the object is published,
suppressing a false positive from Clang's context analysis.
Reviewed-by: Christoph Hellwig <hch@lst.de>
Signed-off-by: Nilay Shroff <nilay@linux.ibm.com>
Signed-off-by: Keith Busch <kbusch@kernel.org>
Diffstat (limited to 'tools/perf/scripts/python/bin/stackcollapse-record')
0 files changed, 0 insertions, 0 deletions
