Re: [Nbd] [PATCH 5/6] block: dasd_genhd: convert to blkdev_reread_part
- To: Jarod Wilson <jarod@...696...>
- Cc: Jens Axboe <axboe@...161...>, "nbd-general@lists.sourceforge.net" <nbd-general@lists.sourceforge.net>, linux-s390@...25..., Stefan Haberland <stefan.haberland@...1296...>, Sebastian Ott <sebott@...1294...>, Linux Kernel Mailing List <linux-kernel@...25...>, Christoph Hellwig <hch@...1270...>, Fabian Frederick <fabf@...1980...>, Alexander Viro <viro@...1300...>, David Herrmann <dh.herrmann@...17...>, Tejun Heo <tj@...1285...>, Andrew Morton <akpm@...133...>
- Subject: Re: [Nbd] [PATCH 5/6] block: dasd_genhd: convert to blkdev_reread_part
- From: Ming Lei <ming.lei@...1301...>
- Date: Tue, 7 Apr 2015 09:59:46 +0800
- Message-id: <CACVXFVP24TLjg6VJ0HJc7pXTU0K1x+7Ez2xzKWDQqO73gCLxQQ@...18...>
- In-reply-to: <20150406135134.GG14217@...696...>
- References: <1428218688-4092-1-git-send-email-ming.lei@...1301...> <1428218688-4092-6-git-send-email-ming.lei@...1301...> <20150406134655.GE14217@...696...> <20150406135134.GG14217@...696...>
On Mon, Apr 6, 2015 at 9:51 PM, Jarod Wilson <jarod@...696...> wrote:
>>
>> Note: patch 6/6 in the series makes this whole while() loops pointless,
>> since the possibility of the -EBUSY return goes away.
>
> Minor clarification: the -EBUSY due to the trylock, which is why that
> retry loop exists, goes away. You *could* still get an -EBUSY through
> blkdev_reread_part()->rescan_partitions()->drop_partitions() if
> bdev->bd_part_count is non-zero.
Not like trylock(&bd_mutex), Inside kernel, it should be driver's
responsibility to avoid that before rescanning partitions, that said
retry may not be needed for this case.
Thanks,
Reply to: