blob: f4bbe5d2fa5b4c6cab5ee115217fcbffc43711b4 [file] [log] [blame]
Linus Walleijed781d392012-05-03 00:44:52 +02001
Srinidhi Kasagaraa44ef42009-11-28 08:17:18 +01002/*
3 * Copyright (C) 2008-2009 ST-Ericsson
4 *
5 * Author: Srinidhi KASAGAR <srinidhi.kasagar@stericsson.com>
6 *
7 * This program is free software; you can redistribute it and/or modify
8 * it under the terms of the GNU General Public License version 2, as
9 * published by the Free Software Foundation.
10 *
11 */
12#include <linux/kernel.h>
13#include <linux/init.h>
14#include <linux/interrupt.h>
15#include <linux/platform_device.h>
16#include <linux/io.h>
Rabin Vincentb8410a12010-08-09 19:18:17 +053017#include <linux/i2c.h>
Rabin Vincentea05a572010-06-03 07:58:42 +010018#include <linux/gpio.h>
Srinidhi Kasagaraa44ef42009-11-28 08:17:18 +010019#include <linux/amba/bus.h>
20#include <linux/amba/pl022.h>
Linus Walleij5d7b8462010-10-14 13:57:59 +020021#include <linux/amba/serial.h>
Srinidhi Kasagaraa44ef42009-11-28 08:17:18 +010022#include <linux/spi/spi.h>
Linus Walleijee66e652011-12-02 14:16:33 +010023#include <linux/mfd/abx500/ab8500.h>
Bengt Jonsson79568b942011-03-11 11:54:46 +010024#include <linux/regulator/ab8500.h>
Sundar Iyer20406eb2010-12-13 09:33:14 +053025#include <linux/mfd/tc3589x.h>
Linus Walleijfe67dfc2011-03-07 11:48:15 +010026#include <linux/mfd/tps6105x.h>
Linus Walleijee66e652011-12-02 14:16:33 +010027#include <linux/mfd/abx500/ab8500-gpio.h>
Philippe Langlaisdd7b2a02011-01-12 11:26:20 +010028#include <linux/leds-lp5521.h>
Philippe Langlaisa71b8192011-01-14 10:53:59 +010029#include <linux/input.h>
Robert Marklund350abe02011-06-20 15:55:46 +020030#include <linux/smsc911x.h>
Philippe Langlaisa71b8192011-01-14 10:53:59 +010031#include <linux/gpio_keys.h>
Shreshtha Kumar Sahu1a7d4362011-06-13 10:11:44 +020032#include <linux/delay.h>
Arnd Bergmann2d334292012-03-07 15:04:07 +000033#include <linux/of.h>
34#include <linux/of_platform.h>
Robert Marklund350abe02011-06-20 15:55:46 +020035#include <linux/leds.h>
Linus Walleija0980662012-05-07 01:33:24 +020036#include <linux/pinctrl/consumer.h>
37
Srinidhi Kasagaraa44ef42009-11-28 08:17:18 +010038#include <asm/mach-types.h>
39#include <asm/mach/arch.h>
Marc Zyngierbbf5f382011-09-06 10:23:45 +010040#include <asm/hardware/gic.h>
Srinidhi Kasagaraa44ef42009-11-28 08:17:18 +010041
Srinidhi Kasagard48a41c2010-02-03 13:02:48 +010042#include <plat/i2c.h>
Linus Walleij5d7b8462010-10-14 13:57:59 +020043#include <plat/ste_dma40.h>
Linus Walleij0f332862011-08-22 08:33:30 +010044#include <plat/gpio-nomadik.h>
Srinidhi Kasagaraa44ef42009-11-28 08:17:18 +010045
46#include <mach/hardware.h>
47#include <mach/setup.h>
Rabin Vincent9e4e7fe2010-05-03 08:03:52 +010048#include <mach/devices.h>
Linus Walleij29aeb3c2010-09-06 22:15:08 +010049#include <mach/irqs.h>
Andreas Westin585d1882012-05-10 10:14:06 +020050#include <mach/crypto-ux500.h>
Srinidhi Kasagaraa44ef42009-11-28 08:17:18 +010051
Linus Walleij5d7b8462010-10-14 13:57:59 +020052#include "ste-dma40-db8500.h"
Rabin Vincentfbf1ead2010-09-29 19:46:32 +053053#include "devices-db8500.h"
Hanumath Prasad008f8a22010-08-19 12:06:32 +010054#include "board-mop500.h"
Bengt Jonssona1e516e2010-12-10 11:08:48 +010055#include "board-mop500-regulators.h"
Ola Liljac0af14d2012-04-20 11:32:59 +020056#include "board-mop500-msp.h"
Rabin Vincentea05a572010-06-03 07:58:42 +010057
Robert Marklund350abe02011-06-20 15:55:46 +020058static struct gpio_led snowball_led_array[] = {
59 {
60 .name = "user_led",
61 .default_trigger = "none",
62 .gpio = 142,
63 },
64};
65
66static struct gpio_led_platform_data snowball_led_data = {
67 .leds = snowball_led_array,
68 .num_leds = ARRAY_SIZE(snowball_led_array),
69};
70
71static struct platform_device snowball_led_dev = {
72 .name = "leds-gpio",
73 .dev = {
74 .platform_data = &snowball_led_data,
75 },
76};
77
Bibek Basu3ef374a2011-02-15 12:56:16 +053078static struct ab8500_gpio_platform_data ab8500_gpio_pdata = {
Philippe Langlaisa1524ee2012-02-13 10:52:25 +010079 .gpio_base = MOP500_AB8500_PIN_GPIO(1),
Bibek Basu3ef374a2011-02-15 12:56:16 +053080 .irq_base = MOP500_AB8500_VIR_GPIO_IRQ_BASE,
81 /* config_reg is the initial configuration of ab8500 pins.
82 * The pins can be configured as GPIO or alt functions based
83 * on value present in GpioSel1 to GpioSel6 and AlternatFunction
84 * register. This is the array of 7 configuration settings.
85 * One has to compile time decide these settings. Below is the
Lucas De Marchi25985ed2011-03-30 22:57:33 -030086 * explanation of these setting
Bibek Basu3ef374a2011-02-15 12:56:16 +053087 * GpioSel1 = 0x00 => Pins GPIO1 to GPIO8 are not used as GPIO
88 * GpioSel2 = 0x1E => Pins GPIO10 to GPIO13 are configured as GPIO
89 * GpioSel3 = 0x80 => Pin GPIO24 is configured as GPIO
90 * GpioSel4 = 0x01 => Pin GPIo25 is configured as GPIO
91 * GpioSel5 = 0x7A => Pins GPIO34, GPIO36 to GPIO39 are conf as GPIO
92 * GpioSel6 = 0x00 => Pins GPIO41 & GPIo42 are not configured as GPIO
93 * AlternaFunction = 0x00 => If Pins GPIO10 to 13 are not configured
94 * as GPIO then this register selectes the alternate fucntions
95 */
96 .config_reg = {0x00, 0x1E, 0x80, 0x01,
97 0x7A, 0x00, 0x00},
98};
99
Robert Marklund350abe02011-06-20 15:55:46 +0200100static struct gpio_keys_button snowball_key_array[] = {
101 {
102 .gpio = 32,
103 .type = EV_KEY,
104 .code = KEY_1,
105 .desc = "userpb",
106 .active_low = 1,
107 .debounce_interval = 50,
108 .wakeup = 1,
109 },
110 {
111 .gpio = 151,
112 .type = EV_KEY,
113 .code = KEY_2,
114 .desc = "extkb1",
115 .active_low = 1,
116 .debounce_interval = 50,
117 .wakeup = 1,
118 },
119 {
120 .gpio = 152,
121 .type = EV_KEY,
122 .code = KEY_3,
123 .desc = "extkb2",
124 .active_low = 1,
125 .debounce_interval = 50,
126 .wakeup = 1,
127 },
128 {
129 .gpio = 161,
130 .type = EV_KEY,
131 .code = KEY_4,
132 .desc = "extkb3",
133 .active_low = 1,
134 .debounce_interval = 50,
135 .wakeup = 1,
136 },
137 {
138 .gpio = 162,
139 .type = EV_KEY,
140 .code = KEY_5,
141 .desc = "extkb4",
142 .active_low = 1,
143 .debounce_interval = 50,
144 .wakeup = 1,
145 },
146};
147
148static struct gpio_keys_platform_data snowball_key_data = {
149 .buttons = snowball_key_array,
150 .nbuttons = ARRAY_SIZE(snowball_key_array),
151};
152
153static struct platform_device snowball_key_dev = {
154 .name = "gpio-keys",
155 .id = -1,
156 .dev = {
157 .platform_data = &snowball_key_data,
158 }
159};
160
161static struct smsc911x_platform_config snowball_sbnet_cfg = {
162 .irq_polarity = SMSC911X_IRQ_POLARITY_ACTIVE_HIGH,
163 .irq_type = SMSC911X_IRQ_TYPE_PUSH_PULL,
164 .flags = SMSC911X_USE_16BIT | SMSC911X_FORCE_INTERNAL_PHY,
165 .shift = 1,
166};
167
168static struct resource sbnet_res[] = {
169 {
170 .name = "smsc911x-memory",
171 .start = (0x5000 << 16),
172 .end = (0x5000 << 16) + 0xffff,
173 .flags = IORESOURCE_MEM,
174 },
175 {
176 .start = NOMADIK_GPIO_TO_IRQ(140),
177 .end = NOMADIK_GPIO_TO_IRQ(140),
178 .flags = IORESOURCE_IRQ | IORESOURCE_IRQ_HIGHEDGE,
179 },
180};
181
182static struct platform_device snowball_sbnet_dev = {
183 .name = "smsc911x",
184 .num_resources = ARRAY_SIZE(sbnet_res),
185 .resource = sbnet_res,
186 .dev = {
187 .platform_data = &snowball_sbnet_cfg,
188 },
189};
190
Rabin Vincent39ae7022010-07-26 11:12:15 +0100191static struct ab8500_platform_data ab8500_platdata = {
192 .irq_base = MOP500_AB8500_IRQ_BASE,
Bengt Jonssondfa3a822011-03-09 13:34:17 +0100193 .regulator_reg_init = ab8500_regulator_reg_init,
194 .num_regulator_reg_init = ARRAY_SIZE(ab8500_regulator_reg_init),
Bengt Jonssona1e516e2010-12-10 11:08:48 +0100195 .regulator = ab8500_regulators,
196 .num_regulator = ARRAY_SIZE(ab8500_regulators),
Bibek Basu3ef374a2011-02-15 12:56:16 +0530197 .gpio = &ab8500_gpio_pdata,
Rabin Vincent39ae7022010-07-26 11:12:15 +0100198};
199
Linus Walleij29aeb3c2010-09-06 22:15:08 +0100200static struct resource ab8500_resources[] = {
201 [0] = {
Rabin Vincent22039b72010-12-08 11:07:56 +0530202 .start = IRQ_DB8500_AB8500,
203 .end = IRQ_DB8500_AB8500,
204 .flags = IORESOURCE_IRQ
Linus Walleij29aeb3c2010-09-06 22:15:08 +0100205 }
206};
207
208struct platform_device ab8500_device = {
Lee Jonesd28f1db2012-05-19 17:21:37 +0200209 .name = "ab8500-core",
Linus Walleij29aeb3c2010-09-06 22:15:08 +0100210 .id = 0,
211 .dev = {
212 .platform_data = &ab8500_platdata,
213 },
214 .num_resources = 1,
215 .resource = ab8500_resources,
216};
217
Rabin Vincentb8410a12010-08-09 19:18:17 +0530218/*
Linus Walleijfe67dfc2011-03-07 11:48:15 +0100219 * TPS61052
220 */
221
222static struct tps6105x_platform_data mop500_tps61052_data = {
223 .mode = TPS6105X_MODE_VOLTAGE,
224 .regulator_data = &tps61052_regulator,
225};
226
227/*
Rabin Vincentb8410a12010-08-09 19:18:17 +0530228 * TC35892
229 */
230
Sundar Iyer20406eb2010-12-13 09:33:14 +0530231static void mop500_tc35892_init(struct tc3589x *tc3589x, unsigned int base)
Rabin Vincentb8410a12010-08-09 19:18:17 +0530232{
Lee Jones18403422012-02-06 11:22:21 -0800233 struct device *parent = NULL;
234#if 0
235 /* FIXME: Is the sdi actually part of tc3589x? */
236 parent = tc3589x->dev;
237#endif
238 mop500_sdi_tc35892_init(parent);
Rabin Vincentb8410a12010-08-09 19:18:17 +0530239}
240
Sundar Iyer20406eb2010-12-13 09:33:14 +0530241static struct tc3589x_gpio_platform_data mop500_tc35892_gpio_data = {
Rabin Vincentb8410a12010-08-09 19:18:17 +0530242 .gpio_base = MOP500_EGPIO(0),
243 .setup = mop500_tc35892_init,
244};
245
Sundar Iyer20406eb2010-12-13 09:33:14 +0530246static struct tc3589x_platform_data mop500_tc35892_data = {
Sundar Iyer611b7592010-12-13 09:33:15 +0530247 .block = TC3589x_BLOCK_GPIO,
Rabin Vincentb8410a12010-08-09 19:18:17 +0530248 .gpio = &mop500_tc35892_gpio_data,
249 .irq_base = MOP500_EGPIO_IRQ_BASE,
250};
251
Philippe Langlaisdd7b2a02011-01-12 11:26:20 +0100252static struct lp5521_led_config lp5521_pri_led[] = {
253 [0] = {
254 .chan_nr = 0,
255 .led_current = 0x2f,
256 .max_current = 0x5f,
257 },
258 [1] = {
259 .chan_nr = 1,
260 .led_current = 0x2f,
261 .max_current = 0x5f,
262 },
263 [2] = {
264 .chan_nr = 2,
265 .led_current = 0x2f,
266 .max_current = 0x5f,
267 },
268};
269
270static struct lp5521_platform_data __initdata lp5521_pri_data = {
271 .label = "lp5521_pri",
272 .led_config = &lp5521_pri_led[0],
273 .num_channels = 3,
274 .clock_mode = LP5521_CLOCK_EXT,
275};
276
277static struct lp5521_led_config lp5521_sec_led[] = {
278 [0] = {
279 .chan_nr = 0,
280 .led_current = 0x2f,
281 .max_current = 0x5f,
282 },
283 [1] = {
284 .chan_nr = 1,
285 .led_current = 0x2f,
286 .max_current = 0x5f,
287 },
288 [2] = {
289 .chan_nr = 2,
290 .led_current = 0x2f,
291 .max_current = 0x5f,
292 },
293};
294
295static struct lp5521_platform_data __initdata lp5521_sec_data = {
296 .label = "lp5521_sec",
297 .led_config = &lp5521_sec_led[0],
298 .num_channels = 3,
299 .clock_mode = LP5521_CLOCK_EXT,
300};
301
Linus Walleijfe67dfc2011-03-07 11:48:15 +0100302static struct i2c_board_info __initdata mop500_i2c0_devices[] = {
Rabin Vincentb8410a12010-08-09 19:18:17 +0530303 {
Sundar Iyer20406eb2010-12-13 09:33:14 +0530304 I2C_BOARD_INFO("tc3589x", 0x42),
Philippe Langlaisdd7b2a02011-01-12 11:26:20 +0100305 .irq = NOMADIK_GPIO_TO_IRQ(217),
Rabin Vincentb8410a12010-08-09 19:18:17 +0530306 .platform_data = &mop500_tc35892_data,
307 },
Linus Walleijcf568c52011-03-30 14:31:42 +0200308 /* I2C0 devices only available prior to HREFv60 */
Linus Walleijfe67dfc2011-03-07 11:48:15 +0100309 {
310 I2C_BOARD_INFO("tps61052", 0x33),
311 .platform_data = &mop500_tps61052_data,
312 },
313};
314
Linus Walleijcf568c52011-03-30 14:31:42 +0200315#define NUM_PRE_V60_I2C0_DEVICES 1
316
Philippe Langlaisdd7b2a02011-01-12 11:26:20 +0100317static struct i2c_board_info __initdata mop500_i2c2_devices[] = {
318 {
319 /* lp5521 LED driver, 1st device */
320 I2C_BOARD_INFO("lp5521", 0x33),
321 .platform_data = &lp5521_pri_data,
322 },
323 {
324 /* lp5521 LED driver, 2st device */
325 I2C_BOARD_INFO("lp5521", 0x34),
326 .platform_data = &lp5521_sec_data,
327 },
Lee Jonesbb3b2182011-01-13 14:41:22 +0000328 {
329 /* Light sensor Rohm BH1780GLI */
330 I2C_BOARD_INFO("bh1780", 0x29),
331 },
Philippe Langlaisdd7b2a02011-01-12 11:26:20 +0100332};
333
Lee Jones18403422012-02-06 11:22:21 -0800334static void __init mop500_i2c_init(struct device *parent)
Rabin Vincentfbf1ead2010-09-29 19:46:32 +0530335{
Lee Jones98582d92012-04-17 15:52:26 +0100336 db8500_add_i2c0(parent, NULL);
337 db8500_add_i2c1(parent, NULL);
338 db8500_add_i2c2(parent, NULL);
339 db8500_add_i2c3(parent, NULL);
Rabin Vincentfbf1ead2010-09-29 19:46:32 +0530340}
Srinidhi Kasagaraa44ef42009-11-28 08:17:18 +0100341
Philippe Langlaisa71b8192011-01-14 10:53:59 +0100342static struct gpio_keys_button mop500_gpio_keys[] = {
343 {
344 .desc = "SFH7741 Proximity Sensor",
345 .type = EV_SW,
346 .code = SW_FRONT_PROXIMITY,
Philippe Langlaisa71b8192011-01-14 10:53:59 +0100347 .active_low = 0,
348 .can_disable = 1,
349 }
350};
351
352static struct regulator *prox_regulator;
353static int mop500_prox_activate(struct device *dev);
354static void mop500_prox_deactivate(struct device *dev);
355
356static struct gpio_keys_platform_data mop500_gpio_keys_data = {
357 .buttons = mop500_gpio_keys,
358 .nbuttons = ARRAY_SIZE(mop500_gpio_keys),
359 .enable = mop500_prox_activate,
360 .disable = mop500_prox_deactivate,
361};
362
363static struct platform_device mop500_gpio_keys_device = {
364 .name = "gpio-keys",
365 .id = 0,
366 .dev = {
367 .platform_data = &mop500_gpio_keys_data,
368 },
369};
370
371static int mop500_prox_activate(struct device *dev)
372{
373 prox_regulator = regulator_get(&mop500_gpio_keys_device.dev,
374 "vcc");
375 if (IS_ERR(prox_regulator)) {
376 dev_err(&mop500_gpio_keys_device.dev,
377 "no regulator\n");
378 return PTR_ERR(prox_regulator);
379 }
380 regulator_enable(prox_regulator);
381 return 0;
382}
383
384static void mop500_prox_deactivate(struct device *dev)
385{
386 regulator_disable(prox_regulator);
387 regulator_put(prox_regulator);
388}
389
Andreas Westin585d1882012-05-10 10:14:06 +0200390static struct cryp_platform_data u8500_cryp1_platform_data = {
391 .mem_to_engine = {
392 .dir = STEDMA40_MEM_TO_PERIPH,
393 .src_dev_type = STEDMA40_DEV_SRC_MEMORY,
394 .dst_dev_type = DB8500_DMA_DEV48_CAC1_TX,
395 .src_info.data_width = STEDMA40_WORD_WIDTH,
396 .dst_info.data_width = STEDMA40_WORD_WIDTH,
397 .mode = STEDMA40_MODE_LOGICAL,
398 .src_info.psize = STEDMA40_PSIZE_LOG_4,
399 .dst_info.psize = STEDMA40_PSIZE_LOG_4,
400 },
401 .engine_to_mem = {
402 .dir = STEDMA40_PERIPH_TO_MEM,
403 .src_dev_type = DB8500_DMA_DEV48_CAC1_RX,
404 .dst_dev_type = STEDMA40_DEV_DST_MEMORY,
405 .src_info.data_width = STEDMA40_WORD_WIDTH,
406 .dst_info.data_width = STEDMA40_WORD_WIDTH,
407 .mode = STEDMA40_MODE_LOGICAL,
408 .src_info.psize = STEDMA40_PSIZE_LOG_4,
409 .dst_info.psize = STEDMA40_PSIZE_LOG_4,
410 }
411};
412
413static struct stedma40_chan_cfg u8500_hash_dma_cfg_tx = {
414 .dir = STEDMA40_MEM_TO_PERIPH,
415 .src_dev_type = STEDMA40_DEV_SRC_MEMORY,
416 .dst_dev_type = DB8500_DMA_DEV50_HAC1_TX,
417 .src_info.data_width = STEDMA40_WORD_WIDTH,
418 .dst_info.data_width = STEDMA40_WORD_WIDTH,
419 .mode = STEDMA40_MODE_LOGICAL,
420 .src_info.psize = STEDMA40_PSIZE_LOG_16,
421 .dst_info.psize = STEDMA40_PSIZE_LOG_16,
422};
423
424static struct hash_platform_data u8500_hash1_platform_data = {
425 .mem_to_engine = &u8500_hash_dma_cfg_tx,
426 .dma_filter = stedma40_filter,
427};
428
Srinidhi Kasagard48a41c2010-02-03 13:02:48 +0100429/* add any platform devices here - TODO */
Robert Marklund350abe02011-06-20 15:55:46 +0200430static struct platform_device *mop500_platform_devs[] __initdata = {
Philippe Langlaisa71b8192011-01-14 10:53:59 +0100431 &mop500_gpio_keys_device,
Robert Marklund350abe02011-06-20 15:55:46 +0200432 &ab8500_device,
Srinidhi Kasagard48a41c2010-02-03 13:02:48 +0100433};
434
Linus Walleij5d7b8462010-10-14 13:57:59 +0200435#ifdef CONFIG_STE_DMA40
436static struct stedma40_chan_cfg ssp0_dma_cfg_rx = {
437 .mode = STEDMA40_MODE_LOGICAL,
438 .dir = STEDMA40_PERIPH_TO_MEM,
439 .src_dev_type = DB8500_DMA_DEV8_SSP0_RX,
440 .dst_dev_type = STEDMA40_DEV_DST_MEMORY,
441 .src_info.data_width = STEDMA40_BYTE_WIDTH,
442 .dst_info.data_width = STEDMA40_BYTE_WIDTH,
443};
444
445static struct stedma40_chan_cfg ssp0_dma_cfg_tx = {
446 .mode = STEDMA40_MODE_LOGICAL,
447 .dir = STEDMA40_MEM_TO_PERIPH,
448 .src_dev_type = STEDMA40_DEV_SRC_MEMORY,
449 .dst_dev_type = DB8500_DMA_DEV8_SSP0_TX,
450 .src_info.data_width = STEDMA40_BYTE_WIDTH,
451 .dst_info.data_width = STEDMA40_BYTE_WIDTH,
452};
453#endif
454
Lee Jones15daf692012-03-15 16:47:11 +0000455static struct pl022_ssp_controller ssp0_plat = {
Linus Walleij5d7b8462010-10-14 13:57:59 +0200456 .bus_id = 0,
457#ifdef CONFIG_STE_DMA40
458 .enable_dma = 1,
459 .dma_filter = stedma40_filter,
460 .dma_rx_param = &ssp0_dma_cfg_rx,
461 .dma_tx_param = &ssp0_dma_cfg_tx,
462#else
463 .enable_dma = 0,
464#endif
465 /* on this platform, gpio 31,142,144,214 &
466 * 224 are connected as chip selects
467 */
468 .num_chipselect = 5,
469};
470
Lee Jones18403422012-02-06 11:22:21 -0800471static void __init mop500_spi_init(struct device *parent)
Rabin Vincentfbf1ead2010-09-29 19:46:32 +0530472{
Lee Jones15daf692012-03-15 16:47:11 +0000473 db8500_add_ssp0(parent, &ssp0_plat);
Rabin Vincentfbf1ead2010-09-29 19:46:32 +0530474}
475
Linus Walleij5d7b8462010-10-14 13:57:59 +0200476#ifdef CONFIG_STE_DMA40
477static struct stedma40_chan_cfg uart0_dma_cfg_rx = {
478 .mode = STEDMA40_MODE_LOGICAL,
479 .dir = STEDMA40_PERIPH_TO_MEM,
480 .src_dev_type = DB8500_DMA_DEV13_UART0_RX,
481 .dst_dev_type = STEDMA40_DEV_DST_MEMORY,
482 .src_info.data_width = STEDMA40_BYTE_WIDTH,
483 .dst_info.data_width = STEDMA40_BYTE_WIDTH,
484};
485
486static struct stedma40_chan_cfg uart0_dma_cfg_tx = {
487 .mode = STEDMA40_MODE_LOGICAL,
488 .dir = STEDMA40_MEM_TO_PERIPH,
489 .src_dev_type = STEDMA40_DEV_SRC_MEMORY,
490 .dst_dev_type = DB8500_DMA_DEV13_UART0_TX,
491 .src_info.data_width = STEDMA40_BYTE_WIDTH,
492 .dst_info.data_width = STEDMA40_BYTE_WIDTH,
493};
494
495static struct stedma40_chan_cfg uart1_dma_cfg_rx = {
496 .mode = STEDMA40_MODE_LOGICAL,
497 .dir = STEDMA40_PERIPH_TO_MEM,
498 .src_dev_type = DB8500_DMA_DEV12_UART1_RX,
499 .dst_dev_type = STEDMA40_DEV_DST_MEMORY,
500 .src_info.data_width = STEDMA40_BYTE_WIDTH,
501 .dst_info.data_width = STEDMA40_BYTE_WIDTH,
502};
503
504static struct stedma40_chan_cfg uart1_dma_cfg_tx = {
505 .mode = STEDMA40_MODE_LOGICAL,
506 .dir = STEDMA40_MEM_TO_PERIPH,
507 .src_dev_type = STEDMA40_DEV_SRC_MEMORY,
508 .dst_dev_type = DB8500_DMA_DEV12_UART1_TX,
509 .src_info.data_width = STEDMA40_BYTE_WIDTH,
510 .dst_info.data_width = STEDMA40_BYTE_WIDTH,
511};
512
513static struct stedma40_chan_cfg uart2_dma_cfg_rx = {
514 .mode = STEDMA40_MODE_LOGICAL,
515 .dir = STEDMA40_PERIPH_TO_MEM,
516 .src_dev_type = DB8500_DMA_DEV11_UART2_RX,
517 .dst_dev_type = STEDMA40_DEV_DST_MEMORY,
518 .src_info.data_width = STEDMA40_BYTE_WIDTH,
519 .dst_info.data_width = STEDMA40_BYTE_WIDTH,
520};
521
522static struct stedma40_chan_cfg uart2_dma_cfg_tx = {
523 .mode = STEDMA40_MODE_LOGICAL,
524 .dir = STEDMA40_MEM_TO_PERIPH,
525 .src_dev_type = STEDMA40_DEV_SRC_MEMORY,
526 .dst_dev_type = DB8500_DMA_DEV11_UART2_TX,
527 .src_info.data_width = STEDMA40_BYTE_WIDTH,
528 .dst_info.data_width = STEDMA40_BYTE_WIDTH,
529};
530#endif
531
Shreshtha Kumar Sahu1a7d4362011-06-13 10:11:44 +0200532#define PRCC_K_SOFTRST_SET 0x18
533#define PRCC_K_SOFTRST_CLEAR 0x1C
534static void ux500_uart0_reset(void)
535{
536 void __iomem *prcc_rst_set, *prcc_rst_clr;
537
538 prcc_rst_set = (void __iomem *)IO_ADDRESS(U8500_CLKRST1_BASE +
539 PRCC_K_SOFTRST_SET);
540 prcc_rst_clr = (void __iomem *)IO_ADDRESS(U8500_CLKRST1_BASE +
541 PRCC_K_SOFTRST_CLEAR);
542
543 /* Activate soft reset PRCC_K_SOFTRST_CLEAR */
544 writel((readl(prcc_rst_clr) | 0x1), prcc_rst_clr);
545 udelay(1);
546
547 /* Release soft reset PRCC_K_SOFTRST_SET */
548 writel((readl(prcc_rst_set) | 0x1), prcc_rst_set);
549 udelay(1);
550}
551
Linus Walleij5d7b8462010-10-14 13:57:59 +0200552static struct amba_pl011_data uart0_plat = {
553#ifdef CONFIG_STE_DMA40
554 .dma_filter = stedma40_filter,
555 .dma_rx_param = &uart0_dma_cfg_rx,
556 .dma_tx_param = &uart0_dma_cfg_tx,
557#endif
Shreshtha Kumar Sahu1a7d4362011-06-13 10:11:44 +0200558 .reset = ux500_uart0_reset,
Linus Walleij5d7b8462010-10-14 13:57:59 +0200559};
560
561static struct amba_pl011_data uart1_plat = {
562#ifdef CONFIG_STE_DMA40
563 .dma_filter = stedma40_filter,
564 .dma_rx_param = &uart1_dma_cfg_rx,
565 .dma_tx_param = &uart1_dma_cfg_tx,
566#endif
567};
568
569static struct amba_pl011_data uart2_plat = {
570#ifdef CONFIG_STE_DMA40
571 .dma_filter = stedma40_filter,
572 .dma_rx_param = &uart2_dma_cfg_rx,
573 .dma_tx_param = &uart2_dma_cfg_tx,
574#endif
575};
576
Lee Jones18403422012-02-06 11:22:21 -0800577static void __init mop500_uart_init(struct device *parent)
Rabin Vincentfbf1ead2010-09-29 19:46:32 +0530578{
Linus Walleij78d80c52012-05-23 21:18:46 +0200579 db8500_add_uart0(parent, &uart0_plat);
Lee Jones18403422012-02-06 11:22:21 -0800580 db8500_add_uart1(parent, &uart1_plat);
581 db8500_add_uart2(parent, &uart2_plat);
Rabin Vincentfbf1ead2010-09-29 19:46:32 +0530582}
583
Andreas Westin585d1882012-05-10 10:14:06 +0200584static void __init u8500_cryp1_hash1_init(struct device *parent)
585{
586 db8500_add_cryp1(parent, &u8500_cryp1_platform_data);
587 db8500_add_hash1(parent, &u8500_hash1_platform_data);
588}
589
Robert Marklund350abe02011-06-20 15:55:46 +0200590static struct platform_device *snowball_platform_devs[] __initdata = {
591 &snowball_led_dev,
592 &snowball_key_dev,
Lee Jonese6fada52012-05-17 13:18:36 +0100593 &snowball_sbnet_dev,
Robert Marklund350abe02011-06-20 15:55:46 +0200594 &ab8500_device,
595};
596
Linus Walleij4b4f7572011-02-15 15:01:35 +0100597static void __init mop500_init_machine(void)
Srinidhi Kasagaraa44ef42009-11-28 08:17:18 +0100598{
Lee Jones18403422012-02-06 11:22:21 -0800599 struct device *parent = NULL;
Linus Walleijcf568c52011-03-30 14:31:42 +0200600 int i2c0_devs;
Lee Jonesb024a0c2012-02-06 11:22:25 -0800601 int i;
Linus Walleijcf568c52011-03-30 14:31:42 +0200602
Lee Jones110c2c22011-08-26 16:54:07 +0100603 mop500_gpio_keys[0].gpio = GPIO_PROX_SENSOR;
Linus Walleij4b4f7572011-02-15 15:01:35 +0100604
Linus Walleijed781d392012-05-03 00:44:52 +0200605 mop500_pinmaps_init();
Lee Jones18403422012-02-06 11:22:21 -0800606 parent = u8500_init_devices();
Rabin Vincentea05a572010-06-03 07:58:42 +0100607
Lee Jones7e0ce272012-03-15 16:46:17 +0000608 /* FIXME: parent of ab8500 should be prcmu */
Lee Jonesb024a0c2012-02-06 11:22:25 -0800609 for (i = 0; i < ARRAY_SIZE(mop500_platform_devs); i++)
610 mop500_platform_devs[i]->dev.parent = parent;
611
Lee Jones110c2c22011-08-26 16:54:07 +0100612 platform_add_devices(mop500_platform_devs,
613 ARRAY_SIZE(mop500_platform_devs));
Srinidhi Kasagard48a41c2010-02-03 13:02:48 +0100614
Lee Jones18403422012-02-06 11:22:21 -0800615 mop500_i2c_init(parent);
616 mop500_sdi_init(parent);
617 mop500_spi_init(parent);
Ola Liljac0af14d2012-04-20 11:32:59 +0200618 mop500_msp_init(parent);
Lee Jones18403422012-02-06 11:22:21 -0800619 mop500_uart_init(parent);
Hanumath Prasad008f8a22010-08-19 12:06:32 +0100620
Andreas Westin585d1882012-05-10 10:14:06 +0200621 u8500_cryp1_hash1_init(parent);
622
Linus Walleijcf568c52011-03-30 14:31:42 +0200623 i2c0_devs = ARRAY_SIZE(mop500_i2c0_devices);
Lee Jones110c2c22011-08-26 16:54:07 +0100624
625 i2c_register_board_info(0, mop500_i2c0_devices, i2c0_devs);
626 i2c_register_board_info(2, mop500_i2c2_devices,
627 ARRAY_SIZE(mop500_i2c2_devices));
628
629 /* This board has full regulator constraints */
630 regulator_has_full_constraints();
Lee Jonesfd6948b2012-05-02 09:53:48 +0100631
632 mop500_uib_init();
Lee Jones110c2c22011-08-26 16:54:07 +0100633}
634
635static void __init snowball_init_machine(void)
636{
Lee Jones18403422012-02-06 11:22:21 -0800637 struct device *parent = NULL;
Lee Jonesb024a0c2012-02-06 11:22:25 -0800638 int i;
Lee Jones110c2c22011-08-26 16:54:07 +0100639
Linus Walleijed781d392012-05-03 00:44:52 +0200640 snowball_pinmaps_init();
Lee Jones18403422012-02-06 11:22:21 -0800641 parent = u8500_init_devices();
Lee Jones110c2c22011-08-26 16:54:07 +0100642
Lee Jonesb024a0c2012-02-06 11:22:25 -0800643 for (i = 0; i < ARRAY_SIZE(snowball_platform_devs); i++)
644 snowball_platform_devs[i]->dev.parent = parent;
645
Lee Jones110c2c22011-08-26 16:54:07 +0100646 platform_add_devices(snowball_platform_devs,
647 ARRAY_SIZE(snowball_platform_devs));
648
Lee Jones18403422012-02-06 11:22:21 -0800649 mop500_i2c_init(parent);
650 snowball_sdi_init(parent);
651 mop500_spi_init(parent);
Ola Liljac0af14d2012-04-20 11:32:59 +0200652 mop500_msp_init(parent);
Lee Jones18403422012-02-06 11:22:21 -0800653 mop500_uart_init(parent);
Lee Jones110c2c22011-08-26 16:54:07 +0100654
Lee Jones110c2c22011-08-26 16:54:07 +0100655 /* This board has full regulator constraints */
656 regulator_has_full_constraints();
657}
658
659static void __init hrefv60_init_machine(void)
660{
Lee Jones18403422012-02-06 11:22:21 -0800661 struct device *parent = NULL;
Lee Jones110c2c22011-08-26 16:54:07 +0100662 int i2c0_devs;
Lee Jonesb024a0c2012-02-06 11:22:25 -0800663 int i;
Lee Jones110c2c22011-08-26 16:54:07 +0100664
665 /*
666 * The HREFv60 board removed a GPIO expander and routed
667 * all these GPIO pins to the internal GPIO controller
668 * instead.
669 */
670 mop500_gpio_keys[0].gpio = HREFV60_PROX_SENSE_GPIO;
671
Linus Walleijed781d392012-05-03 00:44:52 +0200672 hrefv60_pinmaps_init();
Lee Jones18403422012-02-06 11:22:21 -0800673 parent = u8500_init_devices();
Lee Jones110c2c22011-08-26 16:54:07 +0100674
Lee Jonesb024a0c2012-02-06 11:22:25 -0800675 for (i = 0; i < ARRAY_SIZE(mop500_platform_devs); i++)
676 mop500_platform_devs[i]->dev.parent = parent;
677
Lee Jones110c2c22011-08-26 16:54:07 +0100678 platform_add_devices(mop500_platform_devs,
679 ARRAY_SIZE(mop500_platform_devs));
680
Lee Jones18403422012-02-06 11:22:21 -0800681 mop500_i2c_init(parent);
682 hrefv60_sdi_init(parent);
683 mop500_spi_init(parent);
Ola Liljac0af14d2012-04-20 11:32:59 +0200684 mop500_msp_init(parent);
Lee Jones18403422012-02-06 11:22:21 -0800685 mop500_uart_init(parent);
Lee Jones110c2c22011-08-26 16:54:07 +0100686
687 i2c0_devs = ARRAY_SIZE(mop500_i2c0_devices);
688
689 i2c0_devs -= NUM_PRE_V60_I2C0_DEVICES;
Linus Walleijcf568c52011-03-30 14:31:42 +0200690
691 i2c_register_board_info(0, mop500_i2c0_devices, i2c0_devs);
Philippe Langlaisdd7b2a02011-01-12 11:26:20 +0100692 i2c_register_board_info(2, mop500_i2c2_devices,
693 ARRAY_SIZE(mop500_i2c2_devices));
Linus Walleijdb245202011-04-04 10:44:51 +0200694
695 /* This board has full regulator constraints */
696 regulator_has_full_constraints();
Lee Jonesfd6948b2012-05-02 09:53:48 +0100697
698 mop500_uib_init();
Srinidhi Kasagaraa44ef42009-11-28 08:17:18 +0100699}
700
701MACHINE_START(U8500, "ST-Ericsson MOP500 platform")
702 /* Maintainer: Srinidhi Kasagar <srinidhi.kasagar@stericsson.com> */
Nicolas Pitrebc77b1a2011-07-05 22:38:18 -0400703 .atag_offset = 0x100,
Srinidhi Kasagaraa44ef42009-11-28 08:17:18 +0100704 .map_io = u8500_map_io,
Rabin Vincent178980f2010-05-03 07:39:02 +0100705 .init_irq = ux500_init_irq,
Srinidhi Kasagaraa44ef42009-11-28 08:17:18 +0100706 /* we re-use nomadik timer here */
Rabin Vincent41ac3292010-05-03 08:28:05 +0100707 .timer = &ux500_timer,
Marc Zyngierbbf5f382011-09-06 10:23:45 +0100708 .handle_irq = gic_handle_irq,
Linus Walleij4b4f7572011-02-15 15:01:35 +0100709 .init_machine = mop500_init_machine,
Shawn Guoa010bc22012-05-02 17:10:07 +0800710 .init_late = ux500_init_late,
Linus Walleij4b4f7572011-02-15 15:01:35 +0100711MACHINE_END
712
713MACHINE_START(HREFV60, "ST-Ericsson U8500 Platform HREFv60+")
Nicolas Pitrebc77b1a2011-07-05 22:38:18 -0400714 .atag_offset = 0x100,
Linus Walleij4b4f7572011-02-15 15:01:35 +0100715 .map_io = u8500_map_io,
716 .init_irq = ux500_init_irq,
717 .timer = &ux500_timer,
Marc Zyngierbbf5f382011-09-06 10:23:45 +0100718 .handle_irq = gic_handle_irq,
Lee Jones110c2c22011-08-26 16:54:07 +0100719 .init_machine = hrefv60_init_machine,
Shawn Guoa010bc22012-05-02 17:10:07 +0800720 .init_late = ux500_init_late,
Srinidhi Kasagaraa44ef42009-11-28 08:17:18 +0100721MACHINE_END
Robert Marklund350abe02011-06-20 15:55:46 +0200722
723MACHINE_START(SNOWBALL, "Calao Systems Snowball platform")
Nicolas Pitrebc77b1a2011-07-05 22:38:18 -0400724 .atag_offset = 0x100,
Robert Marklund350abe02011-06-20 15:55:46 +0200725 .map_io = u8500_map_io,
726 .init_irq = ux500_init_irq,
727 /* we re-use nomadik timer here */
728 .timer = &ux500_timer,
Marc Zyngierbbf5f382011-09-06 10:23:45 +0100729 .handle_irq = gic_handle_irq,
Lee Jones110c2c22011-08-26 16:54:07 +0100730 .init_machine = snowball_init_machine,
Shawn Guoa010bc22012-05-02 17:10:07 +0800731 .init_late = ux500_init_late,
Robert Marklund350abe02011-06-20 15:55:46 +0200732MACHINE_END
Arnd Bergmann2d334292012-03-07 15:04:07 +0000733
734#ifdef CONFIG_MACH_UX500_DT
Lee Jones7e0ce272012-03-15 16:46:17 +0000735
Lee Jonesc57920e2012-06-15 09:27:54 +0100736static struct platform_device *snowball_of_platform_devs[] __initdata = {
737 &snowball_led_dev,
738 &snowball_key_dev,
739};
740
Lee Jones7e0ce272012-03-15 16:46:17 +0000741struct of_dev_auxdata u8500_auxdata_lookup[] __initdata = {
Lee Jones513c27f2012-04-13 15:05:05 +0100742 /* Requires DMA and call-back bindings. */
Lee Jones4905af02012-03-07 17:35:04 +0000743 OF_DEV_AUXDATA("arm,pl011", 0x80120000, "uart0", &uart0_plat),
744 OF_DEV_AUXDATA("arm,pl011", 0x80121000, "uart1", &uart1_plat),
745 OF_DEV_AUXDATA("arm,pl011", 0x80007000, "uart2", &uart2_plat),
Lee Jones513c27f2012-04-13 15:05:05 +0100746 /* Requires DMA bindings. */
Lee Jones15daf692012-03-15 16:47:11 +0000747 OF_DEV_AUXDATA("arm,pl022", 0x80002000, "ssp0", &ssp0_plat),
Lee Jones5e1ac7d2012-05-29 14:40:04 +0800748 OF_DEV_AUXDATA("arm,pl18x", 0x80126000, "sdi0", &mop500_sdi0_data),
749 OF_DEV_AUXDATA("arm,pl18x", 0x80114000, "sdi4", &mop500_sdi4_data),
Lee Jones513c27f2012-04-13 15:05:05 +0100750 /* Requires clock name bindings. */
751 OF_DEV_AUXDATA("st,nomadik-gpio", 0x8012e000, "gpio.0", NULL),
752 OF_DEV_AUXDATA("st,nomadik-gpio", 0x8012e080, "gpio.1", NULL),
753 OF_DEV_AUXDATA("st,nomadik-gpio", 0x8000e000, "gpio.2", NULL),
754 OF_DEV_AUXDATA("st,nomadik-gpio", 0x8000e080, "gpio.3", NULL),
755 OF_DEV_AUXDATA("st,nomadik-gpio", 0x8000e100, "gpio.4", NULL),
756 OF_DEV_AUXDATA("st,nomadik-gpio", 0x8000e180, "gpio.5", NULL),
757 OF_DEV_AUXDATA("st,nomadik-gpio", 0x8011e000, "gpio.6", NULL),
758 OF_DEV_AUXDATA("st,nomadik-gpio", 0x8011e080, "gpio.7", NULL),
759 OF_DEV_AUXDATA("st,nomadik-gpio", 0xa03fe000, "gpio.8", NULL),
Lee Jones2b667a22012-07-06 15:59:01 +0100760 /* Requires device name bindings. */
761 OF_DEV_AUXDATA("stericsson,nmk_pinctrl", 0, "pinctrl-db8500", NULL),
Lee Jones7e0ce272012-03-15 16:46:17 +0000762 {},
763};
764
Lee Jones2cfaa622012-04-19 21:36:30 +0100765static const struct of_device_id u8500_local_bus_nodes[] = {
Lee Jones7e0ce272012-03-15 16:46:17 +0000766 /* only create devices below soc node */
767 { .compatible = "stericsson,db8500", },
Lee Jones48a4ea62012-05-29 15:06:55 +0800768 { .compatible = "stericsson,db8500-prcmu", },
Lee Jones890d84f2012-05-04 14:01:00 +0100769 { .compatible = "stericsson,db8500-prcmu-regulator", },
Lee Jones48a4ea62012-05-29 15:06:55 +0800770 { .compatible = "stericsson,ab8500", },
771 { .compatible = "stericsson,ab8500-regulator", },
Lee Jones2cfaa622012-04-19 21:36:30 +0100772 { .compatible = "simple-bus"},
Lee Jones7e0ce272012-03-15 16:46:17 +0000773 { },
774};
775
Arnd Bergmann2d334292012-03-07 15:04:07 +0000776static void __init u8500_init_machine(void)
777{
Arnd Bergmann7734fed2012-03-02 22:25:02 +0000778 struct device *parent = NULL;
779 int i2c0_devs;
780 int i;
781
Linus Walleijed781d392012-05-03 00:44:52 +0200782 /* Pinmaps must be in place before devices register */
783 if (of_machine_is_compatible("st-ericsson,mop500"))
784 mop500_pinmaps_init();
785 else if (of_machine_is_compatible("calaosystems,snowball-a9500"))
786 snowball_pinmaps_init();
787 else if (of_machine_is_compatible("st-ericsson,hrefv60+"))
788 hrefv60_pinmaps_init();
789
Lee Jonesf65c1982012-05-29 10:03:09 +0800790 parent = u8500_of_init_devices();
Arnd Bergmann7734fed2012-03-02 22:25:02 +0000791
792 for (i = 0; i < ARRAY_SIZE(mop500_platform_devs); i++)
793 mop500_platform_devs[i]->dev.parent = parent;
794 for (i = 0; i < ARRAY_SIZE(snowball_platform_devs); i++)
795 snowball_platform_devs[i]->dev.parent = parent;
796
Lee Jones7e0ce272012-03-15 16:46:17 +0000797 /* automatically probe child nodes of db8500 device */
Lee Jones2cfaa622012-04-19 21:36:30 +0100798 of_platform_populate(NULL, u8500_local_bus_nodes, u8500_auxdata_lookup, parent);
Arnd Bergmann7734fed2012-03-02 22:25:02 +0000799
800 if (of_machine_is_compatible("st-ericsson,mop500")) {
801 mop500_gpio_keys[0].gpio = GPIO_PROX_SENSOR;
Arnd Bergmann7734fed2012-03-02 22:25:02 +0000802
803 platform_add_devices(mop500_platform_devs,
804 ARRAY_SIZE(mop500_platform_devs));
805
806 mop500_sdi_init(parent);
Lee Jones4809f902012-04-19 21:36:40 +0100807 i2c0_devs = ARRAY_SIZE(mop500_i2c0_devices);
808 i2c_register_board_info(0, mop500_i2c0_devices, i2c0_devs);
809 i2c_register_board_info(2, mop500_i2c2_devices,
810 ARRAY_SIZE(mop500_i2c2_devices));
811
Lee Jonesfd6948b2012-05-02 09:53:48 +0100812 mop500_uib_init();
813
Arnd Bergmann7734fed2012-03-02 22:25:02 +0000814 } else if (of_machine_is_compatible("calaosystems,snowball-a9500")) {
Lee Jones11a0b5f02012-05-30 09:55:38 +0800815 /*
816 * Devices to be DT:ed:
817 * snowball_led_dev = todo
818 * snowball_key_dev = todo
Lee Jonesada46cd2012-05-29 10:28:34 +0800819 * snowball_sbnet_dev = done
Lee Jones48a4ea62012-05-29 15:06:55 +0800820 * ab8500_device = done
Lee Jones11a0b5f02012-05-30 09:55:38 +0800821 */
822 platform_add_devices(snowball_of_platform_devs,
823 ARRAY_SIZE(snowball_of_platform_devs));
Arnd Bergmann7734fed2012-03-02 22:25:02 +0000824
Arnd Bergmann7734fed2012-03-02 22:25:02 +0000825 } else if (of_machine_is_compatible("st-ericsson,hrefv60+")) {
826 /*
827 * The HREFv60 board removed a GPIO expander and routed
828 * all these GPIO pins to the internal GPIO controller
829 * instead.
830 */
831 mop500_gpio_keys[0].gpio = HREFV60_PROX_SENSE_GPIO;
Arnd Bergmann7734fed2012-03-02 22:25:02 +0000832 platform_add_devices(mop500_platform_devs,
833 ARRAY_SIZE(mop500_platform_devs));
834
835 hrefv60_sdi_init(parent);
Lee Jones4809f902012-04-19 21:36:40 +0100836
837 i2c0_devs = ARRAY_SIZE(mop500_i2c0_devices);
838 i2c0_devs -= NUM_PRE_V60_I2C0_DEVICES;
839
840 i2c_register_board_info(0, mop500_i2c0_devices, i2c0_devs);
841 i2c_register_board_info(2, mop500_i2c2_devices,
842 ARRAY_SIZE(mop500_i2c2_devices));
Lee Jonesfd6948b2012-05-02 09:53:48 +0100843
844 mop500_uib_init();
Arnd Bergmann7734fed2012-03-02 22:25:02 +0000845 }
846 mop500_i2c_init(parent);
Arnd Bergmann7734fed2012-03-02 22:25:02 +0000847
Arnd Bergmann7734fed2012-03-02 22:25:02 +0000848 /* This board has full regulator constraints */
849 regulator_has_full_constraints();
Arnd Bergmann2d334292012-03-07 15:04:07 +0000850}
851
852static const char * u8500_dt_board_compat[] = {
853 "calaosystems,snowball-a9500",
854 "st-ericsson,hrefv60+",
855 "st-ericsson,u8500",
856 "st-ericsson,mop500",
857 NULL,
858};
859
860
861DT_MACHINE_START(U8500_DT, "ST-Ericsson U8500 platform (Device Tree Support)")
862 .map_io = u8500_map_io,
863 .init_irq = ux500_init_irq,
864 /* we re-use nomadik timer here */
865 .timer = &ux500_timer,
866 .handle_irq = gic_handle_irq,
867 .init_machine = u8500_init_machine,
Shawn Guoa010bc22012-05-02 17:10:07 +0800868 .init_late = ux500_init_late,
Arnd Bergmann2d334292012-03-07 15:04:07 +0000869 .dt_compat = u8500_dt_board_compat,
870MACHINE_END
871#endif