Sending keep alive ends up in ip_output(), so it needs the NET_LOCK().

ok?

Index: net/if_gre.c
===================================================================
RCS file: /cvs/src/sys/net/if_gre.c,v
retrieving revision 1.81
diff -u -p -r1.81 if_gre.c
--- net/if_gre.c        16 Nov 2016 14:50:13 -0000      1.81
+++ net/if_gre.c        19 Dec 2016 10:38:00 -0000
@@ -662,10 +662,10 @@ gre_send_keepalive(void *arg)
        bzero(&dst, sizeof(dst));
        dst.sa_family = AF_INET;
 
-       s = splsoftnet();
+       NET_LOCK(s);
        /* should we care about the error? */
        gre_output(&sc->sc_if, m, &dst, NULL);
-       splx(s);
+       NET_UNLOCK(s);
 }
 
 void

Reply via email to