usb/128847: Detachment of mounted USB flash drive causes system freeze

2008-11-13 Thread Patrick

>Number: 128847
>Category:   usb
>Synopsis:   Detachment of mounted USB flash drive causes system freeze
>Confidential:   no
>Severity:   serious
>Priority:   low
>Responsible:freebsd-usb
>State:  open
>Quarter:
>Keywords:   
>Date-Required:
>Class:  sw-bug
>Submitter-Id:   current-users
>Arrival-Date:   Thu Nov 13 18:10:06 UTC 2008
>Closed-Date:
>Last-Modified:
>Originator: Patrick
>Release:7.0
>Organization:
>Environment:
FreeBSD hostname 7.0-RELEASE FreeBSD 7.0-RELEASE #0: Sun Feb 24 19:59:52 UTC 
2008 [EMAIL PROTECTED]:/usr/obj/usr/src/sys/GENERIC  i386

>Description:
When I manually detach my USB flash drive that contains files in use on the 
system in question without umounting it, and then re-attach it, my system 
freezes.
>How-To-Repeat:
Mount the USB flash drive. Open one of the files located on the drive with a 
program such as Opera or leafpad (what I did). Manually remove the USB flash 
drive. Reinsert the flash drive.

I then tried to save the file I had opened in leafpad, and it told me it could 
not open the file for saving. I opened up a terminal and ran 'su', and that's 
when my system froze. /var/log/messages showed this:

Nov 13 17:16:10  kernel: GEOM_LABEL: Label msdosfs/WWMPCDD_USB removed.
Nov 13 17:45:23  kernel: umass0: at uhub4 port 5 (addr 2) disconnected
Nov 13 17:45:23  kernel: (da0:umass-sim0:0:0:0): lost device
Nov 13 17:45:23  kernel: umass0: detached
Nov 13 17:45:54  kernel: umass0:  on uhub4
Nov 13 17:45:54  root: Unknown USB device: vendor 0x0781 product 0x5150 bus 
uhub4
Nov 13 17:45:55  kernel: da1 at umass-sim0 bus 0 target 0 lun 0
Nov 13 17:45:55  kernel: da1:  Removable Direct Access 
SCSI-2 device 
Nov 13 17:45:55  kernel: da1: 40.000MB/s transfers
Nov 13 17:45:55  kernel: da1: 244MB (501759 512 byte sectors: 64H 32S/T 244C)
Nov 13 17:45:55  kernel: GEOM_LABEL: Label for provider da1s1 is 
msdosfs/WWMPCDD_USB.
Nov 13 17:45:58  kernel: g_vfs_done():da0s1[WRITE(offset=22452224, 
length=2048)]error = 6
>Fix:


Patch attached with submission follows:

Copyright (c) 1992-2008 The FreeBSD Project.
Copyright (c) 1979, 1980, 1983, 1986, 1988, 1989, 1991, 1992, 1993, 1994
The Regents of the University of California. All rights reserved.
FreeBSD is a registered trademark of The FreeBSD Foundation.
FreeBSD 7.0-RELEASE #0: Sun Feb 24 19:59:52 UTC 2008
[EMAIL PROTECTED]:/usr/obj/usr/src/sys/GENERIC
Timecounter "i8254" frequency 1193182 Hz quality 0
CPU: Intel(R) Pentium(R) 4 CPU 2.40GHz (1202.73-MHz 686-class CPU)
  Origin = "GenuineIntel"  Id = 0xf29  Stepping = 9
  
Features=0xbfebfbff
  Features2=0x4400
  Logical CPUs per core: 2
real memory  = 536805376 (511 MB)
avail memory = 503001088 (479 MB)
ACPI APIC Table: 
FreeBSD/SMP: Multiprocessor System Detected: 2 CPUs
 cpu0 (BSP): APIC ID:  0
 cpu1 (AP): APIC ID:  1
ioapic0: Changing APIC ID to 2
ioapic0  irqs 0-23 on motherboard
kbd1 at kbdmux0
ath_hal: 0.9.20.3 (AR5210, AR5211, AR5212, RF5111, RF5112, RF2413, RF5413)
hptrr: HPT RocketRAID controller driver v1.1 (Feb 24 2008 19:59:27)
acpi0:  on motherboard
acpi0: [ITHREAD]
acpi0: Power Button (fixed)
acpi0: reservation of 0, a (3) failed
acpi0: reservation of 10, 1fef (3) failed
Timecounter "ACPI-fast" frequency 3579545 Hz quality 1000
acpi_timer0: <24-bit timer at 3.579545MHz> port 0x408-0x40b on acpi0
cpu0:  on acpi0
p4tcc0:  on cpu0
cpu1:  on acpi0
p4tcc1:  on cpu1
acpi_button0:  on acpi0
pcib0:  port 0xcf8-0xcff on acpi0
pci0:  on pcib0
agp0:  on hostb0
pcib1:  at device 1.0 on pci0
pci1:  on pcib1
nvidia0:  mem 0xf000-0xf0ff,0xe800-0xefff irq 
16 at device 0.0 on pci1
nvidia0: [GIANT-LOCKED]
nvidia0: [ITHREAD]
uhci0:  port 0xac00-0xac1f irq 16 at 
device 29.0 on pci0
uhci0: [GIANT-LOCKED]
uhci0: [ITHREAD]
usb0:  on uhci0
usb0: USB revision 1.0
uhub0:  on usb0
uhub0: 2 ports with 2 removable, self powered
uhci1:  port 0xa000-0xa01f irq 19 at 
device 29.1 on pci0
uhci1: [GIANT-LOCKED]
uhci1: [ITHREAD]
usb1:  on uhci1
usb1: USB revision 1.0
uhub1:  on usb1
uhub1: 2 ports with 2 removable, self powered
uhci2:  port 0xa400-0xa41f irq 18 at 
device 29.2 on pci0
uhci2: [GIANT-LOCKED]
uhci2: [ITHREAD]
usb2:  on uhci2
usb2: USB revision 1.0
uhub2:  on usb2
uhub2: 2 ports with 2 removable, self powered
uhci3:  port 0xa800-0xa81f irq 16 at 
device 29.3 on pci0
uhci3: [GIANT-LOCKED]
uhci3: [ITHREAD]
usb3:  on uhci3
usb3: USB revision 1.0
uhub3:  on usb3
uhub3: 2 ports with 2 removable, self powered
ehci0:  mem 0xf400-0xf40003ff 
irq 23 at device 29.7 on pci0
ehci0: [GIANT-LOCKED]
ehci0: [ITHREAD]
usb4: EHCI version 1.0
usb4: companion controllers, 2 ports each: usb0 usb1 usb2 usb3
usb4:  on ehci0
usb4: USB revision 2.0
uhub4:  on usb4
uhub4: 8 ports with 8 removable, self powered
pcib2:  at device 30.0 on pci0
pci2:  on pcib2
fwohci0:  mem 
0xf3005000-0xf30057ff,0xf300-0xf3003fff irq 17 at device 1.0 on pci2
fwohci0: [FILTER]
fwohci0: OHCI version 1.10 (ROM=1)
fwohc

Re: usb/102096: [patch] usbd(8) does not handle multiple devices in one event [regression]

2008-11-13 Thread linimon
Synopsis: [patch] usbd(8) does not handle multiple devices in one event 
[regression]

State-Changed-From-To: feedback->closed
State-Changed-By: linimon
State-Changed-When: Thu Nov 13 18:28:48 UTC 2008
State-Changed-Why: 
Close due to feedback timeout.  The recommended approach these days
is to use devd.  Thanks for the submission, however.

http://www.freebsd.org/cgi/query-pr.cgi?pr=102096
___
freebsd-usb@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-usb
To unsubscribe, send any mail to "[EMAIL PROTECTED]"


Re: bin/57255: [patch] usbd(8) and multi-function devices

2008-11-13 Thread linimon
Synopsis: [patch] usbd(8) and multi-function devices

State-Changed-From-To: open->suspended
State-Changed-By: linimon
State-Changed-When: Thu Nov 13 18:30:17 UTC 2008
State-Changed-Why: 
These days, the recommended approach is to use devd, so mark this
suspended unless someone takes an interest in usbd.

http://www.freebsd.org/cgi/query-pr.cgi?pr=57255
___
freebsd-usb@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-usb
To unsubscribe, send any mail to "[EMAIL PROTECTED]"


kernel panic of usb2

2008-11-13 Thread kevin

Hi ,
   i can't write anything in usb flash devices.i can mount device well 
with usb2_storage_mss.

db>bt
Tracing pid 1367 tid 100147 td 0xff0004e756e0
kdb_enter() at kdb_enter+0x3d
panic() at panic+0x176
vm_pfault() at vm_pfault+0x19ce
trap_pfault() at trap_pfault+0x2a9
trap() at trap+0c327
calltrap()  at calltrap+0x8
--- trap 0xc, rip = 0x80511166, rsp = 0xfffee962bac0, rdp = 
0xff

fee962bb00 ---
bcopy() at bcopy+0x16
usb2_bdma_per_sync() at usb2_bdma_per_sync+0x35
usb2_bdma_work_loop() at usb2_bdma_work_loop+0x346
usb2_command_wrapper() at usb2_command_wrapper+0x76
usb2_callback_wrapper() at usb2_callback_wrapper+0x2d4
usb2_command_wrapper() at usb2_command_wrapper+0x76
usb2_callback_proc() at usb2_callback_proc+0x90
usb2_process() at usb2_process+0xd2
fork_exit() at fork_exit+0x118
fork_trampoline() at fork_trampoline+0xe
--- trap 0, rip =0, rsp=0xfffee962bd40,  rbp = 0 ---

Thanks,
kevin

___
freebsd-usb@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-usb
To unsubscribe, send any mail to "[EMAIL PROTECTED]"