linux-mips
[Top] [All Lists]

[PATCH 18/18] KVM/MIPS32-VZ: Dump out additional info about VZ features

To: kvm@vger.kernel.org
Subject: [PATCH 18/18] KVM/MIPS32-VZ: Dump out additional info about VZ features as part of /proc/cpuinfo
From: Sanjay Lal <sanjayl@kymasys.com>
Date: Sat, 18 May 2013 22:47:40 -0700
Cc: linux-mips@linux-mips.org, Ralf Baechle <ralf@linux-mips.org>, Gleb Natapov <gleb@redhat.com>, Marcelo Tosatti <mtosatti@redhat.com>, Sanjay Lal <sanjayl@kymasys.com>
In-reply-to: <1368942460-15577-1-git-send-email-sanjayl@kymasys.com>
List-archive: <http://www.linux-mips.org/archives/linux-mips/>
List-help: <mailto:ecartis@linux-mips.org?Subject=help>
List-id: linux-mips <linux-mips.eddie.linux-mips.org>
List-owner: <mailto:ralf@linux-mips.org>
List-post: <mailto:linux-mips@linux-mips.org>
List-software: Ecartis version 1.0.0
List-subscribe: <mailto:ecartis@linux-mips.org?subject=subscribe%20linux-mips>
List-unsubscribe: <mailto:ecartis@linux-mips.org?subject=unsubscribe%20linux-mips>
Original-recipient: rfc822;linux-mips@linux-mips.org
References: <n> <1368942460-15577-1-git-send-email-sanjayl@kymasys.com>
Sender: linux-mips-bounce@linux-mips.org
Signed-off-by: Sanjay Lal <sanjayl@kymasys.com>
---
 arch/mips/kernel/proc.c | 11 +++++++++++
 1 file changed, 11 insertions(+)

diff --git a/arch/mips/kernel/proc.c b/arch/mips/kernel/proc.c
index a3e4614..308e042 100644
--- a/arch/mips/kernel/proc.c
+++ b/arch/mips/kernel/proc.c
@@ -99,6 +99,17 @@ static int show_cpuinfo(struct seq_file *m, void *v)
        if (cpu_has_vz)         seq_printf(m, "%s", " vz");
        seq_printf(m, "\n");
 
+#ifdef CONFIG_KVM_MIPS_VZ
+       if (cpu_has_vz) {
+               seq_printf(m, "vz guestid\t\t: %s\n",
+                       cpu_has_vzguestid ? "yes" : "no");
+               seq_printf(m, "vz virt irq\t\t: %s\n",
+                       cpu_has_vzvirtirq ? "yes" : "no");
+       }
+       seq_printf(m, "tlbinv instructions\t: %s\n",
+               cpu_has_tlbinv ? "yes" : "no");
+#endif
+
        if (cpu_has_mmips) {
                seq_printf(m, "micromips kernel\t: %s\n",
                      (read_c0_config3() & MIPS_CONF3_ISA_OE) ?  "yes" : "no");
-- 
1.7.11.3


<Prev in Thread] Current Thread [Next in Thread>