Login | Register For Free | Help
Search for: (Advanced)

Mailing List Archive: Linux: Kernel

[PATCH 2/8] pid, kgdb: add pid_max prototype

 

 

Linux kernel RSS feed   Index | Next | Previous | View Threaded


jason.wessel at windriver

Feb 9, 2008, 5:35 AM

Post #1 of 2 (241 views)
Permalink
[PATCH 2/8] pid, kgdb: add pid_max prototype

From: Ingo Molnar <mingo [at] elte>

add pid_max prototype - now used by sysctl and kgdb as well.

Signed-off-by: Ingo Molnar <mingo [at] elte>
Signed-off-by: Thomas Gleixner <tglx [at] linutronix>
Signed-off-by: Jason Wessel <jason.wessel [at] windriver>
---
include/linux/pid.h | 2 ++
kernel/kgdb.c | 2 +-
kernel/sysctl.c | 2 +-
3 files changed, 4 insertions(+), 2 deletions(-)

diff --git a/include/linux/pid.h b/include/linux/pid.h
index f84d532..e066d3d 100644
--- a/include/linux/pid.h
+++ b/include/linux/pid.h
@@ -86,6 +86,8 @@ extern struct task_struct *FASTCALL(get_pid_task(struct pid *pid,

extern struct pid *get_task_pid(struct task_struct *task, enum pid_type type);

+extern int pid_max;
+
/*
* attach_pid() and detach_pid() must be called with the tasklist_lock
* write-held.
diff --git a/kernel/kgdb.c b/kernel/kgdb.c
index 3f06d09..2986bd2 100644
--- a/kernel/kgdb.c
+++ b/kernel/kgdb.c
@@ -45,6 +45,7 @@
#include <linux/sysrq.h>
#include <linux/init.h>
#include <linux/kgdb.h>
+#include <linux/pid.h>
#include <linux/smp.h>
#include <linux/mm.h>

@@ -101,7 +102,6 @@ struct kgdb_bkpt kgdb_break[KGDB_MAX_BREAKPOINTS] = {
* CPU having a lock:
*/

-extern int pid_max;
/* How many times to count all of the waiting CPUs */
#define ROUNDUP_WAIT 640000 /* Arbitrary, increase if needed. */
#define BUF_THREAD_ID_SIZE 16
diff --git a/kernel/sysctl.c b/kernel/sysctl.c
index d41ef6b..97a152c 100644
--- a/kernel/sysctl.c
+++ b/kernel/sysctl.c
@@ -32,6 +32,7 @@
#include <linux/init.h>
#include <linux/kernel.h>
#include <linux/kobject.h>
+#include <linux/pid.h>
#include <linux/net.h>
#include <linux/sysrq.h>
#include <linux/highuid.h>
@@ -71,7 +72,6 @@ extern int max_threads;
extern int core_uses_pid;
extern int suid_dumpable;
extern char core_pattern[];
-extern int pid_max;
extern int min_free_kbytes;
extern int pid_max_min, pid_max_max;
extern int sysctl_drop_caches;
--
1.5.4

--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo [at] vger
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/


hch at infradead

Feb 9, 2008, 9:10 AM

Post #2 of 2 (210 views)
Permalink
Re: [PATCH 2/8] pid, kgdb: add pid_max prototype [In reply to]

On Sat, Feb 09, 2008 at 07:35:08AM -0600, jason.wessel [at] windriver wrote:
> From: Ingo Molnar <mingo [at] elte>
>
> add pid_max prototype - now used by sysctl and kgdb as well.

extern should never be in .c files, so this should be submitted now,
even independent of kgdb.

--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo [at] vger
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/

Linux kernel RSS feed   Index | Next | Previous | View Threaded
 
 


Interested in having your list archived? Contact Gossamer Threads
 
  Web Applications & Managed Hosting Powered by Gossamer Threads Inc.