Lines Matching refs:module_fw
193 module_flash_fw_work_list_add(struct ethtool_module_fw_flash *module_fw, in module_flash_fw_work_list_add() argument
202 work->fw_update.dev == module_fw->fw_update.dev) { in module_flash_fw_work_list_add()
208 list_add_tail(&module_fw->list, &module_fw_flash_work_list); in module_flash_fw_work_list_add()
223 struct ethtool_module_fw_flash *module_fw; in module_flash_fw_work() local
225 module_fw = container_of(work, struct ethtool_module_fw_flash, work); in module_flash_fw_work()
227 ethtool_cmis_fw_update(&module_fw->fw_update); in module_flash_fw_work()
229 module_flash_fw_work_list_del(&module_fw->list); in module_flash_fw_work()
230 module_fw->fw_update.dev->ethtool->module_fw_flash_in_progress = false; in module_flash_fw_work()
231 netdev_put(module_fw->fw_update.dev, &module_fw->dev_tracker); in module_flash_fw_work()
232 release_firmware(module_fw->fw_update.fw); in module_flash_fw_work()
233 kfree(module_fw); in module_flash_fw_work()
239 static int module_flash_fw_work_init(struct ethtool_module_fw_flash *module_fw, in module_flash_fw_work_init() argument
269 INIT_WORK(&module_fw->work, module_flash_fw_work); in module_flash_fw_work_init()
301 struct ethtool_module_fw_flash *module_fw; in module_flash_fw_schedule() local
304 module_fw = kzalloc(sizeof(*module_fw), GFP_KERNEL); in module_flash_fw_schedule()
305 if (!module_fw) in module_flash_fw_schedule()
308 fw_update = &module_fw->fw_update; in module_flash_fw_schedule()
318 err = module_flash_fw_work_init(module_fw, dev, info->extack); in module_flash_fw_schedule()
323 netdev_hold(dev, &module_fw->dev_tracker, GFP_KERNEL); in module_flash_fw_schedule()
334 err = module_flash_fw_work_list_add(module_fw, info); in module_flash_fw_schedule()
338 schedule_work(&module_fw->work); in module_flash_fw_schedule()
345 kfree(module_fw); in module_flash_fw_schedule()