Commit 666224d4 authored by Hariprasad Shenai's avatar Hariprasad Shenai Committed by David S. Miller

cxgb4/csiostor: Don't use MASTER_MUST for fw_hello call

Remove use of calls into t4_fw_hello() with MASTER_MUST, which results in
FW_HELLO_CMD_MASTERFORCE being set. The firmware doesn't support this and of
course any existing PF Drivers will totally go for a toss.
Signed-off-by: default avatarHariprasad Shenai <hariprasad@chelsio.com>
Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
parent 52c9b12d
...@@ -5524,14 +5524,8 @@ static int adap_init0(struct adapter *adap) ...@@ -5524,14 +5524,8 @@ static int adap_init0(struct adapter *adap)
struct fw_caps_config_cmd caps_cmd; struct fw_caps_config_cmd caps_cmd;
int reset = 1; int reset = 1;
/* /* Contact FW, advertising Master capability */
* Contact FW, advertising Master capability (and potentially forcing ret = t4_fw_hello(adap, adap->mbox, adap->mbox, MASTER_MAY, &state);
* ourselves as the Master PF if our module parameter force_init is
* set).
*/
ret = t4_fw_hello(adap, adap->mbox, adap->fn,
force_init ? MASTER_MUST : MASTER_MAY,
&state);
if (ret < 0) { if (ret < 0) {
dev_err(adap->pdev_dev, "could not connect to FW, error %d\n", dev_err(adap->pdev_dev, "could not connect to FW, error %d\n",
ret); ret);
...@@ -5539,8 +5533,6 @@ static int adap_init0(struct adapter *adap) ...@@ -5539,8 +5533,6 @@ static int adap_init0(struct adapter *adap)
} }
if (ret == adap->mbox) if (ret == adap->mbox)
adap->flags |= MASTER_PF; adap->flags |= MASTER_PF;
if (force_init && state == DEV_STATE_INIT)
state = DEV_STATE_UNINIT;
/* /*
* If we're the Master PF Driver and the device is uninitialized, * If we're the Master PF Driver and the device is uninitialized,
......
...@@ -47,7 +47,6 @@ ...@@ -47,7 +47,6 @@
#include "csio_lnode.h" #include "csio_lnode.h"
#include "csio_rnode.h" #include "csio_rnode.h"
int csio_force_master;
int csio_dbg_level = 0xFEFF; int csio_dbg_level = 0xFEFF;
unsigned int csio_port_mask = 0xf; unsigned int csio_port_mask = 0xf;
...@@ -889,7 +888,6 @@ csio_do_hello(struct csio_hw *hw, enum csio_dev_state *state) ...@@ -889,7 +888,6 @@ csio_do_hello(struct csio_hw *hw, enum csio_dev_state *state)
{ {
struct csio_mb *mbp; struct csio_mb *mbp;
int rv = 0; int rv = 0;
enum csio_dev_master master;
enum fw_retval retval; enum fw_retval retval;
uint8_t mpfn; uint8_t mpfn;
char state_str[16]; char state_str[16];
...@@ -904,11 +902,9 @@ csio_do_hello(struct csio_hw *hw, enum csio_dev_state *state) ...@@ -904,11 +902,9 @@ csio_do_hello(struct csio_hw *hw, enum csio_dev_state *state)
goto out; goto out;
} }
master = csio_force_master ? CSIO_MASTER_MUST : CSIO_MASTER_MAY;
retry: retry:
csio_mb_hello(hw, mbp, CSIO_MB_DEFAULT_TMO, hw->pfn, csio_mb_hello(hw, mbp, CSIO_MB_DEFAULT_TMO, hw->pfn,
hw->pfn, master, NULL); hw->pfn, CSIO_MASTER_MAY, NULL);
rv = csio_mb_issue(hw, mbp); rv = csio_mb_issue(hw, mbp);
if (rv) { if (rv) {
......
...@@ -110,7 +110,6 @@ struct csio_scsi_cpu_info { ...@@ -110,7 +110,6 @@ struct csio_scsi_cpu_info {
}; };
extern int csio_dbg_level; extern int csio_dbg_level;
extern int csio_force_master;
extern unsigned int csio_port_mask; extern unsigned int csio_port_mask;
extern int csio_msi; extern int csio_msi;
......
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