68d0d67
Bugzilla: 818378
68d0d67
Upstream-status: Sent upstream by Davej in 2012.  Pinged again on Dec 17, 2013
68d0d67
Dave Jones 6a501c4
diff --git a/fs/proc/proc_devtree.c b/fs/proc/proc_devtree.c
Dave Jones 6a501c4
index 927cbd1..f060f28 100644
Dave Jones 6a501c4
--- a/fs/proc/proc_devtree.c
Dave Jones 6a501c4
+++ b/fs/proc/proc_devtree.c
Dave Jones 6a501c4
@@ -233,6 +233,7 @@ void __init proc_device_tree_init(void)
Dave Jones 6a501c4
 		return;
Dave Jones 6a501c4
 	root = of_find_node_by_path("/");
Dave Jones 6a501c4
 	if (root == NULL) {
Dave Jones 6a501c4
+		remove_proc_entry("device-tree", NULL);
Dave Jones 6a501c4
 		pr_debug("/proc/device-tree: can't find root\n");
Dave Jones 6a501c4
 		return;
Dave Jones 6a501c4
 	}