Proper way to shutdown a USB ethernet adapter?
LukeD at pobox.com
LukeD at pobox.com
Fri May 21 00:03:12 PDT 2004
I'm running i386 5.2-CURRENT and using the axe driver to run a Netgear
FA120 USB ethernet adapter.
5.2-CURRENT FreeBSD 5.2-CURRENT #0: Tue May 18 16:11:06 PDT 2004
It works great. I even figured out how to run usbd and modify usbd.conf
to run ifconfig automatically to give it an ip address when I plug it in
and take away the ip address when I unplug it.
When it's up and running, ifconfig shows:
axe0: flags=8843<UP,BROADCAST,RUNNING,SIMPLEX,MULTICAST> mtu 1500
inet6 fe80::209:5bff:febd:d01a%axe0 prefixlen 64 scopeid 0x1
inet 192.168.10.100 netmask 0xffffff00 broadcast 192.168.10.255
media: Ethernet autoselect (100baseTX)
The problem is that no matter what I try, every time I try to shut down
the system, if this device is plugged in, the system will panic with a
page fault when init terminates.
I get the same panic whenever I run "ifconfig axe0 down".
This happens regardless of whether I'm running usbd or not.
This happens even if I "ifconfig axe0 delete" to remove the IP address
before I shut down.
The only way I've found to avoid the panic is to unplug the device before
shutdown, and that's difficult to do remotely...
Page faults during shutdowns are usually just a simple matter of memory
being deallocated in the wrong order. If that's what this is, it may be
something I could fix. Any suggestions on how I might trace this down?
The panic looks like this:
Fatal trap 12: page fault while in kernel mode
cpuid = 0; apic id = 00
fault virtual address = 0xdeadc0e1
fault code = supervisor read, page not present
instruction pointer = 0x8 : 0xc0487e6e
stack pointer = 0x10 : 0xc4888acc
frame pointer = 0x10 : 0xc4888ae0
code segment = base 0x0, limit 0xfffff, type 0x1b
DPL 0, pres 1, def32 1, gran 1
processor eflags = interrupt enabled, resume, IOPL = 0
current process = 1 (init)
kernel: type 12 trap, code = 0
stopped at usb_transfer_complete+0xba: movzbl 0x3(%eax),%eax
More information about the freebsd-questions