usb/125450: Removing USB flash card while being accessed causes kernel panic

Simson Garfinkel simsong at
Mon Jul 14 16:20:07 UTC 2008

> options USB_DEBUG
> and
> sysctl hw.usb.umass.debug=-1
> sysctl hw.usb.debug=15

Strangely, it was considerably harder to make the machine panic once  
USB_DEBUG was enabled and the usb debug messages were printing to the  
kernel. It took me 6 tries of running the "dd" command on the raw USB  
device and pulling the device before the machine actually panicked.

The panic is happened after the "dd" command finishes printing it's  
statistics. but before the return to the command line.

page fault while in kernel mode.  Fault virtual addr = 0

Is that a dereference through a null pointer?

The IP is 0x20:0xc0460c3b

Is there an easy way to get a link map of the kernel?

Unfortunately, I can't get the stack trace because the system is not  
performing the crash dump. I've never done a FreeBSD crash dump. I  
tried following the directions, but no luck.

I have also tried configuring a dumpdev in the /etc/rc.conf file:

03:27 PM copy:/home/simsong# cat /etc/rc.conf

03:28 PM copy:/home/simsong# cat /etc/fstab
# Device		Mountpoint	FStype	Options		Dump	Pass#
/dev/ad0s1b		none		swap	sw		0	0
/dev/ad0s1a		/		ufs	rw		1	1
/dev/ad0s1e		/tmp		ufs	rw		2	2
/dev/ad0s1f		/usr		ufs	rw		2	2
/dev/ad0s1d		/var		ufs	rw		2	2
/dev/acd0		/cdrom		cd9660	ro,noauto	0	0
/dev/acd1		/cdrom1		cd9660	ro,noauto	0	0
/dev/ad8s1d		/big		ufs	rw		3	3
03:29 PM copy:/home/simsong#

I can't figure out why it won't dump.

> --HPS

More information about the freebsd-usb mailing list