|
|||||||||||
|
kernel/3070: removable media does not detach correctly if it's currently mounted
From: <gumboot(at)clear.net.nz>
Date: Sat Jan 18 2003 - 18:07:41 EST
System : OpenBSD 3.2 Architecture: OpenBSD.i386 Machine : i386 >Description: Removing a USB storage device while it is mounted doesn't clear out all the device cruft that is added when it is attached. Consequential faults include applications (including umount) hanging when trying to access the mount point, and if you're really lucky you can get a kernel panic (I'm not reporting the panic, though). The machine must be rebooted to access the device again. >How-To-Repeat:
Remove a mounted USB storage device while it is mounted. Here's how I did it (my actions annotated with '**'). OpenBSD 3.2-stable (GENERIC.gumboot) #1: Thu Dec 19 18:48:19 NZDT 2002
gumboot@cowpat.grottyflat.net:/usr/src/sys/arch/i386/compile/GENERIC.gumboot
cpu0: AMD K6-2+/III+ ("AuthenticAMD" 586-class) 501 MHz
cpu0: FPU,V86,DE,PSE,TSC,MSR,MCE,CX8,PGE,MMX
real mem = 267956224 (261676K)
pcibios0: PCI IRQ Routing Table rev. 1.0 @ 0xfdd50/128 (6 entries)
pcibios0: PCI Exclusive IRQs: 5 9 11
pcibios0: PCI Interrupt Router at 000:07:0 ("VIA VT82C586 PCI-ISA" rev 0x00)
pcibios0: PCI bus #2 is the last bus
bios0: ROM list: 0xc0000/0x8000 0xc8000/0x2600 pci0 at mainbus0 bus 0: configuration mode 1 (no bios) pchb0 at pci0 dev 0 function 0 "VIA VT82C597 Host-PCI" rev 0x04 ppb0 at pci0 dev 1 function 0 "VIA VT82C598 PCI-AGP" rev 0x00 pci1 at ppb0 bus 1 vga1 at pci1 dev 0 function 0 "Matrox MGA G400/G450 AGP" rev 0x05 wsdisplay0 at vga1: console (80x25, vt100 emulation) wsdisplay0: screen 1-5 added (80x25, vt100 emulation) pcib0 at pci0 dev 7 function 0 "VIA VT82C586 PCI-ISA" rev 0x47 pciide0 at pci0 dev 7 function 1 "VIA VT82C571 IDE" rev 0x06: ATA33, channel 0 configured to compatibility, channel 1 configured to compatibility atapiscsi0 at pciide0 channel 0 drive 1 scsibus0 at atapiscsi0: 2 targets cd0 at scsibus0 targ 0 lun 0: [ASUS, CD-S500/A, 1.5D] SCSI0 5/cdrom removable cd0(pciide0:0:1): using PIO mode 4, Ultra-DMA mode 2 uhci0 at pci0 dev 7 function 2 "VIA VT83C572 USB" rev 0x02: irq 9 usb0 at uhci0: USB revision 1.0 uhub0 at usb0 uhub0: vendor 0x0000 UHCI root hub, class 9/0, rev 1.00/1.00, addr 1 uhub0: 2 ports with 2 removable, self powered "VIA VT82C586 Power Mgmt" rev 0x10 at pci0 dev 7 function 3 not configured pciide1 at pci0 dev 8 function 0 "CMD Technology PCI0649" rev 0x02: DMA, channel 0 configured to native-PCI, channel 1 configured to native-PCI pciide1: using irq 5 for native-PCI interrupt wd0 at pciide1 channel 0 drive 0: [ST320011A] wd0: 16-sector PIO, LBA, 19092MB, 16383 cyl, 16 head, 63 sec, 39102336 sectors wd0(pciide1:0:0): using PIO mode 4, Ultra-DMA mode 5 wd1 at pciide1 channel 1 drive 0: [IC35L040AVER07-0] wd1: 16-sector PIO, LBA, 39266MB, 16383 cyl, 16 head, 63 sec, 80418240 sectors wd2 at pciide1 channel 1 drive 1: [ST380021A] wd2: 16-sector PIO, LBA, 76319MB, 16383 cyl, 16 head, 63 sec, 156301488 sectors wd1(pciide1:1:0): using PIO mode 4, Ultra-DMA mode 5 wd2(pciide1:1:1): using PIO mode 4, Ultra-DMA mode 5 bktr0 at pci0 dev 9 function 0 "Brooktree BT878" rev 0x02: irq 11 bktr0: Askey/Dynalink Magic TView, Philips PAL I tuner. "Brooktree BT878 Audio" rev 0x02 at pci0 dev 9 function 1 not configured cmpci0 at pci0 dev 10 function 0 "C-Media Electronics CMI8738/C3DX Audio" rev 0x10: "C-Media Electronics CMI8738/C3DX Audio" rev 0x10 (rev. 0x10) cmpci0: interrupting at irq 9 audio0 at cmpci0 opl at cmpci0 not configured isa0 at pcib0 isadma0 at isa0 pckbc0 at isa0 port 0x60/5 pckbd0 at pckbc0 (kbd slot) pckbc0: using irq 1 for kbd slot wskbd0 at pckbd0: console keyboard, using wsdisplay0 pmsi0 at pckbc0 (aux slot) pckbc0: using irq 12 for aux slot wsmouse0 at pmsi0 mux 0 we1 at isa0 port 0x300/32 iomem 0xcc000/16384 irq 10: WD8013EPC (16-bit) we1: address 00:00:c0:58:96:4a pcppi0 at isa0 port 0x61 midi0 at pcppi0: [PC speaker] sysbeep0 at pcppi0 lpt0 at isa0 port 0x378/4 irq 7 npx0 at isa0 port 0xf0/16: using exception 16 pccom0 at isa0 port 0x3f8/8 irq 4: ns16550a, 16 byte fifo pccom1 at isa0 port 0x2f8/8 irq 3: ns16550a, 16 byte fifo fdc0 at isa0 port 0x3f0/6 irq 6 drq 2 fd0 at fdc0 drive 0: 1.44MB 80 cyl, 2 head, 18 sec biomask 4a60 netmask 4e60 ttymask 5ee2 pctr: user-level cycle counter enabled mtrr: K6-family MTRR support (2 registers) dkcsum: wd0 matched BIOS disk 80 dkcsum: wd1 matched BIOS disk 81 wd2: no disk label dkcsum: wd2 matched BIOS disk 82 root on wd0a rootdev=0x0 rrootdev=0x300 rawdev=0x302
No further cleanup is performed, and when the device is reattached no new messages appear. Only the final stages are necessary, but I include the others to demonstrate how it normally works. >Fix:
unknown >Release-Note:
This archive was generated by hypermail 2.1.8 : Wed Aug 23 2006 - 13:29:48 EDT |
||||||||||
|
|||||||||||