Skip site navigation (1)Skip section navigation (2)
Date:      09 Jan 2002 16:12:49 -0500
From:      Randell Jesup <rjesup@wgate.com>
To:        hackers@FreeBSD.ORG
Subject:   Re: FreeBSD Floppy driver needs enhancement...
Message-ID:  <7dcbb25c031dc107d2@[192.168.1.4]>

next in thread | raw e-mail | index | archive | help
Terry Lambert <tlambert2@mindspring.com> writes:
>Julian Stacey wrote:
>> Doubtless some will have bad sectors by now.  Here's a rescue tool:
>>         http://bim.bsn.com/~jhs/src/bsd/jhs/bin/public/valid/valid.c & v=
alid.1
>> 
>> `Valid' runs on FreeBSD, but only rescues when running on MSDOS !
>> (because read() on DOS3.2 returns the intact buffer even if the
>> CRC fails, so I can then average each bit of each byte in each
>> sector for all reads).  `Valid' works at sector level, no knowledge
>> of file systems, so it can rescue/ manipulate BSD FS sectors on
>> floppy, tar images, DOS or Minix file systems etc.
>
>Sounds like the FreeBSD floppy driver needs to be modified to
>return the full buffer, even if there is a CRC error.
>
>This implies a descriptor being passed, so that the CRC and
>the data are seperate.
>
>You could probably just wadd an ioctl that expected the
>descriptor to be at the front of a data buffer, so that
>you passed the address of the descriptor + buffer, after
>the ioctl().
>
>This seems a useful feature...

        Yes (if anyone still cares about floppies).  The old Amiga
trackdisk (floppy driver) could do that, since all the decoding was in
software (and via the graphics bitblitter(!)).  Do the integrated disk
controllers in PC's (still) allow direct raw bit access, or only after MFM
decoding?  Also, I seem to remember PC's can't recover from bad sector ID's=
.

        If I remember correctly, you can read uncorrected sectors off of
ATA (maybe) and SCSI (I think), at least using CAM.

        Quite honestly, I can see some use for this in HD's; I don't see
much use for it in floppies, except maybe for HD-less servers like gnat box=
es.

-- 
Randell Jesup, Worldgate Communications, ex-Scala, ex-Amiga OS team
rjesup@wgate.com
"They that can give up essential liberty to obtain a little temporary safet=
y
 deserve neither liberty nor safety." 
              -Benjamin Franklin, Historical Review of Pennsylvania, 1759.


To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-hackers" in the body of the message




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