[Bug 221328] [usb] [panic] kernel panic when mount from external USB HDD

classic Classic list List threaded Threaded
7 messages Options
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

[Bug 221328] [usb] [panic] kernel panic when mount from external USB HDD

bugzilla-noreply
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=221328

            Bug ID: 221328
           Summary: [usb] [panic] kernel panic when mount from external
                    USB HDD
           Product: Base System
           Version: CURRENT
          Hardware: Any
                OS: Any
            Status: New
          Severity: Affects Only Me
          Priority: ---
         Component: usb
          Assignee: [hidden email]
          Reporter: [hidden email]

Quirks for External USB HDD box (Agestar CFB3a, detected as "Prolific
Technology Inc. Mass Storage Device") require some changes for normal work,
otherwise kernel crash while mounting filesystem from it.

Aug  8 14:52:10 home kernel: ugen4.3: <Prolific Technology Inc. Mass Storage
Device> at usbus4
Aug  8 14:52:10 home kernel: umass0 on uhub5
Aug  8 14:52:10 home kernel: umass0: <Prolific Technology Inc. Mass Storage
Device, class 0/0, rev 2.00/1.00, addr 3> on usbus4
Aug  8 14:52:10 home kernel: umass0:  SCSI over Bulk-Only; quirks = 0xc100
Aug  8 14:52:10 home kernel: umass0:3:0: Attached to scbus3
Aug  8 14:52:10 home kernel: da0 at umass-sim0 bus 0 scbus3 target 0 lun 0
Aug  8 14:52:10 home kernel: da0: <ST312081 4A 2AAA> Fixed Direct Access SCSI
device
Aug  8 14:52:10 home kernel: da0: 40.000MB/s transfers
Aug  8 14:52:10 home kernel: da0: 114473MB (234441648 512 byte sectors)
Aug  8 14:52:10 home kernel: da0: quirks=0x2<NO_6_BYTE>
Aug  8 15:00:06 home su: stast to root on /dev/pts/0
Aug  8 15:01:27 home kernel: GEOM_ELI: Device da0.eli created.
Aug  8 15:01:27 home kernel: GEOM_ELI: Encryption: AES-XTS 128
Aug  8 15:01:27 home kernel: GEOM_ELI:     Crypto: software
Aug  8 15:01:55 home kernel: (da0:umass-sim0:0:0:0): WRITE(10). CDB: 2a 00 00
00 9e 00 00 00 08 00
Aug  8 15:01:55 home kernel: (da0:umass-sim0:0:0:0): CAM status: Auto-Sense
Retrieval Failed
Aug  8 15:01:55 home kernel: (da0:umass-sim0:0:0:0): Error 5, Unretryable error
Aug  8 15:01:55 home kernel: GEOM_ELI: g_eli_write_done() failed (error=5)
da0.eli[WRITE(offset=20709376, length=4096)]
Aug  8 15:01:55 home kernel: g_vfs_done():da0.eli[WRITE(offset=20709376,
length=4096)]error = 5
Aug  8 15:02:00 home devd: notify_clients: send() failed; dropping unresponsive
client
Aug  8 15:02:00 home kernel: (da0:umass-sim0:0:0:0): READ(10). CDB: 28 00 00 00
01 40 00 00 40 00
Aug  8 15:02:00 home kernel: (da0:umass-sim0:0:0:0): CAM status: CCB request
completed with an error
Aug  8 15:02:00 home kernel: (da0:umass-sim0:0:0:0): Retrying command
Aug  8 15:02:01 home kernel: (da0:umass-sim0:0:0:0): READ(10). CDB: 28 00 00 00
01 40 00 00 40 00
Aug  8 15:02:01 home kernel: (da0:umass-sim0:0:0:0): CAM status: CCB request
completed with an error
Aug  8 15:02:01 home kernel: (da0:umass-sim0:0:0:0): Retrying command
Aug  8 15:02:01 home kernel: (da0:umass-sim0:0:0:0): READ(10). CDB: 28 00 00 00
01 40 00 00 40 00
Aug  8 15:02:01 home kernel: (da0:umass-sim0:0:0:0): CAM status: CCB request
completed with an error
Aug  8 15:02:01 home kernel: (da0:umass-sim0:0:0:0): Retrying command
Aug  8 15:02:02 home kernel: (da0:umass-sim0:0:0:0): READ(10). CDB: 28 00 00 00
01 40 00 00 40 00
Aug  8 15:02:02 home kernel: (da0:umass-sim0:0:0:0): CAM status: CCB request
completed with an error
Aug  8 15:02:02 home kernel: (da0:umass-sim0:0:0:0): Retrying command
Aug  8 15:03:54 home syslogd: kernel boot file is /boot/kernel/kernel
Aug  8 15:03:54 home kernel: g_vfs_done():da0.eli[READ(offset=163840,
length=32768)]error = 5
Aug  8 15:03:54 home kernel: panic: mount: lost mount
Aug  8 15:03:54 home kernel: cpuid = 0
Aug  8 15:03:54 home kernel: time = 1502179322
Aug  8 15:03:54 home kernel: KDB: stack backtrace:
Aug  8 15:03:54 home kernel: #0 0xffffffff80aa8e07 at kdb_backtrace+0x67
Aug  8 15:03:54 home kernel: #1 0xffffffff80a66b8c at vpanic+0x19c
Aug  8 15:03:54 home kernel: #2 0xffffffff80a669e3 at panic+0x43
Aug  8 15:03:54 home kernel: #3 0xffffffff80b1a95e at vfs_donmount+0x1a7e
Aug  8 15:03:54 home kernel: #4 0xffffffff80b18eb2 at sys_nmount+0x72
Aug  8 15:03:54 home kernel: #5 0xffffffff80edf424 at amd64_syscall+0x6c4
Aug  8 15:03:54 home kernel: #6 0xffffffff80ec23db at Xfast_syscall+0xfb
Aug  8 15:03:54 home kernel: Uptime: 2h49m39s

I found that it can be fixed with quirks by string in loader.conf:
hw.usb.quirk.0="0x067b 0x2506 0 0xffff UQ_MSC_NO_PREVENT_ALLOW"

FreeBSD-current from April 2017.

--
You are receiving this mail because:
You are the assignee for the bug.
_______________________________________________
[hidden email] mailing list
https://lists.freebsd.org/mailman/listinfo/freebsd-usb
To unsubscribe, send any mail to "[hidden email]"
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

[Bug 221328] [usb] [panic] kernel panic when mount from external USB HDD

bugzilla-noreply
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=221328

Hans Petter Selasky <[hidden email]> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |[hidden email]

--- Comment #1 from Hans Petter Selasky <[hidden email]> ---
Hi,

Can you make a permanent patch for:
/sys/dev/usb/quirk/usb_quirk.c

You also need to update:

/sys/dev/usb/usbdevs

--HPS

--
You are receiving this mail because:
You are the assignee for the bug.
_______________________________________________
[hidden email] mailing list
https://lists.freebsd.org/mailman/listinfo/freebsd-usb
To unsubscribe, send any mail to "[hidden email]"
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

[Bug 221328] [usb] [panic] kernel panic when mount from external USB HDD

bugzilla-noreply
In reply to this post by bugzilla-noreply
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=221328

--- Comment #2 from [hidden email] ---
Created attachment 185151
  --> https://bugs.freebsd.org/bugzilla/attachment.cgi?id=185151&action=edit
Patch for dev/usb/quirk/usb_quirk.c

--
You are receiving this mail because:
You are the assignee for the bug.
_______________________________________________
[hidden email] mailing list
https://lists.freebsd.org/mailman/listinfo/freebsd-usb
To unsubscribe, send any mail to "[hidden email]"
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

[Bug 221328] [usb] [panic] kernel panic when mount from external USB HDD

bugzilla-noreply
In reply to this post by bugzilla-noreply
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=221328

--- Comment #3 from [hidden email] ---
Patch for dev/usb/quirk/usb_quirk.c done.

No changes are required for /sys/dev/usb/usbdevs

--
You are receiving this mail because:
You are the assignee for the bug.
_______________________________________________
[hidden email] mailing list
https://lists.freebsd.org/mailman/listinfo/freebsd-usb
To unsubscribe, send any mail to "[hidden email]"
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

[Bug 221328] [usb] [panic] kernel panic when mount from external USB HDD

bugzilla-noreply
In reply to this post by bugzilla-noreply
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=221328

Hans Petter Selasky <[hidden email]> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|New                         |In Progress

--- Comment #4 from Hans Petter Selasky <[hidden email]> ---
There should be a space after ","

UQ_MSC_NO_SYNC_CACHE,UQ_MSC_NO_PREVENT_ALLOW),

Patch looks good!

Will commit it when time permits.

--HPS

--
You are receiving this mail because:
You are the assignee for the bug.
_______________________________________________
[hidden email] mailing list
https://lists.freebsd.org/mailman/listinfo/freebsd-usb
To unsubscribe, send any mail to "[hidden email]"
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

[Bug 221328] [usb] [panic] kernel panic when mount from external USB HDD

bugzilla-noreply
In reply to this post by bugzilla-noreply
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=221328

Hans Petter Selasky <[hidden email]> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|In Progress                 |Closed
         Resolution|---                         |FIXED

--
You are receiving this mail because:
You are the assignee for the bug.
_______________________________________________
[hidden email] mailing list
https://lists.freebsd.org/mailman/listinfo/freebsd-usb
To unsubscribe, send any mail to "[hidden email]"
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

[Bug 221328] [usb] [panic] kernel panic when mount from external USB HDD

bugzilla-noreply
In reply to this post by bugzilla-noreply
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=221328

--- Comment #5 from [hidden email] ---
A commit references this bug:

Author: hselasky
Date: Tue Aug 15 08:44:36 UTC 2017
New revision: 322530
URL: https://svnweb.freebsd.org/changeset/base/322530

Log:
  Add new USB quirk.

  Submitted by:         [hidden email]
  PR:                   221328
  MFC after:            1 week
  Sponsored by:         Mellanox Technologies

Changes:
  head/sys/dev/usb/quirk/usb_quirk.c

--
You are receiving this mail because:
You are the assignee for the bug.
_______________________________________________
[hidden email] mailing list
https://lists.freebsd.org/mailman/listinfo/freebsd-usb
To unsubscribe, send any mail to "[hidden email]"
Loading...