MCPcopy Create free account
hub / github.com/F-Stack/f-stack / nfp_disable_queues

Function nfp_disable_queues

dpdk/drivers/common/nfp/nfp_common.c:202–226  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

200}
201
202void
203nfp_disable_queues(struct nfp_hw *hw)
204{
205 int ret;
206 uint32_t update;
207 uint32_t new_ctrl;
208
209 nn_cfg_writeq(hw, NFP_NET_CFG_TXRS_ENABLE, 0);
210 nn_cfg_writeq(hw, NFP_NET_CFG_RXRS_ENABLE, 0);
211
212 new_ctrl = hw->ctrl & ~NFP_NET_CFG_CTRL_ENABLE;
213 update = NFP_NET_CFG_UPDATE_GEN |
214 NFP_NET_CFG_UPDATE_RING |
215 NFP_NET_CFG_UPDATE_MSIX;
216
217 if ((hw->cap & NFP_NET_CFG_CTRL_RINGCFG) != 0)
218 new_ctrl &= ~NFP_NET_CFG_CTRL_RINGCFG;
219
220 /* If an error when reconfig we avoid to change hw state */
221 ret = nfp_reconfig(hw, new_ctrl, update);
222 if (ret < 0)
223 return;
224
225 hw->ctrl = new_ctrl;
226}

Callers 3

nfp_net_disable_queuesFunction · 0.85
nfp_vdpa_hw_startFunction · 0.85
nfp_vdpa_hw_stopFunction · 0.85

Calls 2

nn_cfg_writeqFunction · 0.85
nfp_reconfigFunction · 0.85

Tested by

no test coverage detected