From: Igor Luri Date: Wed, 12 Nov 2008 11:09:52 +0100 Subject: [U-Boot] [PATCH] FAT on non standard sector size devices Message-ID: <1226484592.6038.29.camel@ilurilinux> List-Id: MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit To: u-boot@lists.denx.de Hi all! There are USB devices with sector size different than 512 bytes. In fact, I have one with 2048 bytes per sector: scsi0 : SCSI emulation for USB Mass Storage devices Vendor: ChipsBnk Model: Flash Disk Rev: 4.00 Type: Direct-Access ANSI SCSI revision: 02 Attached scsi removable disk sda at scsi0, channel 0, id 0, lun 0 SCSI device sda: 129124 2048-byte hdwr sectors (264 MB) sda: Write Protect is off Partition check: sda: sda1 sda2 sda3 sda4 U-boot FAT filesystem code supposes that sector size is always 512 bytes, consecuently fatload and fatls commands ends up with a segmentation fault. Attached patches adds FAT support on devices with sector size up to 8192 bytes. I have only tested on our custom board with u-boot 1.1.6 version. I would aprpeciate if someone could test this patch on latest version. Thanks. Signed-off-by: Igor Luri -- Igor Luri R&D Software Department Fagor Aotek S. Coop. P. O. Box 144 E-20500 Mondrag?n-Arrasate Tel. ++34 943 71 92 00 ++34 943 71 92 01 (Ext. 44268) Fax. ++34 943 79 92 03 www.aotek.es -------------- next part -------------- A non-text attachment was scrubbed... Name: 0001-Add-support-for-non-standard-sector-size-devices.patch Type: application/mbox Size: 6252 bytes Desc: not available Url : http://lists.denx.de/pipermail/u-boot/attachments/20081112/a684ed52/attachment-0002.bin -------------- next part -------------- A non-text attachment was scrubbed... Name: 0002-Add-support-for-non-standard-sector-size-devices.patch Type: application/mbox Size: 2053 bytes Desc: not available Url : http://lists.denx.de/pipermail/u-boot/attachments/20081112/a684ed52/attachment-0003.bin