Skip site navigation (1)Skip section navigation (2)
Date:      Sat, 12 Mar 2005 18:34:15 -0700 (MST)
From:      "M. Warner Losh" <imp@bsdimp.com>
To:        rwatson@FreeBSD.org
Cc:        current@FreeBSD.org
Subject:   Re: sio0 probing broken with fdc change?
Message-ID:  <20050312.183415.102615682.imp@bsdimp.com>
In-Reply-To: <Pine.NEB.3.96L.1050313011119.85608B-100000@fledge.watson.org>
References:  <200503101809.j2AI9PaG011517@repoman.freebsd.org> <Pine.NEB.3.96L.1050313011119.85608B-100000@fledge.watson.org>

next in thread | previous in thread | raw e-mail | index | archive | help
In message: <Pine.NEB.3.96L.1050313011119.85608B-100000@fledge.watson.org>
            Robert Watson <rwatson@FreeBSD.org> writes:
: >   Fix a couple of problems with the probe code when used with pnpbios
: >   resources.  When allocating 6 ports for a 4 port range isa code
: This change appears to break the serial port probing on at least one of my
: test boxes.  Before:
: 
: ...
: fdc0: <Enhanced floppy controller> at port 0x3f0-0x3f5 irq 6 drq 2 on isa0
: fdc0: [FAST]
: fd0: <1440-KB 3.5" drive> on fdc0 drive 0
: ...
: sio0 at port 0x3f8-0x3ff irq 4 flags 0x10 on isa0
: sio0: type 16550A, console
: ...
: sio1 at port 0x2f8-0x2ff irq 3 on isa0
: sio1: type 16550A
: ...
: 
: After:
: 
: sio0: configured irq 4 not in bitmap of probed irqs 0
: sio0: port may not be enabled
: sio1 at port 0x2f8-0x2ff irq 3 on isa0
: sio1: type 16550A
: ...
: sio4: configured irq 4 not in bitmap of probed irqs 0
: sio4: port may not be enabled
: ...
: fdc1: Faking up FDCTL

This means you are using hints to get your floppy recognized.  This
likely is an error that we've silently lived with for too long.  I
hadn't anticipated that my change would break anything here.

: fdc1: <Enhanced floppy controller> at port 0x3f7,0x3f0-0x3f5 irq 6 drq 2
: on isa0
: fdc1: Faking up FDCTL
: fdc1: [FAST]
: 
: Serial output works, but needless to say, no input, rendering the serial
: console less useful than desired.  I don't know a lot about ISA hardware
: probing, but I'd say that something here isn't happy.  I chatted with
: Alexander Kabaev earlier this evening, and he indicated he was seeing an
: identical problem also, so the good/bad news is that it's not just me.

I don't see how a change in the floppy driver could break probing
serial ports.  Can you provide at least a theory of the crime for me
to investigate?  Otherwise, it makes absolutely no sense at all.  It
works for me, so you'll need to track down what it is doing
differently.

Also, can you remove all the devices from device.hints except for sio0
if you are using it for a serial console as well as the hints for the
non-isa devices?  If you are using pnpbios, changes are that you'll
want to do this anyway.  I have some stuff out of the tree that will
make pnpbios probe before hints, but need to work out a few kinks yet
(mostly I need to work out integrating the two together, but I
digress).

I'll be out of touch until sometime tomorrow.  I hate to dump this on
you like this, but I really can't believe that a tiny change to the
resource management of one device would impact sio.  The change also
has a couple of different parts, so you might try to back out
individual portions of it to see what might be the culprit.

Warner

P.S.  Here's the device.hints that I usually use:

hint.atkbd.0.at="atkbdc"
hint.atkbd.0.irq="1"
hint.psm.0.at="atkbdc"
hint.psm.0.irq="12"
hint.vga.0.at="isa"
hint.sc.0.at="isa"
hint.sc.0.flags="0x100"
hint.apm.0.disabled="1"
hint.apm.0.flags="0x20"
hint.sio.0.at="isa"
hint.sio.0.port="0x3F8"
hint.sio.0.flags="0x10"
hint.sio.0.irq="4"

since this is about as minimal as we can get for a sio console
machine.

Of course, I use the full one if I have a machine w/o pnpbios devices.
I haven't had one of those, however, since I threw out all my 386 and
486 (classic, not soekris-class) boxes a year ago.

W



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