From: Julien Meunier Date: Wed, 2 Jan 2019 15:57:45 +0000 (+0200) Subject: net/fm10k: fix internal switch initial status X-Git-Url: http://git.droids-corp.org/?a=commitdiff_plain;h=04018a4552e630a2c019bade0c6b5f822aded0c1;p=dpdk.git net/fm10k: fix internal switch initial status sm_down is a boolean in order to check if the internal switch of the fm10k is up or down. This variable is configured though an interrupt by fm10k_dev_interrupt_handler_pf. If sm_down is uninitialized, we are not sure of its value at the first bring up. For example, if FM10K_EICR_SWITCHREADY is raised, the PMD will try to reconfigure the switch, but it does not make sense, as it's the first startup. The sm_down implementation has been introduced commit 6c9f37245583 ("net/fm10k: support switch restart on PF"). Fixes: 6f22f2f67268 ("net/fm10k: redefine link status semantics") Cc: stable@dpdk.org Signed-off-by: Julien Meunier Acked-by: Xiao Wang --- diff --git a/drivers/net/fm10k/fm10k_ethdev.c b/drivers/net/fm10k/fm10k_ethdev.c index 85fb6c5cbc..caf4d1bc08 100644 --- a/drivers/net/fm10k/fm10k_ethdev.c +++ b/drivers/net/fm10k/fm10k_ethdev.c @@ -3003,6 +3003,7 @@ fm10k_params_init(struct rte_eth_dev *dev) hw->bus.payload = fm10k_bus_payload_256; info->rx_vec_allowed = true; + info->sm_down = false; } static int