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

Function ice_reset

dpdk/drivers/net/ice/base/ice_common.c:1329–1354  ·  view source on GitHub ↗

* ice_reset - Perform different types of reset * @hw: pointer to the hardware structure * @req: reset request * * This function triggers a reset as specified by the req parameter. * * Note: * If anything other than a PF reset is triggered, PXE mode is restored. * This has to be cleared using ice_clear_pxe_mode again, once the AQ * interface has been restored in the rebuild flow. */

Source from the content-addressed store, hash-verified

1327 * interface has been restored in the rebuild flow.
1328 */
1329enum ice_status ice_reset(struct ice_hw *hw, enum ice_reset_req req)
1330{
1331 u32 val = 0;
1332
1333 switch (req) {
1334 case ICE_RESET_PFR:
1335 return ice_pf_reset(hw);
1336 case ICE_RESET_CORER:
1337 ice_debug(hw, ICE_DBG_INIT, "CoreR requested\n");
1338 val = GLGEN_RTRIG_CORER_M;
1339 break;
1340 case ICE_RESET_GLOBR:
1341 ice_debug(hw, ICE_DBG_INIT, "GlobalR requested\n");
1342 val = GLGEN_RTRIG_GLOBR_M;
1343 break;
1344 default:
1345 return ICE_ERR_PARAM;
1346 }
1347
1348 val |= rd32(hw, GLGEN_RTRIG);
1349 wr32(hw, GLGEN_RTRIG, val);
1350 ice_flush(hw);
1351
1352 /* wait for the FW to be ready */
1353 return ice_check_reset(hw);
1354}
1355
1356/**
1357 * ice_copy_rxq_ctx_to_hw

Callers 2

ice_init_hwFunction · 0.85
ice_cfg_tx_topoFunction · 0.85

Calls 4

ice_pf_resetFunction · 0.85
ice_check_resetFunction · 0.85
rd32Function · 0.50
wr32Function · 0.50

Tested by

no test coverage detected