Skip to content

Commit

Permalink
be2net: don't set "pport" field when querying "pvid"
Browse files Browse the repository at this point in the history
In the GET_HSW_CONFIG cmd, the "pport" field must be set only while
querying the switch mode.  When the "pport" field is set, the
"interface_id" field must be set to the port number, otherwise, it
must be set to adapter->if_handle.

Signed-off-by: Vasundhara Volam <vasundhara.volam@emulex.com>
Signed-off-by: Sathya Perla <sathya.perla@emulex.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
  • Loading branch information
Vasundhara Volam authored and David S. Miller committed Jan 15, 2014
1 parent 666d39c commit 2c07c1d
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion drivers/net/ethernet/emulex/benet/be_cmds.c
Original file line number Diff line number Diff line change
Expand Up @@ -2996,7 +2996,7 @@ int be_cmd_get_hsw_config(struct be_adapter *adapter, u16 *pvid,
ctxt, intf_id);
AMAP_SET_BITS(struct amap_get_hsw_req_context, pvid_valid, ctxt, 1);

if (!BEx_chip(adapter)) {
if (!BEx_chip(adapter) && mode) {
AMAP_SET_BITS(struct amap_get_hsw_req_context, interface_id,
ctxt, adapter->hba_port_num);
AMAP_SET_BITS(struct amap_get_hsw_req_context, pport, ctxt, 1);
Expand Down

0 comments on commit 2c07c1d

Please sign in to comment.