diff options
| author | Tal Zussman <tz2294@columbia.edu> | 2026-07-30 02:57:51 -0400 |
|---|---|---|
| committer | Jens Axboe <axboe@kernel.dk> | 2026-07-31 09:00:14 -0600 |
| commit | 8ed0831b5263e1aa48d99063795a1f20e4e69b50 (patch) | |
| tree | 8004db5327c522c49734779ea46911e8108849a1 /tools/perf/scripts/python/flamegraph.py | |
| parent | 14b007e178811db72fbb1ebb3535160db6ec1e6a (diff) | |
block: introduce bio_in_atomic()
Move the atomic context detection logic from erofs's z_erofs_in_atomic()
into the block layer as bio_in_atomic(). This helper returns true when
the current context is unsafe for sleeping bio completion handlers (e.g.,
hard/soft IRQ, preempt-disabled).
The logic was originally added to erofs in commit c99fab6e80b7 ("erofs:
fix atomic context detection when !CONFIG_DEBUG_LOCK_ALLOC"). A
subsequent patch will use it in the block layer's bio completion
infrastructure, so move it to include/linux/bio.h where both subsystems
can share it.
Convert erofs to call the new bio_in_atomic() directly.
Suggested-by: Christoph Hellwig <hch@infradead.org>
Signed-off-by: Tal Zussman <tz2294@columbia.edu>
Reviewed-by: Jan Kara <jack@suse.cz>
Reviewed-by: Christoph Hellwig <hch@lst.de>
Link: https://patch.msgid.link/20260730-blk-dontcache-v7-1-3e8e6850068d@columbia.edu
Signed-off-by: Jens Axboe <axboe@kernel.dk>
Diffstat (limited to 'tools/perf/scripts/python/flamegraph.py')
0 files changed, 0 insertions, 0 deletions
