From patchwork Wed Nov 4 14:49:53 2015 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Christoffer Dall X-Patchwork-Id: 55989 Delivered-To: patch@linaro.org Received: by 10.112.61.134 with SMTP id p6csp2461750lbr; Wed, 4 Nov 2015 06:58:35 -0800 (PST) X-Received: by 10.68.244.234 with SMTP id xj10mr2415004pbc.6.1446649113805; Wed, 04 Nov 2015 06:58:33 -0800 (PST) Return-Path: Received: from bombadil.infradead.org (bombadil.infradead.org. [198.137.202.9]) by mx.google.com with ESMTPS id bc1si870914pbc.70.2015.11.04.06.58.33 for (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Wed, 04 Nov 2015 06:58:33 -0800 (PST) Received-SPF: pass (google.com: domain of linux-arm-kernel-bounces+patch=linaro.org@lists.infradead.org designates 198.137.202.9 as permitted sender) client-ip=198.137.202.9; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-arm-kernel-bounces+patch=linaro.org@lists.infradead.org designates 198.137.202.9 as permitted sender) smtp.mailfrom=linux-arm-kernel-bounces+patch=linaro.org@lists.infradead.org; dkim=neutral (body hash did not verify) header.i=@linaro_org.20150623.gappssmtp.com Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.80.1 #2 (Red Hat Linux)) id 1ZtzUv-00010h-Oe; Wed, 04 Nov 2015 14:57:13 +0000 Received: from merlin.infradead.org ([2001:4978:20e::2]) by bombadil.infradead.org with esmtps (Exim 4.80.1 #2 (Red Hat Linux)) id 1ZtzRS-0005Ft-4n for linux-arm-kernel@bombadil.infradead.org; Wed, 04 Nov 2015 14:53:38 +0000 Received: from mail-wm0-x22a.google.com ([2a00:1450:400c:c09::22a]) by merlin.infradead.org with esmtps (Exim 4.85 #2 (Red Hat Linux)) id 1ZtzRQ-0001Nx-2W for linux-arm-kernel@lists.infradead.org; Wed, 04 Nov 2015 14:53:37 +0000 Received: by wmeg8 with SMTP id g8so43525005wme.1 for ; Wed, 04 Nov 2015 06:53:12 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro_org.20150623.gappssmtp.com; s=20150623; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=RL1cnVbG/Rsys09ZYqwA38PFq7Z/6DhChl2VwtQhPIk=; b=dYGIoGom0Wen4HioCV8nghz6SdfFoBVL2gUYAwaiTEHoZ2IzRLOWjZ3yXMZOU6uqYu vWVHsqf37zr7MTEAfXnn5ZvyeJIiDOQr/Bd++O2tuURgT6KEfzto/k1ARW2gVIEy6LWw HS366a17r5ijqTwyh8NXNn4RrCb5EXNYwVSpL5LExp9wqxuiRt+smtC8Tt6qQqfYAJa5 HNk1fgZYJsMz1B7mmsmO5VeC8+Y45+qwVV7ItA7jItP2MdyjylfAkCiTtLrcqkfC87za 3KUzPo4r5fpyVLgCv3JtZJWdt6zoI5/JW4P92SxBA/ghxP0LTCXD7YZNlsYJi+8PP5Gn WwNg== 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=RL1cnVbG/Rsys09ZYqwA38PFq7Z/6DhChl2VwtQhPIk=; b=k4s0Z5p1p+9hn98skLnxN3WAMmrYRymPGm31DzI01DLC0/d5Fb/+LowIEAdB9DC//c JrNz5z0bMGzOmagwCCjlNTHf8VgIeu17XJmFT4PxuEEtJJhAd714mnMLczEcxFESPqUk KTYfOxf8XrtfBxu5jgOYs+Txs242NMdlExLGU0eM67hOweY2aitrZBogjoB8XuuczGvk ssEYhqScfvKo7uYSkEyeDVwV/sOL+EgpxeV7Ojr8lihHDp0qI7MQz+2zJ/kWCqeQrOK0 9quC/X/KG85q+Ww6pP0gtEy3gnSOffriDgIdXJ4S0Tf+FA/ajbosHT9EkpZ9vAhKLNUb 03HQ== X-Gm-Message-State: ALoCoQn7Jk9T0Eo+2knGURovGyVlLiAQvglw89P+Bp4hNlnwgiWcpJSCXag0uo7wOa9zlndLZG/E X-Received: by 10.28.87.15 with SMTP id l15mr4144517wmb.66.1446648792597; Wed, 04 Nov 2015 06:53:12 -0800 (PST) Received: from localhost.localdomain ([94.18.191.146]) by smtp.gmail.com with ESMTPSA id e9sm1985081wjw.8.2015.11.04.06.53.11 (version=TLS1_2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Wed, 04 Nov 2015 06:53:11 -0800 (PST) From: Christoffer Dall To: Paolo Bonzini , kvmarm@lists.cs.columbia.edu, kvm@vger.kernel.org, linux-arm-kernel@lists.infradead.org Subject: [PULL 14/21] KVM: arm/arm64: Fix vGIC documentation Date: Wed, 4 Nov 2015 15:49:53 +0100 Message-Id: <1446648600-27297-15-git-send-email-christoffer.dall@linaro.org> X-Mailer: git-send-email 2.1.2.330.g565301e.dirty In-Reply-To: <1446648600-27297-1-git-send-email-christoffer.dall@linaro.org> References: <1446648600-27297-1-git-send-email-christoffer.dall@linaro.org> X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20151104_095336_345547_EC5E7F8E X-CRM114-Status: GOOD ( 14.44 ) X-Spam-Score: -1.9 (-) X-Spam-Report: SpamAssassin version 3.4.1 on merlin.infradead.org summary: Content analysis details: (-1.9 points) pts rule name description ---- ---------------------- -------------------------------------------------- -0.0 RCVD_IN_DNSWL_NONE RBL: Sender listed at http://www.dnswl.org/, no trust [2a00:1450:400c:c09:0:0:0:22a listed in] [list.dnswl.org] -0.0 SPF_PASS SPF: sender matches SPF record -1.9 BAYES_00 BODY: Bayes spam probability is 0 to 1% [score: 0.0000] -0.1 DKIM_VALID Message has at least one valid DKIM or DK signature 0.1 DKIM_SIGNED Message has a DKIM or DK signature, not necessarily valid X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.20 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Marc Zyngier , Pavel Fedin , Christoffer Dall MIME-Version: 1.0 Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+patch=linaro.org@lists.infradead.org From: Pavel Fedin Correct some old mistakes in the API documentation: 1. VCPU is identified by index (using kvm_get_vcpu() function), but "cpu id" can be mistaken for affinity ID. 2. Some error codes are wrong. [ Slightly tweaked some grammer and did some s/CPU index/vcpu_index/ in the descriptions. -Christoffer ] Signed-off-by: Pavel Fedin Signed-off-by: Christoffer Dall --- Documentation/virtual/kvm/devices/arm-vgic.txt | 18 ++++++++++-------- 1 file changed, 10 insertions(+), 8 deletions(-) -- 2.1.2.330.g565301e.dirty _______________________________________________ linux-arm-kernel mailing list linux-arm-kernel@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-arm-kernel diff --git a/Documentation/virtual/kvm/devices/arm-vgic.txt b/Documentation/virtual/kvm/devices/arm-vgic.txt index 3fb9054..59541d4 100644 --- a/Documentation/virtual/kvm/devices/arm-vgic.txt +++ b/Documentation/virtual/kvm/devices/arm-vgic.txt @@ -44,28 +44,29 @@ Groups: Attributes: The attr field of kvm_device_attr encodes two values: bits: | 63 .... 40 | 39 .. 32 | 31 .... 0 | - values: | reserved | cpu id | offset | + values: | reserved | vcpu_index | offset | All distributor regs are (rw, 32-bit) The offset is relative to the "Distributor base address" as defined in the GICv2 specs. Getting or setting such a register has the same effect as - reading or writing the register on the actual hardware from the cpu - specified with cpu id field. Note that most distributor fields are not - banked, but return the same value regardless of the cpu id used to access - the register. + reading or writing the register on the actual hardware from the cpu whose + index is specified with the vcpu_index field. Note that most distributor + fields are not banked, but return the same value regardless of the + vcpu_index used to access the register. Limitations: - Priorities are not implemented, and registers are RAZ/WI - Currently only implemented for KVM_DEV_TYPE_ARM_VGIC_V2. Errors: - -ENODEV: Getting or setting this register is not yet supported + -ENXIO: Getting or setting this register is not yet supported -EBUSY: One or more VCPUs are running + -EINVAL: Invalid vcpu_index supplied KVM_DEV_ARM_VGIC_GRP_CPU_REGS Attributes: The attr field of kvm_device_attr encodes two values: bits: | 63 .... 40 | 39 .. 32 | 31 .... 0 | - values: | reserved | cpu id | offset | + values: | reserved | vcpu_index | offset | All CPU interface regs are (rw, 32-bit) @@ -91,8 +92,9 @@ Groups: - Priorities are not implemented, and registers are RAZ/WI - Currently only implemented for KVM_DEV_TYPE_ARM_VGIC_V2. Errors: - -ENODEV: Getting or setting this register is not yet supported + -ENXIO: Getting or setting this register is not yet supported -EBUSY: One or more VCPUs are running + -EINVAL: Invalid vcpu_index supplied KVM_DEV_ARM_VGIC_GRP_NR_IRQS Attributes: