Re: [RFC 3/3] libata-scsi: add optimal transfer length to block limits VPD

2016-07-14 Thread Tom Yan
Well it's mainly to "pre-de-couple" BLK_DEF_MAX_SECTORS from ATA drives. If we left the field unset, the scsi disk driver will fall back to BLK_DEF_MAX_SECTORS when setting the block limit "max_sectors" (while its cap "max_hw_sectors" is set by libata depending on whether the drive supports LBA48 o

Re: [RFC 3/3] libata-scsi: add optimal transfer length to block limits VPD

2016-07-13 Thread Tejun Heo
On Wed, Jul 13, 2016 at 12:47:08PM +0800, tom.t...@gmail.com wrote: > From: Tom Yan > > As of commit 6b7e9cde4969 ("sd: Fix rw_max for devices that report > an optimal xfer size"), the scsi disk driver (correctly) derive both > of the queue limits "io_opt" and "max_sectors" from the optimal > tra

[RFC 3/3] libata-scsi: add optimal transfer length to block limits VPD

2016-07-12 Thread tom . ty89
From: Tom Yan As of commit 6b7e9cde4969 ("sd: Fix rw_max for devices that report an optimal xfer size"), the scsi disk driver (correctly) derive both of the queue limits "io_opt" and "max_sectors" from the optimal transfer length field. In case we would like the two limits to be derived from a v