ata_format_dsm_trim_descr9
Satl write same to dsm trim
Usage
size_t ata_format_dsm_trim_descr(struct scsi_cmnd * cmd, u32 trmax, u64 sector, u32 count);
Arguments
cmd
SCSI command being translated
trmax
Maximum number of entries that will fit in sector_size bytes.
sector
Starting sector
count
Total Range of request in logical sectors
Overview
Rewrite the WRITE SAME descriptor to be a DSM TRIM little-endian formatted descriptor.
Upto 64 entries of the format: 63:48 Range Length 47:0 LBA
Range Length of 0 is ignored. LBA's should be sorted order and not overlap.
Note
this is the same format as ADD LBA(S) TO NV CACHE PINNED SET
Return
Number of bytes copied into sglist.