From mboxrd@z Thu Jan 1 00:00:00 1970 From: "Michael S. Tsirkin" Subject: Re: [RFC PATCH 0/2] irq destination caching prototype Date: Mon, 13 Aug 2012 12:46:09 +0300 Message-ID: <20120813094609.GM14081@redhat.com> References: <1344849408-2697-1-git-send-email-gleb@redhat.com> <20120813093432.GL14081@redhat.com> <20120813093627.GP3341@redhat.com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Cc: kvm@vger.kernel.org, avi@redhat.com To: Gleb Natapov Return-path: Received: from mx1.redhat.com ([209.132.183.28]:61651 "EHLO mx1.redhat.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751143Ab2HMJpE (ORCPT ); Mon, 13 Aug 2012 05:45:04 -0400 Received: from int-mx10.intmail.prod.int.phx2.redhat.com (int-mx10.intmail.prod.int.phx2.redhat.com [10.5.11.23]) by mx1.redhat.com (8.14.4/8.14.4) with ESMTP id q7D9j4I6010664 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=OK) for ; Mon, 13 Aug 2012 05:45:04 -0400 Content-Disposition: inline In-Reply-To: <20120813093627.GP3341@redhat.com> Sender: kvm-owner@vger.kernel.org List-ID: On Mon, Aug 13, 2012 at 12:36:27PM +0300, Gleb Natapov wrote: > On Mon, Aug 13, 2012 at 12:34:32PM +0300, Michael S. Tsirkin wrote: > > On Mon, Aug 13, 2012 at 12:16:46PM +0300, Gleb Natapov wrote: > > > Here is a quick prototype of what we discussed yesterday. This one > > > caches only MSI interrupts for now. The obvious problem is that not > > > all interrupts (namely IPIs and MSIs using KVM_CAP_SIGNAL_MSI) use irq > > > routing table, so they cannot be cached. > > > > I thought this means ID changes need to replace the routing table, no? > > > Correct. This is missing from the patches, but as I said this is just > prototype to see if it is feasible. > What this prototype shows is that we > have problems with IPIs and MSIs from userspace. I think it's a worthwhile optimization all the same. When you feel it's ready, I'm willing to test to see if it helps vhost. > > > > > > Gleb Natapov (2): > > > Call irq_rt callback under rcu_read_lock() > > > Cache msi irq destination. > > > > > > arch/x86/kvm/lapic.c | 2 +- > > > include/linux/kvm_host.h | 1 + > > > virt/kvm/ioapic.c | 2 +- > > > virt/kvm/ioapic.h | 3 ++- > > > virt/kvm/irq_comm.c | 37 ++++++++++++++++++++----------------- > > > 5 files changed, 25 insertions(+), 20 deletions(-) > > > > > > -- > > > 1.7.10.4 > > -- > Gleb.