diff options
Diffstat (limited to 'arch/arm/mach-exynos/mach-nuri.c')
-rw-r--r-- | arch/arm/mach-exynos/mach-nuri.c | 47 |
1 files changed, 43 insertions, 4 deletions
diff --git a/arch/arm/mach-exynos/mach-nuri.c b/arch/arm/mach-exynos/mach-nuri.c index b4f1f902ce6..6c31f2ad765 100644 --- a/arch/arm/mach-exynos/mach-nuri.c +++ b/arch/arm/mach-exynos/mach-nuri.c @@ -25,6 +25,8 @@ #include <linux/mmc/host.h> #include <linux/fb.h> #include <linux/pwm_backlight.h> +#include <linux/platform_data/s3c-hsotg.h> +#include <drm/exynos_drm.h> #include <video/platform_lcd.h> #include <media/m5mols.h> @@ -112,8 +114,8 @@ static struct s3c_sdhci_platdata nuri_hsmmc0_data __initdata = { .host_caps = (MMC_CAP_8_BIT_DATA | MMC_CAP_4_BIT_DATA | MMC_CAP_MMC_HIGHSPEED | MMC_CAP_SD_HIGHSPEED | MMC_CAP_ERASE), + .host_caps2 = MMC_CAP2_BROKEN_VOLTAGE, .cd_type = S3C_SDHCI_CD_PERMANENT, - .clk_type = S3C_SDHCI_CLK_DIV_EXTERNAL, }; static struct regulator_consumer_supply emmc_supplies[] = { @@ -154,7 +156,6 @@ static struct s3c_sdhci_platdata nuri_hsmmc2_data __initdata = { .ext_cd_gpio = EXYNOS4_GPX3(3), /* XEINT_27 */ .ext_cd_gpio_invert = 1, .cd_type = S3C_SDHCI_CD_GPIO, - .clk_type = S3C_SDHCI_CLK_DIV_EXTERNAL, }; /* WLAN */ @@ -163,7 +164,6 @@ static struct s3c_sdhci_platdata nuri_hsmmc3_data __initdata = { .host_caps = MMC_CAP_4_BIT_DATA | MMC_CAP_MMC_HIGHSPEED | MMC_CAP_SD_HIGHSPEED, .cd_type = S3C_SDHCI_CD_EXTERNAL, - .clk_type = S3C_SDHCI_CLK_DIV_EXTERNAL, }; static void __init nuri_sdhci_init(void) @@ -212,6 +212,29 @@ static struct platform_device nuri_gpio_keys = { }, }; +#ifdef CONFIG_DRM_EXYNOS +static struct exynos_drm_fimd_pdata drm_fimd_pdata = { + .panel = { + .timing = { + .xres = 1024, + .yres = 600, + .hsync_len = 40, + .left_margin = 79, + .right_margin = 200, + .vsync_len = 10, + .upper_margin = 10, + .lower_margin = 11, + .refresh = 60, + }, + }, + .vidcon0 = VIDCON0_VIDOUT_RGB | VIDCON0_PNRMODE_RGB | + VIDCON0_CLKSEL_LCD, + .vidcon1 = VIDCON1_INV_HSYNC | VIDCON1_INV_VSYNC, + .default_win = 3, + .bpp = 32, +}; + +#else /* Frame Buffer */ static struct s3c_fb_pd_win nuri_fb_win0 = { .win_mode = { @@ -238,6 +261,7 @@ static struct s3c_fb_platdata nuri_fb_pdata __initdata = { .vidcon1 = VIDCON1_INV_HSYNC | VIDCON1_INV_VSYNC, .setup_gpio = exynos4_fimd0_gpio_setup_24bpp, }; +#endif static void nuri_lcd_power_on(struct plat_lcd_data *pd, unsigned int power) { @@ -350,6 +374,7 @@ static struct regulator_consumer_supply __initdata max8997_ldo1_[] = { REGULATOR_SUPPLY("vdd", "s5p-adc"), /* Used by CPU's ADC drv */ }; static struct regulator_consumer_supply __initdata max8997_ldo3_[] = { + REGULATOR_SUPPLY("vusb_d", "s3c-hsotg"), /* USB */ REGULATOR_SUPPLY("vdd11", "s5p-mipi-csis.0"), /* MIPI */ }; static struct regulator_consumer_supply __initdata max8997_ldo4_[] = { @@ -365,7 +390,7 @@ static struct regulator_consumer_supply __initdata max8997_ldo7_[] = { REGULATOR_SUPPLY("dig_18", "0-001f"), /* HCD803 */ }; static struct regulator_consumer_supply __initdata max8997_ldo8_[] = { - REGULATOR_SUPPLY("vusb_d", NULL), /* Used by CPU */ + REGULATOR_SUPPLY("vusb_a", "s3c-hsotg"), /* USB */ REGULATOR_SUPPLY("vdac", NULL), /* Used by CPU */ }; static struct regulator_consumer_supply __initdata max8997_ldo11_[] = { @@ -821,6 +846,7 @@ static struct regulator_init_data __initdata max8997_esafeout1_data = { .constraints = { .name = "SAFEOUT1", .valid_ops_mask = REGULATOR_CHANGE_STATUS, + .always_on = 1, .state_mem = { .disabled = 1, }, @@ -1078,6 +1104,9 @@ static void __init nuri_ehci_init(void) s5p_ehci_set_platdata(pdata); } +/* USB OTG */ +static struct s3c_hsotg_plat nuri_hsotg_pdata; + /* CAMERA */ static struct regulator_consumer_supply cam_vt_cam15_supply = REGULATOR_SUPPLY("vdd_core", "6-003c"); @@ -1290,6 +1319,7 @@ static struct platform_device *nuri_devices[] __initdata = { &s5p_device_mfc_l, &s5p_device_mfc_r, &s5p_device_fimc_md, + &s3c_device_usb_hsotg, /* NURI Devices */ &nuri_gpio_keys, @@ -1301,6 +1331,9 @@ static struct platform_device *nuri_devices[] __initdata = { &cam_vdda_fixed_rdev, &cam_8m_12v_fixed_rdev, &exynos4_bus_devfreq, +#ifdef CONFIG_DRM_EXYNOS + &exynos_device_drm, +#endif }; static void __init nuri_map_io(void) @@ -1333,11 +1366,17 @@ static void __init nuri_machine_init(void) i2c_register_board_info(9, i2c9_devs, ARRAY_SIZE(i2c9_devs)); s3c_i2c6_set_platdata(&nuri_i2c6_platdata); +#ifdef CONFIG_DRM_EXYNOS + s5p_device_fimd0.dev.platform_data = &drm_fimd_pdata; + exynos4_fimd0_gpio_setup_24bpp(); +#else s5p_fimd0_set_platdata(&nuri_fb_pdata); +#endif nuri_camera_init(); nuri_ehci_init(); + s3c_hsotg_set_platdata(&nuri_hsotg_pdata); /* Last */ platform_add_devices(nuri_devices, ARRAY_SIZE(nuri_devices)); |