diff options
author | Hariprasad Shenai <hariprasad@chelsio.com> | 2015-08-04 14:36:19 +0530 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2015-08-04 01:24:35 -0700 |
commit | d86bd29e0b31f30d5d85ab21385b59703ecc6464 (patch) | |
tree | 91e4f51e8a64e77249d4424a854201448e65960e /drivers/net/ethernet/chelsio/cxgb4vf | |
parent | bf8ebb67dae0a07db7aebe7a65c178ff24d90842 (diff) | |
download | talos-obmc-linux-d86bd29e0b31f30d5d85ab21385b59703ecc6464.tar.gz talos-obmc-linux-d86bd29e0b31f30d5d85ab21385b59703ecc6464.zip |
cxgb4/cxgb4vf: read the correct bits of PL Who Am I register
Read the correct bits of PL Who Am I for the Source PF field which has
changed in T6
Signed-off-by: Hariprasad Shenai <hariprasad@chelsio.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/ethernet/chelsio/cxgb4vf')
-rw-r--r-- | drivers/net/ethernet/chelsio/cxgb4vf/t4vf_hw.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/drivers/net/ethernet/chelsio/cxgb4vf/t4vf_hw.c b/drivers/net/ethernet/chelsio/cxgb4vf/t4vf_hw.c index 0db6dc9e9ed2..63dd5fdac5b9 100644 --- a/drivers/net/ethernet/chelsio/cxgb4vf/t4vf_hw.c +++ b/drivers/net/ethernet/chelsio/cxgb4vf/t4vf_hw.c @@ -619,7 +619,8 @@ int t4vf_get_sge_params(struct adapter *adapter) */ whoami = t4_read_reg(adapter, T4VF_PL_BASE_ADDR + PL_VF_WHOAMI_A); - pf = SOURCEPF_G(whoami); + pf = CHELSIO_CHIP_VERSION(adapter->params.chip) <= CHELSIO_T5 ? + SOURCEPF_G(whoami) : T6_SOURCEPF_G(whoami); s_hps = (HOSTPAGESIZEPF0_S + (HOSTPAGESIZEPF1_S - HOSTPAGESIZEPF0_S) * pf); |