From owner-freebsd-current@FreeBSD.ORG Wed Jul 20 14:33:55 2011 Return-Path: Delivered-To: freebsd-current@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id C229F106566B; Wed, 20 Jul 2011 14:33:55 +0000 (UTC) (envelope-from niclas.zeising@gmail.com) Received: from mail.lysator.liu.se (mail.lysator.liu.se [IPv6:2001:6b0:17:f0a0::3]) by mx1.freebsd.org (Postfix) with ESMTP id 22B648FC14; Wed, 20 Jul 2011 14:33:55 +0000 (UTC) Received: from mail.lysator.liu.se (localhost [127.0.0.1]) by mail.lysator.liu.se (Postfix) with ESMTP id 4EE8040005; Wed, 20 Jul 2011 16:33:53 +0200 (CEST) Received: by mail.lysator.liu.se (Postfix, from userid 1004) id 43E6F40014; Wed, 20 Jul 2011 16:33:53 +0200 (CEST) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on bernadotte.lysator.liu.se X-Spam-Level: X-Spam-Status: No, score=0.0 required=5.0 tests=AWL,FREEMAIL_FROM autolearn=disabled version=3.3.1 X-Spam-Score: 0.0 Received: from mx.daemonic.se (h-90-99.a163.priv.bahnhof.se [79.136.90.99]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (No client certificate requested) by mail.lysator.liu.se (Postfix) with ESMTPSA id DAA7540005; Wed, 20 Jul 2011 16:33:52 +0200 (CEST) Received: from mail.daemonic.se (mail.daemonic.se [IPv6:2001:470:dca9:0:1::4]) by mx.daemonic.se (Postfix) with ESMTPS id 71F89119C08; Wed, 20 Jul 2011 16:33:22 +0200 (CEST) Received: from [IPv6:2001:470:dca9:1::4] (vivi.daemonic.se [IPv6:2001:470:dca9:1::4]) by mail.daemonic.se (Postfix) with ESMTPSA id 2C57312B1E5; Wed, 20 Jul 2011 16:33:22 +0200 (CEST) Message-ID: <4E26E72F.9060703@gmail.com> Date: Wed, 20 Jul 2011 16:33:19 +0200 From: Niclas Zeising User-Agent: Mutt/1.5.21 MIME-Version: 1.0 To: Bernhard Froehlich References: <4E263EFE.3040200@FreeBSD.org> <201107200741.26362.jhb@freebsd.org> <565082b8e8b3e358266054e58e591e12@bluelife.at> In-Reply-To: <565082b8e8b3e358266054e58e591e12@bluelife.at> Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit X-Virus-Scanned: ClamAV using ClamSMTP Cc: Steve Wills , freebsd-current@freebsd.org Subject: Re: em problem in virtualbox since the weekend X-BeenThere: freebsd-current@freebsd.org X-Mailman-Version: 2.1.5 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: Wed, 20 Jul 2011 14:33:55 -0000 On 2011-07-20 14:33, Bernhard Froehlich wrote: > On Wed, 20 Jul 2011 07:41:26 -0400, John Baldwin wrote: >> On Tuesday, July 19, 2011 10:35:42 pm Steve Wills wrote: >>> Hi, >>> >>> While testing some other things, I found -CURRENT from yesterday doesn't >>> work with the em0 in my VirtualBox 4.0.8 (a little out of date >>> admittedly). It worked Friday or Saturday I think. Anyone else seen this >>> or should I open a PR? Has the code changed or am I perhaps >>> misremembering dates? The error reported is: >>> >>> em0: Unable to allocate bus resource: memory >>> em0: Allocation of PCI resources failed >> >> This is due to a bug in VirtualBox's BIOS implementation. Someone >> should file >> a bug report with VirtualBox to ask them to fix their BIOS. The problem is >> that they claim that the Host-PCI bridge in their system only decodes >> addresses 0xa0000-0xbffff (i.e. the VGA window) via the "Producer" resources >> in the _CRS method of the Host-PCI bridge device. This tells the OS >> that all >> the existing PCI devices are using invalid memory address ranges but that >> there is also no available address space to allocate for PCI devices such as >> em0. >> >> You can workaround this by setting "debug.acpi.disabled=hostres" until >> VirtualBox fixes their code. I'm happy to provide further >> clarification to an >> existing VirtaulBox bug report if needed. > > Thanks a lot for the analysis! I've talked to one of the virtualbox > developers about that but they are not aware of such problems with Linux > or Windows guests yet. So they are currently unsure if it's a VirtualBox > or FreeBSD fault and if it's their fault why it works fine with other > guests. I'm also unsure because I haven't heard of that problem before > and now multiple people complain. That looks more like a FreeBSD related > problem on current or stable. > > I think it would be good if someone could try to reproduce that with > emulators/virtualbox-ose-legacy which is 3.2.12 to get some vbox dev > look into the problem again. > This may or may not be related, apologies if it is not. My FreeBSD VirtualBox guest, running inside vbox under Windows, is having trouble mounting it's root partition, mountroot dies with error 19 (which is ENODEV, I've come to understand). I can also see in the dmesg prior to this ahci, ehci and ohci not being able to allocate resources properly, or something similar. Rebuilding the kernel with nooptions NEW_PCIB solves the immediate issue (i.e. the machine boots and can find filesystems, etc.). It is probably so, that if there is a bug in vbox bios, the old pci code masks that bug, but the new version is more stringent and therefore dies on it. This can be the reason no one has seen this issue up until now. Why it works for Linux and Windows guests, I have no idea. I hope this helps someone, or at least can shed some light on the issue at hand. Regards! -- Niclas Zeising