patch-2.1.122 linux/fs/super.c

Next file: linux/fs/sysv/balloc.c
Previous file: linux/fs/proc/array.c
Back to the patch index
Back to the overall index

diff -u --recursive --new-file v2.1.121/linux/fs/super.c linux/fs/super.c
@@ -1226,9 +1226,7 @@
 
 #ifdef CONFIG_BLK_DEV_INITRD
 
-extern int initmem_freed;
-
-static int __init do_change_root(kdev_t new_root_dev,const char *put_old)
+int __init change_root(kdev_t new_root_dev,const char *put_old)
 {
 	kdev_t old_root_dev;
 	struct vfsmount *vfsmnt;
@@ -1248,7 +1246,7 @@
 	dput(old_pwd);
 #if 1
 	shrink_dcache();
-	printk("do_change_root: old root has d_count=%d\n", old_root->d_count);
+	printk("change_root: old root has d_count=%d\n", old_root->d_count);
 #endif
 	/*
 	 * Get the new mount directory
@@ -1291,15 +1289,6 @@
 	}
 	printk(KERN_CRIT "Trouble: add_vfsmnt failed\n");
 	return -ENOMEM;
-}
-
-int change_root(kdev_t new_root_dev,const char *put_old)
-{
-	if (initmem_freed) {
-		printk (KERN_CRIT "Initmem has been already freed. Staying in initrd\n");
-		return -EBUSY;
-	}
-	return do_change_root(new_root_dev, put_old);
 }
 
 #endif

FUNET's LINUX-ADM group, linux-adm@nic.funet.fi
TCL-scripts by Sam Shen, slshen@lbl.gov