On Sat, May 19, 2018 at 02:30:27PM +0200, Peter J. Philipp wrote:
> I have applied it now, what it was
> missing was a terminating semicolon on KERNEL_LOCK(), so far my C goes I was
> able to correct that.
Ah, I tested a GENERIC non MP kernel in qemu. There the define is
a noop and the compiler ignored the missing ; .
> Do you want me to get back to you tonight after 8PM in case this
> box hasn't paniced again?
To trigger the panic, you must send a lot of traffic. Please report
tonight whether it is stable now.
Here is the fixed diff.
bluhm
Index: net/pfkeyv2.c
===================================================================
RCS file: /data/mirror/openbsd/cvs/src/sys/net/pfkeyv2.c,v
retrieving revision 1.179
diff -u -p -r1.179 pfkeyv2.c
--- net/pfkeyv2.c 16 May 2018 13:19:00 -0000 1.179
+++ net/pfkeyv2.c 19 May 2018 12:37:11 -0000
@@ -381,12 +381,15 @@ pfkey_sendup(struct keycb *kp, struct mb
} else
m = m0;
+ KERNEL_LOCK();
if (!sbappendaddr(so, &so->so_rcv, &pfkey_addr, m, NULL)) {
m_freem(m);
+ KERNEL_UNLOCK();
return (ENOBUFS);
}
sorwakeup(so);
+ KERNEL_UNLOCK();
return (0);
}