ar71xx: use the tp-link parser on the tp-link boards
[openwrt/openwrt.git] / target / linux / ar71xx / files / arch / mips / ar71xx / mach-tl-mr3x20.c
index ee1a4b6a117c4405a501efaf25988298241c0556..2869e3933cf0332a1be0b32cbeffef901fc6c812 100644 (file)
@@ -9,8 +9,6 @@
  */
 
 #include <linux/gpio.h>
-#include <linux/mtd/mtd.h>
-#include <linux/mtd/partitions.h>
 
 #include <asm/mach-ar71xx/ar71xx.h>
 
 #define TL_MR3X20_KEYS_POLL_INTERVAL   20      /* msecs */
 #define TL_MR3X20_KEYS_DEBOUNCE_INTERVAL (3 * TL_MR3X20_KEYS_POLL_INTERVAL)
 
-#ifdef CONFIG_MTD_PARTITIONS
-static struct mtd_partition tl_mr3x20_partitions[] = {
-       {
-               .name           = "u-boot",
-               .offset         = 0,
-               .size           = 0x020000,
-               .mask_flags     = MTD_WRITEABLE,
-       }, {
-               .name           = "kernel",
-               .offset         = 0x020000,
-               .size           = 0x140000,
-       }, {
-               .name           = "rootfs",
-               .offset         = 0x160000,
-               .size           = 0x290000,
-       }, {
-               .name           = "art",
-               .offset         = 0x3f0000,
-               .size           = 0x010000,
-               .mask_flags     = MTD_WRITEABLE,
-       }, {
-               .name           = "firmware",
-               .offset         = 0x020000,
-               .size           = 0x3d0000,
-       }
+static const char *tl_mr3x20_part_probes[] = {
+       "tp-link",
+       NULL,
 };
-#define tl_mr3x20_num_partitions       ARRAY_SIZE(tl_mr3x20_partitions)
-#else
-#define tl_mr3x20_partitions           NULL
-#define tl_mr3x20_num_partitions       0
-#endif /* CONFIG_MTD_PARTITIONS */
 
 static struct flash_platform_data tl_mr3x20_flash_data = {
-       .parts          = tl_mr3x20_partitions,
-       .nr_parts       = tl_mr3x20_num_partitions,
+       .part_probes    = tl_mr3x20_part_probes,
 };
 
 static struct gpio_led tl_mr3x20_leds_gpio[] __initdata = {