@@ -50,73 +50,6 @@ static struct platform_device smc911x_device = {
5050 },
5151};
5252
53- static const char * probes [] = { "cmdlinepart" , NULL };
54-
55- static struct mtd_partition * parsed_partitions ;
56-
57- static struct mtd_partition rsk7203_partitions [] = {
58- {
59- .name = "Bootloader" ,
60- .offset = 0x00000000 ,
61- .size = 0x00040000 ,
62- .mask_flags = MTD_WRITEABLE ,
63- }, {
64- .name = "Kernel" ,
65- .offset = MTDPART_OFS_NXTBLK ,
66- .size = 0x001c0000 ,
67- }, {
68- .name = "Flash_FS" ,
69- .offset = MTDPART_OFS_NXTBLK ,
70- .size = MTDPART_SIZ_FULL ,
71- }
72- };
73-
74- static struct physmap_flash_data flash_data = {
75- .width = 2 ,
76- };
77-
78- static struct resource flash_resource = {
79- .start = 0x20000000 ,
80- .end = 0x20400000 ,
81- .flags = IORESOURCE_MEM ,
82- };
83-
84- static struct platform_device flash_device = {
85- .name = "physmap-flash" ,
86- .id = -1 ,
87- .resource = & flash_resource ,
88- .num_resources = 1 ,
89- .dev = {
90- .platform_data = & flash_data ,
91- },
92- };
93-
94- static struct mtd_info * flash_mtd ;
95-
96- static struct map_info rsk7203_flash_map = {
97- .name = "RSK+ Flash" ,
98- .size = 0x400000 ,
99- .bankwidth = 2 ,
100- };
101-
102- static void __init set_mtd_partitions (void )
103- {
104- int nr_parts = 0 ;
105-
106- simple_map_init (& rsk7203_flash_map );
107- flash_mtd = do_map_probe ("cfi_probe" , & rsk7203_flash_map );
108- nr_parts = parse_mtd_partitions (flash_mtd , probes ,
109- & parsed_partitions , 0 );
110- /* If there is no partition table, used the hard coded table */
111- if (nr_parts <= 0 ) {
112- flash_data .parts = rsk7203_partitions ;
113- flash_data .nr_parts = ARRAY_SIZE (rsk7203_partitions );
114- } else {
115- flash_data .nr_parts = nr_parts ;
116- flash_data .parts = parsed_partitions ;
117- }
118- }
119-
12053static struct gpio_led rsk7203_gpio_leds [] = {
12154 {
12255 .name = "green" ,
@@ -155,7 +88,6 @@ static struct platform_device led_device = {
15588
15689static struct platform_device * rsk7203_devices [] __initdata = {
15790 & smc911x_device ,
158- & flash_device ,
15991 & led_device ,
16092};
16193
@@ -165,15 +97,7 @@ static int __init rsk7203_devices_setup(void)
16597 gpio_request (GPIO_FN_TXD0 , NULL );
16698 gpio_request (GPIO_FN_RXD0 , NULL );
16799
168- set_mtd_partitions ();
169100 return platform_add_devices (rsk7203_devices ,
170101 ARRAY_SIZE (rsk7203_devices ));
171102}
172103device_initcall (rsk7203_devices_setup );
173-
174- /*
175- * The Machine Vector
176- */
177- static struct sh_machine_vector mv_rsk7203 __initmv = {
178- .mv_name = "RSK+7203" ,
179- };
0 commit comments