mirror of
https://github.com/hardkernel/linux.git
synced 2026-06-10 12:57:06 +09:00
UPSTREAM: scsi: ufs: core: Increase the maximum data buffer size
Measurements for one particular UFS controller + UFS device show a 25%
higher read bandwidth if the maximum data buffer size is increased from 512
KiB to 1 MiB. Hence increase the maximum size of the data buffer associated
with a single request from SCSI_DEFAULT_MAX_SECTORS (1024) * 512 bytes =
512 KiB to 1 MiB.
Notes:
- The maximum data buffer size supported by the UFSHCI specification
is 65535 * 256 KiB or about 16 GiB.
- The maximum data buffer size for READ(10) commands is 65535 logical
blocks. To transfer more than 65535 * 4096 bytes = 255 MiB with a single
SCSI command, the READ(16) command is required. Support for READ(16) is
optional in the UFS 3.1 and UFS 4.0 standards.
Link: https://lore.kernel.org/r/20220726225232.1362251-1-bvanassche@acm.org
Cc: Adrian Hunter <adrian.hunter@intel.com>
Cc: Avri Altman <avri.altman@wdc.com>
Cc: Bean Huo <beanhuo@micron.com>
Cc: Stanley Chu <stanley.chu@mediatek.com>
Tested-by: Avri Altman <avri.altman@wdc.com>
Acked-by: Avri Altman <avri.altman@wdc.com>
Change-Id: I8c9db803e7f55d911e86d4fa0272d38d13ee05d5
Signed-off-by: Bart Van Assche <bvanassche@acm.org>
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
Bug: 258234315
(cherry picked from commit 86a44f045b)
Signed-off-by: Bart Van Assche <bvanassche@google.com>
This commit is contained in:
committed by
Alistair Delva
parent
8cd06a39b1
commit
ff00ba18aa
@@ -8405,6 +8405,7 @@ static struct scsi_host_template ufshcd_driver_template = {
|
||||
.cmd_per_lun = UFSHCD_CMD_PER_LUN,
|
||||
.can_queue = UFSHCD_CAN_QUEUE,
|
||||
.max_segment_size = PRDT_DATA_BYTE_COUNT_MAX,
|
||||
.max_sectors = (1 << 20) / SECTOR_SIZE, /* 1 MiB */
|
||||
.max_host_blocked = 1,
|
||||
.track_queue_depth = 1,
|
||||
.sdev_groups = ufshcd_driver_groups,
|
||||
|
||||
Reference in New Issue
Block a user