Subject: [PATCH] Remove dead code now that proc_root_follow_link works. From: Eric W. Biederman Date: 1129565889 -0600 --- fs/proc/inode.c | 31 ------------------------------- fs/proc/root.c | 7 ------- include/linux/pspace.h | 6 ------ 3 files changed, 0 insertions(+), 44 deletions(-) de317b4025cd535de1a35d0aa8b94f61e9e61f86 diff --git a/fs/proc/inode.c b/fs/proc/inode.c index a55513b..d620da9 100644 --- a/fs/proc/inode.c +++ b/fs/proc/inode.c @@ -188,33 +188,6 @@ out_fail: goto out; } -#if 0 -static int do_proc_pspace_root_dentry(struct super_block *sb, struct pspace *pspace) -{ - struct inode *root_inode; - struct dentry *root; - root_inode = iget(sb, PROC_ROOT_INO); - if (!root_inode) - goto out_no_root; - - root = d_alloc_root(root_inode); - if (!root) - goto out_no_root; - root->d_fsdata = pspace; - pspace->proc_root = root; - return 0; - out_no_root: - iput(root_inode); - return -ENOMEM; - -} - -int proc_pspace_root_dentry(struct pspace *pspace) -{ - return do_proc_pspace_root_dentry(proc_sb(), pspace); -} -#endif - int proc_fill_super(struct super_block *s, void *data, int silent) { struct inode * root_inode; @@ -238,10 +211,6 @@ int proc_fill_super(struct super_block * if (!s->s_root) goto out_no_root; -#if 0 - if (do_proc_pspace_root_dentry(s, &init_pspace)) - goto out_no_root; -#endif return 0; out_no_root: diff --git a/fs/proc/root.c b/fs/proc/root.c index a20bd22..1e51a7c 100644 --- a/fs/proc/root.c +++ b/fs/proc/root.c @@ -40,13 +40,6 @@ static struct file_system_type proc_fs_t .kill_sb = kill_anon_super, }; -#if 0 -struct super_block *proc_sb(void) -{ - return get_sb_single(&proc_fs_type, 0, NULL, proc_fill_super); -} -#endif - extern int __init proc_init_inodecache(void); void __init proc_root_init(void) { diff --git a/include/linux/pspace.h b/include/linux/pspace.h index 3d61ba8..4ad74c7 100644 --- a/include/linux/pspace.h +++ b/include/linux/pspace.h @@ -12,16 +12,10 @@ struct pidmap #define PIDMAP_ENTRIES ((PID_MAX_LIMIT + 8*PAGE_SIZE - 1)/PAGE_SIZE/8) -#if 0 -struct dentry; -#endif struct pspace { atomic_t count; struct pspace *parent; -#if 0 - struct dentry *proc_root; -#endif int nr_threads; int last_pid; int offset; -- 1.0.GIT