From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1MHGlx-0001Mq-T4 for qemu-devel@nongnu.org; Thu, 18 Jun 2009 08:31:18 -0400 Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1MHGlr-0001LY-M4 for qemu-devel@nongnu.org; Thu, 18 Jun 2009 08:31:16 -0400 Received: from [199.232.76.173] (port=59739 helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1MHGlp-0001LF-Vd for qemu-devel@nongnu.org; Thu, 18 Jun 2009 08:31:10 -0400 Received: from mx2.redhat.com ([66.187.237.31]:33573) by monty-python.gnu.org with esmtp (Exim 4.60) (envelope-from ) id 1MHGlp-0004kM-Iy for qemu-devel@nongnu.org; Thu, 18 Jun 2009 08:31:09 -0400 Message-ID: <4A3A333F.40505@redhat.com> Date: Thu, 18 Jun 2009 14:29:51 +0200 From: Kevin Wolf MIME-Version: 1.0 Subject: Re: [Qemu-devel] [PATCH 0/4] Add multiboot support (x86) v2 References: <2966333961-BeMail@laptop> In-Reply-To: <2966333961-BeMail@laptop> Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable List-Id: qemu-devel.nongnu.org List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: =?UTF-8?B?RnJhbsOnb2lzIFJldm9s?= Cc: rene@exactcode.de, agraf@suse.de, qemu-devel@nongnu.org Fran=C3=A7ois Revol schrieb: >> Fran=C3=A7ois Revol schrieb: >>>> Why would an OS want to parse multiboot structures but not=20 >>>> implement >>>> proper multiboot support? I mean, this really isn't anything >>>> complicated. When you have enabled it to understand multiboot=20 >>>> structures >>>> you are only missing a handful of bytes for the multiboot header. >>>> >>>> What is it that you need to do differently for Haiku? >>> Because Haiku has its own second stage loader, which requires the=20 >>> BIOS=20 >>> to locate the kernel and module in a BFS partition which grub=20 >>> doesn't=20 >>> implement btw. >> That makes sense on real hardware, of course. But for -kernel you=20 >> don't >> need a file system to read the kernel from. >=20 > Except that wouldn't be the actual kernel passed but the 2nd stage. > And having to pass the kernel in a tgz outside the BFS image makes it=20 > more complex to set up. As Alex said, you don't need the tgz. Multiboot supports passing modules to the kernel (or 2nd stage loader), i.e. files that are loaded into memory by the bootloader (qemu in this case). >>> It also handles PM switching by itself. >>> Haiku might also use the BIOS for other stuff, like VESA mode=20 >>> switching, so I'd need to make sure all calls aren't strictly=20 >>> required. >> In theory you could switch back to Real Mode when starting through >> multiboot and then continue as with a normal boot. Admittedly,=20 >> doesn't >> sound exactly nice, but should be doable... >=20 > The loader can likey detect it anyway. If multiboot is used it should't= =20 > need to call the BIOS to read the kernel anyway. It's just a different=20 > code path.=20 Detecting shouldn't be problem, you have the multiboot magic in eax. I thought you would need the BIOS anyway (e.g. for VESA, as you mentioned yourself). If you don't or you can use VM86 instead, it's going to be much simpler, of course. Kevin