From owner-freebsd-current@FreeBSD.ORG Thu Dec 13 17:46:30 2012 Return-Path: Delivered-To: current@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id DF113F18; Thu, 13 Dec 2012 17:46:30 +0000 (UTC) (envelope-from adrian.chadd@gmail.com) Received: from mail-wg0-f52.google.com (mail-wg0-f52.google.com [74.125.82.52]) by mx1.freebsd.org (Postfix) with ESMTP id 105918FC14; Thu, 13 Dec 2012 17:46:29 +0000 (UTC) Received: by mail-wg0-f52.google.com with SMTP id 12so929514wgh.31 for ; Thu, 13 Dec 2012 09:46:23 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:sender:in-reply-to:references:date :x-google-sender-auth:message-id:subject:from:to:cc:content-type; bh=IUXFrUJOwQfoURlqb2RtVB/1gZJhbLwHUV5DQenv++w=; b=Y2Z+csbEudwCZ83iuVSG4a913MR9BvMlRb68+ck0TqZ/yDcZOiy9RvobvchK85lP+4 cjULiE0kZYerQak39xjmB5HZk/uhXRDqBK9THqZSztgMDiG3PNdCf7s6k8DPMjpp+QfD 3RXTp8RUjRWZGDOqoYRXvO3+8rdsgAjaVL1cNvyNqDnuSaKTRLWCcS5U/r5MBRGAAlZA he2Rp3pu1px9blOEOy5SaqujubBo8jio26Utn7lE184DQ//H/Is1p4pvz0qcE1ggQi08 kFdpqlC5v/X84WecuFVlKox7gkEJ/bAl8U0Yqaa7KO2zE7PVdRfHg6ARNpuBwaIdqdVa V9lw== MIME-Version: 1.0 Received: by 10.194.93.40 with SMTP id cr8mr9930777wjb.16.1355420783089; Thu, 13 Dec 2012 09:46:23 -0800 (PST) Sender: adrian.chadd@gmail.com Received: by 10.217.57.9 with HTTP; Thu, 13 Dec 2012 09:46:23 -0800 (PST) In-Reply-To: <20121213162949.GA23250@onelab2.iet.unipi.it> References: <20121213162949.GA23250@onelab2.iet.unipi.it> Date: Thu, 13 Dec 2012 09:46:23 -0800 X-Google-Sender-Auth: wiFE1CjglvD1DhJioWcEbfSLs8Y Message-ID: Subject: Re: new pc-bios/bios.bin breaks freebsd booting From: Adrian Chadd To: Luigi Rizzo Content-Type: text/plain; charset=ISO-8859-1 Cc: emulation@freebsd.org, nox@freebsd.org, current@freebsd.org X-BeenThere: freebsd-current@freebsd.org X-Mailman-Version: 2.1.14 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: Thu, 13 Dec 2012 17:46:31 -0000 Oh, phew. :) adrian On 13 December 2012 08:29, Luigi Rizzo wrote: > On Wed, Dec 12, 2012 at 09:01:01AM -0800, Adrian Chadd wrote: >> Yes, the qemu bios people decided that they could change the ACPI >> setup, in order to make Linux boot slightly (1 line) quieter. >> >> http://git.qemu.org/?p=seabios.git;a=commit;h=4540409d19a4baeec5006d925cfca19f8038a96e > > the qemu folks are actually being very responsive in trying to fix > this for FreeBSD. See > > http://lists.nongnu.org/archive/html/qemu-devel/2012-12/msg01703.html > > and also the message below > > cheers > luigi > > ----- Forwarded message from Paolo Bonzini ----- > > Date: Thu, 13 Dec 2012 14:38:45 +0100 > From: Paolo Bonzini > Subject: Re: [SeaBIOS] [PATCH] acpi: reintroduce LNKS > To: Laszlo Ersek > CC: seabios@seabios.org, rizzo@iet.unipi.it, > Marcelo Tosatti > > Il 13/12/2012 14:33, Laszlo Ersek ha scritto: >>> > Unfortunately, the code after the patch is also against the spec, and it >>> > breaks FreeBSD because it treats IRQ 9 polarity as active low without >>> > the Interrupt() entry. Actually, numeric _PRT entries are handled the >>> > same in Linux and FreeBSD (as active-low). However, under Linux it just >>> > happens to trigger another special casing of SCI which sets SCI up from >>> > its override entry in the MADT, ignoring the DSDT completely. >> I won't pretend I understand what I'm talking about, but the ACPI spec >> 5.0 says in "5.2.12.5 Interrupt Source Override Structure", >> >> Interrupt Source Overrides are also necessary when an identity >> mapped interrupt input has a non-standard polarity. >> >> Hence "necessary but not sufficient", is that it? > > The MADT is about 8259 pins, while the _PRT entry identifies a GSI. So > we have the same GSI (9) specified twice. Linux ignores the settings of > the second entry and reuses those that came from the GSI. The important > bit here is this: > > /* Don't set up the ACPI SCI because it's already set up */ > if (acpi_gbl_FADT.sci_interrupt == gsi) > return gsi; > > (And as you can see it's wrong, sci_interrupt is an 8259 interrupt not a > GSI). > >> SCI_INT in the FADT is explained as >> >> [...] OSPM is required to treat the ACPI SCI interrupt as a >> sharable, level, active low interrupt. >> >> which is then overridden in the MADT, stating active-high polarity. > > Yes, but this doesn't affect the definition of this GSI in the _PRT. It > is always level/active-low for a numeric entry. Among the two > conflicting choices, Linux happens to favor the MADT. FreeBSD doesn't. > > Paolo > > ----- End forwarded message ----- > >> >> >> >> Adrian >> >> On 12 December 2012 08:07, Luigi Rizzo wrote: >> > it seems that qemu-1.3.0 is broken for freebsd... >> > >> > cheers >> > luigi >> > >> > ---------- Forwarded message ---------- >> > From: Luigi Rizzo >> > Date: Wed, Dec 12, 2012 at 8:04 AM >> > Subject: new pc-bios/bios.bin breaks freebsd booting >> > To: qemu-devel@nongnu.org, kraxel@redhat.com >> > >> > >> > I am not sure if it has been reported already but this commit >> > >> > http://git.qemu.org/?p=qemu.git;a=commitdiff;h=d7a51dbbaa70677846453f8c961590913052dd86 >> > >> > (replacing pc-bios/bios.bin with a newer version) >> > breaks booting of FreeBSD on recent qemu (starting roughly with qemu- >> > 1.3.0-rc2). >> > >> > Using a FreeBSD host, and a FreeBSD guest, >> > the qemu thread runs at 100% and the console is stuck >> > after the 'pci0' probe: >> > >> > >> > ... >> > hpet0: iomem 0xfed00000-0xfed003ff on acpi0 >> > >> > Timecounter "HPET" frequency 100000000 Hz quality 950 >> > >> > Timecounter "ACPI-fast" frequency 3579545 Hz quality 900 >> > >> > acpi_timer0: <24-bit timer at 3.579545MHz> port 0xb008-0xb00b on acpi0 >> > >> > pcib0: port 0xcf8-0xcff on acpi0 >> > >> > pci0: on pcib0 >> > >> > Reverting the bios fixes things. >> > I wonder if it isn't the case of reverting this change ? >> > >> > cheers >> > luigi >> > >> > >> > >> > -- >> > -----------------------------------------+------------------------------- >> > Prof. Luigi RIZZO, rizzo@iet.unipi.it . Dip. di Ing. dell'Informazione >> > http://www.iet.unipi.it/~luigi/ . Universita` di Pisa >> > TEL +39-050-2211611 . via Diotisalvi 2 >> > Mobile +39-338-6809875 . 56122 PISA (Italy) >> > -----------------------------------------+------------------------------- >> > >> > >> > >> > >> > -- >> > -----------------------------------------+------------------------------- >> > Prof. Luigi RIZZO, rizzo@iet.unipi.it . Dip. di Ing. dell'Informazione >> > http://www.iet.unipi.it/~luigi/ . Universita` di Pisa >> > TEL +39-050-2211611 . via Diotisalvi 2 >> > Mobile +39-338-6809875 . 56122 PISA (Italy) >> > -----------------------------------------+------------------------------- >> > _______________________________________________ >> > freebsd-current@freebsd.org mailing list >> > http://lists.freebsd.org/mailman/listinfo/freebsd-current >> > To unsubscribe, send any mail to "freebsd-current-unsubscribe@freebsd.org"