* [PATCH] block: default BLOCK_LEGACY_AUTOLOAD to y
@ 2022-02-25 18:14 Christoph Hellwig
2022-02-25 18:37 ` Chaitanya Kulkarni
` (2 more replies)
0 siblings, 3 replies; 5+ messages in thread
From: Christoph Hellwig @ 2022-02-25 18:14 UTC (permalink / raw)
To: axboe; +Cc: linux-block, Luis Chamberlain
As Luis reported, losetup currently doesn't properly create the loop
device without this if the device node already exists because old
scripts created it manually. So default to y for now and remove the
aggressive removal schedule.
Reported-by: Luis Chamberlain <mcgrof@kernel.org>
Signed-off-by: Christoph Hellwig <hch@lst.de>
---
block/Kconfig | 8 +++-----
block/bdev.c | 2 +-
2 files changed, 4 insertions(+), 6 deletions(-)
diff --git a/block/Kconfig b/block/Kconfig
index 168b873eb666d..7eb5d6d53b3fc 100644
--- a/block/Kconfig
+++ b/block/Kconfig
@@ -28,15 +28,13 @@ if BLOCK
config BLOCK_LEGACY_AUTOLOAD
bool "Legacy autoloading support"
+ default y
help
Enable loading modules and creating block device instances based on
accesses through their device special file. This is a historic Linux
feature and makes no sense in a udev world where device files are
- created on demand.
-
- Say N here unless booting or other functionality broke without it, in
- which case you should also send a report to your distribution and
- linux-block@vger.kernel.org.
+ created on demand, but scripts that manually create device nodes and
+ then call losetup might rely on this behavior.
config BLK_RQ_ALLOC_TIME
bool
diff --git a/block/bdev.c b/block/bdev.c
index c687726445660..a3632317c8aae 100644
--- a/block/bdev.c
+++ b/block/bdev.c
@@ -738,7 +738,7 @@ struct block_device *blkdev_get_no_open(dev_t dev)
inode = ilookup(blockdev_superblock, dev);
if (inode)
pr_warn_ratelimited(
-"block device autoloading is deprecated. It will be removed in Linux 5.19\n");
+"block device autoloading is deprecated and will be removed.\n");
}
if (!inode)
return NULL;
--
2.30.2
^ permalink raw reply related [flat|nested] 5+ messages in thread* Re: [PATCH] block: default BLOCK_LEGACY_AUTOLOAD to y
2022-02-25 18:14 [PATCH] block: default BLOCK_LEGACY_AUTOLOAD to y Christoph Hellwig
@ 2022-02-25 18:37 ` Chaitanya Kulkarni
2022-02-25 20:31 ` Jens Axboe
2022-02-25 21:23 ` Luis Chamberlain
2 siblings, 0 replies; 5+ messages in thread
From: Chaitanya Kulkarni @ 2022-02-25 18:37 UTC (permalink / raw)
To: Christoph Hellwig
Cc: linux-block@vger.kernel.org, axboe@kernel.dk, Luis Chamberlain
On 2/25/22 10:14, Christoph Hellwig wrote:
> As Luis reported, losetup currently doesn't properly create the loop
> device without this if the device node already exists because old
> scripts created it manually. So default to y for now and remove the
> aggressive removal schedule.
>
> Reported-by: Luis Chamberlain <mcgrof@kernel.org>
> Signed-off-by: Christoph Hellwig <hch@lst.de>
Looks good.
Reviewed-by: Chaitanya Kulkarni <kch@nvidia.com>
-ck
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [PATCH] block: default BLOCK_LEGACY_AUTOLOAD to y
2022-02-25 18:14 [PATCH] block: default BLOCK_LEGACY_AUTOLOAD to y Christoph Hellwig
2022-02-25 18:37 ` Chaitanya Kulkarni
@ 2022-02-25 20:31 ` Jens Axboe
2022-02-25 21:23 ` Luis Chamberlain
2 siblings, 0 replies; 5+ messages in thread
From: Jens Axboe @ 2022-02-25 20:31 UTC (permalink / raw)
To: Christoph Hellwig; +Cc: Luis Chamberlain, linux-block
On Fri, 25 Feb 2022 19:14:40 +0100, Christoph Hellwig wrote:
> As Luis reported, losetup currently doesn't properly create the loop
> device without this if the device node already exists because old
> scripts created it manually. So default to y for now and remove the
> aggressive removal schedule.
>
>
Applied, thanks!
[1/1] block: default BLOCK_LEGACY_AUTOLOAD to y
commit: 23c8d32e573c97177eb51c1384b774cfa7fa3710
Best regards,
--
Jens Axboe
^ permalink raw reply [flat|nested] 5+ messages in thread* Re: [PATCH] block: default BLOCK_LEGACY_AUTOLOAD to y
2022-02-25 18:14 [PATCH] block: default BLOCK_LEGACY_AUTOLOAD to y Christoph Hellwig
2022-02-25 18:37 ` Chaitanya Kulkarni
2022-02-25 20:31 ` Jens Axboe
@ 2022-02-25 21:23 ` Luis Chamberlain
2022-12-28 16:55 ` Anisse Astier
2 siblings, 1 reply; 5+ messages in thread
From: Luis Chamberlain @ 2022-02-25 21:23 UTC (permalink / raw)
To: Christoph Hellwig, Hannes Reinecke, Jeff Mahoney, Karel Zak,
Ming Lei, Mike Snitzer
Cc: axboe, linux-block
On Fri, Feb 25, 2022 at 07:14:40PM +0100, Christoph Hellwig wrote:
> As Luis reported, losetup currently doesn't properly create the loop
> device without this if the device node already exists because old
> scripts created it manually. So default to y for now and remove the
> aggressive removal schedule.
>
> Reported-by: Luis Chamberlain <mcgrof@kernel.org>
> Signed-off-by: Christoph Hellwig <hch@lst.de>
I'm saddened by the fact that we're not going to get an idea of how far
and wide the stupid mknod prior to modprobe use is by making this
as y default even though I know this is the right thing to do.
I think our ownly measure of success here is to really push
Linux distributions to start disabling BLOCK_LEGACY_AUTOLOAD
and getting their help to see what burts into flames.
Without that endevour we're positioning ourselves to keep the stupid
BLOCK_LEGACY_AUTOLOAD forever.
I *thought* that for some odd uses cases, maybe early-init, or virt-io,
mknod might be used to this day, because of some odd boot failures I saw
with linux-next, but I'm no longer seeing those boot failures anymore
and I cannot confirm.
Luis
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [PATCH] block: default BLOCK_LEGACY_AUTOLOAD to y
2022-02-25 21:23 ` Luis Chamberlain
@ 2022-12-28 16:55 ` Anisse Astier
0 siblings, 0 replies; 5+ messages in thread
From: Anisse Astier @ 2022-12-28 16:55 UTC (permalink / raw)
To: mcgrof; +Cc: axboe, hare, hch, jeffm, kzak, linux-block, ming.lei, snitzer
Hi,
On Fri, 25 Feb 2022 13:23:45 -0800, Luis Chamberlain wrote:
> On Fri, Feb 25, 2022 at 07:14:40PM +0100, Christoph Hellwig wrote:
> > As Luis reported, losetup currently doesn't properly create the loop
> > device without this if the device node already exists because old
> > scripts created it manually. So default to y for now and remove the
> > aggressive removal schedule.
> >
> > Reported-by: Luis Chamberlain <mcgrof@kernel.org>
> > Signed-off-by: Christoph Hellwig <hch@lst.de>
>
> I'm saddened by the fact that we're not going to get an idea of how far
> and wide the stupid mknod prior to modprobe use is by making this
> as y default even though I know this is the right thing to do.
>
> I think our ownly measure of success here is to really push
> Linux distributions to start disabling BLOCK_LEGACY_AUTOLOAD
> and getting their help to see what burts into flames.
I just spent some time bisecting another thing that regresses without
BLOCK_LEGACY_AUTOLOAD (which was disabled here): mdadm software raid
auto-assemble on boot (with udev).
I think it's because it tries to open /dev/md127 and then fails since it's not
created automatically.
Regards,
Anisse
^ permalink raw reply [flat|nested] 5+ messages in thread
end of thread, other threads:[~2022-12-28 17:01 UTC | newest]
Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2022-02-25 18:14 [PATCH] block: default BLOCK_LEGACY_AUTOLOAD to y Christoph Hellwig
2022-02-25 18:37 ` Chaitanya Kulkarni
2022-02-25 20:31 ` Jens Axboe
2022-02-25 21:23 ` Luis Chamberlain
2022-12-28 16:55 ` Anisse Astier
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox