2 * Sparklan WCR-150GN board support
4 * Copyright (C) 2010 Roman Yeryomin <roman@advem.lv>
6 * This program is free software; you can redistribute it and/or modify it
7 * under the terms of the GNU General Public License version 2 as published
8 * by the Free Software Foundation.
11 #include <linux/init.h>
12 #include <linux/platform_device.h>
13 #include <linux/mtd/mtd.h>
14 #include <linux/mtd/partitions.h>
15 #include <linux/mtd/physmap.h>
17 #include <asm/mach-ralink/machine.h>
18 #include <asm/mach-ralink/dev-gpio-buttons.h>
19 #include <asm/mach-ralink/dev-gpio-leds.h>
20 #include <asm/mach-ralink/rt305x.h>
21 #include <asm/mach-ralink/rt305x_regs.h>
25 #ifdef CONFIG_MTD_PARTITIONS
26 static struct mtd_partition wcr150gn_partitions
[] = {
31 .mask_flags
= MTD_WRITEABLE
,
50 #endif /* CONFIG_MTD_PARTITIONS */
52 static struct physmap_flash_data wcr150gn_flash_data
= {
53 #ifdef CONFIG_MTD_PARTITIONS
54 .nr_parts
= ARRAY_SIZE(wcr150gn_partitions
),
55 .parts
= wcr150gn_partitions
,
59 static void __init
wcr150gn_init(void)
61 rt305x_gpio_init(RT305X_GPIO_MODE_GPIO
<< RT305X_GPIO_MODE_UART0_SHIFT
);
62 rt305x_register_flash(0, &wcr150gn_flash_data
);
63 rt305x_register_ethernet();
64 rt305x_register_wifi();
67 MIPS_MACHINE(RAMIPS_MACH_WCR150GN
, "WCR150GN", "Sparklan WCR-150GN",