Lines Matching defs:module

267  * @module: the module to write to
275 * Write a block of data to a flash module, and await for the completion
290 ice_write_one_nvm_block(struct ice_pf *pf, u16 module, u32 offset,
302 dev_dbg(dev, "Writing block of %u bytes for module 0x%02x at offset %u\n",
303 block_size, module, offset);
307 err = ice_aq_update_nvm(hw, module, offset, block_size, block,
310 dev_err(dev, "Failed to flash module 0x%02x with block of size %u at offset %u, err %d aq_err %s\n",
311 module, block_size, offset, err,
313 NL_SET_ERR_MSG_MOD(extack, "Failed to program flash module");
325 dev_err(dev, "Timed out while trying to flash module 0x%02x with block of size %u at offset %u, err %d\n",
326 module, block_size, offset, err);
338 if (completion_module != module) {
340 completion_module, module);
353 dev_err(dev, "Firmware failed to flash module 0x%02x with block of size %u at offset %u, err %s\n",
354 module, block_size, offset,
356 NL_SET_ERR_MSG_MOD(extack, "Firmware failed to program flash module");
366 if (reset_level && last_cmd && module == ICE_SR_1ST_NVM_BANK_PTR) {
382 * ice_write_nvm_module - Write data to an NVM module
384 * @module: the module id to program
391 * Loop over the data for a given NVM module and program it in 4 Kb
400 ice_write_nvm_module(struct ice_pf *pf, u16 module, const char *component,
411 dev_dbg(dev, "Beginning write of flash component '%s', module 0x%02x\n", component, module);
434 err = ice_write_one_nvm_block(pf, module, offset, block_size,
446 dev_dbg(dev, "Completed write of flash component '%s', module 0x%02x\n", component, module);
459 /* Length in seconds to wait before timing out when erasing a flash module.
465 * ice_erase_nvm_module - Erase an NVM module and await firmware completion
467 * @module: the module to erase
471 * Erase the inactive NVM bank associated with this module, and await for
479 ice_erase_nvm_module(struct ice_pf *pf, u16 module, const char *component,
490 dev_dbg(dev, "Beginning erase of flash component '%s', module 0x%02x\n", component, module);
498 err = ice_aq_erase_nvm(hw, module, NULL);
500 dev_err(dev, "Failed to erase %s (module 0x%02x), err %d aq_err %s\n",
501 component, module, err,
503 NL_SET_ERR_MSG_MOD(extack, "Failed to erase flash module");
510 dev_err(dev, "Timed out waiting for firmware to respond with erase completion for %s (module 0x%02x), err %d\n",
511 component, module, err);
520 if (completion_module != module) {
522 component, completion_module, module);
529 dev_err(dev, "Firmware failed to erase %s (module 0x02%x), aq_err %s\n",
530 component, module,
537 dev_dbg(dev, "Completed erase of flash component '%s', module 0x%02x\n", component, module);
624 * module id. Then, erase the secondary bank for this module. Finally, write
639 u16 module;
645 module = ICE_SR_1ST_OROM_BANK_PTR;
651 module = ICE_SR_1ST_NVM_BANK_PTR;
657 module = ICE_SR_NETLIST_BANK_PTR;
674 err = ice_erase_nvm_module(pf, module, name, extack);
678 return ice_write_nvm_module(pf, module, name, component->component_data,