From owner-freebsd-current@FreeBSD.ORG Sun Mar 13 01:18:26 2005 Return-Path: Delivered-To: freebsd-current@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 3428516A4CE; Sun, 13 Mar 2005 01:18:26 +0000 (GMT) Received: from cyrus.watson.org (cyrus.watson.org [204.156.12.53]) by mx1.FreeBSD.org (Postfix) with ESMTP id D389743D48; Sun, 13 Mar 2005 01:18:25 +0000 (GMT) (envelope-from robert@fledge.watson.org) Received: from fledge.watson.org (fledge.watson.org [204.156.12.50]) by cyrus.watson.org (Postfix) with SMTP id 0B0EA46B8C; Sat, 12 Mar 2005 20:18:23 -0500 (EST) Date: Sun, 13 Mar 2005 01:15:55 +0000 (GMT) From: Robert Watson X-Sender: robert@fledge.watson.org To: Warner Losh In-Reply-To: <200503101809.j2AI9PaG011517@repoman.freebsd.org> Message-ID: MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII cc: kan@FreeBSD.org cc: current@FreeBSD.org Subject: sio0 probing broken with fdc change? (was: Re: cvs commit: src/sys/dev/fdc fdc_isa.c) X-BeenThere: freebsd-current@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: Discussions about the use of FreeBSD-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 13 Mar 2005 01:18:26 -0000 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: 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: 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