diff --git a/sys/net/netisr.c b/sys/net/netisr.c index e9b8fa4d833..7b4368276c5 100644 --- a/sys/net/netisr.c +++ b/sys/net/netisr.c @@ -396,8 +396,7 @@ netisr_register(const struct netisr_handler *nhp) * Test that the requested registration is valid. */ CURVNET_ASSERT_SET(); - KASSERT(IS_DEFAULT_VNET(curvnet), ("%s: curvnet %p is not vnet0 %p", - __func__, curvnet, vnet0)); + MPASS(IS_DEFAULT_VNET(curvnet)); KASSERT(nhp->nh_name != NULL, ("%s: nh_name NULL for %u", __func__, proto)); KASSERT(nhp->nh_handler != NULL, @@ -457,8 +456,8 @@ netisr_register(const struct netisr_handler *nhp) npwp->nw_qlimit = netisr_proto[proto].np_qlimit; } - V_netisr_enable[proto] = 1; #ifdef VIMAGE + V_netisr_enable[proto] = 1; VNET_LIST_RLOCK_NOSLEEP(); VNET_FOREACH(vnet_iter) { if (vnet_iter == curvnet)