[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20210105010456.GA6454@localhost.localdomain>
Date: Tue, 5 Jan 2021 10:04:56 +0900
From: Minwoo Im <minwoo.im.dev@...il.com>
To: Christoph Hellwig <hch@....de>
Cc: linux-block@...r.kernel.org, linux-kernel@...r.kernel.org,
linux-fsdevel@...r.kernel.org, Jens Axboe <axboe@...nel.dk>,
Alexander Viro <viro@...iv.linux.org.uk>,
Chaitanya Kulkarni <Chaitanya.Kulkarni@....com>
Subject: Re: [RFC PATCH V3 1/1] block: reject I/O for same fd if block size
changed
Hello Christoph,
Thanks for your review.
On 21-01-04 18:11:41, Christoph Hellwig wrote:
> On Mon, Jan 04, 2021 at 06:11:08PM +0100, Christoph Hellwig wrote:
> > On Mon, Jan 04, 2021 at 10:06:59PM +0900, Minwoo Im wrote:
> > > + if (q->backing_dev_info && q->backing_dev_info->owner &&
> > > + limits->logical_block_size != size) {
> > > + bdev = blkdev_get_no_open(q->backing_dev_info->owner->devt);
> > > + bdev->bd_disk->flags |= GENHD_FL_BLOCK_SIZE_CHANGED;
> > > + blkdev_put_no_open(bdev);
> > > + }
> >
> > We really need the backpointer from the queue to the gendisk I've wanted
> > to add for a while. Can we at least restrict this to a live gendisk?
It was a point that I really would like to ask by RFC whether we can
have backpointer to the gendisk from the request_queue. And I'd like to
have it to simplify this routine and for future usages also.
I will restrict this one by checking GENHD_FL_UP flag from the gendisk
for the next patch.
>
> Alternatively we could make this request_queue QUEUE* flag for now.
As this patch rejects I/O from the block layer partition code, can we
have this flag in gendisk rather than request_queue ?
Thanks,
Powered by blists - more mailing lists