Commit 83430833 authored by Manoj N. Kumar's avatar Manoj N. Kumar Committed by Martin K. Petersen

cxlflash: Increase cmd_per_lun for better throughput

With the current value of cmd_per_lun at 16, the throughput
over a single adapter is limited to around 150kIOPS.

Increase the value of cmd_per_lun to 256 to improve
throughput. With this change a single adapter is able to
attain close to the maximum throughput (380kIOPS).
Also change the number of RRQ entries that can be queued.
Signed-off-by: default avatarManoj N. Kumar <manoj@linux.vnet.ibm.com>
Acked-by: default avatarMatthew R. Ochs <mrochs@linux.vnet.ibm.com>
Reviewed-by: default avatarUma Krishnan <ukrishn@linux.vnet.ibm.com>
Signed-off-by: default avatarMartin K. Petersen <martin.petersen@oracle.com>
parent 603ecce9
...@@ -34,7 +34,6 @@ extern const struct file_operations cxlflash_cxl_fops; ...@@ -34,7 +34,6 @@ extern const struct file_operations cxlflash_cxl_fops;
sectors sectors
*/ */
#define NUM_RRQ_ENTRY 16 /* for master issued cmds */
#define MAX_RHT_PER_CONTEXT (PAGE_SIZE / sizeof(struct sisl_rht_entry)) #define MAX_RHT_PER_CONTEXT (PAGE_SIZE / sizeof(struct sisl_rht_entry))
/* AFU command retry limit */ /* AFU command retry limit */
...@@ -48,9 +47,12 @@ extern const struct file_operations cxlflash_cxl_fops; ...@@ -48,9 +47,12 @@ extern const struct file_operations cxlflash_cxl_fops;
index derivation index derivation
*/ */
#define CXLFLASH_MAX_CMDS 16 #define CXLFLASH_MAX_CMDS 256
#define CXLFLASH_MAX_CMDS_PER_LUN CXLFLASH_MAX_CMDS #define CXLFLASH_MAX_CMDS_PER_LUN CXLFLASH_MAX_CMDS
/* RRQ for master issued cmds */
#define NUM_RRQ_ENTRY CXLFLASH_MAX_CMDS
static inline void check_sizes(void) static inline void check_sizes(void)
{ {
...@@ -149,7 +151,7 @@ struct afu_cmd { ...@@ -149,7 +151,7 @@ struct afu_cmd {
struct afu { struct afu {
/* Stuff requiring alignment go first. */ /* Stuff requiring alignment go first. */
u64 rrq_entry[NUM_RRQ_ENTRY]; /* 128B RRQ */ u64 rrq_entry[NUM_RRQ_ENTRY]; /* 2K RRQ */
/* /*
* Command & data for AFU commands. * Command & data for AFU commands.
*/ */
......
...@@ -2253,7 +2253,7 @@ static struct scsi_host_template driver_template = { ...@@ -2253,7 +2253,7 @@ static struct scsi_host_template driver_template = {
.eh_device_reset_handler = cxlflash_eh_device_reset_handler, .eh_device_reset_handler = cxlflash_eh_device_reset_handler,
.eh_host_reset_handler = cxlflash_eh_host_reset_handler, .eh_host_reset_handler = cxlflash_eh_host_reset_handler,
.change_queue_depth = cxlflash_change_queue_depth, .change_queue_depth = cxlflash_change_queue_depth,
.cmd_per_lun = 16, .cmd_per_lun = CXLFLASH_MAX_CMDS_PER_LUN,
.can_queue = CXLFLASH_MAX_CMDS, .can_queue = CXLFLASH_MAX_CMDS,
.this_id = -1, .this_id = -1,
.sg_tablesize = SG_NONE, /* No scatter gather support */ .sg_tablesize = SG_NONE, /* No scatter gather support */
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment