[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20160416015021.GA3694@infradead.org>
Date: Fri, 15 Apr 2016 18:50:21 -0700
From: Christoph Hellwig <hch@...radead.org>
To: Jinpu Wang <jinpu.wang@...fitbricks.com>
Cc: Jens Axboe <axboe@...com>,
"linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>
Subject: Re: [PATCHv2]brd: set max_discard_sectors properly
> - blk_queue_max_discard_sectors(brd->brd_queue, UINT_MAX);
> + blk_queue_max_discard_sectors(brd->brd_queue, UINT_MAX >> 9);
Shouldn't we fix the issue by capping to UINT_MAX >> 9 inside
blk_queue_max_discard_sectors? That way we'll prevent against having
issues like this in any other driver as well.
Powered by blists - more mailing lists