[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <20250508055951.GA28277@lst.de>
Date: Thu, 8 May 2025 07:59:51 +0200
From: Christoph Hellwig <hch@....de>
To: Ahmad Fatoum <a.fatoum@...gutronix.de>
Cc: "Darrick J. Wong" <djwong@...nel.org>, Christoph Hellwig <hch@....de>,
Jens Axboe <axboe@...nel.dk>, Ulf Hansson <ulf.hansson@...aro.org>,
Jan Lübbe <jlu@...gutronix.de>,
"kernel@...gutronix.de" <kernel@...gutronix.de>,
linux-block@...r.kernel.org, linux-mmc@...r.kernel.org,
"linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>
Subject: Re: [RFC] block: Make MMC respect REQ_NOUNMAP?
On Wed, May 07, 2025 at 06:24:34PM +0200, Ahmad Fatoum wrote:
> blk_ioctl_zeroout
> blkdev_issue_zeroout(..., BLKDEV_ZERO_NOUNMAP)
> __blkdev_issue_write_zeroes(..., BLKDEV_ZERO_NOUNMAP)
> submit_bio_wait(bio->bi_opf = REQ_NOUNMAP)
>
> __REQ_NOUNMAP has comment saying 'do not free blocks when zeroing',
> but as shown above, TRIM allows the card to unmap the indicated region.
__REQ_NOUNMAP is a hint. All the storage specs are a mess in this
area as they usually get the polarity wrong and/or just have very
vague semantics. Also actually writing zeroes and not unmapping is
totally pointless on flash storage as it just increases PE cycles
for no good reason.
Powered by blists - more mailing lists