From owner-freebsd-i386@FreeBSD.ORG Tue Aug 1 21:00:28 2006 Return-Path: X-Original-To: freebsd-i386@FreeBSD.org Delivered-To: freebsd-i386@FreeBSD.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id CCF4316A4EC; Tue, 1 Aug 2006 21:00:28 +0000 (UTC) (envelope-from jrhett@svcolo.com) Received: from outbound0.sv.meer.net (outbound0.mx.meer.net [209.157.153.23]) by mx1.FreeBSD.org (Postfix) with ESMTP id 5871043D66; Tue, 1 Aug 2006 21:00:25 +0000 (GMT) (envelope-from jrhett@svcolo.com) Received: from mail.meer.net (mail.meer.net [209.157.152.14]) by outbound0.sv.meer.net (8.12.10/8.12.6) with ESMTP id k71L0HjN078444; Tue, 1 Aug 2006 14:00:24 -0700 (PDT) (envelope-from jrhett@svcolo.com) Received: from [10.66.240.106] (public-wireless.sv.svcolo.com [64.13.135.30]) by mail.meer.net (8.13.3/8.13.3/meer) with ESMTP id k71Kxj11077410; Tue, 1 Aug 2006 13:59:45 -0700 (PDT) (envelope-from jrhett@svcolo.com) In-Reply-To: <20060731191302.S1172@epsplex.bde.org> References: <200607252036.k6PKanFd072593@www.freebsd.org> <20060731191302.S1172@epsplex.bde.org> Mime-Version: 1.0 (Apple Message framework v752.2) Content-Type: text/plain; charset=US-ASCII; delsp=yes; format=flowed Message-Id: <6EFF87DF-280C-402C-8C2A-10F3144CF41F@svcolo.com> Content-Transfer-Encoding: 7bit From: Jo Rhett Date: Tue, 1 Aug 2006 13:59:44 -0700 To: Bruce Evans X-Mailer: Apple Mail (2.752.2) Cc: freebsd-gnats-submit@FreeBSD.org, freebsd-i386@FreeBSD.org Subject: Re: i386/100831: sio ignores BIOS information about serial ports - bounty offered X-BeenThere: freebsd-i386@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: I386-specific issues for FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 01 Aug 2006 21:00:28 -0000 > On Tue, 25 Jul 2006, Jo Rhett wrote: >> In the middle of the boot process, right after saying "Mounting >> ", com1 becomes com2 and vice versa. The console >> output suddenly starts going to Serial A -- which is connected to >> a modem. Not useful. On Jul 31, 2006, at 2:55 AM, Bruce Evans wrote: > I think you just need to swap the ports in /boot/device.hints? > Consoles > are mostly low-level, and console initialization is very low level. > The initialization is supposed to run before ACPI, etc. have had a > chance to change the resource values dynamically (so that ACPI, etc. > can print messages and otherwise be debugged), so when sio console > initialization uses the apparently-higher-level resource access > functions > it is actually just using the hints, so the hints had better be > correct > -- they are more than hints. The hints are normal/standard but not working. Here's proof: root@arran 23# grep sio device.hints hint.sio.0.at="isa" hint.sio.0.port="0x3F8" hint.sio.0.flags="0x10" hint.sio.0.irq="4" hint.sio.1.at="isa" hint.sio.1.port="0x2F8" hint.sio.1.irq="3" root@arran 24# dmesg |grep sio sio0: <16550A-compatible COM port> port 0x2f8-0x2ff irq 3 flags 0x10 on acpi0 sio0: type 16550A, console sio1: <16550A-compatible COM port> port 0x3f8-0x3ff irq 4 on acpi0 sio1: type 16550A Heh? Hints says 0x3f8 should be sio0 and console... > I don't know exactly what happens with ACPI. Ideally, ACPI should set > the resource values to match the BIOS, and this might involve ignoring > most hints and this changing the values from their defaults, but for > consoles any changes in the values would be wrong and might result in > the high-level console (/dev/console) being attached to a different > device than the low-level console (the one used for kernel printfs). It appears that ACPI is setting the sio order to match the order that the BIOS lists them, which is completely arbitrary and downright wrong. -- Jo Rhett senior geek Silicon Valley Colocation