From a9b1e3c2d7b30bafb1632402cc0a042d5ac5586b Mon Sep 17 00:00:00 2001 From: Taylor R Campbell Date: Wed, 1 Aug 2018 18:15:02 +0000 Subject: [PATCH] Use a different psz for a different lock. --- sys/net/if_vlan.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/sys/net/if_vlan.c b/sys/net/if_vlan.c index 089b61c66a47..3d575096ec4f 100644 --- a/sys/net/if_vlan.c +++ b/sys/net/if_vlan.c @@ -161,6 +161,7 @@ struct ifvlan { * instead of direct dereference */ kmutex_t ifv_lock; /* writer lock for ifv_mib */ + pserialize_t ifv_psz; LIST_HEAD(__vlan_mchead, vlan_mc_entry) ifv_mc_listhead; LIST_ENTRY(ifvlan) ifv_list; @@ -355,6 +356,7 @@ vlan_clone_create(struct if_clone *ifc, int unit) psref_target_init(&mib->ifvm_psref, ifvm_psref_class); mutex_init(&ifv->ifv_lock, MUTEX_DEFAULT, IPL_NONE); + ifv->ifv_psz = pserialize_create(); ifv->ifv_mib = mib; mutex_enter(&ifv_list.lock); @@ -792,7 +794,7 @@ vlan_linkmib_update(struct ifvlan *ifv, struct ifvlan_linkmib *nmib) membar_producer(); ifv->ifv_mib = nmib; - pserialize_perform(vlan_psz); + pserialize_perform(ifv->ifv_psz); psref_target_destroy(&omib->ifvm_psref, ifvm_psref_class); } -- 2.11.0