From mboxrd@z Thu Jan 1 00:00:00 1970 From: Avi Kivity Subject: Re: [PATCH 8/9] coalesce mmio regions with an explicit call Date: Tue, 23 Sep 2008 10:29:48 +0300 Message-ID: <48D89AEC.5090102@redhat.com> References: <1221840506-22996-1-git-send-email-glommer@redhat.com> <1221840506-22996-9-git-send-email-glommer@redhat.com> <48D54370.7090709@redhat.com> <20080922135645.GF3618@poweredge.glommer> Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Cc: kvm@vger.kernel.org, aliguori@us.ibm.com To: Glauber Costa Return-path: Received: from mx2.redhat.com ([66.187.237.31]:33952 "EHLO mx2.redhat.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753272AbYIWH35 (ORCPT ); Tue, 23 Sep 2008 03:29:57 -0400 In-Reply-To: <20080922135645.GF3618@poweredge.glommer> Sender: kvm-owner@vger.kernel.org List-ID: Glauber Costa wrote: > On Sat, Sep 20, 2008 at 11:39:44AM -0700, Avi Kivity wrote: > >> Glauber Costa wrote: >> >>> Remove explicit calls to mmio coalescing. Rather, >>> include it in the registration functions. >>> >>> index 5ae3960..2d97b34 100644 >>> --- a/qemu/hw/e1000.c >>> +++ b/qemu/hw/e1000.c >>> @@ -942,18 +942,6 @@ e1000_mmio_map(PCIDevice *pci_dev, int region_num, >>> d->mmio_base = addr; >>> cpu_register_physical_memory(addr, PNPMMIO_SIZE, d->mmio_index); >>> - >>> - if (kvm_enabled()) { >>> - int i; >>> - uint32_t excluded_regs[] = { >>> - E1000_MDIC, E1000_ICR, E1000_ICS, E1000_IMS, >>> - E1000_IMC, E1000_TCTL, E1000_TDT, PNPMMIO_SIZE >>> - }; >>> - qemu_kvm_register_coalesced_mmio(addr, excluded_regs[0]); >>> - for (i = 0; excluded_regs[i] != PNPMMIO_SIZE; i++) >>> - qemu_kvm_register_coalesced_mmio(addr + excluded_regs[i] + 4, >>> - excluded_regs[i + 1] - excluded_regs[i] - 4); >>> - } >>> } >>> >>> >> Where did all of this go? >> > > All the region is coalesced (not just the pieces) automatically during memory registration. > Or not at all, in case coalescing is disabled. > You can't coalesce the registers which trigger device action. You'll destroy latency and/or functionality. -- error compiling committee.c: too many arguments to function