Bug 59026 - re-add Floppy-Dtectection-Support for FreeBSD/alpha
Summary: re-add Floppy-Dtectection-Support for FreeBSD/alpha
Status: Closed FIXED
Alias: None
Product: Base System
Classification: Unclassified
Component: alpha (show other bugs)
Version: unspecified
Hardware: Any Any
: Normal Affects Only Me
Assignee: freebsd-alpha mailing list
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2003-11-06 23:20 UTC by Oliver Lehmann
Modified: 2003-12-08 02:56 UTC (History)
1 user (show)

See Also:


Attachments
src::sys::isa::fd.c (966 bytes, text/plain)
2003-11-06 23:20 UTC, Oliver Lehmann
no flags Details

Note You need to log in before you can comment on or make changes to this bug.
Description Oliver Lehmann freebsd_committer 2003-11-06 23:20:08 UTC
To get back a working and floppydrive detection on FreeBSD/alpha:

I moved in fd_probe() 
	if (fd->type == FDT_NONE && (fd->fdu == 0 || fd->fdu == 1)) {
out of the
#if defined(__i386__) || defined(__amd64__)
block and created an #else section (like it allready was in RELENG_4!)
where the fd->type is set to 144 by force.

Why not just re-create the #else block? Why moving the if statement out of
the #ifdef block? Doing it that way, it's still possible to set
hint.fd.0.flags for example to 3 (720KB Floppy), and only set the 1.44M
type as a fallback when flags is NULL (FDT_NONE) which means in that case,
hint.fd.0.flags isn't defined. (Because we don't query the "BIOS" as we do
it for x86 to get the info what kind of floppy is attached to fdc.)

	before:

orm0: <Option ROM> at iomem 0xc0000-0xc7fff on isa0
fdc0: <Enhanced floppy controller (i82077, NE72065 or clone)> at port 0x3f7,0x3f0-0x3f5 irq 6 drq 2 on isa0
fdc0: interrupting at ISA irq 6
atkbdc0: <Keyboard controller (i8042)> at port 0x64,0x60 on isa0


	after:

orm0: <Option ROM> at iomem 0xc0000-0xc7fff on isa0
fdc0: <Enhanced floppy controller (i82077, NE72065 or clone)> at port 0x3f7,0x3f0-0x3f5 irq 6 drq 2 on isa0
fdc0: interrupting at ISA irq 6
fdc0: FIFO enabled, 8 bytes threshold
fd0: <1440-KB 3.5" drive> on fdc0 drive 0
atkbdc0: <Keyboard controller (i8042)> at port 0x64,0x60 on isa0

How-To-Repeat: 	make kernel
	<reboot>
	fdc gets detected, but no fd%d
Comment 1 Dag-Erling Smørgrav 2003-12-04 23:42:46 UTC
The preferred solution seems to be to add the following line to
/boot/device.hints:

hint.fd.0.flags=3D"4"

DES
--=20
Dag-Erling Sm=F8rgrav - des@des.no
Comment 2 Dag-Erling Smørgrav freebsd_committer 2003-12-08 02:56:22 UTC
State Changed
From-To: open->closed

See src/sys/alpha/conf/GENERIC.hints rev 1.7