[patch] MCA recovery verify pfn_valid

From: Russ Anderson <rja_at_efs.americas.sgi.com>
Date: 2005-09-17 07:54:53
Verify the pfn is valid before calling pfn_to_page().

Signed-off-by: Russ Anderson (rja@sgi.com)

---------------------------------------------------------------------
 arch/ia64/kernel/mca_drv.c |    3 +++
 1 files changed, 3 insertions(+)

Index: linux-2.6.git#test/arch/ia64/kernel/mca_drv.c
===================================================================
--- linux-2.6.git#test.orig/arch/ia64/kernel/mca_drv.c	2005-09-16 16:28:11.857773257 -0500
+++ linux-2.6.git#test/arch/ia64/kernel/mca_drv.c	2005-09-16 16:29:32.119181669 -0500
@@ -87,6 +87,9 @@ mca_page_isolate(unsigned long paddr)
 	if ( !ia64_phys_addr_valid(paddr) ) 
 		return ISOLATE_NG;
 
+	if ( !pfn_valid(paddr))
+		return ISOLATE_OK;
+
 	/* convert physical address to physical page number */
 	p = pfn_to_page(paddr>>PAGE_SHIFT);
 
-
To unsubscribe from this list: send the line "unsubscribe linux-ia64" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Received on Sat Sep 17 07:55:36 2005

This archive was generated by hypermail 2.1.8 : 2005-09-17 07:55:43 EST