Re: [PATCH] nbd: set discard_alignment to the granularity

2018-06-12 Thread Wouter Verhelst
Hi Josef, On Tue, Jun 05, 2018 at 11:41:23AM -0400, Josef Bacik wrote: > Technically we should be able to get away with 0 as the > discard_alignment, but there's no way currently for the protocol to > indicate different alignments, Actually there is, with the NBD_INFO_BLOCK_SIZE (and related)

Re: [PATCH] nbd: set discard_alignment to the granularity

2018-06-05 Thread Jens Axboe
On 6/5/18 9:41 AM, Josef Bacik wrote: > Technically we should be able to get away with 0 as the > discard_alignment, but there's no way currently for the protocol to > indicate different alignments, and in real life most disks have > discard_alignment == discard_granularity. Just set our

[PATCH] nbd: set discard_alignment to the granularity

2018-06-05 Thread Josef Bacik
Technically we should be able to get away with 0 as the discard_alignment, but there's no way currently for the protocol to indicate different alignments, and in real life most disks have discard_alignment == discard_granularity. Just set our alignment to our blocksize to make sure discards will