pandora: create proc entry early
authorGrazvydas Ignotas <notasas@gmail.com>
Tue, 22 Jun 2010 20:40:52 +0000 (23:40 +0300)
committerGrazvydas Ignotas <notasas@gmail.com>
Fri, 3 Jun 2011 22:29:28 +0000 (01:29 +0300)
this will avoid needing to handle it in drivers.

arch/arm/mach-omap2/board-omap3pandora.c

index dd8b403..577483c 100644 (file)
@@ -727,6 +727,22 @@ static void __init omap3pandora_init(void)
        omap_mux_init_signal("sdrc_cke1", OMAP_PIN_OUTPUT);
 }
 
+/* HACK: create it here, so that others don't need to bother */
+#ifdef CONFIG_PROC_FS
+#include <linux/proc_fs.h>
+
+static int __init proc_pandora_init(void)
+{
+       struct proc_dir_entry *ret;
+
+       ret = proc_mkdir("pandora", NULL);
+       if (!ret)
+               return -ENOMEM;
+       return 0;
+}
+fs_initcall(proc_pandora_init);
+#endif
+
 MACHINE_START(OMAP3_PANDORA, "Pandora Handheld Console")
        .boot_params    = 0x80000100,
        .map_io         = omap3_map_io,