linux/block
Christoph Hellwig b9684a71fc block, loop: support partitions without scanning
Historically we did distinguish between a flag that surpressed partition
scanning, and a combinations of the minors variable and another flag if
any partitions were supported.  This was generally confusing and doesn't
make much sense, but some corner case uses of the loop driver actually
do want to support manually added partitions on a device that does not
actively scan for partitions.  To make things worsee the loop driver
also wants to dynamically toggle the scanning for partitions on a live
gendisk, which makes the disk->flags updates non-atomic.

Introduce a new GD_SUPPRESS_PART_SCAN bit in disk->state that disables
just scanning for partitions, and toggle that instead of GENHD_FL_NO_PART
in the loop driver.

Fixes: 1ebe2e5f9d ("block: remove GENHD_FL_EXT_DEVT")
Reported-by: Ming Lei <ming.lei@redhat.com>
Signed-off-by: Christoph Hellwig <hch@lst.de>
Reviewed-by: Ming Lei <ming.lei@redhat.com>
Link: https://lore.kernel.org/r/20220527055806.1972352-1-hch@lst.de
Signed-off-by: Jens Axboe <axboe@kernel.dk>
2022-05-27 06:39:00 -06:00
..
partitions block: turn bdev->bd_openers into an atomic_t 2022-04-18 06:54:09 -06:00
badblocks.c
bdev.c block: turn bdev->bd_openers into an atomic_t 2022-04-18 06:54:09 -06:00
bfq-cgroup.c bfq: Make sure bfqg for which we are queueing requests is online 2022-04-17 19:34:32 -06:00
bfq-iosched.c bfq: Get rid of __bio_blkcg() usage 2022-04-17 19:34:29 -06:00
bfq-iosched.h bfq: Get rid of __bio_blkcg() usage 2022-04-17 19:34:29 -06:00
bfq-wf2q.c block, bfq: cleanup bfq_bfqq_to_bfqg() 2022-02-18 06:13:00 -07:00
bio-integrity.c for-5.18/block-2022-03-18 2022-03-21 16:48:55 -07:00
bio.c block: turn bio_kmalloc into a simple kmalloc wrapper 2022-04-17 19:30:41 -06:00
blk-cgroup-rwstat.c
blk-cgroup-rwstat.h block: partition include/linux/blk-cgroup.h 2022-02-11 10:02:41 -07:00
blk-cgroup.c for-5.18/block-2022-04-01 2022-04-01 16:20:00 -07:00
blk-cgroup.h block: don't merge across cgroup boundaries if blkcg is enabled 2022-03-14 19:14:37 -06:00
blk-core.c block: decouple REQ_OP_SECURE_ERASE from REQ_OP_DISCARD 2022-04-17 19:49:59 -06:00
blk-crypto-fallback.c block: turn bio_kmalloc into a simple kmalloc wrapper 2022-04-17 19:30:41 -06:00
blk-crypto-internal.h blk-crypto: show crypto capabilities in sysfs 2022-02-28 06:40:23 -07:00
blk-crypto-profile.c
blk-crypto-sysfs.c blk-crypto: show crypto capabilities in sysfs 2022-02-28 06:40:23 -07:00
blk-crypto.c blk-crypto: show crypto capabilities in sysfs 2022-02-28 06:40:23 -07:00
blk-flush.c block: pass a block_device and opf to bio_init 2022-02-02 07:49:59 -07:00
blk-ia-ranges.c block: fix memory leak in disk_register_independent_access_ranges 2022-01-23 09:13:09 -07:00
blk-integrity.c
blk-ioc.c block: restore the old set_task_ioprio() behaviour wrt PF_EXITING 2022-03-28 06:34:11 -06:00
blk-iocost.c block: partition include/linux/blk-cgroup.h 2022-02-11 10:02:41 -07:00
blk-iolatency.c block: fix rq-qos breakage from skipping rq_qos_done_bio() 2022-03-14 14:23:13 -06:00
blk-ioprio.c block: partition include/linux/blk-cgroup.h 2022-02-11 10:02:41 -07:00
blk-ioprio.h
blk-lib.c block: decouple REQ_OP_SECURE_ERASE from REQ_OP_DISCARD 2022-04-17 19:49:59 -06:00
blk-map.c block: turn bio_kmalloc into a simple kmalloc wrapper 2022-04-17 19:30:41 -06:00
blk-merge.c for-5.18/write-streams-2022-03-18 2022-03-26 11:51:46 -07:00
blk-mq-cpumap.c
blk-mq-debugfs-zoned.c
blk-mq-debugfs.c block: decouple REQ_OP_SECURE_ERASE from REQ_OP_DISCARD 2022-04-17 19:49:59 -06:00
blk-mq-debugfs.h blk-mq: manage hctx map via xarray 2022-03-08 19:39:38 -07:00
blk-mq-pci.c
blk-mq-rdma.c
blk-mq-sched.c block: limit request dispatch loop duration 2022-03-17 20:31:43 -06:00
blk-mq-sched.h
blk-mq-sysfs.c blk-mq: prepare for implementing hctx table via xarray 2022-03-08 17:57:19 -07:00
blk-mq-tag.c blk-mq: manage hctx map via xarray 2022-03-08 19:39:38 -07:00
blk-mq-tag.h
blk-mq-virtio.c
blk-mq.c block: don't print I/O error warning for dead disks 2022-04-15 06:33:03 -06:00
blk-mq.h blk-mq: manage hctx map via xarray 2022-03-08 19:39:38 -07: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.h block: fix rq-qos breakage from skipping rq_qos_done_bio() 2022-03-14 14:23:13 -06:00
blk-settings.c block: decouple REQ_OP_SECURE_ERASE from REQ_OP_DISCARD 2022-04-17 19:49:59 -06:00
blk-stat.c block: make queue stat accounting a reference 2021-12-14 17:23:05 -07:00
blk-stat.h block: make queue stat accounting a reference 2021-12-14 17:23:05 -07:00
blk-sysfs.c SCSI misc on 20220324 2022-03-24 19:37:53 -07:00
blk-throttle.c block: cancel all throttled bios in del_gendisk() 2022-03-18 09:57:56 -06:00
blk-throttle.h block: cancel all throttled bios in del_gendisk() 2022-03-18 09:57:56 -06:00
blk-timeout.c
blk-wbt.c
blk-wbt.h blk-wbt: remove wbt_track stub 2022-03-31 12:58:38 -06:00
blk-zoned.c SCSI misc on 20220324 2022-03-24 19:37:53 -07:00
blk.h block: refactor discard bio size limiting 2022-04-17 19:49:59 -06:00
bounce.c for-5.18/write-streams-2022-03-18 2022-03-26 11:51:46 -07:00
bsg-lib.c
bsg.c
disk-events.c block: remove genhd.h 2022-02-02 07:49:59 -07:00
elevator.c for-5.18/block-2022-03-18 2022-03-21 16:48:55 -07:00
elevator.h
fops.c block: decouple REQ_OP_SECURE_ERASE from REQ_OP_DISCARD 2022-04-17 19:49:59 -06:00
genhd.c block, loop: support partitions without scanning 2022-05-27 06:39:00 -06:00
holder.c block: remove genhd.h 2022-02-02 07:49:59 -07:00
ioctl.c block: decouple REQ_OP_SECURE_ERASE from REQ_OP_DISCARD 2022-04-17 19:49:59 -06:00
ioprio.c for-5.17/block-2022-01-11 2022-01-12 10:26:52 -08:00
Kconfig block: add pi for extended integrity 2022-03-07 12:48:35 -07:00
Kconfig.iosched block: only build the icq tracking code when needed 2021-12-16 10:59:02 -07:00
kyber-iosched.c block: make queue stat accounting a reference 2021-12-14 17:23:05 -07:00
Makefile blk-crypto: show crypto capabilities in sysfs 2022-02-28 06:40:23 -07:00
mq-deadline.c block: fix async_depth sysfs interface for mq-deadline 2022-01-20 10:54:02 -07:00
opal_proto.h
sed-opal.c block: remove genhd.h 2022-02-02 07:49:59 -07:00
t10-pi.c block: add pi for extended integrity 2022-03-07 12:48:35 -07:00