linux-kernelorg-stable/block
Fengnan Chang 4d0e1f2139 blk-mq: use queue_hctx in blk_mq_map_queue_type
Some caller of blk_mq_map_queue_type now didn't grab
'q_usage_counter', such as blk_mq_cpu_mapped_to_hctx, so we need
protect 'queue_hw_ctx' through rcu.

Also checked all other functions, no more missed cases.

Fixes: 89e1fb7cef ("blk-mq: fix potential uaf for 'queue_hw_ctx'")
Reported-by: Jens Axboe <axboe@kernel.dk>
Signed-off-by: Fengnan Chang <changfengnan@bytedance.com>
Signed-off-by: Jens Axboe <axboe@kernel.dk>
2025-12-01 07:18:31 -07:00
..
partitions block: use min() instead of min_t() 2025-11-20 07:44:29 -07:00
Kconfig block: Remove obsolete configs BLK_MQ_{PCI,VIRTIO} 2025-05-14 05:43:56 -06:00
Kconfig.iosched
Makefile blk-mq: move the DMA mapping code to a separate file 2025-05-16 08:43:41 -06:00
badblocks.c
bdev.c fs: rename generic_delete_inode() and generic_drop_inode() 2025-09-15 16:09:42 +02:00
bfq-cgroup.c
bfq-iosched.c blk-mq: fix elevator depth_updated method 2025-09-05 13:52:52 -06:00
bfq-iosched.h lib/sbitmap: convert shallow_depth from one word to the whole sbitmap 2025-08-07 06:30:17 -06:00
bfq-wf2q.c
bio-integrity-auto.c block: make bio auto-integrity deadlock safe 2025-11-04 12:41:50 -07:00
bio-integrity.c block: make bio auto-integrity deadlock safe 2025-11-04 12:41:50 -07:00
bio.c block: accumulate memory segment gaps per bio 2025-11-06 18:11:58 -07:00
blk-cgroup-fc-appid.c
blk-cgroup-rwstat.c
blk-cgroup-rwstat.h
blk-cgroup.c block: Remove elevator_lock usage from blkg_conf frozen operations 2025-10-15 08:00:19 -06:00
blk-cgroup.h block: initialize bio issue time in blk_mq_submit_bio() 2025-09-10 05:23:45 -06:00
blk-core.c block: fix typos in comments and strings in blk-core 2025-11-25 10:39:49 -07:00
blk-crypto-fallback.c blk-crypto: convert to use bio_submit_split_bioset() 2025-09-10 05:23:46 -06:00
blk-crypto-internal.h
blk-crypto-profile.c blk-crypto: export wrapped key functions 2025-05-06 19:08:08 +02:00
blk-crypto-sysfs.c
blk-crypto.c
blk-flush.c
blk-ia-ranges.c
blk-integrity.c for-6.18/block-20250929 2025-10-02 10:16:56 -07:00
blk-ioc.c copy_process: pass clone_flags as u64 across calltree 2025-09-01 15:31:34 +02:00
blk-iocost.c block: use min() instead of min_t() 2025-11-20 07:44:29 -07:00
blk-iolatency.c blk-mq: add QUEUE_FLAG_BIO_ISSUE_TIME 2025-09-10 05:23:45 -06:00
blk-ioprio.c
blk-ioprio.h
blk-lib.c block: ignore __blkdev_issue_discard() return value 2025-11-25 12:19:39 -07:00
blk-map.c block: accumulate memory segment gaps per bio 2025-11-06 18:11:58 -07:00
blk-merge.c Revert "block: consider discard merge last" 2025-11-18 15:00:12 -07:00
blk-mq-cpumap.c blk-mq: add number of queue calc helper 2025-07-01 10:24:19 -06:00
blk-mq-debugfs.c blk-mq: add QUEUE_FLAG_BIO_ISSUE_TIME 2025-09-10 05:23:45 -06:00
blk-mq-debugfs.h
blk-mq-dma.c block-dma: properly take MMIO path 2025-11-14 05:09:56 -07:00
blk-mq-sched.c block: use {alloc|free}_sched data methods 2025-11-13 09:27:49 -07:00
blk-mq-sched.h block: use {alloc|free}_sched data methods 2025-11-13 09:27:49 -07:00
blk-mq-sysfs.c blk-mq: Move flush queue allocation into blk_mq_init_hctx() 2025-09-08 08:05:32 -06:00
blk-mq-tag.c blk-mq: use array manage hctx map instead of xarray 2025-11-28 09:09:19 -07:00
blk-mq.c blk-mq: fix potential uaf for 'queue_hw_ctx' 2025-11-28 09:09:19 -07:00
blk-mq.h blk-mq: use queue_hctx in blk_mq_map_queue_type 2025-12-01 07:18:31 -07:00
blk-pm.c
blk-pm.h
blk-rq-qos.c block: avoid cpu_hotplug_lock depedency on freeze_lock 2025-08-21 07:11:11 -06:00
blk-rq-qos.h block: validate QoS before calling __rq_qos_done_bio() 2025-08-26 10:34:08 -06:00
blk-settings.c block: add lockdep to queue_limits_commit_update() 2025-11-11 07:51:08 -07:00
blk-stat.c treewide, timers: Rename from_timer() to timer_container_of() 2025-06-08 09:07:37 +02:00
blk-stat.h
blk-sysfs.c block: Remove queue freezing from several sysfs store callbacks 2025-11-18 15:00:11 -07:00
blk-throttle.c block/blk-throttle: Remove throtl_slice from struct throtl_data 2025-11-17 09:39:48 -07:00
blk-throttle.h blk-throttle: fix access race during throttle policy activation 2025-09-08 08:24:44 -06:00
blk-timeout.c
blk-wbt.c blk-wbt: Eliminate ambiguity in the comments of struct rq_wb 2025-08-11 10:21:38 -06:00
blk-wbt.h
blk-zoned.c block: fix NULL pointer dereference in disk_report_zones() 2025-11-13 09:10:04 -07:00
blk.h block: unify elevator tags and type xarrays into struct elv_change_ctx 2025-11-13 09:27:49 -07:00
bsg-lib.c
bsg.c
disk-events.c
early-lookup.c
elevator.c block: use {alloc|free}_sched data methods 2025-11-13 09:27:49 -07:00
elevator.h block: remove the declaration of elevator_init_mq function 2025-11-18 16:27:19 -07:00
fops.c block: move bio_iov_iter_get_bdev_pages to block/fops.c 2025-10-07 08:05:44 -06:00
genhd.c block: Remove references to __device_add_disk() 2025-11-25 10:36:37 -07:00
holder.c
ioctl.c block: introduce BLKREPORTZONESV2 ioctl 2025-11-05 08:07:21 -07:00
ioprio.c block: remove test of incorrect io priority level 2025-05-08 09:04:12 -06:00
kyber-iosched.c block: define alloc_sched_data and free_sched_data methods for kyber 2025-11-13 09:27:49 -07:00
mq-deadline.c block/mq-deadline: Switch back to a single dispatch list 2025-10-20 10:37:42 -06:00
opal_proto.h
sed-opal.c
t10-pi.c block: rename tuple_size field in blk_integrity to metadata_size 2025-07-01 14:00:14 +02:00