From mboxrd@z Thu Jan 1 00:00:00 1970 From: Paolo Bonzini Subject: Re: Announcing qboot, a minimal x86 firmware for QEMU Date: Wed, 27 May 2015 13:00:56 +0200 Message-ID: <5565A3E8.1010607@redhat.com> References: <555DE2EF.1000509@redhat.com> <20150522110136.GF14428@redhat.com> <20150522111259.GG14428@redhat.com> <55631B3A.7080803@redhat.com> <5564E4C9.8010906@codeaurora.org> <55658EAB.3010107@redhat.com> <55659010.6010302@cloudius-systems.com> Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit Cc: qemu-devel , KVM list To: Avi Kivity , Christopher Covington , "Daniel P. Berrange" , Peter Maydell Return-path: Received: from mail-wg0-f50.google.com ([74.125.82.50]:35065 "EHLO mail-wg0-f50.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751445AbbE0LBC (ORCPT ); Wed, 27 May 2015 07:01:02 -0400 Received: by wgme6 with SMTP id e6so6068364wgm.2 for ; Wed, 27 May 2015 04:01:01 -0700 (PDT) In-Reply-To: <55659010.6010302@cloudius-systems.com> Sender: kvm-owner@vger.kernel.org List-ID: On 27/05/2015 11:36, Avi Kivity wrote: > > > On 05/27/2015 12:30 PM, Paolo Bonzini wrote: >> >> On 26/05/2015 23:25, Christopher Covington wrote: >>> On 05/25/2015 08:53 AM, Paolo Bonzini wrote: >>>> On 22/05/2015 13:12, Daniel P. Berrange wrote: >>>>> In >>>>> particular I don't see why we need to have a SATA controller and >>>>> ISA/LPC >>>>> bridge in every virt machine - root PCI bus only should be >>>>> possible, as you >>>>> can provide disks via virtio-blk or virtio-scsi and serial, >>>>> parallel, mouse, >>>>> floppy via PCI devices and/or by adding a USB bus in the cases >>>>> where you >>>>> really need one. >>>> I think removing the ISA/LPC bridge is hard. It includes the real-time >>>> clock and fw_cfg, for example. >>> Could VirtIO specified replacements make sense for these peripherals? >> Not really. virtio is too heavyweight and you'd be reinventing the >> wheel unnecessarily. >> >> For example, ARM's "-M virt" uses a pl011 block for the RTC, and also >> uses fw_cfg. Another commonly used ISA device is the UART, for which >> again -M virt uses a pl031. >> > > The RTC can be replaced by kvmclock, the keyboard by virtio-console. > Maybe we can provide an msr- or pci- based interface to fw_cfg. The RTC is used for more than clock unfortunately. S3 support uses it for example, both to tell the firmware that it's an S3 resume and for resuming when the alarm fires. All in all, getting rid of ISA seems like chasing windmills. If you want to do that, fine, but then do not do that on a minimal firmware like qboot or SeaBIOS. For example, UEFI provides run-time services that let you access some low-level devices like this, and that's part of why the ARM virtual machine image specification mandates UEFI support. But even then, the ARM virtual machine image specification lets you choose between pl031 and a Xen pv console, and doesn't specify virtio-console... Paolo Paolo