1 /* linux/arch/arm/mach-s5pv210/mach-goni.c
3 * Copyright (c) 2010 Samsung Electronics Co., Ltd.
4 * http://www.samsung.com/
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.
11 #include <linux/kernel.h>
12 #include <linux/types.h>
13 #include <linux/init.h>
14 #include <linux/serial_core.h>
15 #include <linux/serial_s3c.h>
17 #include <linux/i2c.h>
18 #include <linux/i2c-gpio.h>
19 #include <linux/i2c/atmel_mxt_ts.h>
20 #include <linux/mfd/max8998.h>
21 #include <linux/mfd/wm8994/pdata.h>
22 #include <linux/regulator/fixed.h>
23 #include <linux/spi/spi.h>
24 #include <linux/spi/spi_gpio.h>
25 #include <linux/lcd.h>
26 #include <linux/gpio_keys.h>
27 #include <linux/input.h>
28 #include <linux/gpio.h>
29 #include <linux/mmc/host.h>
30 #include <linux/interrupt.h>
31 #include <linux/platform_data/s3c-hsotg.h>
33 #include <asm/mach/arch.h>
34 #include <asm/mach/map.h>
35 #include <asm/setup.h>
36 #include <asm/mach-types.h>
38 #include <video/samsung_fimd.h>
40 #include <mach/regs-clock.h>
42 #include <plat/gpio-cfg.h>
43 #include <plat/devs.h>
46 #include <linux/platform_data/i2c-s3c2410.h>
47 #include <plat/keypad.h>
48 #include <plat/sdhci.h>
49 #include <plat/clock.h>
50 #include <plat/samsung-time.h>
55 /* Following are default values for UCON, ULCON and UFCON UART registers */
56 #define GONI_UCON_DEFAULT (S3C2410_UCON_TXILEVEL | \
57 S3C2410_UCON_RXILEVEL | \
58 S3C2410_UCON_TXIRQMODE | \
59 S3C2410_UCON_RXIRQMODE | \
60 S3C2410_UCON_RXFIFO_TOI | \
61 S3C2443_UCON_RXERR_IRQEN)
63 #define GONI_ULCON_DEFAULT S3C2410_LCON_CS8
65 #define GONI_UFCON_DEFAULT S3C2410_UFCON_FIFOMODE
67 static struct s3c2410_uartcfg goni_uartcfgs
[] __initdata
= {
71 .ucon
= GONI_UCON_DEFAULT
,
72 .ulcon
= GONI_ULCON_DEFAULT
,
73 .ufcon
= GONI_UFCON_DEFAULT
|
74 S5PV210_UFCON_TXTRIG256
| S5PV210_UFCON_RXTRIG256
,
79 .ucon
= GONI_UCON_DEFAULT
,
80 .ulcon
= GONI_ULCON_DEFAULT
,
81 .ufcon
= GONI_UFCON_DEFAULT
|
82 S5PV210_UFCON_TXTRIG64
| S5PV210_UFCON_RXTRIG64
,
87 .ucon
= GONI_UCON_DEFAULT
,
88 .ulcon
= GONI_ULCON_DEFAULT
,
89 .ufcon
= GONI_UFCON_DEFAULT
|
90 S5PV210_UFCON_TXTRIG16
| S5PV210_UFCON_RXTRIG16
,
95 .ucon
= GONI_UCON_DEFAULT
,
96 .ulcon
= GONI_ULCON_DEFAULT
,
97 .ufcon
= GONI_UFCON_DEFAULT
|
98 S5PV210_UFCON_TXTRIG16
| S5PV210_UFCON_RXTRIG16
,
103 static struct s3c_fb_pd_win goni_fb_win0
= {
109 .virtual_y
= 2 * 800,
112 static struct fb_videomode goni_lcd_timing
= {
124 static struct s3c_fb_platdata goni_lcd_pdata __initdata
= {
125 .win
[0] = &goni_fb_win0
,
126 .vtiming
= &goni_lcd_timing
,
127 .vidcon0
= VIDCON0_VIDOUT_RGB
| VIDCON0_PNRMODE_RGB
|
129 .vidcon1
= VIDCON1_INV_VCLK
| VIDCON1_INV_VDEN
130 | VIDCON1_INV_HSYNC
| VIDCON1_INV_VSYNC
,
131 .setup_gpio
= s5pv210_fb_gpio_setup_24bpp
,
134 static int lcd_power_on(struct lcd_device
*ld
, int enable
)
139 static int reset_lcd(struct lcd_device
*ld
)
141 static unsigned int first
= 1;
144 reset_gpio
= S5PV210_MP05(5);
147 gpio_request(reset_gpio
, "MLCD_RST");
151 gpio_direction_output(reset_gpio
, 1);
155 static struct lcd_platform_data goni_lcd_platform_data
= {
157 .power_on
= lcd_power_on
,
159 .reset_delay
= 120, /* 120ms */
160 .power_on_delay
= 25, /* 25ms */
161 .power_off_delay
= 200, /* 200ms */
164 #define LCD_BUS_NUM 3
165 static struct spi_board_info spi_board_info
[] __initdata
= {
167 .modalias
= "s6e63m0",
168 .platform_data
= &goni_lcd_platform_data
,
169 .max_speed_hz
= 1200000,
170 .bus_num
= LCD_BUS_NUM
,
173 .controller_data
= (void *)S5PV210_MP01(1), /* DISPLAY_CS */
177 static struct spi_gpio_platform_data lcd_spi_gpio_data
= {
178 .sck
= S5PV210_MP04(1), /* DISPLAY_CLK */
179 .mosi
= S5PV210_MP04(3), /* DISPLAY_SI */
180 .miso
= SPI_GPIO_NO_MISO
,
184 static struct platform_device goni_spi_gpio
= {
188 .parent
= &s3c_device_fb
.dev
,
189 .platform_data
= &lcd_spi_gpio_data
,
194 static uint32_t keymap
[] __initdata
= {
195 /* KEY(row, col, keycode) */
196 KEY(0, 1, KEY_MENU
), /* Send */
197 KEY(0, 2, KEY_BACK
), /* End */
198 KEY(1, 1, KEY_CONFIG
), /* Half shot */
199 KEY(1, 2, KEY_VOLUMEUP
),
200 KEY(2, 1, KEY_CAMERA
), /* Full shot */
201 KEY(2, 2, KEY_VOLUMEDOWN
),
204 static struct matrix_keymap_data keymap_data __initdata
= {
206 .keymap_size
= ARRAY_SIZE(keymap
),
209 static struct samsung_keypad_platdata keypad_data __initdata
= {
210 .keymap_data
= &keymap_data
,
216 static struct i2c_board_info i2c1_devs
[] __initdata
= {
218 I2C_BOARD_INFO("si470x", 0x10),
222 static void __init
goni_radio_init(void)
226 gpio
= S5PV210_GPJ2(4); /* XMSMDATA_4 */
227 gpio_request(gpio
, "FM_INT");
228 s3c_gpio_cfgpin(gpio
, S3C_GPIO_SFN(0xf));
229 i2c1_devs
[0].irq
= gpio_to_irq(gpio
);
231 gpio
= S5PV210_GPJ2(5); /* XMSMDATA_5 */
232 gpio_request_one(gpio
, GPIOF_OUT_INIT_HIGH
, "FM_RST");
236 static struct mxt_platform_data qt602240_platform_data
= {
237 .irqflags
= IRQF_TRIGGER_FALLING
,
240 static struct s3c2410_platform_i2c i2c2_data __initdata
= {
244 .frequency
= 400 * 1000,
248 static struct i2c_board_info i2c2_devs
[] __initdata
= {
250 I2C_BOARD_INFO("qt602240_ts", 0x4a),
251 .platform_data
= &qt602240_platform_data
,
255 static void __init
goni_tsp_init(void)
259 gpio
= S5PV210_GPJ1(3); /* XMSMADDR_11 */
260 gpio_request_one(gpio
, GPIOF_OUT_INIT_HIGH
, "TSP_LDO_ON");
261 gpio_export(gpio
, 0);
263 gpio
= S5PV210_GPJ0(5); /* XMSMADDR_5 */
264 gpio_request(gpio
, "TSP_INT");
266 s5p_register_gpio_interrupt(gpio
);
267 s3c_gpio_cfgpin(gpio
, S3C_GPIO_SFN(0xf));
268 s3c_gpio_setpull(gpio
, S3C_GPIO_PULL_UP
);
269 i2c2_devs
[0].irq
= gpio_to_irq(gpio
);
273 static struct s3c_hsotg_plat goni_hsotg_pdata
;
275 /* MAX8998 regulators */
276 #if defined(CONFIG_REGULATOR_MAX8998) || defined(CONFIG_REGULATOR_MAX8998_MODULE)
278 static struct regulator_consumer_supply goni_ldo3_consumers
[] = {
279 REGULATOR_SUPPLY("vusb_a", "s3c-hsotg"),
282 static struct regulator_consumer_supply goni_ldo5_consumers
[] = {
283 REGULATOR_SUPPLY("vmmc", "s3c-sdhci.0"),
286 static struct regulator_consumer_supply goni_ldo8_consumers
[] = {
287 REGULATOR_SUPPLY("vusb_d", "s3c-hsotg"),
288 REGULATOR_SUPPLY("vdd33a_dac", "s5p-sdo"),
291 static struct regulator_consumer_supply goni_ldo11_consumers
[] = {
292 REGULATOR_SUPPLY("vddio", "0-0030"), /* "CAM_IO_2.8V" */
295 static struct regulator_consumer_supply goni_ldo13_consumers
[] = {
296 REGULATOR_SUPPLY("vdda", "0-0030"), /* "CAM_A_2.8V" */
299 static struct regulator_consumer_supply goni_ldo14_consumers
[] = {
300 REGULATOR_SUPPLY("vdd_core", "0-0030"), /* "CAM_CIF_1.8V" */
303 static struct regulator_init_data goni_ldo2_data
= {
305 .name
= "VALIVE_1.1V",
316 static struct regulator_init_data goni_ldo3_data
= {
318 .name
= "VUSB+MIPI_1.1V",
322 .valid_ops_mask
= REGULATOR_CHANGE_STATUS
,
324 .num_consumer_supplies
= ARRAY_SIZE(goni_ldo3_consumers
),
325 .consumer_supplies
= goni_ldo3_consumers
,
328 static struct regulator_init_data goni_ldo4_data
= {
337 static struct regulator_init_data goni_ldo5_data
= {
343 .valid_ops_mask
= REGULATOR_CHANGE_STATUS
,
345 .num_consumer_supplies
= ARRAY_SIZE(goni_ldo5_consumers
),
346 .consumer_supplies
= goni_ldo5_consumers
,
349 static struct regulator_init_data goni_ldo6_data
= {
358 static struct regulator_init_data goni_ldo7_data
= {
368 static struct regulator_init_data goni_ldo8_data
= {
370 .name
= "VUSB+VADC_3.3V",
374 .valid_ops_mask
= REGULATOR_CHANGE_STATUS
,
376 .num_consumer_supplies
= ARRAY_SIZE(goni_ldo8_consumers
),
377 .consumer_supplies
= goni_ldo8_consumers
,
380 static struct regulator_init_data goni_ldo9_data
= {
382 .name
= "VCC+VCAM_2.8V",
389 static struct regulator_init_data goni_ldo10_data
= {
399 static struct regulator_init_data goni_ldo11_data
= {
401 .name
= "CAM_IO_2.8V",
405 .valid_ops_mask
= REGULATOR_CHANGE_STATUS
,
407 .num_consumer_supplies
= ARRAY_SIZE(goni_ldo11_consumers
),
408 .consumer_supplies
= goni_ldo11_consumers
,
411 static struct regulator_init_data goni_ldo12_data
= {
413 .name
= "CAM_ISP_1.2V",
420 static struct regulator_init_data goni_ldo13_data
= {
422 .name
= "CAM_A_2.8V",
426 .valid_ops_mask
= REGULATOR_CHANGE_STATUS
,
428 .num_consumer_supplies
= ARRAY_SIZE(goni_ldo13_consumers
),
429 .consumer_supplies
= goni_ldo13_consumers
,
432 static struct regulator_init_data goni_ldo14_data
= {
434 .name
= "CAM_CIF_1.8V",
438 .valid_ops_mask
= REGULATOR_CHANGE_STATUS
,
440 .num_consumer_supplies
= ARRAY_SIZE(goni_ldo14_consumers
),
441 .consumer_supplies
= goni_ldo14_consumers
,
444 static struct regulator_init_data goni_ldo15_data
= {
446 .name
= "CAM_AF_3.3V",
453 static struct regulator_init_data goni_ldo16_data
= {
455 .name
= "VMIPI_1.8V",
462 static struct regulator_init_data goni_ldo17_data
= {
464 .name
= "VCC_3.0V_LCD",
473 static struct regulator_consumer_supply buck1_consumer
=
474 REGULATOR_SUPPLY("vddarm", NULL
);
476 static struct regulator_consumer_supply buck2_consumer
=
477 REGULATOR_SUPPLY("vddint", NULL
);
479 static struct regulator_consumer_supply buck3_consumer
=
480 REGULATOR_SUPPLY("vdet", "s5p-sdo");
483 static struct regulator_init_data goni_buck1_data
= {
489 .valid_ops_mask
= REGULATOR_CHANGE_VOLTAGE
|
490 REGULATOR_CHANGE_STATUS
,
492 .num_consumer_supplies
= 1,
493 .consumer_supplies
= &buck1_consumer
,
496 static struct regulator_init_data goni_buck2_data
= {
502 .valid_ops_mask
= REGULATOR_CHANGE_VOLTAGE
|
503 REGULATOR_CHANGE_STATUS
,
505 .num_consumer_supplies
= 1,
506 .consumer_supplies
= &buck2_consumer
,
509 static struct regulator_init_data goni_buck3_data
= {
519 .num_consumer_supplies
= 1,
520 .consumer_supplies
= &buck3_consumer
,
523 static struct regulator_init_data goni_buck4_data
= {
525 .name
= "CAM_CORE_1.2V",
533 static struct max8998_regulator_data goni_regulators
[] = {
534 { MAX8998_LDO2
, &goni_ldo2_data
},
535 { MAX8998_LDO3
, &goni_ldo3_data
},
536 { MAX8998_LDO4
, &goni_ldo4_data
},
537 { MAX8998_LDO5
, &goni_ldo5_data
},
538 { MAX8998_LDO6
, &goni_ldo6_data
},
539 { MAX8998_LDO7
, &goni_ldo7_data
},
540 { MAX8998_LDO8
, &goni_ldo8_data
},
541 { MAX8998_LDO9
, &goni_ldo9_data
},
542 { MAX8998_LDO10
, &goni_ldo10_data
},
543 { MAX8998_LDO11
, &goni_ldo11_data
},
544 { MAX8998_LDO12
, &goni_ldo12_data
},
545 { MAX8998_LDO13
, &goni_ldo13_data
},
546 { MAX8998_LDO14
, &goni_ldo14_data
},
547 { MAX8998_LDO15
, &goni_ldo15_data
},
548 { MAX8998_LDO16
, &goni_ldo16_data
},
549 { MAX8998_LDO17
, &goni_ldo17_data
},
550 { MAX8998_BUCK1
, &goni_buck1_data
},
551 { MAX8998_BUCK2
, &goni_buck2_data
},
552 { MAX8998_BUCK3
, &goni_buck3_data
},
553 { MAX8998_BUCK4
, &goni_buck4_data
},
556 static struct max8998_platform_data goni_max8998_pdata
= {
557 .num_regulators
= ARRAY_SIZE(goni_regulators
),
558 .regulators
= goni_regulators
,
559 .buck1_set1
= S5PV210_GPH0(3),
560 .buck1_set2
= S5PV210_GPH0(4),
561 .buck2_set3
= S5PV210_GPH0(5),
562 .buck1_voltage
= { 1200000, 1200000, 1200000, 1200000 },
563 .buck2_voltage
= { 1200000, 1200000 },
567 static struct regulator_consumer_supply wm8994_fixed_voltage0_supplies
[] = {
568 REGULATOR_SUPPLY("DBVDD", "5-001a"),
569 REGULATOR_SUPPLY("AVDD2", "5-001a"),
570 REGULATOR_SUPPLY("CPVDD", "5-001a"),
573 static struct regulator_consumer_supply wm8994_fixed_voltage1_supplies
[] = {
574 REGULATOR_SUPPLY("SPKVDD1", "5-001a"),
575 REGULATOR_SUPPLY("SPKVDD2", "5-001a"),
578 static struct regulator_init_data wm8994_fixed_voltage0_init_data
= {
582 .num_consumer_supplies
= ARRAY_SIZE(wm8994_fixed_voltage0_supplies
),
583 .consumer_supplies
= wm8994_fixed_voltage0_supplies
,
586 static struct regulator_init_data wm8994_fixed_voltage1_init_data
= {
590 .num_consumer_supplies
= ARRAY_SIZE(wm8994_fixed_voltage1_supplies
),
591 .consumer_supplies
= wm8994_fixed_voltage1_supplies
,
594 static struct fixed_voltage_config wm8994_fixed_voltage0_config
= {
595 .supply_name
= "VCC_1.8V_PDA",
596 .microvolts
= 1800000,
598 .init_data
= &wm8994_fixed_voltage0_init_data
,
601 static struct fixed_voltage_config wm8994_fixed_voltage1_config
= {
602 .supply_name
= "V_BAT",
603 .microvolts
= 3700000,
605 .init_data
= &wm8994_fixed_voltage1_init_data
,
608 static struct platform_device wm8994_fixed_voltage0
= {
609 .name
= "reg-fixed-voltage",
612 .platform_data
= &wm8994_fixed_voltage0_config
,
616 static struct platform_device wm8994_fixed_voltage1
= {
617 .name
= "reg-fixed-voltage",
620 .platform_data
= &wm8994_fixed_voltage1_config
,
624 static struct regulator_consumer_supply wm8994_avdd1_supply
=
625 REGULATOR_SUPPLY("AVDD1", "5-001a");
627 static struct regulator_consumer_supply wm8994_dcvdd_supply
=
628 REGULATOR_SUPPLY("DCVDD", "5-001a");
630 static struct regulator_init_data wm8994_ldo1_data
= {
632 .name
= "AVDD1_3.0V",
633 .valid_ops_mask
= REGULATOR_CHANGE_STATUS
,
635 .num_consumer_supplies
= 1,
636 .consumer_supplies
= &wm8994_avdd1_supply
,
639 static struct regulator_init_data wm8994_ldo2_data
= {
641 .name
= "DCVDD_1.0V",
643 .num_consumer_supplies
= 1,
644 .consumer_supplies
= &wm8994_dcvdd_supply
,
647 static struct wm8994_pdata wm8994_platform_data
= {
648 /* configure gpio1 function: 0x0001(Logic level input/output) */
649 .gpio_defaults
[0] = 0x0001,
650 /* configure gpio3/4/5/7 function for AIF2 voice */
651 .gpio_defaults
[2] = 0x8100,
652 .gpio_defaults
[3] = 0x8100,
653 .gpio_defaults
[4] = 0x8100,
654 .gpio_defaults
[6] = 0x0100,
655 /* configure gpio8/9/10/11 function for AIF3 BT */
656 .gpio_defaults
[7] = 0x8100,
657 .gpio_defaults
[8] = 0x0100,
658 .gpio_defaults
[9] = 0x0100,
659 .gpio_defaults
[10] = 0x0100,
660 .ldo
[0] = { S5PV210_MP03(6), &wm8994_ldo1_data
}, /* XM0FRNB_2 */
661 .ldo
[1] = { 0, &wm8994_ldo2_data
},
665 #define AP_I2C_GPIO_PMIC_BUS_4 4
666 static struct i2c_gpio_platform_data goni_i2c_gpio_pmic_data
= {
667 .sda_pin
= S5PV210_GPJ4(0), /* XMSMCSN */
668 .scl_pin
= S5PV210_GPJ4(3), /* XMSMIRQN */
671 static struct platform_device goni_i2c_gpio_pmic
= {
673 .id
= AP_I2C_GPIO_PMIC_BUS_4
,
675 .platform_data
= &goni_i2c_gpio_pmic_data
,
679 static struct i2c_board_info i2c_gpio_pmic_devs
[] __initdata
= {
680 #if defined(CONFIG_REGULATOR_MAX8998) || defined(CONFIG_REGULATOR_MAX8998_MODULE)
682 /* 0xCC when SRAD = 0 */
683 I2C_BOARD_INFO("max8998", 0xCC >> 1),
684 .platform_data
= &goni_max8998_pdata
,
689 /* GPIO I2C AP 1.8V */
690 #define AP_I2C_GPIO_BUS_5 5
691 static struct i2c_gpio_platform_data goni_i2c_gpio5_data
= {
692 .sda_pin
= S5PV210_MP05(3), /* XM0ADDR_11 */
693 .scl_pin
= S5PV210_MP05(2), /* XM0ADDR_10 */
696 static struct platform_device goni_i2c_gpio5
= {
698 .id
= AP_I2C_GPIO_BUS_5
,
700 .platform_data
= &goni_i2c_gpio5_data
,
704 static struct i2c_board_info i2c_gpio5_devs
[] __initdata
= {
706 /* CS/ADDR = low 0x34 (FYI: high = 0x36) */
707 I2C_BOARD_INFO("wm8994", 0x1a),
708 .platform_data
= &wm8994_platform_data
,
712 /* PMIC Power button */
713 static struct gpio_keys_button goni_gpio_keys_table
[] = {
716 .gpio
= S5PV210_GPH2(6),
717 .desc
= "gpio-keys: KEY_POWER",
721 .debounce_interval
= 1,
725 static struct gpio_keys_platform_data goni_gpio_keys_data
= {
726 .buttons
= goni_gpio_keys_table
,
727 .nbuttons
= ARRAY_SIZE(goni_gpio_keys_table
),
730 static struct platform_device goni_device_gpiokeys
= {
733 .platform_data
= &goni_gpio_keys_data
,
737 static void __init
goni_pmic_init(void)
739 /* AP_PMIC_IRQ: EINT7 */
740 s3c_gpio_cfgpin(S5PV210_GPH0(7), S3C_GPIO_SFN(0xf));
741 s3c_gpio_setpull(S5PV210_GPH0(7), S3C_GPIO_PULL_UP
);
744 s3c_gpio_cfgpin(S5PV210_GPH2(6), S3C_GPIO_SFN(0xf));
745 s3c_gpio_setpull(S5PV210_GPH2(6), S3C_GPIO_PULL_UP
);
749 static struct s3c_sdhci_platdata goni_hsmmc0_data __initdata
= {
751 .cd_type
= S3C_SDHCI_CD_PERMANENT
,
755 static struct s3c_sdhci_platdata goni_hsmmc1_data __initdata
= {
757 .cd_type
= S3C_SDHCI_CD_EXTERNAL
,
758 /* ext_cd_{init,cleanup} callbacks will be added later */
762 #define GONI_EXT_FLASH_EN S5PV210_MP05(4)
763 #define GONI_EXT_FLASH_CD S5PV210_GPH3(4)
764 static struct s3c_sdhci_platdata goni_hsmmc2_data __initdata
= {
766 .cd_type
= S3C_SDHCI_CD_GPIO
,
767 .ext_cd_gpio
= GONI_EXT_FLASH_CD
,
768 .ext_cd_gpio_invert
= 1,
771 static struct regulator_consumer_supply mmc2_supplies
[] = {
772 REGULATOR_SUPPLY("vmmc", "s3c-sdhci.2"),
775 static struct regulator_init_data mmc2_fixed_voltage_init_data
= {
778 .valid_ops_mask
= REGULATOR_CHANGE_STATUS
,
780 .num_consumer_supplies
= ARRAY_SIZE(mmc2_supplies
),
781 .consumer_supplies
= mmc2_supplies
,
784 static struct fixed_voltage_config mmc2_fixed_voltage_config
= {
785 .supply_name
= "EXT_FLASH_EN",
786 .microvolts
= 2800000,
787 .gpio
= GONI_EXT_FLASH_EN
,
789 .init_data
= &mmc2_fixed_voltage_init_data
,
792 static struct platform_device mmc2_fixed_voltage
= {
793 .name
= "reg-fixed-voltage",
796 .platform_data
= &mmc2_fixed_voltage_config
,
800 static void goni_setup_sdhci(void)
802 s3c_sdhci0_set_platdata(&goni_hsmmc0_data
);
803 s3c_sdhci1_set_platdata(&goni_hsmmc1_data
);
804 s3c_sdhci2_set_platdata(&goni_hsmmc2_data
);
808 static struct platform_device goni_device_audio
= {
809 .name
= "smdk-audio",
813 static struct platform_device
*goni_devices
[] __initdata
= {
821 &goni_device_gpiokeys
,
831 &s5pv210_device_iis0
,
832 &s3c_device_usb_hsotg
,
833 &samsung_device_keypad
,
836 &wm8994_fixed_voltage0
,
837 &wm8994_fixed_voltage1
,
840 static void __init
goni_sound_init(void)
842 /* Ths main clock of WM8994 codec uses the output of CLKOUT pin.
843 * The CLKOUT[9:8] set to 0x3(XUSBXTI) of 0xE010E000(OTHERS)
844 * because it needs 24MHz clock to operate WM8994 codec.
846 __raw_writel(__raw_readl(S5P_OTHERS
) | (0x3 << 8), S5P_OTHERS
);
849 static void __init
goni_map_io(void)
851 s5pv210_init_io(NULL
, 0);
852 s3c24xx_init_clocks(clk_xusbxti
.rate
);
853 s3c24xx_init_uarts(goni_uartcfgs
, ARRAY_SIZE(goni_uartcfgs
));
854 samsung_set_timer_source(SAMSUNG_PWM3
, SAMSUNG_PWM4
);
857 static void __init
goni_reserve(void)
859 s5p_mfc_reserve_mem(0x43000000, 8 << 20, 0x51000000, 8 << 20);
862 static void __init
goni_machine_init(void)
864 /* Radio: call before I2C 1 registeration */
868 s3c_i2c0_set_platdata(NULL
);
871 s3c_i2c1_set_platdata(NULL
);
872 i2c_register_board_info(1, i2c1_devs
, ARRAY_SIZE(i2c1_devs
));
874 /* TSP: call before I2C 2 registeration */
878 s3c_i2c2_set_platdata(&i2c2_data
);
879 i2c_register_board_info(2, i2c2_devs
, ARRAY_SIZE(i2c2_devs
));
883 i2c_register_board_info(AP_I2C_GPIO_PMIC_BUS_4
, i2c_gpio_pmic_devs
,
884 ARRAY_SIZE(i2c_gpio_pmic_devs
));
890 i2c_register_board_info(AP_I2C_GPIO_BUS_5
, i2c_gpio5_devs
,
891 ARRAY_SIZE(i2c_gpio5_devs
));
894 s3c_fb_set_platdata(&goni_lcd_pdata
);
896 s3c_hsotg_set_platdata(&goni_hsotg_pdata
);
899 spi_register_board_info(spi_board_info
, ARRAY_SIZE(spi_board_info
));
902 samsung_keypad_set_platdata(&keypad_data
);
904 platform_add_devices(goni_devices
, ARRAY_SIZE(goni_devices
));
907 MACHINE_START(GONI
, "GONI")
908 /* Maintainers: Kyungmin Park <kyungmin.park@samsung.com> */
909 .atag_offset
= 0x100,
910 .init_irq
= s5pv210_init_irq
,
911 .map_io
= goni_map_io
,
912 .init_machine
= goni_machine_init
,
913 .init_time
= samsung_timer_init
,
914 .reserve
= &goni_reserve
,
915 .restart
= s5pv210_restart
,