aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/scsi/fcoe/fcoe.c
diff options
context:
space:
mode:
authorYi Zou <yi.zou@intel.com>2009-08-25 16:59:03 -0400
committerJames Bottomley <James.Bottomley@suse.de>2009-09-10 13:07:27 -0400
commit05cc7390735c49357b9ae67bf97f1c1579547f5b (patch)
tree350ec608799ade3d3ad8000c45008bc948542aaa /drivers/scsi/fcoe/fcoe.c
parentb2f0091fbf8b475fa09b5e1712e0ab84cb3e1ca4 (diff)
[SCSI] fcoe: Add sysfs parameter to fcoe for minimum DDP read I/O size
This adds fcoe_ddp_min as a module parameter for fcoe module to: /sys/module/fcoe/parameters/ddp_min It is observed that for some hardware, particularly Intel 82599, there is too much overhead in setting up context for direct data placement (DDP) read when the requested read I/O size is small. This is added as a module parameter for performance tuning and is set as 0 by default and user can change this based on their own hardware. Signed-off-by: Yi Zou <yi.zou@intel.com> Signed-off-by: Robert Love <robert.w.love@intel.com> Signed-off-by: James Bottomley <James.Bottomley@suse.de>
Diffstat (limited to 'drivers/scsi/fcoe/fcoe.c')
-rw-r--r--drivers/scsi/fcoe/fcoe.c9
1 files changed, 8 insertions, 1 deletions
diff --git a/drivers/scsi/fcoe/fcoe.c b/drivers/scsi/fcoe/fcoe.c
index e32a0ed266aa..a39d370bccf8 100644
--- a/drivers/scsi/fcoe/fcoe.c
+++ b/drivers/scsi/fcoe/fcoe.c
@@ -49,6 +49,12 @@ MODULE_AUTHOR("Open-FCoE.org");
49MODULE_DESCRIPTION("FCoE"); 49MODULE_DESCRIPTION("FCoE");
50MODULE_LICENSE("GPL v2"); 50MODULE_LICENSE("GPL v2");
51 51
52/* Performance tuning parameters for fcoe */
53static unsigned int fcoe_ddp_min;
54module_param_named(ddp_min, fcoe_ddp_min, uint, S_IRUGO | S_IWUSR);
55MODULE_PARM_DESC(ddp_min, "Minimum I/O size in bytes for " \
56 "Direct Data Placement (DDP).");
57
52/* fcoe host list */ 58/* fcoe host list */
53LIST_HEAD(fcoe_hostlist); 59LIST_HEAD(fcoe_hostlist);
54DEFINE_RWLOCK(fcoe_hostlist_lock); 60DEFINE_RWLOCK(fcoe_hostlist_lock);
@@ -414,7 +420,8 @@ static int fcoe_shost_config(struct fc_lport *lp, struct Scsi_Host *shost,
414 */ 420 */
415bool fcoe_oem_match(struct fc_frame *fp) 421bool fcoe_oem_match(struct fc_frame *fp)
416{ 422{
417 return fc_fcp_is_read(fr_fsp(fp)); 423 return fc_fcp_is_read(fr_fsp(fp)) &&
424 (fr_fsp(fp)->data_len > fcoe_ddp_min);
418} 425}
419 426
420/** 427/**