From owner-freebsd-stable@FreeBSD.ORG Wed Aug 29 16:37: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 D0A58106564A; Wed, 29 Aug 2012 16:37:13 +0000 (UTC) (envelope-from gperez@entel.upc.edu) Received: from violet.upc.es (violet.upc.es [147.83.2.51]) by mx1.freebsd.org (Postfix) with ESMTP id 528EB8FC21; Wed, 29 Aug 2012 16:37:12 +0000 (UTC) Received: from ackerman2.upc.es (ackerman2.upc.es [147.83.2.244]) by violet.upc.es (8.14.1/8.13.1) with ESMTP id q7TGbBhL030278 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=FAIL); Wed, 29 Aug 2012 18:37:11 +0200 Received: from portgus.lan (51.Red-79-159-211.staticIP.rima-tde.net [79.159.211.51]) (authenticated bits=0) by ackerman2.upc.es (8.14.4/8.14.4) with ESMTP id q7TGb9Pd017416 (version=TLSv1/SSLv3 cipher=DHE-RSA-CAMELLIA256-SHA bits=256 verify=NO); Wed, 29 Aug 2012 18:37:10 +0200 Message-ID: <503E4501.6070607@entel.upc.edu> Date: Wed, 29 Aug 2012 18:36:17 +0200 From: =?UTF-8?B?R3VzdGF1IFDDqXJleiBpIFF1ZXJvbA==?= User-Agent: Mozilla/5.0 (X11; FreeBSD amd64; rv:14.0) Gecko/20120806 Thunderbird/14.0 MIME-Version: 1.0 To: Andriy Gapon References: <503C930C.3010405@entel.upc.edu> <503DE1BC.4050907@entel.upc.edu> <20120829101202.GA74970@server.rulingia.com> <201208290813.55855.jhb@freebsd.org> <503E1961.80402@FreeBSD.org> <503E1F02.6050505@entel.upc.edu> <503E2453.9040407@FreeBSD.org> In-Reply-To: <503E2453.9040407@FreeBSD.org> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 8bit X-Scanned-By: MIMEDefang 2.70 on 147.83.2.244 X-Mail-Scanned: Criba 2.0 + Clamd X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-3.0 (violet.upc.es [147.83.2.51]); Wed, 29 Aug 2012 18:37:11 +0200 (CEST) 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 16:37:14 -0000 Al 29/08/2012 16:16, En/na Andriy Gapon ha escrit: > on 29/08/2012 16:54 Gustau Pérez i Querol said the following: >> Al 29/08/2012 15:30, En/na Andriy Gapon ha escrit: >>> 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). >>> >> The output of lspci gives the same info as pciconf. I'm attaching it however. > [snip] >> 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 0 >> Bus: primary=01, secondary=01, subordinate=02, sec-latency=0 >> !!! Unknown I/O range types e0/df >> !!! Unknown memory range types f100/f0ff >> >> 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 0 >> Bus: primary=02, secondary=02, subordinate=03, sec-latency=0 >> !!! Unknown I/O range types e0/df >> !!! Unknown memory range types f100/f0ff > I think that I was wrong with regard to Linux. I see that it does extensive > bridge reconfiguring if it notices any insanity. And I'd say that VirtualBix does > create an insane config here. > I believe that primary should be 0, secondary should be 1 and 2 respectively (as > they are) and subordinate should be equal to secondary. So primary bus numbers > and subordinate bus numbers are insane here. > I am not sure how much the incorrect bus numbers actually affect FreeBSD PCI-PCI > driver as it does not seem to use primary and subordinate numbers for anything > important. > > Memory and I/O misconfiguration are most likely much more important here. > > In any case, here is a link to the broken VirtualBox code: > http://www.virtualbox.org/svn/vbox/trunk/src/VBox/Devices/Bus/DevPciIch9.cpp > See function ich9pciInitBridgeTopology, which sets primary bus and secondary bus > to X and subordinate bus to X+1. > > And here a link to Linux code that re-configures those bus numbers: > http://lxr.linux.no/#linux+v3.5.3/drivers/pci/probe.c#L663 > > I bet that was "bus configuration invalid, reconfiguring" message during Linux boot. I did not see that message. Anyhow I found how to fix VBox to work as it should. I think I'm closing this thread and move it to @emulation. Gustau -- --------------------------------------------------------------------------- Prou top-posting : http://ca.wikipedia.org/wiki/Top-posting Stop top-posting : http://en.wikipedia.org/wiki/Posting_style O O O Gustau Pérez i Querol O O O Departament d'Enginyeria Telemàtica O O O Universitat Politècnica de Catalunya Edifici C3 - Despatx S101-B UPC Campus Nord UPC C/ Jordi Girona, 1-3 08034 - Barcelona