Bug 15321 - vfat usb device cannot be mounted on 2.6.32, works on 2.6.26
Summary: vfat usb device cannot be mounted on 2.6.32, works on 2.6.26
Status: RESOLVED INVALID
Alias: None
Product: Drivers
Classification: Unclassified
Component: USB (show other bugs)
Hardware: All Linux
: P1 normal
Assignee: Greg Kroah-Hartman
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2010-02-15 21:54 UTC by Shai Berger
Modified: 2010-02-22 00:03 UTC (History)
0 users

See Also:
Kernel Version: 2.6.32 (debian 2.6.32-trunk-686 ver. 2.6.32-5)
Subsystem:
Regression: Yes
Bisected commit-id:


Attachments
Output of dmesg after connecting device to a Lenny (2.6.26) machine (1.63 KB, text/plain)
2010-02-15 21:54 UTC, Shai Berger
Details
output of lsusb -v from Lenny (14.74 KB, text/plain)
2010-02-15 21:56 UTC, Shai Berger
Details
output of lsusb -v from Sid (2.6.32) (16.93 KB, text/plain)
2010-02-15 21:57 UTC, Shai Berger
Details
usbmon output from Sid (2.6.32) (126.25 KB, text/plain)
2010-02-21 22:42 UTC, Shai Berger
Details
usbmon output from Lenny (2.6.26) (96.04 KB, text/plain)
2010-02-21 22:55 UTC, Shai Berger
Details
no, 2.6.32 does mount it after all... (130.75 KB, text/plain)
2010-02-21 23:14 UTC, Shai Berger
Details

Description Shai Berger 2010-02-15 21:54:22 UTC
Created attachment 25057 [details]
Output of dmesg after connecting device to a Lenny (2.6.26) machine

Hi,

This is my first kernel bug, I hope the report is filled correctly. I am filing it on advice from  Moritz Muehlenhoff of the Debian kernel team, see http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=569906

Repeating the story for your convenience: The device is a so-called MP4 Player. I can mount it on a machine running Debian Stable, that is, kernel 2.6.26, by just specifying the vfat filesystem type. I cannot mount it on Debian unstable, running kernel 2.6.32, nor on Ubuntu 9.10, which uses 2.6.31-19.

I am copying below the relevant part of dmesg output from 2.6.32 (as collected by Debian's reportbug utility), and attaching three files: dmesg from 2.6.26, and "lsusb -v" from both systems when the device is attached. These inputs (and perhaps others which are on the Debian bug) led mr. Muehlenhoff to the conclusion that the problem is related to the "list of USB mass storage devices, which are not fully standards compliant and to which several workarounds are applied".

Thanks,

  Shai.

[1815555.504019] usb 1-1: new high speed USB device using ehci_hcd and address 33
[1815555.638436] usb 1-1: New USB device found, idVendor=10d6, idProduct=1101
[1815555.638441] usb 1-1: New USB device strings: Mfr=1, Product=2, SerialNumber=3
[1815555.638445] usb 1-1: Product: media player
[1815555.638447] usb 1-1: Manufacturer: actions
[1815555.638450] usb 1-1: SerialNumber: 单䑂卉K
[1815555.638563] usb 1-1: configuration #1 chosen from 1 choice
[1815555.640305] scsi43 : SCSI emulation for USB Mass Storage devices
[1815555.640535] usb-storage: device found at 33
[1815555.640538] usb-storage: waiting for device to settle before scanning
[1815560.640360] usb-storage: device scan complete
[1815560.681606] scsi 43:0:0:0: Direct-Access     GENERIC  USB DISK DEVICE  1.00 PQ: 0 ANSI: 0 CCS
[1815560.682225] scsi 43:0:0:1: Direct-Access     GENERIC  USB DISK DEVICE  1.00 PQ: 0 ANSI: 0 CCS
[1815560.682705] sd 43:0:0:0: Attached scsi generic sg2 type 0
[1815560.682876] sd 43:0:0:1: Attached scsi generic sg3 type 0
[1815560.686844] sd 43:0:0:0: [sdb] 3833344 512-byte logical blocks: (1.96 GB/1.82 GiB)
[1815560.687712] sd 43:0:0:1: [sdc] Attached SCSI removable disk
[1815560.688335] sd 43:0:0:0: [sdb] Write Protect is off
[1815560.688339] sd 43:0:0:0: [sdb] Mode Sense: 00 12 00 00
[1815560.688342] sd 43:0:0:0: [sdb] Assuming drive cache: write through
[1815560.691708] sd 43:0:0:0: [sdb] Assuming drive cache: write through
[1815560.691712]  sdb:
[1815560.695333] sd 43:0:0:0: [sdb] Assuming drive cache: write through
[1815560.695337] sd 43:0:0:0: [sdb] Attached SCSI removable disk
Comment 1 Shai Berger 2010-02-15 21:56:18 UTC
Created attachment 25058 [details]
output of lsusb -v from Lenny

(guess attachments need to be added one-by-one...)
Comment 2 Shai Berger 2010-02-15 21:57:10 UTC
Created attachment 25059 [details]
output of lsusb -v from Sid (2.6.32)
Comment 3 Andrew Morton 2010-02-19 21:18:39 UTC
(switched to email.  Please respond via emailed reply-to-all, not via the
bugzilla web interface).

(It's a regression)

On Mon, 15 Feb 2010 21:54:25 GMT
bugzilla-daemon@bugzilla.kernel.org wrote:

> http://bugzilla.kernel.org/show_bug.cgi?id=15321
> 
>            Summary: vfat usb device cannot be mounted on 2.6.32, works on
>                     2.6.26
>            Product: Drivers
>            Version: 2.5
>     Kernel Version: 2.6.32 (debian 2.6.32-trunk-686 ver. 2.6.32-5)
>           Platform: All
>         OS/Version: Linux
>               Tree: Mainline
>             Status: NEW
>           Severity: normal
>           Priority: P1
>          Component: USB
>         AssignedTo: greg@kroah.com
>         ReportedBy: shai@platonix.com
>         Regression: Yes
> 
> 
> Created an attachment (id=25057)
>  --> (http://bugzilla.kernel.org/attachment.cgi?id=25057)
> Output of dmesg after connecting device to a Lenny (2.6.26) machine
> 
> Hi,
> 
> This is my first kernel bug, I hope the report is filled correctly. I am
> filing
> it on advice from  Moritz Muehlenhoff of the Debian kernel team, see
> http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=569906
> 
> Repeating the story for your convenience: The device is a so-called MP4
> Player.
> I can mount it on a machine running Debian Stable, that is, kernel 2.6.26, by
> just specifying the vfat filesystem type. I cannot mount it on Debian
> unstable,
> running kernel 2.6.32, nor on Ubuntu 9.10, which uses 2.6.31-19.
> 
> I am copying below the relevant part of dmesg output from 2.6.32 (as
> collected
> by Debian's reportbug utility), and attaching three files: dmesg from 2.6.26,
> and "lsusb -v" from both systems when the device is attached. These inputs
> (and
> perhaps others which are on the Debian bug) led mr. Muehlenhoff to the
> conclusion that the problem is related to the "list of USB mass storage
> devices, which are not fully standards compliant and to which several
> workarounds are applied".
> 
> Thanks,
> 
>   Shai.
> 
> [1815555.504019] usb 1-1: new high speed USB device using ehci_hcd and
> address
> 33
> [1815555.638436] usb 1-1: New USB device found, idVendor=10d6, idProduct=1101
> [1815555.638441] usb 1-1: New USB device strings: Mfr=1, Product=2,
> SerialNumber=3
> [1815555.638445] usb 1-1: Product: media player
> [1815555.638447] usb 1-1: Manufacturer: actions
> [1815555.638450] usb 1-1: SerialNumber: _________K
> [1815555.638563] usb 1-1: configuration #1 chosen from 1 choice
> [1815555.640305] scsi43 : SCSI emulation for USB Mass Storage devices
> [1815555.640535] usb-storage: device found at 33
> [1815555.640538] usb-storage: waiting for device to settle before scanning
> [1815560.640360] usb-storage: device scan complete
> [1815560.681606] scsi 43:0:0:0: Direct-Access     GENERIC  USB DISK DEVICE 
> 1.00 PQ: 0 ANSI: 0 CCS
> [1815560.682225] scsi 43:0:0:1: Direct-Access     GENERIC  USB DISK DEVICE 
> 1.00 PQ: 0 ANSI: 0 CCS
> [1815560.682705] sd 43:0:0:0: Attached scsi generic sg2 type 0
> [1815560.682876] sd 43:0:0:1: Attached scsi generic sg3 type 0
> [1815560.686844] sd 43:0:0:0: [sdb] 3833344 512-byte logical blocks: (1.96
> GB/1.82 GiB)
> [1815560.687712] sd 43:0:0:1: [sdc] Attached SCSI removable disk
> [1815560.688335] sd 43:0:0:0: [sdb] Write Protect is off
> [1815560.688339] sd 43:0:0:0: [sdb] Mode Sense: 00 12 00 00
> [1815560.688342] sd 43:0:0:0: [sdb] Assuming drive cache: write through
> [1815560.691708] sd 43:0:0:0: [sdb] Assuming drive cache: write through
> [1815560.691712]  sdb:
> [1815560.695333] sd 43:0:0:0: [sdb] Assuming drive cache: write through
> [1815560.695337] sd 43:0:0:0: [sdb] Attached SCSI removable disk
>
Comment 4 Alan Stern 2010-02-21 22:24:04 UTC
On Fri, 19 Feb 2010, Andrew Morton wrote:

> > http://bugzilla.kernel.org/show_bug.cgi?id=15321
> > 
> >            Summary: vfat usb device cannot be mounted on 2.6.32, works on
> >                     2.6.26

...

> > Hi,
> > 
> > This is my first kernel bug, I hope the report is filled correctly. I am
> filing
> > it on advice from  Moritz Muehlenhoff of the Debian kernel team, see
> > http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=569906
> > 
> > Repeating the story for your convenience: The device is a so-called MP4
> Player.
> > I can mount it on a machine running Debian Stable, that is, kernel 2.6.26,
> by
> > just specifying the vfat filesystem type. I cannot mount it on Debian
> unstable,
> > running kernel 2.6.32, nor on Ubuntu 9.10, which uses 2.6.31-19.

What do you mean exactly?  That is, what happens when you try to mount 
it?

> > I am copying below the relevant part of dmesg output from 2.6.32 (as
> collected
> > by Debian's reportbug utility), and attaching three files: dmesg from
> 2.6.26,
> > and "lsusb -v" from both systems when the device is attached. These inputs
> (and
> > perhaps others which are on the Debian bug) led mr. Muehlenhoff to the
> > conclusion that the problem is related to the "list of USB mass storage
> > devices, which are not fully standards compliant and to which several
> > workarounds are applied".

Muehlenhoff wasn't entirely correct; 2.6.26 does include an entry with
idVendor=10d6, but it has idProduct=2200 instead of 1101.

The best way to find the cause of the problem is for you to collect a
usbmon trace under 2.6.32, showing what happens when you plug in the
drive and try to mount it.  See the kernel source file
Documentation/usb/usbmon.txt for instructions.  Attach the trace to the
bug report and then reply to this email to let us know it's ready.

It wouldn't hurt to collect an analogous usbmon trace under 2.6.26; the 
differences between the two traces might be informative.

Alan Stern
Comment 5 Shai Berger 2010-02-21 22:42:32 UTC
Created attachment 25146 [details]
usbmon output from Sid (2.6.32)

Here is the usbmon output on 2.6.32, while connecting, trying to mount, and finally disconnecting the device. The mount attempt was:

$ sudo mount -t vfat -o readonly /dev/sdb  /media/mp4/
mount: wrong fs type, bad option, bad superblock on /dev/sdb,
       missing codepage or helper program, or other error
       In some cases useful info is found in syslog - try
       dmesg | tail  or so

$ echo $?
32
Comment 6 Shai Berger 2010-02-21 22:55:14 UTC
Created attachment 25147 [details]
usbmon output from Lenny (2.6.26)

This is usbmon output from 2.6.26. The output was collected while I connected the device, mounted it (essentially same command as before), listed its root directory to make sure everything succeeded, unmounted and disconnected.
Comment 7 Shai Berger 2010-02-21 23:14:23 UTC
Created attachment 25148 [details]
no, 2.6.32 does mount it after all...
Comment 8 Shai Berger 2010-02-21 23:39:53 UTC
I'm sorry -- I've probably done something wrong earlier, and then tried to 
mount the device as "readonly" to be on the safe side, and that seems to have 
been the source of my problems later. After generating the usbmon reports 
(relying on shell history), I noticed the "-o readonly" in the command and the 
"...bad option, " in the error message, tried without it, and it worked.

There still is something weird here -- HAL doesn't seem to realize the device 
is there, but that's probably not a kernel issue. I've attached the usbmon 
output of successful connect-mount-ls-umount-disconnect on 2.6.32 for 
completeness.

I apologize sincerely for wasting your time,

Shai.

PS: I'm closing the bug. I hope that's ok, and I hope I'll be allowed to reopen if it turns out that there's a kernel issue after all.

Thanks, and again, sorry,

Shai.
Comment 9 Shai Berger 2010-02-22 00:03:19 UTC
I'm sorry -- I've probably done something wrong earlier, and then tried to 
mount the device as "readonly" to be on the safe side, and that seems to have 
been the source of my problems later. After generating the usbmon reports 
(relying on shell history), I noticed the "-o readonly" in the command and the 
"...bad option, " in the error message, tried without it, and it worked.

There still is something weird here -- HAL doesn't seem to realize the device 
is there, but that's probably not a kernel issue. I've attached the usbmon 
output of successful connect-mount-ls-umount-disconnect on 2.6.32 for 
completeness.

I apologize sincerely for wasting your time,

Shai.

Note You need to log in before you can comment on or make changes to this bug.