summaryrefslogtreecommitdiff
path: root/drivers/net/ethernet/sfc/mcdi_port.c
diff options
context:
space:
mode:
authorDaniel Pieczko <dpieczko@solarflare.com>2015-06-02 11:38:49 +0100
committerDavid S. Miller <davem@davemloft.net>2015-06-02 12:57:28 -0700
commit0a2ab4d988d75a42f3997343d1f0a767b9fdec3d (patch)
tree1b0d38cf3c3a45edb0ee66b5c5eae5218072acbc /drivers/net/ethernet/sfc/mcdi_port.c
parente80ca0139929a37a8d2b7fc90625aa5107066f57 (diff)
sfc: set the port-id when calling MC_CMD_MAC_STATS
The port-id must be known so that the RMON level can be set for the collection of vadapter stats. Signed-off-by: Shradha Shah <sshah@solarflare.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/ethernet/sfc/mcdi_port.c')
-rw-r--r--drivers/net/ethernet/sfc/mcdi_port.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/drivers/net/ethernet/sfc/mcdi_port.c b/drivers/net/ethernet/sfc/mcdi_port.c
index 9bf04cbce20a..fffc34888c02 100644
--- a/drivers/net/ethernet/sfc/mcdi_port.c
+++ b/drivers/net/ethernet/sfc/mcdi_port.c
@@ -924,6 +924,7 @@ enum efx_stats_action {
static int efx_mcdi_mac_stats(struct efx_nic *efx,
enum efx_stats_action action, int clear)
{
+ struct efx_ef10_nic_data *nic_data = efx->nic_data;
MCDI_DECLARE_BUF(inbuf, MC_CMD_MAC_STATS_IN_LEN);
int rc;
int change = action == EFX_STATS_PULL ? 0 : 1;
@@ -945,6 +946,7 @@ static int efx_mcdi_mac_stats(struct efx_nic *efx,
MAC_STATS_IN_PERIODIC_NOEVENT, 1,
MAC_STATS_IN_PERIOD_MS, period);
MCDI_SET_DWORD(inbuf, MAC_STATS_IN_DMA_LEN, dma_len);
+ MCDI_SET_DWORD(inbuf, MAC_STATS_IN_PORT_ID, nic_data->vport_id);
rc = efx_mcdi_rpc(efx, MC_CMD_MAC_STATS, inbuf, sizeof(inbuf),
NULL, 0, NULL);