From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from [140.186.70.92] (port=44355 helo=eggs.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1PRUB8-0008RU-Mi for qemu-devel@nongnu.org; Sat, 11 Dec 2010 13:28:35 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1PRUAq-0004na-4o for qemu-devel@nongnu.org; Sat, 11 Dec 2010 13:28:18 -0500 Received: from mx1.redhat.com ([209.132.183.28]:14546) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1PRUAp-0004n3-Tk for qemu-devel@nongnu.org; Sat, 11 Dec 2010 13:28:00 -0500 Date: Sat, 11 Dec 2010 20:27:52 +0200 From: Gleb Natapov Subject: Re: [Qemu-devel] Re: [PATCHv8 00/16] boot order specification Message-ID: <20101211182752.GA11388@redhat.com> References: <1291808109-22563-1-git-send-email-gleb@redhat.com> <20101211160617.GA9026@redhat.com> <20101211180223.GA7994@redhat.com> MIME-Version: 1.0 Content-Type: text/plain; charset=koi8-r Content-Disposition: inline Content-Transfer-Encoding: quoted-printable In-Reply-To: <20101211180223.GA7994@redhat.com> List-Id: qemu-devel.nongnu.org List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Blue Swirl Cc: The OpenBIOS Mailinglist , kevin@koconnor.net, qemu-devel@nongnu.org, kvm@vger.kernel.org On Sat, Dec 11, 2010 at 08:02:23PM +0200, Gleb Natapov wrote: > On Sat, Dec 11, 2010 at 05:19:01PM +0000, Blue Swirl wrote: > > >> =9A =9A =9A =9A =9A =9A =9A =9A =9A =9A =9A =9A =9A =9A =9A =9A =9A = =9A =9A =9A =9A =9A =9A =9A What should we do with > > >> ata-2@600 vs drive@1? > > > There is no available IDE OF binding spec, so I when with the way > > > OpenBIOS reports ata on qemu-x86. I have no idea what 600 in ata-2@600 > > > may mean, but looking at g3_beige_300.html there is no such node there > > > and looking at any other device tree in http://penguinppc.org/histori= cal/dev-trees-html/ > > > I haven't found one that use this kind of addressing for pci-ata. > > > http://penguinppc.org/historical/dev-trees-html/g3bw_400.html for > > > instance has pci@80000000/pci-bridge@d/pci-ata@1/ata-4. ata-2@600 kin= d of > > > addressing is used by devices on mac-io bus which I do not think we > > > emulate in qemu. So it looks like OpneBIOS is wrong here. > >=20 > > We have PMAC IDE, but this device is CMD646, so mac-io bus addressing > > rules should not be used. > >=20 > So you agree that OpenBIOS is wrong here? >=20 > > In this tree there are two disks connected to CMD646, named > > /pci@80000000/pci-bridge@d/pci-ata@1/ata-4/disk and > > /pci@80000000/pci-bridge@d/pci-ata@1/ata-4/disk@1: > > http://penguinppc.org/historical/dev-trees-html/g4_pci_350.html > You are saying that qemu creates paths like: > /grackle@fec00000/ide@3/drive@1/disk@0 > /grackle@fec00000/ide@3/drive@1/disk@1 >=20 > I do not understand why qemu creates node drive@1. It should be drive@0 > according to the code. I'll look at why unit-address is incorrect for > the node. But assuming that this problem is fixed then paths created by > qemu is very similar to the paths in g4_pci_350.html. It looks like in=20 > g4_pci_350.html they omit unit address if it is zero. >=20 Ah the problem is that we have not qdevified mac io bus. Since first to ide disks are automatically attached to mac-io bus device paths for them are incorrect. Next two ide devices will be attached to CMD646 and qemu will generate correct device paths for them: qemu-system-ppc -drive if=3Dnone,id=3Dhda,file=3D/dev/null -device ide-driv= e,drive=3Dhda,bootindex=3D1 -drive if=3Dnone,id=3Dcd,file=3D/dev/null -device ide-drive,drive=3Dcd,boot= index=3D0 -nographic -drive if=3Dnone,id=3Dhdb,file=3D/dev/null -device ide-drive,drive=3Dhdb,bus=3Dide= =2E0,bootindex=3D2 -drive if=3Dnone,id=3Dhdc,file=3D/dev/null -device ide-drive,drive=3Dhdc,bus=3Dide= =2E0,bootindex=3D3 adding '/grackle@fec00000/ide@3/drive@1/disk@1' at index 0 adding '/grackle@fec00000/ide@3/drive@1/disk@0' at index 1 adding '/grackle@fec00000/ide@3/drive@0/disk@0' at index 2 adding '/grackle@fec00000/ide@3/drive@0/disk@1' at index 3 So the fix is to qdevify mac io bus. -- Gleb.