From mboxrd@z Thu Jan 1 00:00:00 1970 From: Avi Kivity Subject: Re: Undocumented KVM_SET_LAPIC ioctl() Date: Wed, 27 Apr 2011 10:37:58 +0300 Message-ID: <4DB7C7D6.7000502@redhat.com> References: Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Cc: KVM General , Ingo Molnar , Cyrill Gorcunov To: Pekka Enberg Return-path: Received: from mx1.redhat.com ([209.132.183.28]:16780 "EHLO mx1.redhat.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753463Ab1D0HiL (ORCPT ); Wed, 27 Apr 2011 03:38:11 -0400 In-Reply-To: Sender: kvm-owner@vger.kernel.org List-ID: On 04/27/2011 10:23 AM, Pekka Enberg wrote: > Hi! > > We're currently having issues while trying to make the KVM in-kernel > lapic to work. There seems to be a KVM_SET_LAPIC ioctl() for this but > it's not documented in Documentation/kvm/api.txt. Are there other > ioctls we should know about? We're using KVM_CREATE_IRQCHIP obviously. Plenty, yes. KVM_IRQ_LINE - raise or lower an irq line. KVM_GET_IRQCHIP/KVM_SET_IRQCHIP - save/restore PIC/IOAPIC states. KVM_CREATE_PIT2/KVM_GET_PIT2/KVM_SET_PIT2 - PIT support (optional) KVM_IRQ_LINE_STATUS - like KVM_IRQ_LINE, but provide information about whether the interrupt was coalesced or not. Useful for compensating for time drift. KVM_SET_GSI_ROUTING - manipulate the routes between irq lines and the IOAPIC and PIC; also maintain virtual routes for message signalled interrupts (MSI) KVM_IRQFD - raise an edge-triggered interrupt via an eventfd; useful for talking to a guest from outside its host process KVM_GET_LAPIC/KVM_SET_LAPIC - save/restore local APIC register state I'll post documentation patches. To get started, KVM_SET_LAPIC is simple - it simply accepts a 1K buffer that maps 1:1 to local APIC registers as documented in the Intel SDM, volume 3. -- error compiling committee.c: too many arguments to function