Date: Mon, 10 Nov 2003 16:07:55 +1030 (CST) From: "Greg 'groggy' Lehey" <grog@blackwater.lemis.com> To: FreeBSD-gnats-submit@FreeBSD.org Subject: kern/59103: Serious data corruiption reading compact flash IDE drives Message-ID: <200311100537.hAA5btWH009502@blackwater.lemis.com> Resent-Message-ID: <200311100540.hAA5e7ZA091393@freefall.freebsd.org>
index | next in thread | raw e-mail
>Number: 59103
>Category: kern
>Synopsis: Serious data corruiption reading compact flash IDE drives
>Confidential: no
>Severity: critical
>Priority: high
>Responsible: freebsd-bugs
>State: open
>Quarter:
>Keywords:
>Date-Required:
>Class: sw-bug
>Submitter-Id: current-users
>Arrival-Date: Sun Nov 09 21:40:06 PST 2003
>Closed-Date:
>Last-Modified:
>Originator: Greg 'groggy' Lehey
>Release: FreeBSD 5.1-CURRENT i386
>Organization:
LEMIS (SA) Pty Ltd
>Environment:
System: FreeBSD wantadilla.lemis.com 5.0-CURRENT FreeBSD 5.0-CURRENT #1: Sat Oct 26 11:16:38 CST 2002 grog@current.lemis.com:/usr/obj/src/FreeBSD/5-CURRENT-WANTADILLA/src/sys/WANTADILLA i386
FreeBSD sydney.worldwide.lemis.com 5.1-CURRENT FreeBSD 5.1-CURRENT #2: Thu Oct 9 18:20:30 CST 2003 grog@sydney.worldwide.lemis.com:/home/obj/src/FreeBSD/5-CURRENT-KONDOPARINGA/src/sys/KONDOPARINGA i386
>Description:
It is no longer possible to read CF cards with FAT file
systems (digital camera data) with -CURRENT. This situation
has persisted for well over a month.
I have given this PR the category critical/high because of the
data corruption and the fact that it occurs in what is to
become a part of the base kernel. Ideally, the change to this
implementatino should not have occurred until such bugs were
ironed out.
>How-To-Repeat:
Mount a compact flash card on a -CURRENT machine:
ad4: FAILURE - SETFEATURES status=51<READY,DSC,ERROR> error=4<ABORTED>
ad4: FAILURE - SETFEATURES status=51<READY,DSC,ERROR> error=4<ABORTED>
GEOM: create disk ad4 dp=0xc217d070
ad4: 46MB <> [185/16/32] at ata2-master PIO2
# mount -t msdos /dev/ad4s1 /camera
Mounting root from ufs:/dev/ad0s3a
# xv <any image file>
The file will be corrupt.
The same hardware, running under 4.6-RELEASE, does not report the
failures above:
ata4 at port 0x240-0x247,0x24e irq 11 slot 0 on pccard0
ad8: 46MB <> [185/16/32] at ata4-master BIOSPIO
After copying the file to disk, the EOF is the same, but the
contents are different (and correct in this case):
$ cmp dscn2621.jpg dscn2621-corrupt.jpg
dscn2621.jpg dscn2621-corrupt.jpg differ: char 7681, line 30
The data comes back in sync at offset 8192, suggesting that
the data is not being transferred for the full length.
>Fix:
>Release-Note:
>Audit-Trail:
>Unformatted:
help
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200311100537.hAA5btWH009502>
