Skip to content

Commit

Permalink
net/nfp: fix link status interrupt
Browse files Browse the repository at this point in the history
[ upstream commit 94d0631a8275afa4314ee1d4f08d2fbd02325124 ]

In rare cases, when DPDK application exit, the interrupt handler was not
processed the interrupt in time, resulting in the LSC interrupt mask bit
not being cleared. So when the DPDK application start again, the newly
coming LSC interrupts cannot be received and processed properly.

Fix this problem by force clear the LSC interrupt mask on port
initialization.

Fixes: 6c53f87 ("nfp: add link status interrupt")

Signed-off-by: Shihong Wang <shihong.wang@corigine.com>
Signed-off-by: Peng Zhang <peng.zhang@corigine.com>
Reviewed-by: Chaoyong He <chaoyong.he@corigine.com>
  • Loading branch information
Peng-Mu authored and bluca committed Nov 8, 2023
1 parent 8056f3b commit fff9e49
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions drivers/net/nfp/nfp_net.c
Original file line number Diff line number Diff line change
Expand Up @@ -3040,6 +3040,8 @@ nfp_net_init(struct rte_eth_dev *eth_dev)
(void *)eth_dev);
/* Telling the firmware about the LSC interrupt entry */
nn_cfg_writeb(hw, NFP_NET_CFG_LSC, NFP_NET_IRQ_LSC_IDX);
/* Unmask the LSC interrupt */
nfp_net_irq_unmask(eth_dev);
/* Recording current stats counters values */
nfp_net_stats_reset(eth_dev);
}
Expand Down

0 comments on commit fff9e49

Please sign in to comment.