summaryrefslogtreecommitdiff
path: root/drivers/net/cxgb4/t4_hw.c
diff options
context:
space:
mode:
authorDimitris Michailidis <dm@chelsio.com>2010-07-11 12:01:18 +0000
committerDavid S. Miller <davem@davemloft.net>2010-07-11 17:07:46 -0700
commitf796564a5fd7be1a4597b66e2a516c18685641df (patch)
tree826260c75661df51280ae3a03ff782a45d12aba8 /drivers/net/cxgb4/t4_hw.c
parent671b0060d82984a566f2e75ffd166a9b61c6da7d (diff)
cxgb4: implement the ETHTOOL_GRXFH command
Signed-off-by: Dimitris Michailidis <dm@chelsio.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/cxgb4/t4_hw.c')
-rw-r--r--drivers/net/cxgb4/t4_hw.c11
1 files changed, 11 insertions, 0 deletions
diff --git a/drivers/net/cxgb4/t4_hw.c b/drivers/net/cxgb4/t4_hw.c
index 3e63d1487f5f..ab46797623b6 100644
--- a/drivers/net/cxgb4/t4_hw.c
+++ b/drivers/net/cxgb4/t4_hw.c
@@ -3133,8 +3133,10 @@ int __devinit t4_port_init(struct adapter *adap, int mbox, int pf, int vf)
u8 addr[6];
int ret, i, j = 0;
struct fw_port_cmd c;
+ struct fw_rss_vi_config_cmd rvc;
memset(&c, 0, sizeof(c));
+ memset(&rvc, 0, sizeof(rvc));
for_each_port(adap, i) {
unsigned int rss_size;
@@ -3171,6 +3173,15 @@ int __devinit t4_port_init(struct adapter *adap, int mbox, int pf, int vf)
p->port_type = FW_PORT_CMD_PTYPE_GET(ret);
p->mod_type = FW_PORT_MOD_TYPE_NA;
+ rvc.op_to_viid = htonl(FW_CMD_OP(FW_RSS_VI_CONFIG_CMD) |
+ FW_CMD_REQUEST | FW_CMD_READ |
+ FW_RSS_VI_CONFIG_CMD_VIID(p->viid));
+ rvc.retval_len16 = htonl(FW_LEN16(rvc));
+ ret = t4_wr_mbox(adap, mbox, &rvc, sizeof(rvc), &rvc);
+ if (ret)
+ return ret;
+ p->rss_mode = ntohl(rvc.u.basicvirtual.defaultq_to_udpen);
+
init_link_config(&p->link_cfg, ntohs(c.u.info.pcap));
j++;
}