summaryrefslogtreecommitdiffstats
path: root/arch/x86/xen/p2m.c
diff options
context:
space:
mode:
authorKonrad Rzeszutek Wilk <konrad.wilk@oracle.com>2011-09-29 13:09:34 -0400
committerKonrad Rzeszutek Wilk <konrad.wilk@oracle.com>2011-10-19 17:03:32 -0400
commit8404877ee1cfdbc872e153fd89022f9e47f6f5a3 (patch)
tree8a319093c106cbeb2017d0af8421c055a4851fd3 /arch/x86/xen/p2m.c
parent5e287830136a8edb76e9f9c432b264d99833172f (diff)
downloadop-kernel-dev-8404877ee1cfdbc872e153fd89022f9e47f6f5a3.zip
op-kernel-dev-8404877ee1cfdbc872e153fd89022f9e47f6f5a3.tar.gz
xen/p2m/debugfs: Fix potential pointer exception.
We could be referencing the last + 1 element of level_name[] array which would cause a pointer exception, because of the initial setup of lvl=4. [v1: No need to do this for type_name, pointed out by Ian Campbell] Signed-off-by: Konrad Rzeszutek Wilk <konrad.wilk@oracle.com>
Diffstat (limited to 'arch/x86/xen/p2m.c')
-rw-r--r--arch/x86/xen/p2m.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/arch/x86/xen/p2m.c b/arch/x86/xen/p2m.c
index 58efeb9..2e3bf7a 100644
--- a/arch/x86/xen/p2m.c
+++ b/arch/x86/xen/p2m.c
@@ -786,7 +786,7 @@ EXPORT_SYMBOL_GPL(m2p_find_override_pfn);
int p2m_dump_show(struct seq_file *m, void *v)
{
static const char * const level_name[] = { "top", "middle",
- "entry", "abnormal" };
+ "entry", "abnormal", "error"};
static const char * const type_name[] = { "identity", "missing",
"pfn", "abnormal"};
#define TYPE_IDENTITY 0
OpenPOWER on IntegriCloud