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>
Sat, 14 Jan 2012 22:16:27 +0000 (00:16 +0200)
this will avoid needing to handle it in drivers.

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

index f7811f4..f2eb88a 100644 (file)
@@ -600,6 +600,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")
        .atag_offset    = 0x100,
        .reserve        = omap_reserve,