summaryrefslogtreecommitdiff
path: root/net/ethtool
diff options
context:
space:
mode:
authorJakub Kicinski <kuba@kernel.org>2026-05-22 16:13:04 -0700
committerJakub Kicinski <kuba@kernel.org>2026-05-26 08:19:32 -0700
commit84371fb58423f997939aacdcbc02d128d76a54e5 (patch)
treeab9785ef82f8a8ff60cd746e5baa9a60ad868bd4 /net/ethtool
parenta0bfd64397b819c8ad0c4ac7fd948702e78193e0 (diff)
downloadlinux-stable-84371fb58423f997939aacdcbc02d128d76a54e5.tar.gz
linux-stable-84371fb58423f997939aacdcbc02d128d76a54e5.zip
ethtool: module: call ethnl_ops_complete() on module flash errors
When validate() fails we are skipping over ethnl_ops_complete() even tho we already called ethnl_ops_begin(). Fixes: 32b4c8b53ee7 ("ethtool: Add ability to flash transceiver modules' firmware") Reviewed-by: Maxime Chevallier <maxime.chevallier@bootlin.com> Reviewed-by: Danielle Ratson <danieller@nvidia.com> Link: https://patch.msgid.link/20260522231312.1710836-2-kuba@kernel.org Signed-off-by: Jakub Kicinski <kuba@kernel.org>
Diffstat (limited to 'net/ethtool')
-rw-r--r--net/ethtool/module.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/net/ethtool/module.c b/net/ethtool/module.c
index cad2eb25b5a4..741f6fb25d45 100644
--- a/net/ethtool/module.c
+++ b/net/ethtool/module.c
@@ -427,10 +427,11 @@ int ethnl_act_module_fw_flash(struct sk_buff *skb, struct genl_info *info)
ret = ethnl_module_fw_flash_validate(dev, info->extack);
if (ret < 0)
- goto out_unlock;
+ goto out_complete;
ret = module_flash_fw(dev, tb, skb, info);
+out_complete:
ethnl_ops_complete(dev);
out_unlock: