From: Christoph Hellwig <hch@infradead.org>
To: Mikulas Patocka <mpatocka@redhat.com>
Cc: Jens Axboe <axboe@kernel.dk>,
Zdenek Kabelac <zkabelac@redhat.com>,
Christoph Hellwig <hch@infradead.org>,
linux-block@vger.kernel.org, dm-devel@redhat.com
Subject: Re: [PATCH v2 4/4] brd: implement secure erase and write zeroes
Date: Fri, 23 Sep 2022 08:54:19 -0700 [thread overview]
Message-ID: <Yy3Wq2Hnb8KEbyb3@infradead.org> (raw)
In-Reply-To: <alpine.LRH.2.02.2209201358580.26535@file01.intranet.prod.int.rdu2.redhat.com>
On Tue, Sep 20, 2022 at 01:59:46PM -0400, Mikulas Patocka wrote:
> This patch implements REQ_OP_SECURE_ERASE and REQ_OP_WRITE_ZEROES on brd.
> Write zeroes will free the pages just like discard, but the difference is
> that it writes zeroes to the preceding and following page if the range is
> not aligned on page boundary. Secure erase is just like write zeroes,
> except that it clears the page content before freeing the page.
So while I can see the use case for the simple discard you mentioned,
and maybe even the WRITE_ZEROES, I'd rather have a really good
justification for REQ_OP_SECURE_ERASE. It is a bad interface,
and there are alsmost no good reasons for ever using it. So sprinkling
it in random drivers just we can is not helpful.
next prev parent reply other threads:[~2022-09-23 15:54 UTC|newest]
Thread overview: 20+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-09-20 17:52 [PATCH v2 0/4] brd: implement discard Mikulas Patocka
2022-09-20 17:53 ` [PATCH v2 1/4] brd: make brd_insert_page return bool Mikulas Patocka
2022-09-21 5:00 ` Chaitanya Kulkarni
2022-09-20 17:56 ` [PATCH v2 2/4] brd: extend the rcu regions to cover read and write Mikulas Patocka
2022-09-23 15:52 ` Christoph Hellwig
2022-09-20 17:58 ` [PATCH v2 3/4] brd: enable discard Mikulas Patocka
2023-07-10 12:32 ` Li Nan
2023-07-10 15:24 ` Mikulas Patocka
2023-07-10 19:05 ` Jens Axboe
2023-07-13 11:45 ` Christoph Hellwig
2023-07-19 20:14 ` Mikulas Patocka
2022-09-20 17:59 ` [PATCH v2 4/4] brd: implement secure erase and write zeroes Mikulas Patocka
2022-09-21 5:03 ` Chaitanya Kulkarni
2022-09-21 9:09 ` Pankaj Raghav
2022-09-23 15:54 ` Christoph Hellwig [this message]
2022-09-21 5:20 ` [dm-devel] [PATCH v2 0/4] brd: implement discard Gao Xiang
2022-09-27 14:09 ` Mikulas Patocka
2022-09-28 1:03 ` Gao Xiang
2022-09-29 20:05 ` Mikulas Patocka
2022-09-29 20:48 ` Gao Xiang
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=Yy3Wq2Hnb8KEbyb3@infradead.org \
--to=hch@infradead.org \
--cc=axboe@kernel.dk \
--cc=dm-devel@redhat.com \
--cc=linux-block@vger.kernel.org \
--cc=mpatocka@redhat.com \
--cc=zkabelac@redhat.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).