From owner-freebsd-stable@FreeBSD.ORG Wed Aug 29 13:30:13 2012 Return-Path: Delivered-To: freebsd-stable@FreeBSD.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 58E1E106564A; Wed, 29 Aug 2012 13:30:13 +0000 (UTC) (envelope-from avg@FreeBSD.org) Received: from citadel.icyb.net.ua (citadel.icyb.net.ua [212.40.38.140]) by mx1.freebsd.org (Postfix) with ESMTP id 78F328FC12; Wed, 29 Aug 2012 13:30:12 +0000 (UTC) Received: from odyssey.starpoint.kiev.ua (alpha-e.starpoint.kiev.ua [212.40.38.101]) by citadel.icyb.net.ua (8.8.8p3/ICyb-2.3exp) with ESMTP id QAA07191; Wed, 29 Aug 2012 16:30:10 +0300 (EEST) (envelope-from avg@FreeBSD.org) Message-ID: <503E1961.80402@FreeBSD.org> Date: Wed, 29 Aug 2012 16:30:09 +0300 From: Andriy Gapon User-Agent: Mozilla/5.0 (X11; FreeBSD amd64; rv:14.0) Gecko/20120730 Thunderbird/14.0 MIME-Version: 1.0 To: John Baldwin , gperez@entel.upc.edu References: <503C930C.3010405@entel.upc.edu> <503DE1BC.4050907@entel.upc.edu> <20120829101202.GA74970@server.rulingia.com> <201208290813.55855.jhb@freebsd.org> In-Reply-To: <201208290813.55855.jhb@freebsd.org> X-Enigmail-Version: 1.4.3 Content-Type: text/plain; charset=ISO-8859-15 Content-Transfer-Encoding: 8bit Cc: freebsd-stable@FreeBSD.org Subject: Re: Problem adding more than 8 network adapters X-BeenThere: freebsd-stable@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Production branch of FreeBSD source code List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 29 Aug 2012 13:30:13 -0000 on 29/08/2012 15:13 John Baldwin said the following: > On Wednesday, August 29, 2012 6:12:02 am Peter Jeremy wrote: >> [Moving to -stable and adding jhb@ for his input] >> >> On 2012-Aug-29 11:32:44 +0200, Gustau Pérez i Querol wrote: [snip] >> Ah.. lspci shows the 9th LANCE at 02:00.0. The verbose boot shows >> FreeBSD finds pcib2 (at pci0 device 25.0) but doesn't see anything >> on that bus. ISTR jhb@ will recognize that problem. > > Silly firmware, VM, whatever it is. :) It's buggy. > >>> pcib1: at device 24.0 on pci0 >>> pcib1: domain 0 >>> pcib1: secondary bus 1 >>> pcib1: subordinate bus 2 >>> pcib1: no prefetched decode >>> pcib1: Subtractively decoded bridge. >>> pci1: on pcib1 >>> pci1: domain=0, physical bus=1 >>> pcib2: at device 25.0 on pci0 >>> pcib2: domain 0 >>> pcib2: secondary bus 2 >>> pcib2: subordinate bus 3 >>> pcib2: no prefetched decode >>> pcib2: Subtractively decoded bridge. >>> pci2: on pcib2 >>> pci2: domain=0, physical bus=2 > > This is indeed the problem. PCI bus 2 is "claimed" by both pcib1 and pcib2 > since the VM author programmed the bridges incorrectly. In this case, the > subordinate bus should be "1" and "2", not "2" and "3". You could add a hack > to pci_pci.c to fix the subordinate bus on these bridges which should probably > fix this. > >>> 00:18.0 PCI bridge: Intel Corporation 82801 Mobile PCI Bridge (rev f2) (prog-if 01 [Subtractive decode]) >>> Flags: bus master, 66MHz, fast devsel, latency 64 >>> Bus: primary=00, secondary=01, subordinate=01, sec-latency=0 >>> >>> 00:19.0 PCI bridge: Intel Corporation 82801 Mobile PCI Bridge (rev f2) (prog-if 01 [Subtractive decode]) >>> Flags: bus master, 66MHz, fast devsel, latency 64 >>> Bus: primary=00, secondary=02, subordinate=02, sec-latency=0 >>> I/O behind bridge: 00001000-00001fff >>> Memory behind bridge: 40000000-400fffff > > Note here in this output (presumably from lspci under Linux?), the > subordinate bus register == secondary bus register for each bridge. > I wonder where the discrepancy could come from. Why would VirtualBox emulate the bridge differently for different OSes? And I do not see any quirks related to bus numbers for this PCI ID in either Linux, FreeBSD or lspci code... I think that output of lspci on FreeBSD could be interesting too (it's available via sysutils/pciutils port). -- Andriy Gapon