tech-kern archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

Re: Scanning floppy devices with assumed density



john%ziaspace.com@localhost (John Klos) writes:

>boot device: fd0 [ 5.121888] fd0d: hard error reading fsbn 0 of 0-2 (st0 
>0x40<abnrml> st1 0x1<no_am> st2 0x0 cyl 0 head 0 sec 1)

>She wondered why fd0d is being used here. I can't imagine this is due to 
>scanning for a disklabel, since they've been around forever, so is this 
>perhaps due to dkwedge_discover?

fd doesn't try to discover wedges, but for identifying a possible wedge
rootconf() calls opendisk() and VOP_IOCTL(, DIOCGDINFO, ) to check the
disklabel. And opendisk() only opens the RAW_PART.

It's difficult to skip floppy devices, these are disks with a disklabel
like anything else. But the MD autoconf code could do that and
provide partition data (offset, length) instead of a partition number,
then the MI code doesn't have to find this.

An alternative would be to change opendisk() to accept a partition number.
But that's way more intrusive.

Another question of course is why the isa fd driver reads a disklabel at all
when it (ab-)uses the partition number to select densities.

The amiga fd driver also handles disk formats that way, but it also just
fakes a disklabel, the isa fd driver should do the same.



Home | Main Index | Thread Index | Old Index