patch-2.1.79 linux/fs/proc/base.c

Next file: linux/fs/proc/link.c
Previous file: linux/fs/proc/array.c
Back to the patch index
Back to the overall index

diff -u --recursive --new-file v2.1.78/linux/fs/proc/base.c linux/fs/proc/base.c
@@ -158,6 +158,15 @@
 };
 #endif
 
+#ifdef __SMP__
+static struct proc_dir_entry proc_pid_cpu = {
+	PROC_PID_CPU, 3, "cpu",
+	S_IFREG | S_IRUGO, 1, 0, 0,
+	0, &proc_array_inode_operations,
+	NULL, proc_pid_fill_inode,
+};
+#endif
+
 void proc_base_init(void)
 {
 #if CONFIG_AP1000
@@ -174,4 +183,17 @@
 	proc_register(&proc_pid, &proc_pid_stat);
 	proc_register(&proc_pid, &proc_pid_statm);
 	proc_register(&proc_pid, &proc_pid_maps);
+#ifdef __SMP__	
+	proc_register(&proc_pid, &proc_pid_cpu);
+#endif	
 };
+
+
+
+
+
+
+
+
+
+

FUNET's LINUX-ADM group, linux-adm@nic.funet.fi
TCL-scripts by Sam Shen, slshen@lbl.gov