diff options
| author | Thomas Gleixner <tglx@linutronix.de> | 2011-05-14 12:06:36 +0200 | 
|---|---|---|
| committer | Thomas Gleixner <tglx@linutronix.de> | 2011-05-14 12:06:36 +0200 | 
| commit | a18f22a968de17b29f2310cdb7ba69163e65ec15 (patch) | |
| tree | a7d56d88fad5e444d7661484109758a2f436129e /fs/proc/root.c | |
| parent | a1c57e0fec53defe745e64417eacdbd3618c3e66 (diff) | |
| parent | 798778b8653f64b7b2162ac70eca10367cff6ce8 (diff) | |
Merge branch 'consolidate-clksrc-i8253' of master.kernel.org:~rmk/linux-2.6-arm into timers/clocksource
Conflicts:
	arch/ia64/kernel/cyclone.c
	arch/mips/kernel/i8253.c
	arch/x86/kernel/i8253.c
Reason: Resolve conflicts so further cleanups do not conflict further
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
Diffstat (limited to 'fs/proc/root.c')
| -rw-r--r-- | fs/proc/root.c | 32 | 
1 files changed, 11 insertions, 21 deletions
diff --git a/fs/proc/root.c b/fs/proc/root.c index ef9fa8e24ad6..a9000e9cfee5 100644 --- a/fs/proc/root.c +++ b/fs/proc/root.c @@ -43,17 +43,6 @@ static struct dentry *proc_mount(struct file_system_type *fs_type,  	struct pid_namespace *ns;  	struct proc_inode *ei; -	if (proc_mnt) { -		/* Seed the root directory with a pid so it doesn't need -		 * to be special in base.c.  I would do this earlier but -		 * the only task alive when /proc is mounted the first time -		 * is the init_task and it doesn't have any pids. -		 */ -		ei = PROC_I(proc_mnt->mnt_sb->s_root->d_inode); -		if (!ei->pid) -			ei->pid = find_get_pid(1); -	} -  	if (flags & MS_KERNMOUNT)  		ns = (struct pid_namespace *)data;  	else @@ -71,16 +60,16 @@ static struct dentry *proc_mount(struct file_system_type *fs_type,  			return ERR_PTR(err);  		} -		ei = PROC_I(sb->s_root->d_inode); -		if (!ei->pid) { -			rcu_read_lock(); -			ei->pid = get_pid(find_pid_ns(1, ns)); -			rcu_read_unlock(); -		} -  		sb->s_flags |= MS_ACTIVE;  	} +	ei = PROC_I(sb->s_root->d_inode); +	if (!ei->pid) { +		rcu_read_lock(); +		ei->pid = get_pid(find_pid_ns(1, ns)); +		rcu_read_unlock(); +	} +  	return dget(sb->s_root);  } @@ -101,19 +90,20 @@ static struct file_system_type proc_fs_type = {  void __init proc_root_init(void)  { +	struct vfsmount *mnt;  	int err;  	proc_init_inodecache();  	err = register_filesystem(&proc_fs_type);  	if (err)  		return; -	proc_mnt = kern_mount_data(&proc_fs_type, &init_pid_ns); -	if (IS_ERR(proc_mnt)) { +	mnt = kern_mount_data(&proc_fs_type, &init_pid_ns); +	if (IS_ERR(mnt)) {  		unregister_filesystem(&proc_fs_type);  		return;  	} -	init_pid_ns.proc_mnt = proc_mnt; +	init_pid_ns.proc_mnt = mnt;  	proc_symlink("mounts", NULL, "self/mounts");  	proc_net_init();  | 
