sio0 probing broken with fdc change? (was: Re: cvs commit: src/sys/dev/fdc fdc_isa.c)

From: Robert Watson <rwatson_at_FreeBSD.org>
Date: Sun, 13 Mar 2005 01:15:55 +0000 (GMT)
On Thu, 10 Mar 2005, Warner Losh wrote:

>   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
>   returns an error.  I'm not sure yet why this is the case, but suspect
>   it is just a non-regularity in how the resource allocation code works
>   which should be corrected.  Use 1 as the ports size in this case.
>   However, in the hints case, we have to specify the length, so use 6 in
>   that case.  I believe that this is also acpi friendly.
>   
>   Also, complain when we can't allocate FDOUT register space.  Right now we
>   silently fail when we can't.  This failure is referred to above.
>   
>   When there's no resource for FDCTL, go ahead and allocate one by hand.
>   Many PNPBIOS tables don't list this resource, and our hints mechanism also
>   doesn't cover that range.  If we can't allocate it, whine, but fake up
>   something.  Before, we were always bogusly faking it and no one noticed
>   the sham (save the original author who has now fixed his private shame).

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
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.

Thanks,

Robert N M Watson
Received on Sun Mar 13 2005 - 00:18:26 UTC

This archive was generated by hypermail 2.4.0 : Wed May 19 2021 - 11:38:29 UTC