mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git/
synced 2026-11-10 20:48:12 +00:00
netxen: unregister notifiers if PCI registration fails
netxen_init_module() registers the netdevice and inetaddr notifiers before registering the PCI driver. If pci_register_driver() fails, the function returns the error directly and leaves both notifiers registered. That leaves notifier callbacks installed for a module that failed to load. Mirror the module exit path on this failure and unregister the notifiers before returning the error. Cc: stable+noautosel@kernel.org # untested fix to unlikely driver error path Signed-off-by: Can Peng <pengcan@kylinos.cn> Reviewed-by: Jacob Keller <jacob.e.keller@intel.com> Link: https://patch.msgid.link/20260728032046.121631-2-pengcan@kylinos.cn Signed-off-by: Jakub Kicinski <kuba@kernel.org>
This commit is contained in:
parent
d661abdc30
commit
e8aaf6ba33
1 changed files with 12 additions and 1 deletions
Loading…
Add table
Add a link
Reference in a new issue