Re: [PATCH] virtio_blk: add SECURE ERASE command support

2022-08-28 Thread Alvaro Karsz
> If you can include it in a v2 series that would be nice. Sure, I'll create a new version. ___ Virtualization mailing list Virtualization@lists.linux-foundation.org https://lists.linuxfoundation.org/mailman/listinfo/virtualization

Re: [PATCH] virtio_blk: add SECURE ERASE command support

2022-08-25 Thread Stefan Hajnoczi
On Wed, Aug 24, 2022 at 10:48:30PM +0300, Alvaro Karsz wrote: > > How about calculating the minimum of the limits? > > Sounds reasonable. > Should I add it to this patch (as v2)? > Or maybe it can be a follow up patch, and it can include the write > zeros command as well. If you can include it in

Re: [PATCH] virtio_blk: add SECURE ERASE command support

2022-08-24 Thread Alvaro Karsz
> How about calculating the minimum of the limits? Sounds reasonable. Should I add it to this patch (as v2)? Or maybe it can be a follow up patch, and it can include the write zeros command as well. ___ Virtualization mailing list Virtualization@lists.li

Re: [PATCH] virtio_blk: add SECURE ERASE command support

2022-08-24 Thread Stefan Hajnoczi
On Wed, Aug 24, 2022 at 09:45:57AM +0300, Alvaro Karsz wrote: > > What about max_secure_erase_seg and secure_erase_sector_alignment? > > Hi Stefan, > If I understand correctly, the Linux kernel uses the same "max > segments" value for a discard and a secure erase command. > > > unsigned int blk_r

Re: [PATCH] virtio_blk: add SECURE ERASE command support

2022-08-23 Thread Alvaro Karsz
> What about max_secure_erase_seg and secure_erase_sector_alignment? Hi Stefan, If I understand correctly, the Linux kernel uses the same "max segments" value for a discard and a secure erase command. > unsigned int blk_recalc_rq_segments(struct request *rq) > { > unsigned int nr_phys_segs =

Re: [PATCH] virtio_blk: add SECURE ERASE command support

2022-08-23 Thread Stefan Hajnoczi
On Mon, Aug 22, 2022 at 07:20:55PM +0300, Alvaro Karsz wrote: > @@ -1075,6 +1079,12 @@ static int virtblk_probe(struct virtio_device *vdev) > blk_queue_max_write_zeroes_sectors(q, v ? v : UINT_MAX); > } > > + if (virtio_has_feature(vdev, VIRTIO_BLK_F_SECURE_ERASE)) { > +