From patchwork Wed Dec 12 17:47:58 2012 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Paolo Bonzini X-Patchwork-Id: 205606 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from lists.gnu.org (lists.gnu.org [208.118.235.17]) (using TLSv1 with cipher AES256-SHA (256/256 bits)) (Client did not present a certificate) by ozlabs.org (Postfix) with ESMTPS id D38FB2C0091 for ; Thu, 13 Dec 2012 05:35:34 +1100 (EST) Received: from localhost ([::1]:57535 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1TiqQK-0002ZU-J0 for incoming@patchwork.ozlabs.org; Wed, 12 Dec 2012 12:48:48 -0500 Received: from eggs.gnu.org ([208.118.235.92]:47400) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1TiqPo-00029x-GW for qemu-devel@nongnu.org; Wed, 12 Dec 2012 12:48:22 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1TiqPh-0003i2-5i for qemu-devel@nongnu.org; Wed, 12 Dec 2012 12:48:16 -0500 Received: from mail-ia0-f182.google.com ([209.85.210.182]:60457) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1TiqPg-0003hm-Ns for qemu-devel@nongnu.org; Wed, 12 Dec 2012 12:48:09 -0500 Received: by mail-ia0-f182.google.com with SMTP id x2so1235986iad.27 for ; Wed, 12 Dec 2012 09:48:08 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=sender:message-id:date:from:user-agent:mime-version:to:cc:subject :references:in-reply-to:content-type; bh=hx06R/aBTKpyiswREc4QIS9HlxBz/bwSsCijyUpRcJI=; b=N6Xy/PhGK7vqHZwwcrPPNITV8vHzpA0vDLlL/iQmYOe1vfby4u7/fLCMkZxQUiR92g cd0lVd8OApibsgZoJCZPkyuply/gExk9U9pAYJpUiZIhixV2eLx/qILNZzIzvyqNBSn9 oRhJ8QVTmfwhcwDz/ClSvuOU+Adq81ixbVPPTDheQwwFrllQ6vzOj6a+Y6FBSBgxBWeV FkPimnyqiteXU8UzbL5WRIODk7amy81VEsFpZPdQ7XuGx7LMWafxkFy1rNErWO2qLgq/ RdkTEWo8oDLk8COSFlSOMSgcl9tKR17j+ZXrDVPXqEkzQG6sBZS891RYiDQeRXsosXnY xm/w== Received: by 10.50.46.129 with SMTP id v1mr14188107igm.42.1355334487891; Wed, 12 Dec 2012 09:48:07 -0800 (PST) Received: from yakj.usersys.redhat.com (93-34-219-150.ip51.fastwebnet.it. [93.34.219.150]) by mx.google.com with ESMTPS id vq4sm2244634igb.10.2012.12.12.09.48.00 (version=TLSv1/SSLv3 cipher=OTHER); Wed, 12 Dec 2012 09:48:05 -0800 (PST) Message-ID: <50C8C34E.9080409@redhat.com> Date: Wed, 12 Dec 2012 18:47:58 +0100 From: Paolo Bonzini User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:17.0) Gecko/17.0 Thunderbird/17.0 MIME-Version: 1.0 To: Luigi Rizzo References: In-Reply-To: X-detected-operating-system: by eggs.gnu.org: GNU/Linux 3.x [fuzzy] X-Received-From: 209.85.210.182 Cc: qemu-devel@nongnu.org, kraxel@redhat.com Subject: Re: [Qemu-devel] new pc-bios/bios.bin breaks freebsd booting X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+incoming=patchwork.ozlabs.org@nongnu.org Sender: qemu-devel-bounces+incoming=patchwork.ozlabs.org@nongnu.org Il 12/12/2012 17:04, Luigi Rizzo ha scritto: > 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 ? Not reverting the change (which fixes other things), but yes---we should get the fix into SeaBIOS. I don't have a FreeBSD VM handy, can you try the attached BIOS so I can have your Tested-by? The patch I used is after my signature. Paolo Tested-by: Luigi Rizzo diff --git a/src/acpi-dsdt.dsl b/src/acpi-dsdt.dsl index 8019b71..b58ef62 100644 --- a/src/acpi-dsdt.dsl +++ b/src/acpi-dsdt.dsl @@ -187,7 +187,7 @@ DefinitionBlock ( prt_slot0(0x0000), /* Device 1 is power mgmt device, and can only use irq 9 */ - Package() { 0x1ffff, 0, 0, 9 }, + Package() { 0x1ffff, 0, LNKS, 0 }, Package() { 0x1ffff, 1, LNKB, 0 }, Package() { 0x1ffff, 2, LNKC, 0 }, Package() { 0x1ffff, 3, LNKD, 0 }, @@ -278,6 +278,22 @@ DefinitionBlock ( define_link(LNKB, 1, PRQ1) define_link(LNKC, 2, PRQ2) define_link(LNKD, 3, PRQ3) + + Device(LNKS) { + Name(_HID, EISAID("PNP0C0F")) + Name(_UID, 4) + Name(_PRS, ResourceTemplate() { + Interrupt(, Level, ActiveHigh, Shared) { 9 } + }) + + // The SCI cannot be disabled and is always attached to GSI 9, + // so these are no-ops. We only need this link to override the + // polarity to active high and match the content of the MADT. + Method(_STA, 0, NotSerialized) { Return (0x0b) } + Method(_DIS, 0, NotSerialized) { } + Method(_CRS, 0, NotSerialized) { Return (_PRS) } + Method(_SRS, 1, NotSerialized) { } + } } #include "acpi-dsdt-cpu-hotplug.dsl"