diff options
Diffstat (limited to 'include/linux')
| -rw-r--r-- | include/linux/init_task.h | 1 | ||||
| -rw-r--r-- | include/linux/proc_fs.h | 2 | ||||
| -rw-r--r-- | include/linux/sched.h | 2 |
3 files changed, 5 insertions, 0 deletions
diff --git a/include/linux/init_task.h b/include/linux/init_task.h index 96a5f926300e..6372a411be8f 100644 --- a/include/linux/init_task.h +++ b/include/linux/init_task.h @@ -101,6 +101,7 @@ .blocked = {{0}}, \ .posix_timers = LIST_HEAD_INIT(tsk.posix_timers), \ .alloc_lock = SPIN_LOCK_UNLOCKED, \ + .proc_lock = SPIN_LOCK_UNLOCKED, \ .switch_lock = SPIN_LOCK_UNLOCKED, \ .journal_info = NULL, \ } diff --git a/include/linux/proc_fs.h b/include/linux/proc_fs.h index 0dd15d1cb2e2..4607df82fd93 100644 --- a/include/linux/proc_fs.h +++ b/include/linux/proc_fs.h @@ -87,6 +87,8 @@ extern void proc_root_init(void); extern void proc_misc_init(void); struct dentry *proc_pid_lookup(struct inode *dir, struct dentry * dentry); +struct dentry *proc_pid_unhash(struct task_struct *p); +void proc_pid_flush(struct dentry *proc_dentry); int proc_pid_readdir(struct file * filp, void * dirent, filldir_t filldir); extern struct proc_dir_entry *create_proc_entry(const char *name, mode_t mode, diff --git a/include/linux/sched.h b/include/linux/sched.h index 46981bca766f..75e6e1b5b363 100644 --- a/include/linux/sched.h +++ b/include/linux/sched.h @@ -429,6 +429,8 @@ struct task_struct { u32 self_exec_id; /* Protection of (de-)allocation: mm, files, fs, tty */ spinlock_t alloc_lock; +/* Protection of proc_dentry: nesting proc_lock, dcache_lock, write_lock_irq(&tasklist_lock); */ + spinlock_t proc_lock; /* context-switch lock */ spinlock_t switch_lock; |
