aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/scsi/bnx2i/bnx2i_init.c
diff options
context:
space:
mode:
authorAnil Veerabhadrappa <anilgv@broadcom.com>2009-12-07 14:39:54 -0500
committerJames Bottomley <James.Bottomley@suse.de>2009-12-10 10:45:56 -0500
commitf8c9abe797c54e798b4025b54d71e5d2054c929a (patch)
tree2470a2259301ed422dbca68170ade904309ce7d1 /drivers/scsi/bnx2i/bnx2i_init.c
parent5d9e1fa99c2a9a5977f5757f4e0fd02697c995c2 (diff)
[SCSI] bnx2i: Adjust sq_size module parametr to power of 2 only if a non-zero value is specified
This issue was discovered during 10G iscsi testing Default value of 'sq_size' module parameter is '0' which means driver should use predefined SQ queue size when setting up iscsi connection. roundup_pow_of_two(0) results in '1' and forces driver to setup connections with send queue size of '1' and results in lower performance as well Signed-off-by: Anil Veerabhadrappa <anilgv@broadcom.com> Reviewed-by: Mike Christie <michaelc@cs.wisc.edu> Signed-off-by: James Bottomley <James.Bottomley@suse.de>
Diffstat (limited to 'drivers/scsi/bnx2i/bnx2i_init.c')
-rw-r--r--drivers/scsi/bnx2i/bnx2i_init.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/scsi/bnx2i/bnx2i_init.c b/drivers/scsi/bnx2i/bnx2i_init.c
index 1dba86c931e0..0307f85b4e2e 100644
--- a/drivers/scsi/bnx2i/bnx2i_init.c
+++ b/drivers/scsi/bnx2i/bnx2i_init.c
@@ -367,7 +367,7 @@ static int __init bnx2i_mod_init(void)
367 367
368 printk(KERN_INFO "%s", version); 368 printk(KERN_INFO "%s", version);
369 369
370 if (!is_power_of_2(sq_size)) 370 if (sq_size && !is_power_of_2(sq_size))
371 sq_size = roundup_pow_of_two(sq_size); 371 sq_size = roundup_pow_of_two(sq_size);
372 372
373 mutex_init(&bnx2i_dev_lock); 373 mutex_init(&bnx2i_dev_lock);