From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:43289) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1WPMzs-00006z-Ju for qemu-devel@nongnu.org; Sun, 16 Mar 2014 22:09:53 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1WPMzm-0005eB-El for qemu-devel@nongnu.org; Sun, 16 Mar 2014 22:09:48 -0400 Received: from mail-pa0-f45.google.com ([209.85.220.45]:46158) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1WPMzm-0005dz-9E for qemu-devel@nongnu.org; Sun, 16 Mar 2014 22:09:42 -0400 Received: by mail-pa0-f45.google.com with SMTP id kl14so5069191pab.18 for ; Sun, 16 Mar 2014 19:09:39 -0700 (PDT) Message-ID: <53265956.8010603@ozlabs.ru> Date: Mon, 17 Mar 2014 13:09:26 +1100 From: Alexey Kardashevskiy MIME-Version: 1.0 References: In-Reply-To: Content-Type: text/plain; charset=KOI8-R Content-Transfer-Encoding: 7bit Subject: Re: [Qemu-devel] Multiple pci buses List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: BALATON Zoltan , qemu-devel@nongnu.org, "qemu-ppc@nongnu.org" On 03/16/2014 08:21 AM, BALATON Zoltan wrote: > Hello, > > I'm trying to change hw/ppc/mac_newworld.c and hw/pci-host/uninorth.c to > bring the mac99 machine type closer to what's seen in these dumps: > > https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=604134 > http://nandra.segv.jp/NetBSD/G4.dump-device-tree.txt > http://raveland.org/ports/eeprom.txt > http://mail-index.netbsd.org/port-macppc/2007/10/24/0000.html > > This machine seems to have 3 pci busses but the third is not important just > the other two: > > ff8721c0: /pci@f0000000 > ff898cd0: /uni-north-agp@b > ff898f40: /ATY,Rage128Ps@10 > ff873268: /pci@f2000000 > ff8742d8: /pci-bridge@d > ff876368: /mac-io@7 > > The first is actually an AGP bus with the onboard graphics card and the > second is where other devices are. It would be enough to create an empty > bus without the AGP graphics card for now and have the devices on the > second bus. The pci_pmac_init function in uninorth.c seems to have some > commented out code to try to model this but that does not work. Can someone > who understands this better please explain what should be done to model the > above? How to create two pci buses and connect them to separate memory > regions? [adding qemu-devel@nongnu.org to cc] I have no idea how that "pmac" works... On pseries you can add multiple PHBs via "-device spapr-pci-host-bridge,id=lalala" and then put devices onto it by "-device e1000,bus=lalala.0" so this should be good reference to start with. -- Alexey