]> pilppa.com Git - linux-2.6-omap-h63xx.git/commitdiff
ARM: OMAP: Add board-nokia770.c
authorJuha Yrjola <juha.yrjola@nokia.com>
Wed, 8 Feb 2006 16:54:10 +0000 (18:54 +0200)
committerJuha Yrjola <juha.yrjola@nokia.com>
Wed, 8 Feb 2006 16:54:10 +0000 (18:54 +0200)
Signed-off-by: Juha Yrjölä <juha.yrjola@nokia.com>
arch/arm/configs/n770_defconfig
arch/arm/mach-omap1/Kconfig
arch/arm/mach-omap1/Makefile
arch/arm/mach-omap1/board-nokia770.c [new file with mode: 0644]

index b8b7f9c8d9ecd5009afb546a887637d0abeccf79..c1e2b57eb34c57541a00d8f1b31b449f38b799e0 100644 (file)
@@ -1,7 +1,7 @@
 #
 # Automatically generated make config: don't edit
 # Linux kernel version: 2.6.16-rc2-omap1
-# Wed Feb  8 18:02:17 2006
+# Wed Feb  8 18:52:38 2006
 #
 CONFIG_ARM=y
 CONFIG_MMU=y
@@ -145,7 +145,8 @@ CONFIG_ARCH_OMAP16XX=y
 # CONFIG_MACH_OMAP_H2 is not set
 # CONFIG_MACH_OMAP_H3 is not set
 # CONFIG_MACH_OMAP_OSK is not set
-CONFIG_MACH_OMAP_GENERIC=y
+CONFIG_MACH_NOKIA770=y
+# CONFIG_MACH_OMAP_GENERIC is not set
 
 #
 # OMAP CPU Speed
index e89e4fd6c5171ef8b4d52f23777ba0dfc1bfcfec..0cad7be2c43d4e87629e868add298f89118da210 100644 (file)
@@ -80,6 +80,13 @@ config MACH_OMAP_PALMTE
           informations.
           Say Y here if you have such a PDA, say NO otherwise.
 
+config MACH_NOKIA770
+       bool "Nokia 770"
+       depends on ARCH_OMAP1 && ARCH_OMAP16XX
+       help
+         Support for the Nokia 770 Internet Tablet. Say Y here if you
+         have such a device.
+
 config MACH_OMAP_GENERIC
        bool "Generic OMAP board"
        depends on ARCH_OMAP1 && (ARCH_OMAP15XX || ARCH_OMAP16XX)
index fe6598d18e098c4346813e6c20c1ae244e6a6690..5e0e023af7e8d2e416696e897f4251dd155daf4a 100644 (file)
@@ -21,6 +21,7 @@ obj-$(CONFIG_MACH_OMAP_OSK)           += board-osk.o
 obj-$(CONFIG_MACH_OMAP_H3)             += board-h3.o
 obj-$(CONFIG_MACH_VOICEBLUE)           += board-voiceblue.o
 obj-$(CONFIG_MACH_OMAP_PALMTE)         += board-palmte.o
+obj-$(CONFIG_MACH_NOKIA770)            += board-nokia770.o
 
 ifeq ($(CONFIG_ARCH_OMAP15XX),y)
 # Innovator-1510 FPGA
diff --git a/arch/arm/mach-omap1/board-nokia770.c b/arch/arm/mach-omap1/board-nokia770.c
new file mode 100644 (file)
index 0000000..5438de3
--- /dev/null
@@ -0,0 +1,91 @@
+/*
+ * linux/arch/arm/mach-omap1/board-nokia770.c
+ *
+ * Modified from board-generic.c
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License version 2 as
+ * published by the Free Software Foundation.
+ */
+
+#include <linux/kernel.h>
+#include <linux/init.h>
+#include <linux/platform_device.h>
+#include <linux/spi/spi.h>
+
+#include <asm/hardware.h>
+#include <asm/mach-types.h>
+#include <asm/mach/arch.h>
+#include <asm/mach/map.h>
+
+#include <asm/arch/gpio.h>
+#include <asm/arch/mux.h>
+#include <asm/arch/usb.h>
+#include <asm/arch/board.h>
+#include <asm/arch/common.h>
+
+static void __init omap_nokia770_init_irq(void)
+{
+       omap1_init_common_hw();
+       omap_init_irq();
+}
+
+static struct platform_device *nokia770_devices[] __initdata = {
+};
+
+/* assume no Mini-AB port */
+
+static struct omap_usb_config nokia770_usb_config __initdata = {
+       .otg            = 1,
+       .register_host  = 1,
+       .register_dev   = 1,
+       .hmc_mode       = 16,
+       .pins[0]        = 6,
+};
+
+static struct omap_mmc_config nokia770_mmc_config __initdata = {
+       .mmc[0] = {
+               .enabled        = 0,
+               .wire4          = 0,
+               .wp_pin         = -1,
+               .power_pin      = -1,
+               .switch_pin     = -1,
+       },
+       .mmc[1] = {
+               .enabled        = 0,
+               .wire4          = 0,
+               .wp_pin         = -1,
+               .power_pin      = -1,
+               .switch_pin     = -1,
+       },
+};
+
+static struct omap_board_config_kernel nokia770_config[] = {
+       { OMAP_TAG_USB,         NULL },
+       { OMAP_TAG_MMC,         &nokia770_mmc_config },
+};
+
+static void __init omap_nokia770_init(void)
+{
+       nokia770_config[0].data = &nokia770_usb_config;
+
+       platform_add_devices(nokia770_devices, ARRAY_SIZE(nokia770_devices));
+       omap_board_config = nokia770_config;
+       omap_board_config_size = ARRAY_SIZE(nokia770_config);
+       omap_serial_init();
+}
+
+static void __init omap_nokia770_map_io(void)
+{
+       omap1_map_common_io();
+}
+
+MACHINE_START(NOKIA770, "Nokia 770")
+       .phys_io        = 0xfff00000,
+       .io_pg_offst    = ((0xfef00000) >> 18) & 0xfffc,
+       .boot_params    = 0x10000100,
+       .map_io         = omap_nokia770_map_io,
+       .init_irq       = omap_nokia770_init_irq,
+       .init_machine   = omap_nokia770_init,
+       .timer          = &omap_timer,
+MACHINE_END