patch-2.4.19 linux-2.4.19/include/linux/sched.h
Next file: linux-2.4.19/include/linux/seq_file.h
Previous file: linux-2.4.19/include/linux/rtnetlink.h
Back to the patch index
Back to the overall index
- Lines: 88
- Date:
Fri Aug 2 17:39:45 2002
- Orig file:
linux-2.4.18/include/linux/sched.h
- Orig date:
Fri Dec 21 09:42:03 2001
diff -urN linux-2.4.18/include/linux/sched.h linux-2.4.19/include/linux/sched.h
@@ -42,6 +42,7 @@
#define CLONE_VFORK 0x00004000 /* set if the parent wants the child to wake it up on mm_release */
#define CLONE_PARENT 0x00008000 /* set if we want to have the same parent as the cloner */
#define CLONE_THREAD 0x00010000 /* Same thread group? */
+#define CLONE_NEWNS 0x00020000 /* New namespace group? */
#define CLONE_SIGNAL (CLONE_SIGHAND | CLONE_THREAD)
@@ -79,7 +80,9 @@
#include <linux/time.h>
#include <linux/param.h>
#include <linux/resource.h>
+#ifdef __KERNEL__
#include <linux/timer.h>
+#endif
#include <asm/processor.h>
@@ -166,6 +169,7 @@
*/
#define NR_OPEN_DEFAULT BITS_PER_LONG
+struct namespace;
/*
* Open file table structure
*/
@@ -199,7 +203,9 @@
}
/* Maximum number of active map areas.. This is a random (large) number */
-#define MAX_MAP_COUNT (65536)
+#define DEFAULT_MAX_MAP_COUNT (65536)
+
+extern int max_map_count;
struct mm_struct {
struct vm_area_struct * mmap; /* list of VMAs */
@@ -389,6 +395,8 @@
struct fs_struct *fs;
/* open file information */
struct files_struct *files;
+/* namespace */
+ struct namespace *namespace;
/* signal handlers */
spinlock_t sigmask_lock; /* Protects signal and blocked */
struct signal_struct *sig;
@@ -450,6 +458,8 @@
#define MAX_COUNTER (20*HZ/100)
#define DEF_NICE (0)
+asmlinkage long sys_sched_yield(void);
+#define yield() sys_sched_yield()
/*
* The default (Linux) execution domain.
@@ -610,6 +620,7 @@
extern void proc_caches_init(void);
extern void flush_signals(struct task_struct *);
extern void flush_signal_handlers(struct task_struct *);
+extern void sig_exit(int, int, struct siginfo *);
extern int dequeue_signal(sigset_t *, siginfo_t *);
extern void block_all_signals(int (*notifier)(void *priv), void *priv,
sigset_t *mask);
@@ -870,9 +881,14 @@
#define for_each_task(p) \
for (p = &init_task ; (p = p->next_task) != &init_task ; )
+#define for_each_thread(task) \
+ for (task = next_thread(current) ; task != current ; task = next_thread(task))
+
#define next_thread(p) \
list_entry((p)->thread_group.next, struct task_struct, thread_group)
+#define thread_group_leader(p) (p->pid == p->tgid)
+
static inline void del_from_runqueue(struct task_struct * p)
{
nr_running--;
@@ -888,7 +904,8 @@
static inline void unhash_process(struct task_struct *p)
{
- if (task_on_runqueue(p)) BUG();
+ if (task_on_runqueue(p))
+ out_of_line_bug();
write_lock_irq(&tasklist_lock);
nr_threads--;
unhash_pid(p);
FUNET's LINUX-ADM group, linux-adm@nic.funet.fi
TCL-scripts by Sam Shen (who was at: slshen@lbl.gov)