lkml.org 
[lkml]   [2020]   [Apr]   [23]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: s390 boot woe due to "block: fix busy device checking in blk_drop_partitions"
Hi.

On Fri, Apr 10, 2020 at 07:45:44AM +0200, Christoph Hellwig <hch@lst.de> wrote:
> @@ -496,7 +496,7 @@ int blk_drop_partitions(struct gendisk *disk, struct block_device *bdev)
> - if (bdev->bd_part_count || bdev->bd_openers)
> + if (bdev->bd_part_count || bdev->bd_openers > 1)
> return -EBUSY;
I noticed this (and the previous patch) change unmasks race between
ioctl(LOOP_SET_STATUS64, ... lo_flags=LO_FLAGS_PARTSCAN ...) and udev
processing loop device uevents. See [1] for details.

Should the condition be changed in the case of newly setup loop devices?
(Or shouldn't the ioctl propagate EBUSY in its return value?)

Thanks,
Michal

[1] https://bugzilla.opensuse.org/show_bug.cgi?id=1169932
[unhandled content-type:application/pgp-signature]
\
 
 \ /
  Last update: 2020-04-23 13:07    [W:0.054 / U:0.596 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site