bnx2fc version 1.0.10
Subsystems (2)
cover bnx2fc version 1.0.10
James,
Please include the following bug fixes in the next merge window.
Thanks,
Bhanu
Bhanu Prakash Gollapudi (4):
bnx2fc: fix panic in bnx2fc_post_io_req
bnx2fc: Handle LOGO flooding from the target
bnx2fc: NPIV ports go offline when interface is brought down & up
bnx2fc: Bumped version to 1.0.10
drivers/scsi/bnx2fc/bnx2fc.h | 8 ++++++-- drivers/scsi/bnx2fc/bnx2fc_fcoe.c | 20 ++++++++++++++------ 2 files changed, 20 insertions(+), 8 deletions(-)
PATCH 1/4 bnx2fc: fix panic in bnx2fc_post_io_req
System panics while accessing stale pointer - timer_work_queue - in the IO path before bnx2fc_stop is called. Fix is to destroy the workqueue after the destroy operation is complete.
--- drivers/scsi/bnx2fc/bnx2fc_fcoe.c | 5 +++-- 1 files changed, 3 insertions(+), 2 deletions(-)
drivers/scsi/bnx2fc/bnx2fc_fcoe.c +3 -2
@@ -1537,6 +1537,7 @@ static void __bnx2fc_destroy(struct bnx2fc_interface *interface)static int bnx2fc_destroy (struct net_device *netdev) {struct bnx2fc_interface *interface =NULL ; +struct workqueue_struct *timer_work_queue;int rc =0 ;rtnl_lock ();
@@ -1549,9 +1550,9 @@ static int bnx2fc_destroy(struct net_device *netdev) goto netdev_err; } - -destroy_workqueue (interface->timer_work_queue); + timer_work_queue = interface->timer_work_queue;__bnx2fc_destroy (interface); +destroy_workqueue (timer_work_queue); netdev_err:mutex_unlock (&bnx2fc_dev_lock);
Signature · 1 line
1.7.0.6
PATCH 2/4 bnx2fc: Handle LOGO flooding from the target
In reply to Bhanu Prakash GollapudiHost drops sessions when flood of unsolicited LOGOs are received from the target. Because of unsufficient PLOGI retries, upon exceeding the retry count of 3, the target sessions are dropped. Increased the retry count to 255 to allow sufficient retries in this scenario.
--- drivers/scsi/bnx2fc/bnx2fc.h | 2 ++ drivers/scsi/bnx2fc/bnx2fc_fcoe.c | 4 ++-- 2 files changed, 4 insertions(+), 2 deletions(-)
drivers/scsi/bnx2fc/bnx2fc.h +2 -0
@@ -114,6 +114,8 @@#define BNX2FC_HASH_TBL_CHUNK_SIZE (16 * 1024)#define BNX2FC_MAX_SEQS 255 +#define BNX2FC_MAX_RETRY_CNT 3 +#define BNX2FC_MAX_RPORT_RETRY_CNT 255#define BNX2FC_READ (1 << 1)#define BNX2FC_WRITE (1 << 0)
drivers/scsi/bnx2fc/bnx2fc_fcoe.c +2 -2
@@ -953,8 +953,8 @@ static int bnx2fc_lport_config(struct fc_lport *lport) { lport->link_up =0 ; lport->qfull =0 ; - lport->max_retry_count =3 ; - lport->max_rport_retry_count =3 ; + lport->max_retry_count =BNX2FC_MAX_RETRY_CNT ; + lport->max_rport_retry_count =BNX2FC_MAX_RPORT_RETRY_CNT ; lport->e_d_tov =2 *1000 ; lport->r_a_tov =10 *1000 ;
Signature · 1 line
1.7.0.6
PATCH 3/4 bnx2fc: NPIV ports go offline when interface is brought down & up
In reply to Bhanu Prakash GollapudiWhen there are 255 NPIV ports, and the interface is brought down & up, both physical and NPIV ports are logged off and never logged back in. Since discovery happens on single CPU, XID resources on that CPU will be limited, which when exhausted the discovery fails. Increase the XID resource range to ensure that the discovery completes successfully. Also ensure that fc_exch_mgr_alloc() doesn't fail on the system that has lower number of CPUs.
--- drivers/scsi/bnx2fc/bnx2fc.h | 4 +++- drivers/scsi/bnx2fc/bnx2fc_fcoe.c | 9 ++++++++- 2 files changed, 11 insertions(+), 2 deletions(-)
drivers/scsi/bnx2fc/bnx2fc.h +3 -1
@@ -123,8 +123,10 @@#define BNX2FC_MIN_XID 0#define BNX2FC_MAX_XID \ (BNX2FC_MAX_OUTSTANDING_CMNDS + BNX2FC_ELSTM_XIDS - 1) +#define FCOE_MAX_NUM_XIDS 0x2000#define FCOE_MIN_XID (BNX2FC_MAX_XID + 1) -#define FCOE_MAX_XID (FCOE_MIN_XID + 4095) +#define FCOE_MAX_XID (FCOE_MIN_XID + FCOE_MAX_NUM_XIDS - 1) +#define FCOE_XIDS_PER_CPU (FCOE_MIN_XID + (512 * nr_cpu_ids) - 1)#define BNX2FC_MAX_LUN 0xFFFF#define BNX2FC_MAX_FCP_TGT 256#define BNX2FC_MAX_CMD_LEN 16
drivers/scsi/bnx2fc/bnx2fc_fcoe.c +8 -1
@@ -940,8 +940,14 @@ static int bnx2fc_libfc_config(struct fc_lport *lport)static int bnx2fc_em_config (struct fc_lport *lport) { +int max_xid; + +if (nr_cpu_ids <=2 ) + max_xid =FCOE_XIDS_PER_CPU ; +else + max_xid =FCOE_MAX_XID ;if (!fc_exch_mgr_alloc (lport,FC_CLASS_3 ,FCOE_MIN_XID , -FCOE_MAX_XID ,NULL )) { + max_xid,NULL )) { printk(KERN_ERR PFX "em_config:fc_exch_mgr_alloc failed\n");return -ENOMEM ; }
@@ -2056,6 +2062,7 @@ if_create_err: ifput_err:bnx2fc_net_cleanup (interface);bnx2fc_interface_put (interface); + goto mod_err; netdev_err:module_put (THIS_MODULE ); mod_err:
Signature · 1 line
1.7.0.6
PATCH 4/4 bnx2fc: Bumped version to 1.0.10
In reply to Bhanu Prakash Gollapudi--- drivers/scsi/bnx2fc/bnx2fc.h | 2 +- drivers/scsi/bnx2fc/bnx2fc_fcoe.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-)
drivers/scsi/bnx2fc/bnx2fc.h +1 -1
@@ -62,7 +62,7 @@#include "bnx2fc_constants.h" #define BNX2FC_NAME "bnx2fc" -#define BNX2FC_VERSION "1.0.9" +#define BNX2FC_VERSION "1.0.10"#define PFX "bnx2fc: "
drivers/scsi/bnx2fc/bnx2fc_fcoe.c +1 -1
@@ -22,7 +22,7 @@ DEFINE_PER_CPU(struct bnx2fc_percpu_s, bnx2fc_percpu);#define DRV_MODULE_NAME "bnx2fc"#define DRV_MODULE_VERSION BNX2FC_VERSION -#define DRV_MODULE_RELDATE "Oct 21, 2011" +#define DRV_MODULE_RELDATE "Jan 22, 2011" static char version[] __devinitdata =
Signature · 1 line
1.7.0.6