From patchwork Wed Oct 16 17:02:32 2013 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Anup Patel X-Patchwork-Id: 3054791 Return-Path: X-Original-To: patchwork-linux-arm@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork2.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.19.201]) by patchwork2.web.kernel.org (Postfix) with ESMTP id DEB91BF924 for ; Wed, 16 Oct 2013 17:05:59 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id CF85F20451 for ; Wed, 16 Oct 2013 17:05:58 +0000 (UTC) Received: from casper.infradead.org (casper.infradead.org [85.118.1.10]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id AC2A520357 for ; Wed, 16 Oct 2013 17:05:57 +0000 (UTC) Received: from merlin.infradead.org ([2001:4978:20e::2]) by casper.infradead.org with esmtps (Exim 4.80.1 #2 (Red Hat Linux)) id 1VWUWQ-0004C6-Jl; Wed, 16 Oct 2013 17:04:35 +0000 Received: from localhost ([::1] helo=merlin.infradead.org) by merlin.infradead.org with esmtp (Exim 4.80.1 #2 (Red Hat Linux)) id 1VWUW2-0007KZ-A3; Wed, 16 Oct 2013 17:04:10 +0000 Received: from mail-pa0-f49.google.com ([209.85.220.49]) by merlin.infradead.org with esmtps (Exim 4.80.1 #2 (Red Hat Linux)) id 1VWUVo-0007G9-9E for linux-arm-kernel@lists.infradead.org; Wed, 16 Oct 2013 17:03:57 +0000 Received: by mail-pa0-f49.google.com with SMTP id lj1so1085765pab.8 for ; Wed, 16 Oct 2013 10:03:34 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references; bh=o/G71zmubvN0p7TZGCmg5B6x6EdwSGESdBYw5isjY+U=; b=D4dQBIlD4pTSqn7DxlB/hNAPSwEFqmnDRXaq62nt4Pso0VzZ3BfmbKTE60xDDW7Igs UmidJ8YvD2DzARmI5QucvyddEMeFRuNii16b6kbGeRubhg7K7W3BsOIDtmW9XLtKWGBh FESTeA1IwdkOi0S2Ofh0dsoLgtOrfmU/h3+iZMkB32TcTYcBAyqQ3otLUsgyJhs8VKFh zZmPxRtdlVpMFAGnO4LVPnoYcqplGR9kSbAeulVP2K20fTx5Dy1bX1aJn5t5Yuj3fuCO 2hIWAxeMtasPapUTFbILlB19BPOnFM+JlCHLJBcgOfnWGOuJn19hkVic8prPndnIGGQS 4NDw== X-Gm-Message-State: ALoCoQmwrB2d23Sq9l7zaIIfoD9vOWaWaCOkZld/z1QGZzhGuhLIDJAsX35vPH9jBk4zdel1tC2u X-Received: by 10.66.25.133 with SMTP id c5mr4637933pag.4.1381943014736; Wed, 16 Oct 2013 10:03:34 -0700 (PDT) Received: from pnqlab006.amcc.com ([182.73.239.130]) by mx.google.com with ESMTPSA id hz10sm92298689pbc.36.1969.12.31.16.00.00 (version=TLSv1.1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Wed, 16 Oct 2013 10:03:33 -0700 (PDT) From: Anup Patel To: kvmarm@lists.cs.columbia.edu Subject: [RFC PATCH 3/5] KVM: Add documentation for KVM_EXIT_PSCI exit reason Date: Wed, 16 Oct 2013 22:32:32 +0530 Message-Id: <1381942954-22388-4-git-send-email-anup.patel@linaro.org> X-Mailer: git-send-email 1.7.9.5 In-Reply-To: <1381942954-22388-1-git-send-email-anup.patel@linaro.org> References: <1381942954-22388-1-git-send-email-anup.patel@linaro.org> X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20131016_130356_445334_FA5FC78E X-CRM114-Status: GOOD ( 10.49 ) X-Spam-Score: 0.4 (/) Cc: Mark Rutland , linaro-kernel@lists.linaro.org, Russell King , Anup Patel , patches@linaro.org, Marc Zyngier , Catalin Marinas , Will Deacon , linux-arm-kernel@lists.infradead.org, Christoffer Dall , Pranavkumar Sawargaonkar X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org X-Spam-Status: No, score=-1.7 required=5.0 tests=BAYES_00,KHOP_BIG_TO_CC, RCVD_IN_DNSWL_MED, RP_MATCHES_RCVD, UNPARSEABLE_RELAY autolearn=no version=3.3.1 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on mail.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP This patch adds documentation for KVM_EXIT_PSCI exit reason and PSCI call info in KVM run structure. We use exit reason KVM_EXIT_PSCI to forward PSCI calls such as SYSTEM_OFF and SYSTEM_RESET to user space (i.e. QEMU or KVMTOOL) Signed-off-by: Anup Patel Signed-off-by: Pranavkumar Sawargaonkar --- Documentation/virtual/kvm/api.txt | 13 +++++++++++++ 1 file changed, 13 insertions(+) diff --git a/Documentation/virtual/kvm/api.txt b/Documentation/virtual/kvm/api.txt index 076b849..215774d 100644 --- a/Documentation/virtual/kvm/api.txt +++ b/Documentation/virtual/kvm/api.txt @@ -2655,6 +2655,19 @@ It gets triggered whenever both KVM_CAP_PPC_EPR are enabled and an external interrupt has just been delivered into the guest. User space should put the acknowledged interrupt vector into the 'epr' field. + /* KVM_EXIT_PSCI */ + struct { + __u32 fn; + __u64 args[7]; + __u64 ret[4]; + } psci; + +ARM/ARM64 specific. The KVM ARM/ARM64 emulates Power State and Coordination +Interface (PSCI) for the Guest. This exit occurs when Guest issues a PSCI +function call to KVM ARM/ARM64 which is not emulated by in-kernel PSCI +emulation and needs to be emulated in user space (i.e. QEMU or KVMTOOL). +Examples of such PSCI functions are SYSTEM_OFF and SYSTEM_RESET. + /* Fix the size of the union. */ char padding[256]; };