]> Pileus Git - ~andy/linux/blob - arch/arm/mach-ux500/board-mop500.c
Merge branch 'misc' of git://git.kernel.org/pub/scm/linux/kernel/git/mmarek/kbuild
[~andy/linux] / arch / arm / mach-ux500 / board-mop500.c
1 /*
2  * Copyright (C) 2008-2012 ST-Ericsson
3  *
4  * Author: Srinidhi KASAGAR <srinidhi.kasagar@stericsson.com>
5  *
6  * This program is free software; you can redistribute it and/or modify
7  * it under the terms of the GNU General Public License version 2, as
8  * published by the Free Software Foundation.
9  *
10  */
11 #include <linux/kernel.h>
12 #include <linux/init.h>
13 #include <linux/interrupt.h>
14 #include <linux/platform_device.h>
15 #include <linux/clk.h>
16 #include <linux/io.h>
17 #include <linux/i2c.h>
18 #include <linux/platform_data/i2c-nomadik.h>
19 #include <linux/platform_data/db8500_thermal.h>
20 #include <linux/gpio.h>
21 #include <linux/amba/bus.h>
22 #include <linux/amba/pl022.h>
23 #include <linux/amba/serial.h>
24 #include <linux/spi/spi.h>
25 #include <linux/mfd/abx500/ab8500.h>
26 #include <linux/regulator/ab8500.h>
27 #include <linux/regulator/fixed.h>
28 #include <linux/regulator/driver.h>
29 #include <linux/regulator/gpio-regulator.h>
30 #include <linux/mfd/tc3589x.h>
31 #include <linux/mfd/tps6105x.h>
32 #include <linux/mfd/abx500/ab8500-gpio.h>
33 #include <linux/mfd/abx500/ab8500-codec.h>
34 #include <linux/platform_data/leds-lp55xx.h>
35 #include <linux/input.h>
36 #include <linux/smsc911x.h>
37 #include <linux/gpio_keys.h>
38 #include <linux/delay.h>
39 #include <linux/leds.h>
40 #include <linux/pinctrl/consumer.h>
41 #include <linux/platform_data/pinctrl-nomadik.h>
42 #include <linux/platform_data/dma-ste-dma40.h>
43
44 #include <asm/mach-types.h>
45
46 #include "setup.h"
47 #include "devices.h"
48 #include "irqs.h"
49 #include <linux/platform_data/crypto-ux500.h>
50
51 #include "ste-dma40-db8500.h"
52 #include "db8500-regs.h"
53 #include "devices-db8500.h"
54 #include "board-mop500.h"
55 #include "board-mop500-regulators.h"
56
57 static struct gpio_led snowball_led_array[] = {
58         {
59                 .name = "user_led",
60                 .default_trigger = "heartbeat",
61                 .gpio = 142,
62         },
63 };
64
65 static struct gpio_led_platform_data snowball_led_data = {
66         .leds = snowball_led_array,
67         .num_leds = ARRAY_SIZE(snowball_led_array),
68 };
69
70 static struct platform_device snowball_led_dev = {
71         .name = "leds-gpio",
72         .dev = {
73                 .platform_data = &snowball_led_data,
74         },
75 };
76
77 static struct fixed_voltage_config snowball_gpio_en_3v3_data = {
78        .supply_name            = "EN-3V3",
79        .gpio                   = SNOWBALL_EN_3V3_ETH_GPIO,
80        .microvolts             = 3300000,
81        .enable_high            = 1,
82        .init_data              = &gpio_en_3v3_regulator,
83        .startup_delay          = 5000, /* 1200us */
84 };
85
86 static struct platform_device snowball_gpio_en_3v3_regulator_dev = {
87        .name   = "reg-fixed-voltage",
88        .id     = 1,
89        .dev    = {
90                .platform_data  = &snowball_gpio_en_3v3_data,
91        },
92 };
93
94 /* Dynamically populated. */
95 static struct gpio sdi0_reg_gpios[] = {
96         { 0, GPIOF_OUT_INIT_LOW, "mmci_vsel" },
97 };
98
99 static struct gpio_regulator_state sdi0_reg_states[] = {
100         { .value = 2900000, .gpios = (0 << 0) },
101         { .value = 1800000, .gpios = (1 << 0) },
102 };
103
104 static struct gpio_regulator_config sdi0_reg_info = {
105         .supply_name            = "ext-mmc-level-shifter",
106         .gpios                  = sdi0_reg_gpios,
107         .nr_gpios               = ARRAY_SIZE(sdi0_reg_gpios),
108         .states                 = sdi0_reg_states,
109         .nr_states              = ARRAY_SIZE(sdi0_reg_states),
110         .type                   = REGULATOR_VOLTAGE,
111         .enable_high            = 1,
112         .enabled_at_boot        = 0,
113         .init_data              = &sdi0_reg_init_data,
114         .startup_delay          = 100,
115 };
116
117 static struct platform_device sdi0_regulator = {
118         .name = "gpio-regulator",
119         .id   = -1,
120         .dev  = {
121                 .platform_data = &sdi0_reg_info,
122         },
123 };
124
125 static struct abx500_gpio_platform_data ab8500_gpio_pdata = {
126         .gpio_base              = MOP500_AB8500_PIN_GPIO(1),
127 };
128
129 /* ab8500-codec */
130 static struct ab8500_codec_platform_data ab8500_codec_pdata = {
131         .amics =  {
132                 .mic1_type = AMIC_TYPE_DIFFERENTIAL,
133                 .mic2_type = AMIC_TYPE_DIFFERENTIAL,
134                 .mic1a_micbias = AMIC_MICBIAS_VAMIC1,
135                 .mic1b_micbias = AMIC_MICBIAS_VAMIC1,
136                 .mic2_micbias = AMIC_MICBIAS_VAMIC2
137         },
138         .ear_cmv = EAR_CMV_0_95V
139 };
140
141 static struct gpio_keys_button snowball_key_array[] = {
142         {
143                 .gpio           = 32,
144                 .type           = EV_KEY,
145                 .code           = KEY_1,
146                 .desc           = "userpb",
147                 .active_low     = 1,
148                 .debounce_interval = 50,
149                 .wakeup         = 1,
150         },
151         {
152                 .gpio           = 151,
153                 .type           = EV_KEY,
154                 .code           = KEY_2,
155                 .desc           = "extkb1",
156                 .active_low     = 1,
157                 .debounce_interval = 50,
158                 .wakeup         = 1,
159         },
160         {
161                 .gpio           = 152,
162                 .type           = EV_KEY,
163                 .code           = KEY_3,
164                 .desc           = "extkb2",
165                 .active_low     = 1,
166                 .debounce_interval = 50,
167                 .wakeup         = 1,
168         },
169         {
170                 .gpio           = 161,
171                 .type           = EV_KEY,
172                 .code           = KEY_4,
173                 .desc           = "extkb3",
174                 .active_low     = 1,
175                 .debounce_interval = 50,
176                 .wakeup         = 1,
177         },
178         {
179                 .gpio           = 162,
180                 .type           = EV_KEY,
181                 .code           = KEY_5,
182                 .desc           = "extkb4",
183                 .active_low     = 1,
184                 .debounce_interval = 50,
185                 .wakeup         = 1,
186         },
187 };
188
189 static struct gpio_keys_platform_data snowball_key_data = {
190         .buttons        = snowball_key_array,
191         .nbuttons       = ARRAY_SIZE(snowball_key_array),
192 };
193
194 static struct platform_device snowball_key_dev = {
195         .name           = "gpio-keys",
196         .id             = -1,
197         .dev            = {
198                 .platform_data  = &snowball_key_data,
199         }
200 };
201
202 static struct smsc911x_platform_config snowball_sbnet_cfg = {
203         .irq_polarity = SMSC911X_IRQ_POLARITY_ACTIVE_HIGH,
204         .irq_type = SMSC911X_IRQ_TYPE_PUSH_PULL,
205         .flags = SMSC911X_USE_16BIT | SMSC911X_FORCE_INTERNAL_PHY,
206         .shift = 1,
207 };
208
209 static struct resource sbnet_res[] = {
210         {
211                 .name = "smsc911x-memory",
212                 .start = (0x5000 << 16),
213                 .end  =  (0x5000 << 16) + 0xffff,
214                 .flags = IORESOURCE_MEM,
215         },
216         {
217                 .start = NOMADIK_GPIO_TO_IRQ(140),
218                 .end = NOMADIK_GPIO_TO_IRQ(140),
219                 .flags = IORESOURCE_IRQ | IORESOURCE_IRQ_HIGHEDGE,
220         },
221 };
222
223 static struct platform_device snowball_sbnet_dev = {
224         .name           = "smsc911x",
225         .num_resources  = ARRAY_SIZE(sbnet_res),
226         .resource       = sbnet_res,
227         .dev            = {
228                 .platform_data = &snowball_sbnet_cfg,
229         },
230 };
231
232 struct ab8500_platform_data ab8500_platdata = {
233         .irq_base       = MOP500_AB8500_IRQ_BASE,
234         .regulator      = &ab8500_regulator_plat_data,
235         .gpio           = &ab8500_gpio_pdata,
236         .codec          = &ab8500_codec_pdata,
237 };
238
239 static struct platform_device u8500_cpufreq_cooling_device = {
240         .name           = "db8500-cpufreq-cooling",
241 };
242
243 /*
244  * TPS61052
245  */
246
247 static struct tps6105x_platform_data mop500_tps61052_data = {
248         .mode = TPS6105X_MODE_VOLTAGE,
249         .regulator_data = &tps61052_regulator,
250 };
251
252 /*
253  * TC35892
254  */
255
256 static void mop500_tc35892_init(struct tc3589x *tc3589x, unsigned int base)
257 {
258         struct device *parent = NULL;
259 #if 0
260         /* FIXME: Is the sdi actually part of tc3589x? */
261         parent = tc3589x->dev;
262 #endif
263         mop500_sdi_tc35892_init(parent);
264 }
265
266 static struct tc3589x_gpio_platform_data mop500_tc35892_gpio_data = {
267         .gpio_base      = MOP500_EGPIO(0),
268         .setup          = mop500_tc35892_init,
269 };
270
271 static struct tc3589x_platform_data mop500_tc35892_data = {
272         .block          = TC3589x_BLOCK_GPIO,
273         .gpio           = &mop500_tc35892_gpio_data,
274         .irq_base       = MOP500_EGPIO_IRQ_BASE,
275 };
276
277 static struct lp55xx_led_config lp5521_pri_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
295 static struct lp55xx_platform_data __initdata lp5521_pri_data = {
296        .label = "lp5521_pri",
297        .led_config     = &lp5521_pri_led[0],
298        .num_channels   = 3,
299        .clock_mode     = LP55XX_CLOCK_EXT,
300 };
301
302 static struct lp55xx_led_config lp5521_sec_led[] = {
303        [0] = {
304                .chan_nr = 0,
305                .led_current = 0x2f,
306                .max_current = 0x5f,
307        },
308        [1] = {
309                .chan_nr = 1,
310                .led_current = 0x2f,
311                .max_current = 0x5f,
312        },
313        [2] = {
314                .chan_nr = 2,
315                .led_current = 0x2f,
316                .max_current = 0x5f,
317        },
318 };
319
320 static struct lp55xx_platform_data __initdata lp5521_sec_data = {
321        .label = "lp5521_sec",
322        .led_config     = &lp5521_sec_led[0],
323        .num_channels   = 3,
324        .clock_mode     = LP55XX_CLOCK_EXT,
325 };
326
327 static struct i2c_board_info __initdata mop500_i2c0_devices[] = {
328         {
329                 I2C_BOARD_INFO("tc3589x", 0x42),
330                 .irq            = NOMADIK_GPIO_TO_IRQ(217),
331                 .platform_data  = &mop500_tc35892_data,
332         },
333         /* I2C0 devices only available prior to HREFv60 */
334         {
335                 I2C_BOARD_INFO("tps61052", 0x33),
336                 .platform_data  = &mop500_tps61052_data,
337         },
338 };
339
340 #define NUM_PRE_V60_I2C0_DEVICES 1
341
342 static struct i2c_board_info __initdata mop500_i2c2_devices[] = {
343         {
344                 /* lp5521 LED driver, 1st device */
345                 I2C_BOARD_INFO("lp5521", 0x33),
346                 .platform_data = &lp5521_pri_data,
347         },
348         {
349                 /* lp5521 LED driver, 2st device */
350                 I2C_BOARD_INFO("lp5521", 0x34),
351                 .platform_data = &lp5521_sec_data,
352         },
353         {
354                 /* Light sensor Rohm BH1780GLI */
355                 I2C_BOARD_INFO("bh1780", 0x29),
356         },
357 };
358
359 static void __init mop500_i2c_init(struct device *parent)
360 {
361         db8500_add_i2c0(parent, NULL);
362         db8500_add_i2c1(parent, NULL);
363         db8500_add_i2c2(parent, NULL);
364         db8500_add_i2c3(parent, NULL);
365 }
366
367 static struct gpio_keys_button mop500_gpio_keys[] = {
368         {
369                 .desc                   = "SFH7741 Proximity Sensor",
370                 .type                   = EV_SW,
371                 .code                   = SW_FRONT_PROXIMITY,
372                 .active_low             = 0,
373                 .can_disable            = 1,
374         }
375 };
376
377 static struct regulator *prox_regulator;
378 static int mop500_prox_activate(struct device *dev);
379 static void mop500_prox_deactivate(struct device *dev);
380
381 static struct gpio_keys_platform_data mop500_gpio_keys_data = {
382         .buttons        = mop500_gpio_keys,
383         .nbuttons       = ARRAY_SIZE(mop500_gpio_keys),
384         .enable         = mop500_prox_activate,
385         .disable        = mop500_prox_deactivate,
386 };
387
388 static struct platform_device mop500_gpio_keys_device = {
389         .name   = "gpio-keys",
390         .id     = 0,
391         .dev    = {
392                 .platform_data  = &mop500_gpio_keys_data,
393         },
394 };
395
396 static int mop500_prox_activate(struct device *dev)
397 {
398         prox_regulator = regulator_get(&mop500_gpio_keys_device.dev,
399                                                 "vcc");
400         if (IS_ERR(prox_regulator)) {
401                 dev_err(&mop500_gpio_keys_device.dev,
402                         "no regulator\n");
403                 return PTR_ERR(prox_regulator);
404         }
405
406         return regulator_enable(prox_regulator);
407 }
408
409 static void mop500_prox_deactivate(struct device *dev)
410 {
411         regulator_disable(prox_regulator);
412         regulator_put(prox_regulator);
413 }
414
415 static struct cryp_platform_data u8500_cryp1_platform_data = {
416                 .mem_to_engine = {
417                                 .dir = DMA_MEM_TO_DEV,
418                                 .dev_type = DB8500_DMA_DEV48_CAC1,
419                                 .mode = STEDMA40_MODE_LOGICAL,
420                 },
421                 .engine_to_mem = {
422                                 .dir = DMA_DEV_TO_MEM,
423                                 .dev_type = DB8500_DMA_DEV48_CAC1,
424                                 .mode = STEDMA40_MODE_LOGICAL,
425                 }
426 };
427
428 static struct stedma40_chan_cfg u8500_hash_dma_cfg_tx = {
429                 .dir = DMA_MEM_TO_DEV,
430                 .dev_type = DB8500_DMA_DEV50_HAC1_TX,
431                 .mode = STEDMA40_MODE_LOGICAL,
432 };
433
434 static struct hash_platform_data u8500_hash1_platform_data = {
435                 .mem_to_engine = &u8500_hash_dma_cfg_tx,
436                 .dma_filter = stedma40_filter,
437 };
438
439 /* add any platform devices here - TODO */
440 static struct platform_device *mop500_platform_devs[] __initdata = {
441         &mop500_gpio_keys_device,
442         &sdi0_regulator,
443 };
444
445 #ifdef CONFIG_STE_DMA40
446 static struct stedma40_chan_cfg ssp0_dma_cfg_rx = {
447         .mode = STEDMA40_MODE_LOGICAL,
448         .dir = DMA_DEV_TO_MEM,
449         .dev_type = DB8500_DMA_DEV8_SSP0,
450 };
451
452 static struct stedma40_chan_cfg ssp0_dma_cfg_tx = {
453         .mode = STEDMA40_MODE_LOGICAL,
454         .dir = DMA_MEM_TO_DEV,
455         .dev_type = DB8500_DMA_DEV8_SSP0,
456 };
457 #endif
458
459 struct pl022_ssp_controller ssp0_plat = {
460         .bus_id = 0,
461 #ifdef CONFIG_STE_DMA40
462         .enable_dma = 1,
463         .dma_filter = stedma40_filter,
464         .dma_rx_param = &ssp0_dma_cfg_rx,
465         .dma_tx_param = &ssp0_dma_cfg_tx,
466 #else
467         .enable_dma = 0,
468 #endif
469         /* on this platform, gpio 31,142,144,214 &
470          * 224 are connected as chip selects
471          */
472         .num_chipselect = 5,
473 };
474
475 static void __init mop500_spi_init(struct device *parent)
476 {
477         db8500_add_ssp0(parent, &ssp0_plat);
478 }
479
480 #ifdef CONFIG_STE_DMA40
481 static struct stedma40_chan_cfg uart0_dma_cfg_rx = {
482         .mode = STEDMA40_MODE_LOGICAL,
483         .dir = DMA_DEV_TO_MEM,
484         .dev_type = DB8500_DMA_DEV13_UART0,
485 };
486
487 static struct stedma40_chan_cfg uart0_dma_cfg_tx = {
488         .mode = STEDMA40_MODE_LOGICAL,
489         .dir = DMA_MEM_TO_DEV,
490         .dev_type = DB8500_DMA_DEV13_UART0,
491 };
492
493 static struct stedma40_chan_cfg uart1_dma_cfg_rx = {
494         .mode = STEDMA40_MODE_LOGICAL,
495         .dir = DMA_DEV_TO_MEM,
496         .dev_type = DB8500_DMA_DEV12_UART1,
497 };
498
499 static struct stedma40_chan_cfg uart1_dma_cfg_tx = {
500         .mode = STEDMA40_MODE_LOGICAL,
501         .dir = DMA_MEM_TO_DEV,
502         .dev_type = DB8500_DMA_DEV12_UART1,
503 };
504
505 static struct stedma40_chan_cfg uart2_dma_cfg_rx = {
506         .mode = STEDMA40_MODE_LOGICAL,
507         .dir = DMA_DEV_TO_MEM,
508         .dev_type = DB8500_DMA_DEV11_UART2,
509 };
510
511 static struct stedma40_chan_cfg uart2_dma_cfg_tx = {
512         .mode = STEDMA40_MODE_LOGICAL,
513         .dir = DMA_MEM_TO_DEV,
514         .dev_type = DB8500_DMA_DEV11_UART2,
515 };
516 #endif
517
518 struct amba_pl011_data uart0_plat = {
519 #ifdef CONFIG_STE_DMA40
520         .dma_filter = stedma40_filter,
521         .dma_rx_param = &uart0_dma_cfg_rx,
522         .dma_tx_param = &uart0_dma_cfg_tx,
523 #endif
524 };
525
526 struct amba_pl011_data uart1_plat = {
527 #ifdef CONFIG_STE_DMA40
528         .dma_filter = stedma40_filter,
529         .dma_rx_param = &uart1_dma_cfg_rx,
530         .dma_tx_param = &uart1_dma_cfg_tx,
531 #endif
532 };
533
534 struct amba_pl011_data uart2_plat = {
535 #ifdef CONFIG_STE_DMA40
536         .dma_filter = stedma40_filter,
537         .dma_rx_param = &uart2_dma_cfg_rx,
538         .dma_tx_param = &uart2_dma_cfg_tx,
539 #endif
540 };
541
542 static void __init mop500_uart_init(struct device *parent)
543 {
544         db8500_add_uart0(parent, &uart0_plat);
545         db8500_add_uart1(parent, &uart1_plat);
546         db8500_add_uart2(parent, &uart2_plat);
547 }
548
549 static void __init u8500_cryp1_hash1_init(struct device *parent)
550 {
551         db8500_add_cryp1(parent, &u8500_cryp1_platform_data);
552         db8500_add_hash1(parent, &u8500_hash1_platform_data);
553 }
554
555 static struct platform_device *snowball_platform_devs[] __initdata = {
556         &snowball_led_dev,
557         &snowball_key_dev,
558         &snowball_sbnet_dev,
559         &snowball_gpio_en_3v3_regulator_dev,
560         &u8500_cpufreq_cooling_device,
561         &sdi0_regulator,
562 };
563
564 static void __init mop500_init_machine(void)
565 {
566         struct device *parent = NULL;
567         int i2c0_devs;
568         int i;
569
570         platform_device_register(&db8500_prcmu_device);
571         mop500_gpio_keys[0].gpio = GPIO_PROX_SENSOR;
572
573         sdi0_reg_info.enable_gpio = GPIO_SDMMC_EN;
574         sdi0_reg_info.gpios[0].gpio = GPIO_SDMMC_1V8_3V_SEL;
575
576         mop500_pinmaps_init();
577         parent = u8500_init_devices();
578
579         for (i = 0; i < ARRAY_SIZE(mop500_platform_devs); i++)
580                 mop500_platform_devs[i]->dev.parent = parent;
581
582         platform_add_devices(mop500_platform_devs,
583                         ARRAY_SIZE(mop500_platform_devs));
584
585         mop500_i2c_init(parent);
586         mop500_sdi_init(parent);
587         mop500_spi_init(parent);
588         mop500_audio_init(parent);
589         mop500_uart_init(parent);
590
591         u8500_cryp1_hash1_init(parent);
592
593         i2c0_devs = ARRAY_SIZE(mop500_i2c0_devices);
594
595         i2c_register_board_info(0, mop500_i2c0_devices, i2c0_devs);
596         i2c_register_board_info(2, mop500_i2c2_devices,
597                                 ARRAY_SIZE(mop500_i2c2_devices));
598
599         /* This board has full regulator constraints */
600         regulator_has_full_constraints();
601 }
602
603 static void __init snowball_init_machine(void)
604 {
605         struct device *parent = NULL;
606         int i;
607
608         platform_device_register(&db8500_prcmu_device);
609
610         sdi0_reg_info.enable_gpio = SNOWBALL_SDMMC_EN_GPIO;
611         sdi0_reg_info.gpios[0].gpio = SNOWBALL_SDMMC_1V8_3V_GPIO;
612
613         snowball_pinmaps_init();
614         parent = u8500_init_devices();
615
616         for (i = 0; i < ARRAY_SIZE(snowball_platform_devs); i++)
617                 snowball_platform_devs[i]->dev.parent = parent;
618
619         platform_add_devices(snowball_platform_devs,
620                         ARRAY_SIZE(snowball_platform_devs));
621
622         mop500_i2c_init(parent);
623         snowball_sdi_init(parent);
624         mop500_spi_init(parent);
625         mop500_audio_init(parent);
626         mop500_uart_init(parent);
627
628         u8500_cryp1_hash1_init(parent);
629
630         /* This board has full regulator constraints */
631         regulator_has_full_constraints();
632 }
633
634 static void __init hrefv60_init_machine(void)
635 {
636         struct device *parent = NULL;
637         int i2c0_devs;
638         int i;
639
640         platform_device_register(&db8500_prcmu_device);
641         /*
642          * The HREFv60 board removed a GPIO expander and routed
643          * all these GPIO pins to the internal GPIO controller
644          * instead.
645          */
646         mop500_gpio_keys[0].gpio = HREFV60_PROX_SENSE_GPIO;
647
648         sdi0_reg_info.enable_gpio = HREFV60_SDMMC_EN_GPIO;
649         sdi0_reg_info.gpios[0].gpio = HREFV60_SDMMC_1V8_3V_GPIO;
650
651         hrefv60_pinmaps_init();
652         parent = u8500_init_devices();
653
654         for (i = 0; i < ARRAY_SIZE(mop500_platform_devs); i++)
655                 mop500_platform_devs[i]->dev.parent = parent;
656
657         platform_add_devices(mop500_platform_devs,
658                         ARRAY_SIZE(mop500_platform_devs));
659
660         mop500_i2c_init(parent);
661         hrefv60_sdi_init(parent);
662         mop500_spi_init(parent);
663         mop500_audio_init(parent);
664         mop500_uart_init(parent);
665
666         i2c0_devs = ARRAY_SIZE(mop500_i2c0_devices);
667
668         i2c0_devs -= NUM_PRE_V60_I2C0_DEVICES;
669
670         i2c_register_board_info(0, mop500_i2c0_devices, i2c0_devs);
671         i2c_register_board_info(2, mop500_i2c2_devices,
672                                 ARRAY_SIZE(mop500_i2c2_devices));
673
674         /* This board has full regulator constraints */
675         regulator_has_full_constraints();
676 }
677
678 MACHINE_START(U8500, "ST-Ericsson MOP500 platform")
679         /* Maintainer: Srinidhi Kasagar <srinidhi.kasagar@stericsson.com> */
680         .atag_offset    = 0x100,
681         .smp            = smp_ops(ux500_smp_ops),
682         .map_io         = u8500_map_io,
683         .init_irq       = ux500_init_irq,
684         /* we re-use nomadik timer here */
685         .init_time      = ux500_timer_init,
686         .init_machine   = mop500_init_machine,
687         .init_late      = ux500_init_late,
688         .restart        = ux500_restart,
689 MACHINE_END
690
691 MACHINE_START(U8520, "ST-Ericsson U8520 Platform HREFP520")
692         .atag_offset    = 0x100,
693         .map_io         = u8500_map_io,
694         .init_irq       = ux500_init_irq,
695         .init_time      = ux500_timer_init,
696         .init_machine   = mop500_init_machine,
697         .init_late      = ux500_init_late,
698         .restart        = ux500_restart,
699 MACHINE_END
700
701 MACHINE_START(HREFV60, "ST-Ericsson U8500 Platform HREFv60+")
702         .atag_offset    = 0x100,
703         .smp            = smp_ops(ux500_smp_ops),
704         .map_io         = u8500_map_io,
705         .init_irq       = ux500_init_irq,
706         .init_time      = ux500_timer_init,
707         .init_machine   = hrefv60_init_machine,
708         .init_late      = ux500_init_late,
709         .restart        = ux500_restart,
710 MACHINE_END
711
712 MACHINE_START(SNOWBALL, "Calao Systems Snowball platform")
713         .atag_offset    = 0x100,
714         .smp            = smp_ops(ux500_smp_ops),
715         .map_io         = u8500_map_io,
716         .init_irq       = ux500_init_irq,
717         /* we re-use nomadik timer here */
718         .init_time      = ux500_timer_init,
719         .init_machine   = snowball_init_machine,
720         .init_late      = NULL,
721         .restart        = ux500_restart,
722 MACHINE_END