[PATCH] Make sysctl vm subdir dependent on CONFIG_MMU

From: Miles Bader (miles@lsi.nec.co.jp)
Date: Mon Feb 17 2003 - 05:59:00 EST


diff -ruN -X../cludes linux-2.5.61-uc0.orig/kernel/sysctl.c linux-2.5.61-uc0/kernel/sysctl.c
--- linux-2.5.61-uc0.orig/kernel/sysctl.c 2002-12-16 12:53:59.000000000 +0900
+++ linux-2.5.61-uc0/kernel/sysctl.c 2003-02-17 19:24:58.000000000 +0900
@@ -111,7 +111,9 @@
         { root_table, LIST_HEAD_INIT(root_table_header.ctl_entry) };
 
 static ctl_table kern_table[];
+#ifdef CONFIG_MMU
 static ctl_table vm_table[];
+#endif
 #ifdef CONFIG_NET
 extern ctl_table net_table[];
 #endif
@@ -148,7 +150,9 @@
 
 static ctl_table root_table[] = {
         {CTL_KERN, "kernel", NULL, 0, 0555, kern_table},
+#ifdef CONFIG_MMU
         {CTL_VM, "vm", NULL, 0, 0555, vm_table},
+#endif
 #ifdef CONFIG_NET
         {CTL_NET, "net", NULL, 0, 0555, net_table},
 #endif
@@ -271,6 +275,7 @@
 static int one_hundred = 100;
 
 
+#ifdef CONFIG_MMU
 static ctl_table vm_table[] = {
         {VM_OVERCOMMIT_MEMORY, "overcommit_memory", &sysctl_overcommit_memory,
          sizeof(sysctl_overcommit_memory), 0644, NULL, &proc_dointvec},
@@ -321,6 +326,7 @@
          NULL, },
         {0}
 };
+#endif /* CONFIG_MMU */
 
 static ctl_table proc_table[] = {
         {0}
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/



This archive was generated by hypermail 2b29 : Sun Feb 23 2003 - 22:00:17 EST