From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:45806) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ahvLN-0007f2-9Q for qemu-devel@nongnu.org; Mon, 21 Mar 2016 04:37:46 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1ahvLK-00048X-2c for qemu-devel@nongnu.org; Mon, 21 Mar 2016 04:37:45 -0400 Received: from mx1.redhat.com ([209.132.183.28]:56231) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ahvLJ-00048T-T6 for qemu-devel@nongnu.org; Mon, 21 Mar 2016 04:37:41 -0400 Received: from int-mx14.intmail.prod.int.phx2.redhat.com (int-mx14.intmail.prod.int.phx2.redhat.com [10.5.11.27]) by mx1.redhat.com (Postfix) with ESMTPS id 65AFC7F097 for ; Mon, 21 Mar 2016 08:37:41 +0000 (UTC) Date: Mon, 21 Mar 2016 08:37:39 +0000 From: "Richard W.M. Jones" Message-ID: <20160321083739.GN1681@redhat.com> References: <20160319203124.GB19398@redhat.com> <1458547107.4299.7.camel@redhat.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <1458547107.4299.7.camel@redhat.com> Subject: Re: [Qemu-devel] Why is SeaBIOS used with -kernel? List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Gerd Hoffmann Cc: Marc =?iso-8859-1?Q?Mar=ED?= , qemu-devel@nongnu.org On Mon, Mar 21, 2016 at 08:58:27AM +0100, Gerd Hoffmann wrote: > On Sa, 2016-03-19 at 20:31 +0000, Richard W.M. Jones wrote: > > I've been analyzing the libguestfs appliance[1] boot time. See > > attached file, especially the end of it. > > > > About 50% of the boot time is because of SeaBIOS. > > And the bulk of that is loading the kernel from fw_cfg. Yes after further investigation that is correct. It looks like fw_cfg has grown a DMA interface, but it's not used on x86. There is still a considerable amount of SeaBIOS overhead. In particular, it scans the whole of the PCI bus looking for boot devices, but that work is both slow and completely unnecessary if we're using the linuxbios option ROM to boot. > > I'm using the qemu -kernel option. I understand that the kernel needs > > some BIOS features, eg. video stuff, E820. But kvmtool comes with a > > really minimal BIOS that implements a tiny number of calls[2] and is > > far faster than SeaBIOS. > > > > Is there something I'm missing, or for Linux + -kernel could we use a > > much simpler BIOS? > > marc (cc'ed) worked on porting the linuxboot option rom over to use the > new fwcfg dma interface, which should make things a order of magnitude > faster. That seems to be stalled though. Marc? To Marc: Are there patches you can point me to? Rich. -- Richard Jones, Virtualization Group, Red Hat http://people.redhat.com/~rjones Read my programming and virtualization blog: http://rwmj.wordpress.com virt-df lists disk usage of guests without needing to install any software inside the virtual machine. Supports Linux and Windows. http://people.redhat.com/~rjones/virt-df/