From 5ce57a0010b85860a165aa4c9a20627159b75712 Mon Sep 17 00:00:00 2001 From: bouyer Date: Fri, 10 Jun 2005 10:28:17 +0000 Subject: [PATCH] call (ifp->if_input) at splnet(). ifp->if_input points to ether_input() which doesn't raise the IPL itself in all cases. Should also fix PR 29546 (the pkgsrc kernel module needs to be updated). --- sys/net/if_tap.c | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/sys/net/if_tap.c b/sys/net/if_tap.c index 118416209a8f..771bf21be33d 100644 --- a/sys/net/if_tap.c +++ b/sys/net/if_tap.c @@ -1,4 +1,4 @@ -/* $NetBSD: if_tap.c,v 1.8 2005/05/17 04:14:58 christos Exp $ */ +/* $NetBSD: if_tap.c,v 1.9 2005/06/10 10:28:17 bouyer Exp $ */ /* * Copyright (c) 2003, 2004 The NetBSD Foundation. @@ -43,7 +43,7 @@ */ #include -__KERNEL_RCSID(0, "$NetBSD: if_tap.c,v 1.8 2005/05/17 04:14:58 christos Exp $"); +__KERNEL_RCSID(0, "$NetBSD: if_tap.c,v 1.9 2005/06/10 10:28:17 bouyer Exp $"); #if defined(_KERNEL_OPT) #include "bpfilter.h" @@ -919,6 +919,7 @@ tap_dev_write(int unit, struct uio *uio, int flags) struct ifnet *ifp; struct mbuf *m, **mp; int error = 0; + int s; if (sc == NULL) return (ENXIO); @@ -959,7 +960,9 @@ tap_dev_write(int unit, struct uio *uio, int flags) if (ifp->if_bpf) bpf_mtap(ifp->if_bpf, m); #endif + s =splnet(); (*ifp->if_input)(ifp, m); + splx(s); return (0); }