kernel refuses to handle 2GB secure digital cards correctly. 2GB (transcend 150x, fwiw) inserted into SD slot in 4-slot card reader; attaching card reader yields: umass0: SMSC 223 USB97C223, rev 2.00/1.95, addr 3 da0 at umass-sim0 bus 0 target 0 lun 0 da0: <SMSC 223 U HS-CF 1.95> Removable Direct Access SCSI-0 device da0: 40.000MB/s transfers da0: Attempt to query device size failed: NOT READY, Medium not present da1 at umass-sim0 bus 0 target 0 lun 1 da1: <SMSC 223 U HS-MS 1.95> Removable Direct Access SCSI-0 device da1: 40.000MB/s transfers da1: Attempt to query device size failed: NOT READY, Medium not present da2 at umass-sim0 bus 0 target 0 lun 2 da2: <SMSC 223 U HS-SM 1.95> Removable Direct Access SCSI-0 device da2: 40.000MB/s transfers da2: Attempt to query device size failed: NOT READY, Medium not present da3 at umass-sim0 bus 0 target 0 lun 3 da3: <SMSC 223 U HS-SD/MMC 1.95> Removable Direct Access SCSI-0 device da3: 40.000MB/s transfers da3: 1962MB (2009600 1024 byte sectors: 255H 63S/T 125C) Note that card is detected correctly as da3 (and also da3s1 pops up in /dev). Trying to access da3s1 (mount_msdosfs) yields: g_vfs_done():da3s1[READ(offset=512, length=4096)]error = 22 Also fdisk seems to go through something similar: # fdisk da3 fdisk: could not detect sector size # fdisk-linux -b 1024 /dev/da3 Unable to read /dev/da3 The card works fine in the same card reader under WinME (sorry...) and also works fine in the DigiMate II-plus for copying its contents to external storage and also works fine in two digital cameras (and, yes, as 2GB). How-To-Repeat: Plug in said 2GB SD card and try to access it
Responsible Changed From-To: freebsd-bugs->freebsd-usb reclassify.
Responsible Changed From-To: freebsd-usb->freebsd-geom mjacob suggests this reassignment.
It looks like msdosfs cannot handle sector sizes different than 512B... What if u try this: 1. dd if=/dev/da3 of=/tmp/da3.cpy ibs=1k obs=1m 2. mdconfig -a -f /tmp/da3.cpy 3. mount_msdosfs /dev/md0s1 /mnt ? -Arne ____________________________________________________________________________________ Get the free Yahoo! toolbar and rest assured with the added security of spyware protection. http://new.toolbar.yahoo.com/toolbar/features/norton/index.php
[sorry I goofed up with send-pr; this is my first bug report...] No, it's not a geom issue. Same thing happens with geom disabled. Nothing to do with msdosfs, either. I have since tried the following: 1) booted into single user without any geom modules; same effect 2) dd with conv=noerror seems to deliver some data of some sort (though not sufficient for a valid file system) 3) reading 512, 1k, 2k, 4k off da3 fails. lseek() to 512, 1024, 1536, 2048 and *then* reading 512, 1k, 2k, 4k fails as well. Bernard
Luckily the WinME machine is a laptop which has a PCMCIA slot and also has a slightly elderly 6.2 pre-release on it. So I grabbed hold of a pcmcia (cardbus) SD card reader, inserted card. Voila: ad4 at ata2 got detected, ad4 accessible by fdisk, ad4s1 mountable msdosfs. May i humbly suggest that the bug is somewhere in either umass or cam or both. Bernard
Well... that was pretty fast :-( Address validator or Nigeran scammer: > Received: from sun.com (125.84.217.87.dynamic.jazztel.es [87.217.84.125]) > by $CENSORED (Postfix) with SMTP id 872F82A674 > for $MYADDRESS; Wed, 27 Jun 2007 21:01:09 +0200 (CEST) > From: BMW PROMOTION <infobmwpromotoon@aol.com > > To: fbsd-send-pr $MYADDRESS > Subject: CONGRATULATIONS YOU HAVE WON THE BMW CAR PROMOTION > X-MSMail-Priority: Normal > Reply-To: BMW PROMOTION <infobmwpromotoon@aol.com > I'll toss that address and monitor the PR instead. Damn spammers. Anyway... some Linuxen seems to get a little friendlier with the concept of 1024 byte bocks: $ fdisk -b 1024 /dev/discs/disc4/disc You will not be able to write the partition table. Command (m for help): p Disk /dev/discs/disc4/disc: 2057 MB, 2057830400 bytes 53 heads, 52 sectors/track, 729 cylinders Units = cylinders of 2756 * 1024 = 2822144 bytes Device Boot Start End Blocks Id System /dev/discs/disc4/part1 1 1459 4018957 6 FAT16 Partition 1 has different physical/logical beginnings (non-Linux?): phys=(0, 3, 55) logical=(0, 4, 36) Partition 1 has different physical/logical endings: phys=(996, 52, 52) logical=(1458, 18, 16) I haven't managed to mount the card on the router yet, though. Bernard