Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 25 May 2009 15:06:27 +0200
From:      Milan Obuch <freebsd-virtualization@dino.sk>
To:        freebsd-virtualization@freebsd.org
Subject:   Panic in netgraph with VIMAGE
Message-ID:  <200905251506.27771.freebsd-virtualization@dino.sk>

next in thread | raw e-mail | index | archive | help
Hi,
there is some bug in (most probably) netgraph code. I did fresh csup and=20
rebuild today. Whenever I try to turn bluetooth on (equivalent to plugging =
in=20
the dongle), panic occurs:

ubt0: <Micro Star International product 0xa97a, class 224/1, rev 2.00/31.64=
,=20
addr 2> on usbus3
panic:=20
in /usr/src/sys/modules/netgraph/netgraph/../../../netgraph/ng_base.c:634=20
ng_make_node_common()
 vnet=3D0 curvnet=3D0
cpuid =3D 0

This does not occur with kernel from sources three days old.

Part from core.txt file:

#0  doadump () at pcpu.h:246
246<--->pcpu.h: No such file or directory.
<------>in pcpu.h
(kgdb) #0  doadump () at pcpu.h:246
#1  0xc0554e0e in boot (howto=3D260) at /usr/src/sys/kern/kern_shutdown.c:4=
20
#2  0xc05550e2 in panic (fmt=3DVariable "fmt" is not available.
) at /usr/src/sys/kern/kern_shutdown.c:576
#3  0xc0b947c1 in ng_make_node_common (type=3D0xc0b8f9a0, nodepp=3D0xc416b3=
a8)
    at /usr/src/sys/modules/netgraph/netgraph/../../../netgraph/ng_base.c:6=
34
#4  0xc0b8bcc4 in ubt_attach (dev=3D0xc4294280)
   =20
at /usr/src/sys/modules/netgraph/bluetooth/ubt/../../../../dev/usb/bluetoot=
h/ng_ubt.c:443
#5  0xc057dcbf in device_attach (dev=3D0xc4294280) at device_if.h:178
#6  0xc057e88e in device_probe_and_attach (dev=3D0xc4294280)
    at /usr/src/sys/kern/subr_bus.c:2473
#7  0xc0b38240 in usb2_probe_and_attach_sub (udev=3D0xc41fd800, uaa=3D0xe41=
16c1c)
    at /usr/src/sys/modules/usb/usb/../../../dev/usb/usb_device.c:1131
#8  0xc0b3871a in usb2_probe_and_attach (udev=3D0xc41fd800, iface_index=3D2=
55 '=FF')
    at /usr/src/sys/modules/usb/usb/../../../dev/usb/usb_device.c:1288
#9  0xc0b40ff0 in uhub_explore (udev=3D0xc3f07000)
    at /usr/src/sys/modules/usb/usb/../../../dev/usb/usb_hub.c:218
#10 0xc0b31f29 in usb2_bus_explore (pm=3D0xc3ed0dd4)
   =20
at /usr/src/sys/modules/usb/usb/../../../dev/usb/controller/usb_controller.=
c:215
#11 0xc0b4343a in usb2_process (arg=3D0xc3ed0d74)
    at /usr/src/sys/modules/usb/usb/../../../dev/usb/usb_process.c:139
#12 0xc0530008 in fork_exit (callout=3D0xc0b43360 <usb2_process>,.
    arg=3D0xc3ed0d74, frame=3D0xe4116d38) at /usr/src/sys/kern/kern_fork.c:=
830
#13 0xc070b550 in fork_trampoline () at /usr/src/sys/i386/i386/exception.s:=
270

At line 634 in ng_base.c, there is

INIT_VNET_NETGRAPH(curvnet);

I have options VIMAGE in my kernel config (actually this is first one=20
succesfully compiled with mentioned option, but I did not try it too often,=
=20
it just failed to compile before).

Now I recompiled kernel again, this time without options VIMAGE in config, =
and=20
panic does not occur.

So the original problem is INIT_VNET_NETGRAPH implementation in presence of=
=20
options VIMAGE in kernel config. If anyone has anything to test, please let=
=20
me know.

Regards,
Milan



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200905251506.27771.freebsd-virtualization>