A correction to my report: the media query is not the only path that
recurses through the stack, and the How-To-Repeat usually crashes the
machine before its last command.

Setting the parent recurses as well.  bpe_set_parent() calls
ifsetlro(ifp0, 0) on the new parent (if_bpe.c:638).  When the parent
is itself a bpe, ifsetlro() calls its bpe_ioctl(SIOCSIFXFLAGS), which
calls ifsetlro() on that bpe's parent (if_bpe.c:320-322), and so on
down the whole chain.  So once the stack is deep enough, the
"ifconfig bpeN parent bpeM" inside the loop already overflows the
kernel stack; one of my crashes stopped in ifsetlro() (the others in
if_get() and bpe_ioctl()), and running the How-To-Repeat again
here crashed in the loop, before "ifconfig bpe300".

The diff in the report covers this too

Reply via email to