OSDN Git Service

sfc: initialise RSS context ID to 'no RSS context' in efx_init_struct()
authorEdward Cree <ecree@solarflare.com>
Thu, 2 Jul 2020 16:31:19 +0000 (17:31 +0100)
committerDavid S. Miller <davem@davemloft.net>
Thu, 2 Jul 2020 21:47:40 +0000 (14:47 -0700)
Previously this was only happening in ef10-specific code.

Signed-off-by: Edward Cree <ecree@solarflare.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/ethernet/sfc/ef10.c
drivers/net/ethernet/sfc/efx_common.c

index d2101d2..cb7b634 100644 (file)
@@ -552,8 +552,6 @@ static int efx_ef10_probe(struct efx_nic *efx)
        }
        nic_data->warm_boot_count = rc;
 
-       efx->rss_context.context_id = EFX_MCDI_RSS_CONTEXT_INVALID;
-
        /* In case we're recovering from a crash (kexec), we want to
         * cancel any outstanding request by the previous user of this
         * function.  We send a special message using the least
index c841234..5667694 100644 (file)
@@ -1017,6 +1017,7 @@ int efx_init_struct(struct efx_nic *efx,
        efx->rx_packet_ts_offset =
                efx->type->rx_ts_offset - efx->type->rx_prefix_size;
        INIT_LIST_HEAD(&efx->rss_context.list);
+       efx->rss_context.context_id = EFX_MCDI_RSS_CONTEXT_INVALID;
        mutex_init(&efx->rss_lock);
        efx->vport_id = EVB_PORT_ID_ASSIGNED;
        spin_lock_init(&efx->stats_lock);