mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
* [PATCH] acpi - Add support for AddressRangeUnusuable ACPI memory type
@ 2008-07-24 16:49 Cihula, Joseph
  2008-07-28 14:13 ` Ingo Molnar
  0 siblings, 1 reply; 2+ messages in thread
From: Cihula, Joseph @ 2008-07-24 16:49 UTC (permalink / raw)
  To: linux-kernel, x86; +Cc: Kleen, Andi, Wang, Shane, Wei, Gang, Brown, Len

[-- Attachment #1: Type: text/plain, Size: 2312 bytes --]

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 = "System RAM"; break;
 		case E820_ACPI:	res->name = "ACPI Tables"; break;
 		case E820_NVS:	res->name = "ACPI Non-volatile Storage";
break;
+		case E820_UNUSABLE:     res->name = "Unusable memory";
break;
 		default:	res->name = "reserved";
 		}
 		res->start = 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 = "System RAM"; break;
 		case E820_ACPI:	res->name = "ACPI Tables"; break;
 		case E820_NVS:	res->name = "ACPI Non-volatile Storage";
break;
+		case E820_UNUSABLE:     res->name = "Unusable memory";
break;
 		default:	res->name = "reserved";
 		}
 		res->start = 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
 
 #ifndef __ASSEMBLY__
 struct e820entry {
 <<linux-acpi-2.6.26.patch>> 

[-- Attachment #2: linux-acpi-2.6.26.patch --]
[-- Type: application/octet-stream, Size: 1731 bytes --]

--- 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 = "System RAM"; break;
 		case E820_ACPI:	res->name = "ACPI Tables"; break;
 		case E820_NVS:	res->name = "ACPI Non-volatile Storage"; break;
+		case E820_UNUSABLE:     res->name = "Unusable memory"; break;
 		default:	res->name = "reserved";
 		}
 		res->start = 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 = "System RAM"; break;
 		case E820_ACPI:	res->name = "ACPI Tables"; break;
 		case E820_NVS:	res->name = "ACPI Non-volatile Storage"; break;
+		case E820_UNUSABLE:     res->name = "Unusable memory"; break;
 		default:	res->name = "reserved";
 		}
 		res->start = 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
 
 #ifndef __ASSEMBLY__
 struct e820entry {

^ permalink raw reply	[flat|nested] 2+ messages in thread

* Re: [PATCH] acpi - Add support for AddressRangeUnusuable ACPI memory type
  2008-07-24 16:49 [PATCH] acpi - Add support for AddressRangeUnusuable ACPI memory type Cihula, Joseph
@ 2008-07-28 14:13 ` Ingo Molnar
  0 siblings, 0 replies; 2+ messages in thread
From: Ingo Molnar @ 2008-07-28 14:13 UTC (permalink / raw)
  To: Cihula, Joseph
  Cc: linux-kernel, x86, Kleen, Andi, Wang, Shane, Wei, Gang, Brown,
	Len, Yinghai Lu


* Cihula, Joseph <joseph.cihula@intel.com> wrote:

> 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.

Looks good to me, but the 32-bit and 64-bit files that this patch 
changes got unified in the latest upstream tree - could you please 
resend this against tip/master:

 http://people.redhat.com/mingo/tip.git/README

thanks,

	Ingo

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2008-07-28 14:14 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2008-07-24 16:49 [PATCH] acpi - Add support for AddressRangeUnusuable ACPI memory type Cihula, Joseph
2008-07-28 14:13 ` Ingo Molnar

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®