Re: [PATCH v6 3/4] SCT Write Same / DSM Trim

2016-08-22 Thread Tom Yan
On 22 August 2016 at 18:52, Tom Yan wrote: > > For the "payload block size" that is "always" 512-byte as per the same > spec, I don't think we need to concern about it. I think it only > matters if we want to enable multi-block TRIM payload according to the > reported limit in IDENTIFY DEVICE data

Re: [PATCH v6 3/4] SCT Write Same / DSM Trim

2016-08-22 Thread Tom Yan
In that case I see no reason that my suggestion should not be adopted. Currently speaking (as I mentioned in the commit message) it is reasonable to decrease it per logical sector size in the TRIM-only sense as well because of the block layer / bio size limit. FWIW, as of ACS-4, RANGE LENGTH field

Re: [PATCH v6 3/4] SCT Write Same / DSM Trim

2016-08-22 Thread Shaun Tancheff
On Mon, Aug 22, 2016 at 12:02 PM, Tom Yan wrote: > On 22 August 2016 at 15:04, Shaun Tancheff wrote: >> On Mon, Aug 22, 2016 at 3:33 AM, Tom Yan wrote: >>> On 22 August 2016 at 08:31, Tom Yan wrote: > Since I have no experience with SCT Write Same at all, and neither do > I own any spinning HD

Re: [PATCH v6 3/4] SCT Write Same / DSM Trim

2016-08-22 Thread Tom Yan
On 22 August 2016 at 15:04, Shaun Tancheff wrote: > On Mon, Aug 22, 2016 at 3:33 AM, Tom Yan wrote: >> On 22 August 2016 at 08:31, Tom Yan wrote: >>> As mentioned before, as of the latest draft of ACS-4, nothing about a >>> larger payload size is mentioned. Conservatively speaking, it sort of >>

Re: [PATCH v6 3/4] SCT Write Same / DSM Trim

2016-08-22 Thread Shaun Tancheff
On Mon, Aug 22, 2016 at 3:33 AM, Tom Yan wrote: > On 22 August 2016 at 08:31, Tom Yan wrote: >> As mentioned before, as of the latest draft of ACS-4, nothing about a >> larger payload size is mentioned. Conservatively speaking, it sort of > > *payload block size > >> means that we are allowing fo

Re: [PATCH v6 3/4] SCT Write Same / DSM Trim

2016-08-22 Thread Tom Yan
On 22 August 2016 at 08:31, Tom Yan wrote: > As mentioned before, as of the latest draft of ACS-4, nothing about a > larger payload size is mentioned. Conservatively speaking, it sort of *payload block size > means that we are allowing four 512-byte block payload on 4Kn device *eight 512-byte-b

Re: [PATCH v6 3/4] SCT Write Same / DSM Trim

2016-08-22 Thread Tom Yan
As mentioned before, as of the latest draft of ACS-4, nothing about a larger payload size is mentioned. Conservatively speaking, it sort of means that we are allowing four 512-byte block payload on 4Kn device regardless of the reported limit in the IDENTIFY DEVICE data. I am really not sure if it's

Re: [PATCH v6 3/4] SCT Write Same / DSM Trim

2016-08-21 Thread Hannes Reinecke
On 08/22/2016 06:23 AM, Shaun Tancheff wrote: > Correct handling of devices with sector_size other that 512 bytes. > > Signed-off-by: Shaun Tancheff > --- > In the case of a 4Kn device sector_size it is possible to describe a much > larger DSM Trim than the current fixed default of 512 bytes. >

[PATCH v6 3/4] SCT Write Same / DSM Trim

2016-08-21 Thread Shaun Tancheff
Correct handling of devices with sector_size other that 512 bytes. Signed-off-by: Shaun Tancheff --- In the case of a 4Kn device sector_size it is possible to describe a much larger DSM Trim than the current fixed default of 512 bytes. This patch assumes the minimum descriptor is sector_size and