Skip site navigation (1)Skip section navigation (2)
Date:      Sun, 01 Jul 2007 21:00:47 -0700
From:      Nate Lawson <nate@root.org>
To:        "M. Warner Losh" <imp@bsdimp.com>
Cc:        current@FreeBSD.org
Subject:   Re: GEOM weirdness with SD flash reader?
Message-ID:  <4688786F.5080408@root.org>
In-Reply-To: <20070701.215404.1670806422.imp@bsdimp.com>
References:  <46880400.70808@root.org> <20070701.215404.1670806422.imp@bsdimp.com>

next in thread | previous in thread | raw e-mail | index | archive | help
M. Warner Losh wrote:
> In message: <46880400.70808@root.org>
>             Nate Lawson <nate@root.org> writes:
> : Simply trying to mount a FAT filesystem in an external USB SD flash
> : reader.  The reader works fine, no errors in dmesg.
> : 
> : deenlo# fdisk da2
> : ******* Working on device /dev/da2 *******
> : parameters extracted from in-core disklabel are:
> : cylinders=982 heads=64 sectors/track=32 (2048 blks/cyl)
> : 
> : parameters to be used for BIOS calculations are:
> : cylinders=982 heads=64 sectors/track=32 (2048 blks/cyl)
> : 
> : Media sector size is 512
> : Warning: BIOS sector numbering starts with sector 1
> : Information from DOS bootblock is:
> : The data for partition 1 is:
> : sysid 6 (0x06),(Primary 'big' DOS (>= 32MB))
> :     start 243, size 2011917 (982 Meg), flag 0
> :         beg: cyl 0/ head 3/ sector 55;
> :         end: cyl 998/ head 3/ sector 3
> : The data for partition 2 is:
> : <UNUSED>
> : The data for partition 3 is:
> : <UNUSED>
> : The data for partition 4 is:
> : <UNUSED>
> : deenlo# mount -t msdosfs /dev/da2s1 /mnt/dos
> : mount_msdosfs: /dev/da2s1: No such file or directory
> : deenlo# mount -t msdosfs /dev/da2 /mnt/dos
> : mount_msdosfs: /dev/da2: Invalid argument
> : deenlo# mount -t msdosfs /dev/da2s1 /mnt/dos
> : [success]
> : 
> : So I'm guessing GEOM had to decide to create /dev/da2s1 after I tried to
> : mount /dev/da2 directly?  Nothing else would create the da2s1 device.
> : Once the device was created with make_dev(), repeated unmounts/mounts
> : work fine.
> 
> The reading of the device is taking a while, no?  I've seen
> significant lags between when the flash reader is inserted, and the
> device is ready and the tasting process finishes.  Reseating
> everything often fixes the problem.

Nope, dmarck is right.  The reader was inserted "empty", then the media
was added.  It took a write to the device (maybe via the mount attempt
of /dev/da2) to trigger a re-taste.

-- 
Nate



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?4688786F.5080408>