fs/proc/proc_devtree.c: remove empty /proc/device-tree when no openfirmware exists.
Distribution kernels might want to build in support for /proc/device-tree
for kernels that might end up running on hardware that doesn't support
openfirmware. This results in an empty /proc/device-tree existing.
Remove it if the OFW root node doesn't exist.
This situation actually confuses grub2, resulting in install failures.
grub2 sees the /proc/device-tree and picks the wrong install target cf.
grub should be more robust, but still, leaving an empty proc dir seems
Signed-off-by: Dave Jones <firstname.lastname@example.org>
Cc: Al Viro <viro@ZenIV.linux.org.uk>
Cc: Paul Mackerras <email@example.com>
Cc: Josh Boyer <firstname.lastname@example.org>
Cc: Benjamin Herrenschmidt <email@example.com>
Signed-off-by: Andrew Morton <firstname.lastname@example.org>
Signed-off-by: Linus Torvalds <email@example.com>
1 file changed