* [PATCH V2 0/4] Add MMC erase and secure erase
@ 2010-06-13 10:01 Adrian Hunter
2010-06-13 10:38 ` Adrian Hunter
2010-06-14 8:09 ` Christoph Hellwig
0 siblings, 2 replies; 5+ messages in thread
From: Adrian Hunter @ 2010-06-13 10:01 UTC (permalink / raw)
To: jens.axboe
Cc: hch, Andrew Morton, Kyungmin Park, LKML,
linux-mmc@vger.kernel.org, Madhusudhan Chikkature
Hi
Add ability to do MMC erase and secure erase operations from userspace,
using the BLKDISCARD ioctl and a newly created BLKSECDISCARD ioctl.
Changes from V1
- use discard I/O requests instead of implementing BLKDISCARD in mmc_block
- do not validate erase size for MMC erases, instead round to erase size
- rename MMC max_erase to pref_erase and expose it through sysfs as
"preferred_erase_size"
Adrian Hunter (4):
block: Add BLKSECDISCARD
mmc: Add erase, secure erase, trim and secure trim operations
mmc_block: Add discard and secure discard support
omap_hsmmc: Add erase capability
block/compat_ioctl.c | 1 +
block/ioctl.c | 5 +
drivers/mmc/card/block.c | 125 +++++++++++++++-
drivers/mmc/card/queue.c | 16 ++-
drivers/mmc/core/core.c | 346 +++++++++++++++++++++++++++++++++++++++++
drivers/mmc/core/core.h | 2 +
drivers/mmc/core/mmc.c | 47 ++++++-
drivers/mmc/core/sd.c | 82 ++++++++++
drivers/mmc/core/sd_ops.c | 48 ++++++
drivers/mmc/core/sd_ops.h | 1 +
drivers/mmc/host/omap_hsmmc.c | 13 ++-
include/linux/fs.h | 1 +
include/linux/mmc/card.h | 19 +++
include/linux/mmc/core.h | 19 +++
include/linux/mmc/host.h | 1 +
include/linux/mmc/mmc.h | 24 ++-
include/linux/mmc/sd.h | 5 +
17 files changed, 742 insertions(+), 13 deletions(-)
Regards
Adrian
^ permalink raw reply [flat|nested] 5+ messages in thread
* [PATCH V2 0/4] Add MMC erase and secure erase
2010-06-13 10:01 [PATCH V2 0/4] Add MMC erase and secure erase Adrian Hunter
@ 2010-06-13 10:38 ` Adrian Hunter
2010-06-14 8:09 ` Christoph Hellwig
1 sibling, 0 replies; 5+ messages in thread
From: Adrian Hunter @ 2010-06-13 10:38 UTC (permalink / raw)
To: Jens Axboe
Cc: hch@lst.de, Andrew Morton, Kyungmin Park, LKML,
linux-mmc@vger.kernel.org, Madhusudhan Chikkature
<Now with Jens Axboe correct email address>
Hi
Add ability to do MMC erase and secure erase operations from userspace,
using the BLKDISCARD ioctl and a newly created BLKSECDISCARD ioctl.
Changes from V1
- use discard I/O requests instead of implementing BLKDISCARD in mmc_block
- do not validate erase size for MMC erases, instead round to erase size
- rename MMC max_erase to pref_erase and expose it through sysfs as
"preferred_erase_size"
Adrian Hunter (4):
block: Add BLKSECDISCARD
mmc: Add erase, secure erase, trim and secure trim operations
mmc_block: Add discard and secure discard support
omap_hsmmc: Add erase capability
block/compat_ioctl.c | 1 +
block/ioctl.c | 5 +
drivers/mmc/card/block.c | 125 +++++++++++++++-
drivers/mmc/card/queue.c | 16 ++-
drivers/mmc/core/core.c | 346 +++++++++++++++++++++++++++++++++++++++++
drivers/mmc/core/core.h | 2 +
drivers/mmc/core/mmc.c | 47 ++++++-
drivers/mmc/core/sd.c | 82 ++++++++++
drivers/mmc/core/sd_ops.c | 48 ++++++
drivers/mmc/core/sd_ops.h | 1 +
drivers/mmc/host/omap_hsmmc.c | 13 ++-
include/linux/fs.h | 1 +
include/linux/mmc/card.h | 19 +++
include/linux/mmc/core.h | 19 +++
include/linux/mmc/host.h | 1 +
include/linux/mmc/mmc.h | 24 ++-
include/linux/mmc/sd.h | 5 +
17 files changed, 742 insertions(+), 13 deletions(-)
Regards
Adrian
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [PATCH V2 0/4] Add MMC erase and secure erase
2010-06-13 10:01 [PATCH V2 0/4] Add MMC erase and secure erase Adrian Hunter
2010-06-13 10:38 ` Adrian Hunter
@ 2010-06-14 8:09 ` Christoph Hellwig
2010-06-14 11:10 ` Adrian Hunter
1 sibling, 1 reply; 5+ messages in thread
From: Christoph Hellwig @ 2010-06-14 8:09 UTC (permalink / raw)
To: Adrian Hunter
Cc: jens.axboe, hch, Andrew Morton, Kyungmin Park, LKML,
linux-mmc@vger.kernel.org, Madhusudhan Chikkature
On Sun, Jun 13, 2010 at 01:01:34PM +0300, Adrian Hunter wrote:
> Hi
>
> Add ability to do MMC erase and secure erase operations from userspace,
> using the BLKDISCARD ioctl and a newly created BLKSECDISCARD ioctl.
Have you done any measurement if the use of the block layer changes
performance of the discard requests for you? I'd really prefer to
send down the secure erase that way, too. This could easily be done
by having a DISCARD_SECURE rw flag, which just ORs another flag into
the request type field.
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [PATCH V2 0/4] Add MMC erase and secure erase
2010-06-14 8:09 ` Christoph Hellwig
@ 2010-06-14 11:10 ` Adrian Hunter
2010-06-14 11:21 ` Christoph Hellwig
0 siblings, 1 reply; 5+ messages in thread
From: Adrian Hunter @ 2010-06-14 11:10 UTC (permalink / raw)
To: Christoph Hellwig
Cc: jens.axboe@oracle.com, Andrew Morton, Kyungmin Park, LKML,
linux-mmc@vger.kernel.org, Madhusudhan Chikkature
Christoph Hellwig wrote:
> On Sun, Jun 13, 2010 at 01:01:34PM +0300, Adrian Hunter wrote:
>> Hi
>>
>> Add ability to do MMC erase and secure erase operations from userspace,
>> using the BLKDISCARD ioctl and a newly created BLKSECDISCARD ioctl.
>
> Have you done any measurement if the use of the block layer changes
> performance of the discard requests for you?
No. For my purposes there will be only 1 discard request for the entire
device which will take several minutes to process, so block layer
performance is not a factor.
> I'd really prefer to
> send down the secure erase that way, too. This could easily be done
> by having a DISCARD_SECURE rw flag, which just ORs another flag into
> the request type field.
Needs a bio flag, a request flag, setup the request flag based on the
bio flag, prevent merging secure and non-secure discards, prevent drivers
doing non-secure discards for secure discards.
Seems like a lot of little changes for something that no one wants.
Shouldn't it wait for someone to need it first?
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [PATCH V2 0/4] Add MMC erase and secure erase
2010-06-14 11:10 ` Adrian Hunter
@ 2010-06-14 11:21 ` Christoph Hellwig
0 siblings, 0 replies; 5+ messages in thread
From: Christoph Hellwig @ 2010-06-14 11:21 UTC (permalink / raw)
To: Adrian Hunter
Cc: Christoph Hellwig, jens.axboe@oracle.com, Andrew Morton,
Kyungmin Park, LKML, linux-mmc@vger.kernel.org,
Madhusudhan Chikkature
On Mon, Jun 14, 2010 at 02:10:06PM +0300, Adrian Hunter wrote:
> Needs a bio flag, a request flag, setup the request flag based on the
> bio flag, prevent merging secure and non-secure discards, prevent drivers
> doing non-secure discards for secure discards.
>
> Seems like a lot of little changes for something that no one wants.
> Shouldn't it wait for someone to need it first?
I know that some people have asked for this. But if you want to keep
it in the driver for now that's fine to me. But in that case please:
(a) make it entirely driver private and leave no traces of it in the
block layer
(b) split it into a separate patch from the discard support
^ permalink raw reply [flat|nested] 5+ messages in thread
end of thread, other threads:[~2010-06-14 11:22 UTC | newest]
Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2010-06-13 10:01 [PATCH V2 0/4] Add MMC erase and secure erase Adrian Hunter
2010-06-13 10:38 ` Adrian Hunter
2010-06-14 8:09 ` Christoph Hellwig
2010-06-14 11:10 ` Adrian Hunter
2010-06-14 11:21 ` Christoph Hellwig
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox