Page MenuHomeFreeBSD

iflib: Remove redundant VLAN events deregistration
ClosedPublic

Authored by piotr.pietruszewski_intel.com on Sep 19 2019, 9:20 AM.
Tags
None
Referenced Files
F113921122: D21711.id.diff
Sat, Apr 5, 3:31 PM
F113917193: D21711.diff
Sat, Apr 5, 1:54 PM
Unknown Object (File)
Sat, Mar 29, 3:39 PM
Unknown Object (File)
Jan 26 2025, 6:12 PM
Unknown Object (File)
Jan 26 2025, 11:49 AM
Unknown Object (File)
Jan 25 2025, 7:49 PM
Unknown Object (File)
Jan 24 2025, 10:57 PM
Unknown Object (File)
Jan 4 2025, 1:28 AM
Subscribers

Details

Summary

r351152 introduced iflib_deregister() function calling
EVENTHANDLER_DEREGISTER() to unregister VLAN events. This patch removes
duplicate of EVENTHANDLER_DEREGISTER() calls placed in
iflib_device_deregister() as this function is now calling
iflib_deregister(). This is to avoid deregistering same event twice.

This patch also adds check in iflib_vlan_register() to prevent
registering VLAN while being in detach.

Patch co-authored by Krzysztof Galazka <krzysztof.galazka@intel.com>,
erj <erj@FreeBSD.org> and Jacob Keller <jacob.e.keller@intel.com>.

Signed-off-by: Piotr Pietruszewski <piotr.pietruszewski@intel.com>

Test Plan

Before applying this patch, kernel panic should be observed after issuing:

for i in {1..10}; do kldunload if_ix; kldload if_ix; done

Usually, less than 10 cycles are needed to trigger the panic. After applying
the patch, panic should be gone.

Diff Detail

Repository
rS FreeBSD src repository - subversion
Lint
Lint Not Applicable
Unit
Tests Not Applicable