linux-stable/block
Ming Lei d937647284 block: make sure local irq is disabled when calling __blkcg_rstat_flush
commit 9c39b7a905 upstream.

When __blkcg_rstat_flush() is called from cgroup_rstat_flush*() code
path, interrupt is always disabled.

When we start to flush blkcg per-cpu stats list in __blkg_release()
for avoiding to leak blkcg_gq's reference in commit 20cb1c2fb7
("blk-cgroup: Flush stats before releasing blkcg_gq"), local irq
isn't disabled yet, then lockdep warning may be triggered because
the dependent cgroup locks may be acquired from irq(soft irq) handler.

Fix the issue by disabling local irq always.

Fixes: 20cb1c2fb7 ("blk-cgroup: Flush stats before releasing blkcg_gq")
Reported-by: Shinichiro Kawasaki <shinichiro.kawasaki@wdc.com>
Closes: https://lore.kernel.org/linux-block/pz2wzwnmn5tk3pwpskmjhli6g3qly7eoknilb26of376c7kwxy@qydzpvt6zpis/T/#u
Cc: stable@vger.kernel.org
Cc: Jay Shin <jaeshin@redhat.com>
Cc: Tejun Heo <tj@kernel.org>
Cc: Waiman Long <longman@redhat.com>
Signed-off-by: Ming Lei <ming.lei@redhat.com>
Reviewed-by: Waiman Long <longman@redhat.com>
Link: https://lore.kernel.org/r/20230622084249.1208005-1-ming.lei@redhat.com
Signed-off-by: Jens Axboe <axboe@kernel.dk>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2023-06-28 11:14:10 +02:00
..
partitions driver core: make struct device_type.uevent() take a const * 2023-01-27 13:45:36 +01:00
badblocks.c block/badblocks: Remove redundant assignments 2022-04-23 07:15:26 -06:00
bdev.c block: remove ->rw_page 2023-02-02 22:33:34 -08:00
bfq-cgroup.c for-6.3/block-2023-02-16 2023-02-20 14:27:21 -08:00
bfq-iosched.c block, bfq: Fix division by zero error on zero wsum 2023-05-24 17:30:06 +01:00
bfq-iosched.h block, bfq: cleanup 'bfqg->online' 2023-02-07 10:20:59 -07:00
bfq-wf2q.c block, bfq: inject I/O to underutilized actuators 2023-01-29 15:18:33 -07:00
bio-integrity.c block: bio-integrity: Copy flags when bio_integrity_payload is cloned 2023-02-16 11:05:41 -07:00
bio.c block-6.3-2023-03-03 2023-03-03 10:21:39 -08:00
blk-cgroup-fc-appid.c cgroup: Homogenize cgroup_get_from_id() return value 2022-08-26 10:57:41 -10:00
blk-cgroup-rwstat.c Revert "blk-cgroup: pin the gendisk in struct blkcg_gq" 2023-02-14 14:24:09 -07:00
blk-cgroup-rwstat.h block: Use the new blk_opf_t type 2022-07-14 12:14:30 -06:00
blk-cgroup.c block: make sure local irq is disabled when calling __blkcg_rstat_flush 2023-06-28 11:14:10 +02:00
blk-cgroup.h Revert "blk-cgroup: pin the gendisk in struct blkcg_gq" 2023-02-14 14:24:09 -07:00
blk-core.c block: count 'ios' and 'sectors' when io is done for bio-based device 2023-03-15 09:25:04 -06:00
blk-crypto-fallback.c treewide: use get_random_bytes() when possible 2022-10-11 17:42:58 -06:00
blk-crypto-internal.h blk-mq: release crypto keyslot before reporting I/O complete 2023-05-11 23:16:48 +09:00
blk-crypto-profile.c blk-crypto: make blk_crypto_evict_key() more robust 2023-05-11 23:16:48 +09:00
blk-crypto-sysfs.c block: make kobj_type structures constant 2023-02-09 09:38:16 -07:00
blk-crypto.c blk-crypto: make blk_crypto_evict_key() more robust 2023-05-11 23:16:48 +09:00
blk-flush.c block: change request end_io handler to pass back a return value 2022-09-30 07:49:09 -06:00
blk-ia-ranges.c block: make kobj_type structures constant 2023-02-09 09:38:16 -07:00
blk-integrity.c block: make kobj_type structures constant 2023-02-09 09:38:16 -07:00
blk-ioc.c block: fix default IO priority handling again 2022-06-27 06:29:12 -06:00
blk-iocost.c blk-iocost: Pass gendisk to ioc_refresh_params 2023-02-28 05:51:19 -07:00
blk-iolatency.c Revert "blk-cgroup: pin the gendisk in struct blkcg_gq" 2023-02-14 14:24:09 -07:00
blk-ioprio.c blk-cgroup: pass a gendisk to pd_alloc_fn 2023-02-03 08:20:05 -07:00
blk-ioprio.h blk-ioprio: pass a gendisk to blk_ioprio_init and blk_ioprio_exit 2022-09-26 19:09:31 -06:00
blk-lib.c blk-lib: fix blkdev_issue_secure_erase 2022-09-15 00:25:17 -06:00
blk-map.c block: fix bio-cache for passthru IO 2023-05-30 14:17:22 +01:00
blk-merge.c blk-mq: release crypto keyslot before reporting I/O complete 2023-05-11 23:16:48 +09:00
blk-mq-cpumap.c blk-mq: Build default queue map via group_cpus_evenly() 2023-01-17 18:50:06 +01:00
blk-mq-debugfs-zoned.c block: move zone related fields to struct gendisk 2022-07-06 06:46:26 -06:00
blk-mq-debugfs.c blk-rq-qos: store a gendisk instead of request_queue in struct rq_qos 2023-02-03 08:20:05 -07:00
blk-mq-debugfs.h block: remove per-disk debugfs files in blk_unregister_queue 2022-06-17 07:31:05 -06:00
blk-mq-pci.c block: Change the return type of blk_mq_map_queues() into void 2022-08-22 10:07:53 -06:00
blk-mq-rdma.c block: Change the return type of blk_mq_map_queues() into void 2022-08-22 10:07:53 -06:00
blk-mq-sched.c blk-mq: correct stale comment of .get_budget 2023-02-06 09:22:29 -07:00
blk-mq-sched.h block: move blk_mq_sched_assign_ioc to blk-ioc.c 2021-11-29 06:41:29 -07:00
blk-mq-sysfs.c block: make kobj_type structures constant 2023-02-09 09:38:16 -07:00
blk-mq-tag.c blk-mq: fix race condition in active queue accounting 2023-06-05 09:29:43 +02:00
blk-mq-tag.h blk-mq: blk_mq_tag_busy is no need to return a value 2022-06-27 06:29:12 -06:00
blk-mq-virtio.c block: Change the return type of blk_mq_map_queues() into void 2022-08-22 10:07:53 -06:00
blk-mq.c blk-mq: fix blk_mq_hw_ctx active request accounting 2023-06-14 11:17:02 +02:00
blk-mq.h blk-mq: fix "bad unlock balance detected" on q->srcu in __blk_mq_run_dispatch_ops 2023-03-14 19:20:55 -06:00
blk-pm.c scsi: block: pm: Always set request queue runtime active in blk_post_runtime_resume() 2021-12-22 23:38:29 -05:00
blk-pm.h
blk-rq-qos.c blk-rq-qos: store a gendisk instead of request_queue in struct rq_qos 2023-02-03 08:20:05 -07:00
blk-rq-qos.h blk-rq-qos: store a gendisk instead of request_queue in struct rq_qos 2023-02-03 08:20:05 -07:00
blk-settings.c block: fix revalidate performance regression 2023-06-09 10:48:18 +02:00
blk-stat.c blk-stat: fix QUEUE_FLAG_STATS clear 2023-05-11 23:16:48 +09:00
blk-stat.h block: make queue stat accounting a reference 2021-12-14 17:23:05 -07:00
blk-sysfs.c block: make kobj_type structures constant 2023-02-09 09:38:16 -07:00
blk-throttle.c Revert "blk-cgroup: pin the gendisk in struct blkcg_gq" 2023-02-14 14:24:09 -07:00
blk-throttle.h blk-throttle: pass a gendisk to blk_throtl_cancel_bios 2022-09-26 19:17:28 -06:00
blk-timeout.c
blk-wbt.c blk-wbt: fix that wbt can't be disabled by default 2023-06-05 09:29:43 +02:00
blk-wbt.h blk-wbt: move private information from blk-wbt.h to blk-wbt.c 2023-02-03 08:20:05 -07:00
blk-zoned.c block: remove more NULL checks after bdev_get_queue() 2023-02-21 09:23:22 -07:00
blk.h blk-mq: enforce op-specific segment limits in blk_insert_cloned_request 2023-03-02 21:00:20 -07:00
bounce.c block: change the blk_queue_bounce calling convention 2022-08-02 17:22:54 -06:00
bsg-lib.c blk-mq: move the call to blk_put_queue out of blk_mq_destroy_queue 2022-10-25 08:25:10 -06:00
bsg.c Driver Core changes for 6.2-rc1 2022-12-16 03:54:54 -08:00
disk-events.c block: remove genhd.h 2022-02-02 07:49:59 -07:00
elevator.c block: make kobj_type structures constant 2023-02-09 09:38:16 -07:00
elevator.h block: add proper helpers for elevator_type module refcount management 2022-10-23 18:59:17 -06:00
fops.c block: Deny writable memory mapping if block is read-only 2023-06-09 10:48:10 +02:00
genhd.c block: don't set GD_NEED_PART_SCAN if scan partition failed 2023-04-06 20:41:53 -06:00
holder.c block: don't allow a disk link holder to itself 2022-11-16 15:19:56 -07:00
ioctl.c block: fix scan partition for exclusively open device again 2023-02-17 06:15:57 -07:00
ioprio.c block: Fix handling of tasks without ioprio in ioprio_get(2) 2022-06-27 06:29:12 -06:00
Kconfig block: remove obsolete config BLOCK_COMPAT 2023-03-16 09:35:44 -06:00
Kconfig.iosched block: Default to use cgroup support for BFQ 2023-01-30 09:42:42 -07:00
kyber-iosched.c treewide: Convert del_timer*() to timer_shutdown*() 2022-12-25 13:38:09 -08:00
Makefile blk-cgroup: move blkcg_{get,set}_fc_appid out of line 2022-05-02 14:06:20 -06:00
mq-deadline.c block: mq-deadline: Rename deadline_is_seq_writes() 2022-11-28 19:27:45 -07:00
opal_proto.h block: sed-opal: Add ioctl to return device status 2022-08-22 07:52:51 -06:00
sed-opal.c sed-opal: add support flag for SUM in status ioctl 2023-02-17 06:15:53 -07:00
t10-pi.c block: add pi for extended integrity 2022-03-07 12:48:35 -07:00