[PATCH] acpi - Add support for AddressRangeUnusuable ACPI memory type

Previous message: [thread] [date] [author]
Next message: [thread] [date] [author]
From: Cihula, Joseph
Date: Thursday, July 24, 2008 - 9:49 am

Add support for the E820_UNUSABLE memory type, which is defined in
Revision 3.0b (Oct. 10, 2006) of the ACPI Specification on p. 394 Table
14-1:
	AddressRangeUnusuable
	This range of address contains memory in which errors have been
detected. This range must not be used by the OSPM.

This patch applies cleanly to 2.6.26.

Signed-off-by:  Joseph Cihula <joseph.cihula@intel.com>
Signed-off-by:  Shane Wang <shane.wang@intel.com>
Signed-off-by:  Gang Wei <gang.wei@intel.com>

--- linux-2.6.26/arch/x86/kernel/e820_32.c	2008-07-13
14:51:29.000000000 -0700
+++ linux-2.6.26-acpi/arch/x86/kernel/e820_32.c	2008-07-23
13:25:44.000000000 -0700
@@ -198,6 +198,7 @@
 		case E820_RAM:	res->name =3D "System RAM"; break;
 		case E820_ACPI:	res->name =3D "ACPI Tables"; break;
 		case E820_NVS:	res->name =3D "ACPI Non-volatile Storage";
break;
+		case E820_UNUSABLE:     res->name =3D "Unusable memory";
break;
 		default:	res->name =3D "reserved";
 		}
 		res->start =3D e820.map[i].addr;
@@ -604,6 +605,9 @@
 		case E820_NVS:
 				printk("(ACPI NVS)\n");
 				break;
+		case E820_UNUSABLE:
+				printk("(unusable)\n");
+				break;
 		default:	printk("type %u\n", e820.map[i].type);
 				break;
 		}
--- linux-2.6.26/arch/x86/kernel/e820_64.c	2008-07-13
14:51:29.000000000 -0700
+++ linux-2.6.26-acpi/arch/x86/kernel/e820_64.c	2008-07-23
13:27:29.000000000 -0700
@@ -336,6 +336,7 @@
 		case E820_RAM:	res->name =3D "System RAM"; break;
 		case E820_ACPI:	res->name =3D "ACPI Tables"; break;
 		case E820_NVS:	res->name =3D "ACPI Non-volatile Storage";
break;
+		case E820_UNUSABLE:     res->name =3D "Unusable memory";
break;
 		default:	res->name =3D "reserved";
 		}
 		res->start =3D e820.map[i].addr;
@@ -495,6 +496,9 @@
 		case E820_NVS:
 			printk(KERN_CONT "(ACPI NVS)\n");
 			break;
+ 		case E820_UNUSABLE:
+			printk("(unusable)\n");
+			break;
 		default:
 			printk(KERN_CONT "type %u\n", e820.map[i].type);
 			break;
--- linux-2.6.26/include/asm-x86/e820.h	2008-07-13 14:51:29.000000000
-0700
+++ linux-2.6.26-acpi/include/asm-x86/e820.h	2008-07-23
13:25:44.000000000 -0700
@@ -8,6 +8,7 @@
 #define E820_RESERVED	2
 #define E820_ACPI	3
 #define E820_NVS	4
+#define E820_UNUSABLE	5
=20
 #ifndef __ASSEMBLY__
 struct e820entry {
 <<linux-acpi-2.6.26.patch>>=20
Previous message: [thread] [date] [author]
Next message: [thread] [date] [author]

Messages in current thread:
[PATCH] acpi - Add support for AddressRangeUnusuable ACPI ..., Cihula, Joseph, (Thu Jul 24, 9:49 am)