From c149132d425cc9c3756c3136cf4f512a5feedd27 Mon Sep 17 00:00:00 2001 From: Vladislav Zolotarov Date: Thu, 21 Jul 2011 07:58:54 +0000 Subject: [PATCH] --- yaml --- r: 256524 b: refs/heads/master c: 7961689586d30a34c10b18ac95ba1cd72cefe725 h: refs/heads/master v: v3 --- [refs] | 2 +- trunk/drivers/net/bnx2x/bnx2x_cmn.c | 3 +++ trunk/drivers/net/bnx2x/bnx2x_reg.h | 6 +++--- trunk/drivers/net/bnx2x/bnx2x_sp.c | 6 ++++++ 4 files changed, 13 insertions(+), 4 deletions(-) diff --git a/[refs] b/[refs] index dd2a820c46da..5151e32c1cea 100644 --- a/[refs] +++ b/[refs] @@ -1,2 +1,2 @@ --- -refs/heads/master: 8736c82650500222c031dd7f59f0126e59808e36 +refs/heads/master: 7961689586d30a34c10b18ac95ba1cd72cefe725 diff --git a/trunk/drivers/net/bnx2x/bnx2x_cmn.c b/trunk/drivers/net/bnx2x/bnx2x_cmn.c index 3aadc306c8d2..5b0dba6d4efa 100644 --- a/trunk/drivers/net/bnx2x/bnx2x_cmn.c +++ b/trunk/drivers/net/bnx2x/bnx2x_cmn.c @@ -2042,6 +2042,9 @@ int bnx2x_nic_unload(struct bnx2x *bp, int unload_mode) */ bnx2x_squeeze_objects(bp); + /* There should be no more pending SP commands at this stage */ + bp->sp_state = 0; + bp->port.pmf = 0; /* Free SKBs, SGEs, TPA pool and driver internals */ diff --git a/trunk/drivers/net/bnx2x/bnx2x_reg.h b/trunk/drivers/net/bnx2x/bnx2x_reg.h index 1e6784b7734a..02461fef8751 100644 --- a/trunk/drivers/net/bnx2x/bnx2x_reg.h +++ b/trunk/drivers/net/bnx2x/bnx2x_reg.h @@ -371,7 +371,7 @@ mechanism. The fields are: [5:0] - message length; [12:6] - message pointer; 18:13] - next pointer. */ #define CCM_REG_XX_DESCR_TABLE 0xd0300 -#define CCM_REG_XX_DESCR_TABLE_SIZE 36 +#define CCM_REG_XX_DESCR_TABLE_SIZE 24 /* [R 7] Used to read the value of XX protection Free counter. */ #define CCM_REG_XX_FREE 0xd0184 /* [RW 6] Initial value for the credit counter; responsible for fulfilling @@ -4226,7 +4226,7 @@ mechanism. The fields are: [5:0] - length of the message; 15:6] - message pointer; 20:16] - next pointer. */ #define TCM_REG_XX_DESCR_TABLE 0x50280 -#define TCM_REG_XX_DESCR_TABLE_SIZE 32 +#define TCM_REG_XX_DESCR_TABLE_SIZE 29 /* [R 6] Use to read the value of XX protection Free counter. */ #define TCM_REG_XX_FREE 0x50178 /* [RW 6] Initial value for the credit counter; responsible for fulfilling @@ -4754,7 +4754,7 @@ mechanism. The fields are:[5:0] - message length; 14:6] - message pointer; 19:15] - next pointer. */ #define UCM_REG_XX_DESCR_TABLE 0xe0280 -#define UCM_REG_XX_DESCR_TABLE_SIZE 32 +#define UCM_REG_XX_DESCR_TABLE_SIZE 27 /* [R 6] Use to read the XX protection Free counter. */ #define UCM_REG_XX_FREE 0xe016c /* [RW 6] Initial value for the credit counter; responsible for fulfilling diff --git a/trunk/drivers/net/bnx2x/bnx2x_sp.c b/trunk/drivers/net/bnx2x/bnx2x_sp.c index cce87d5e7609..df52f110c6c5 100644 --- a/trunk/drivers/net/bnx2x/bnx2x_sp.c +++ b/trunk/drivers/net/bnx2x/bnx2x_sp.c @@ -1689,6 +1689,12 @@ int bnx2x_config_vlan_mac( if (!bnx2x_exe_queue_empty(&o->exe_queue)) rc = 1; + if (test_bit(RAMROD_DRV_CLR_ONLY, ramrod_flags)) { + DP(BNX2X_MSG_SP, "RAMROD_DRV_CLR_ONLY requested: " + "clearing a pending bit.\n"); + raw->clear_pending(raw); + } + /* Execute commands if required */ if (cont || test_bit(RAMROD_EXEC, ramrod_flags) || test_bit(RAMROD_COMP_WAIT, ramrod_flags)) {