[RFC PATCH 09/12] mm: enable allocate mirrored memory at boot time

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Add a boot option called "mirrorable" to allocate mirrored memory at boot time
(after bootmem free).

Signed-off-by: Xishi Qiu <qiuxishi@xxxxxxxxxx>
---
 mm/page_alloc.c | 7 +++++++
 1 file changed, 7 insertions(+)

diff --git a/mm/page_alloc.c b/mm/page_alloc.c
index 63b90ca..d4d2066 100644
--- a/mm/page_alloc.c
+++ b/mm/page_alloc.c
@@ -213,6 +213,13 @@ int user_min_free_kbytes = -1;
 #ifdef CONFIG_MEMORY_MIRROR
 struct mirror_info mirror_info;
 int sysctl_mirrorable = 0;
+
+static int __init set_mirrorable(char *p)
+{
+	sysctl_mirrorable = 1;
+	return 0;
+}
+early_param("mirrorable", set_mirrorable);
 #endif
 
 static unsigned long __meminitdata nr_kernel_pages;
-- 
2.0.0


--
To unsubscribe, send a message with 'unsubscribe linux-mm' in
the body to majordomo@xxxxxxxxx.  For more info on Linux MM,
see: http://www.linux-mm.org/ .
Don't email: <a href=mailto:"dont@xxxxxxxxx";> email@xxxxxxxxx </a>




[Index of Archives]     [Linux ARM Kernel]     [Linux ARM]     [Linux Omap]     [Fedora ARM]     [IETF Annouce]     [Bugtraq]     [Linux]     [Linux OMAP]     [Linux MIPS]     [ECOS]     [Asterisk Internet PBX]     [Linux API]