2 * This file is subject to the terms and conditions of the GNU General Public
3 * License. See the file "COPYING" in the main directory of this archive
6 * Copyright (C) 2006 MIPS Technologies, Inc.
7 * written by Ralf Baechle <ralf@linux-mips.org>
10 #include <linux/init.h>
11 #include <linux/platform_device.h>
12 #include <linux/mtd/partitions.h>
13 #include <linux/mtd/physmap.h>
14 #include <mtd/mtd-abi.h>
16 static struct mtd_partition sead3_mtd_partitions
[] = {
22 .name
= "Board Config",
25 .mask_flags
= MTD_WRITEABLE
29 static struct physmap_flash_data sead3_flash_data
= {
31 .nr_parts
= ARRAY_SIZE(sead3_mtd_partitions
),
32 .parts
= sead3_mtd_partitions
35 static struct resource sead3_flash_resource
= {
38 .flags
= IORESOURCE_MEM
41 static struct platform_device sead3_flash
= {
42 .name
= "physmap-flash",
45 .platform_data
= &sead3_flash_data
,
48 .resource
= &sead3_flash_resource
,
51 static int __init
sead3_mtd_init(void)
53 platform_device_register(&sead3_flash
);
58 module_init(sead3_mtd_init
)