Tom Rini | 10e4779 | 2018-05-06 17:58:06 -0400 | [diff] [blame] | 1 | // SPDX-License-Identifier: GPL-2.0+ |
Piotr Wilczek | 2b3c92a | 2013-09-20 15:01:27 +0200 | [diff] [blame] | 2 | /* |
| 3 | * Copyright (c) 2013 Samsung Electronics Co., Ltd. All rights reserved. |
| 4 | * Sanghee Kim <sh0130.kim@samsung.com> |
| 5 | * Piotr Wilczek <p.wilczek@samsung.com> |
Piotr Wilczek | 2b3c92a | 2013-09-20 15:01:27 +0200 | [diff] [blame] | 6 | */ |
| 7 | |
| 8 | #include <common.h> |
| 9 | #include <lcd.h> |
Simon Glass | 0f2af88 | 2020-05-10 11:40:05 -0600 | [diff] [blame] | 10 | #include <log.h> |
Simon Glass | 37f1162 | 2014-10-20 19:48:37 -0600 | [diff] [blame] | 11 | #include <asm/gpio.h> |
Piotr Wilczek | 2b3c92a | 2013-09-20 15:01:27 +0200 | [diff] [blame] | 12 | #include <asm/arch/pinmux.h> |
| 13 | #include <asm/arch/power.h> |
Piotr Wilczek | 87d2e78 | 2014-03-07 14:59:49 +0100 | [diff] [blame] | 14 | #include <asm/arch/mipi_dsim.h> |
Simon Glass | dbd7954 | 2020-05-10 11:40:11 -0600 | [diff] [blame] | 15 | #include <linux/delay.h> |
Piotr Wilczek | 2b3c92a | 2013-09-20 15:01:27 +0200 | [diff] [blame] | 16 | #include <power/pmic.h> |
| 17 | #include <power/max77686_pmic.h> |
| 18 | #include <power/battery.h> |
| 19 | #include <power/max77693_pmic.h> |
| 20 | #include <power/max77693_muic.h> |
| 21 | #include <power/max77693_fg.h> |
| 22 | #include <libtizen.h> |
| 23 | #include <errno.h> |
Piotr Wilczek | 0c2ba4c | 2013-11-21 15:46:45 +0100 | [diff] [blame] | 24 | #include <usb.h> |
Marek Vasut | f1be9cb | 2015-12-04 02:51:20 +0100 | [diff] [blame] | 25 | #include <usb/dwc2_udc.h> |
Piotr Wilczek | 0c2ba4c | 2013-11-21 15:46:45 +0100 | [diff] [blame] | 26 | #include <usb_mass_storage.h> |
Piotr Wilczek | 2b3c92a | 2013-09-20 15:01:27 +0200 | [diff] [blame] | 27 | |
Piotr Wilczek | 2b3c92a | 2013-09-20 15:01:27 +0200 | [diff] [blame] | 28 | static unsigned int board_rev = -1; |
| 29 | |
| 30 | static inline u32 get_model_rev(void); |
| 31 | |
| 32 | static void check_hw_revision(void) |
| 33 | { |
| 34 | int modelrev = 0; |
Simon Glass | 4f83d3d | 2014-10-20 19:48:39 -0600 | [diff] [blame] | 35 | char str[12]; |
Piotr Wilczek | 2b3c92a | 2013-09-20 15:01:27 +0200 | [diff] [blame] | 36 | int i; |
| 37 | |
Piotr Wilczek | 2b3c92a | 2013-09-20 15:01:27 +0200 | [diff] [blame] | 38 | /* |
| 39 | * GPM1[1:0]: MODEL_REV[1:0] |
| 40 | * Don't set as pull-none for these N/C pin. |
| 41 | * TRM say that it may cause unexcepted state and leakage current. |
| 42 | * and pull-none is only for output function. |
| 43 | */ |
Simon Glass | 4f83d3d | 2014-10-20 19:48:39 -0600 | [diff] [blame] | 44 | for (i = 0; i < 2; i++) { |
| 45 | int pin = i + EXYNOS4X12_GPIO_M10; |
| 46 | |
| 47 | sprintf(str, "model_rev%d", i); |
| 48 | gpio_request(pin, str); |
| 49 | gpio_cfg_pin(pin, S5P_GPIO_INPUT); |
| 50 | } |
Piotr Wilczek | 2b3c92a | 2013-09-20 15:01:27 +0200 | [diff] [blame] | 51 | |
| 52 | /* GPM1[5:2]: HW_REV[3:0] */ |
Simon Glass | 4f83d3d | 2014-10-20 19:48:39 -0600 | [diff] [blame] | 53 | for (i = 0; i < 4; i++) { |
| 54 | int pin = i + EXYNOS4X12_GPIO_M12; |
| 55 | |
| 56 | sprintf(str, "hw_rev%d", i); |
| 57 | gpio_request(pin, str); |
| 58 | gpio_cfg_pin(pin, S5P_GPIO_INPUT); |
| 59 | gpio_set_pull(pin, S5P_GPIO_PULL_NONE); |
Piotr Wilczek | 2b3c92a | 2013-09-20 15:01:27 +0200 | [diff] [blame] | 60 | } |
| 61 | |
| 62 | /* GPM1[1:0]: MODEL_REV[1:0] */ |
| 63 | for (i = 0; i < 2; i++) |
Akshay Saraswat | 1376cdd | 2014-05-13 10:30:14 +0530 | [diff] [blame] | 64 | modelrev |= (gpio_get_value(EXYNOS4X12_GPIO_M10 + i) << i); |
Piotr Wilczek | 2b3c92a | 2013-09-20 15:01:27 +0200 | [diff] [blame] | 65 | |
| 66 | /* board_rev[15:8] = model */ |
| 67 | board_rev = modelrev << 8; |
| 68 | } |
Piotr Wilczek | 2b3c92a | 2013-09-20 15:01:27 +0200 | [diff] [blame] | 69 | |
Tom Rini | 4cc3885 | 2021-08-30 09:16:30 -0400 | [diff] [blame] | 70 | #ifdef CONFIG_REVISION_TAG |
Piotr Wilczek | 2b3c92a | 2013-09-20 15:01:27 +0200 | [diff] [blame] | 71 | u32 get_board_rev(void) |
| 72 | { |
| 73 | return board_rev; |
| 74 | } |
Tom Rini | 4cc3885 | 2021-08-30 09:16:30 -0400 | [diff] [blame] | 75 | #endif |
Piotr Wilczek | 2b3c92a | 2013-09-20 15:01:27 +0200 | [diff] [blame] | 76 | |
| 77 | static inline u32 get_model_rev(void) |
| 78 | { |
| 79 | return (board_rev >> 8) & 0xff; |
| 80 | } |
| 81 | |
| 82 | static void board_external_gpio_init(void) |
| 83 | { |
Piotr Wilczek | 2b3c92a | 2013-09-20 15:01:27 +0200 | [diff] [blame] | 84 | /* |
| 85 | * some pins which in alive block are connected with external pull-up |
| 86 | * but it's default setting is pull-down. |
| 87 | * if that pin set as input then that floated |
| 88 | */ |
| 89 | |
Akshay Saraswat | 1376cdd | 2014-05-13 10:30:14 +0530 | [diff] [blame] | 90 | gpio_set_pull(EXYNOS4X12_GPIO_X02, S5P_GPIO_PULL_NONE); /* PS_ALS_INT */ |
| 91 | gpio_set_pull(EXYNOS4X12_GPIO_X04, S5P_GPIO_PULL_NONE); /* TSP_nINT */ |
| 92 | gpio_set_pull(EXYNOS4X12_GPIO_X07, S5P_GPIO_PULL_NONE); /* AP_PMIC_IRQ*/ |
| 93 | gpio_set_pull(EXYNOS4X12_GPIO_X15, S5P_GPIO_PULL_NONE); /* IF_PMIC_IRQ*/ |
| 94 | gpio_set_pull(EXYNOS4X12_GPIO_X20, S5P_GPIO_PULL_NONE); /* VOL_UP */ |
| 95 | gpio_set_pull(EXYNOS4X12_GPIO_X21, S5P_GPIO_PULL_NONE); /* VOL_DOWN */ |
| 96 | gpio_set_pull(EXYNOS4X12_GPIO_X23, S5P_GPIO_PULL_NONE); /* FUEL_ALERT */ |
| 97 | gpio_set_pull(EXYNOS4X12_GPIO_X24, S5P_GPIO_PULL_NONE); /* ADC_INT */ |
| 98 | gpio_set_pull(EXYNOS4X12_GPIO_X27, S5P_GPIO_PULL_NONE); /* nPOWER */ |
| 99 | gpio_set_pull(EXYNOS4X12_GPIO_X30, S5P_GPIO_PULL_NONE); /* WPC_INT */ |
| 100 | gpio_set_pull(EXYNOS4X12_GPIO_X35, S5P_GPIO_PULL_NONE); /* OK_KEY */ |
| 101 | gpio_set_pull(EXYNOS4X12_GPIO_X37, S5P_GPIO_PULL_NONE); /* HDMI_HPD */ |
Piotr Wilczek | 2b3c92a | 2013-09-20 15:01:27 +0200 | [diff] [blame] | 102 | } |
| 103 | |
Piotr Wilczek | 87d2e78 | 2014-03-07 14:59:49 +0100 | [diff] [blame] | 104 | int exynos_early_init_f(void) |
Piotr Wilczek | 2b3c92a | 2013-09-20 15:01:27 +0200 | [diff] [blame] | 105 | { |
Piotr Wilczek | 2b3c92a | 2013-09-20 15:01:27 +0200 | [diff] [blame] | 106 | board_external_gpio_init(); |
| 107 | |
Piotr Wilczek | 2b3c92a | 2013-09-20 15:01:27 +0200 | [diff] [blame] | 108 | return 0; |
| 109 | } |
| 110 | |
Piotr Wilczek | 87d2e78 | 2014-03-07 14:59:49 +0100 | [diff] [blame] | 111 | int exynos_init(void) |
Piotr Wilczek | 2b3c92a | 2013-09-20 15:01:27 +0200 | [diff] [blame] | 112 | { |
Łukasz Majewski | 27937c0 | 2014-04-09 15:09:44 +0200 | [diff] [blame] | 113 | struct exynos4_power *pwr = |
| 114 | (struct exynos4_power *)samsung_get_base_power(); |
| 115 | |
Piotr Wilczek | 87d2e78 | 2014-03-07 14:59:49 +0100 | [diff] [blame] | 116 | check_hw_revision(); |
| 117 | printf("HW Revision:\t0x%04x\n", board_rev); |
Piotr Wilczek | 2b3c92a | 2013-09-20 15:01:27 +0200 | [diff] [blame] | 118 | |
Łukasz Majewski | 27937c0 | 2014-04-09 15:09:44 +0200 | [diff] [blame] | 119 | /* |
| 120 | * First bootloader on the TRATS2 platform uses |
| 121 | * INFORM4 and INFORM5 registers for recovery |
| 122 | * |
| 123 | * To indicate correct boot chain - those two |
| 124 | * registers must be cleared out |
| 125 | */ |
| 126 | writel(0, &pwr->inform4); |
| 127 | writel(0, &pwr->inform5); |
| 128 | |
Piotr Wilczek | 2b3c92a | 2013-09-20 15:01:27 +0200 | [diff] [blame] | 129 | return 0; |
| 130 | } |
| 131 | |
Piotr Wilczek | 87d2e78 | 2014-03-07 14:59:49 +0100 | [diff] [blame] | 132 | int exynos_power_init(void) |
Piotr Wilczek | 2b3c92a | 2013-09-20 15:01:27 +0200 | [diff] [blame] | 133 | { |
Igor Opaniuk | f7c9176 | 2021-02-09 13:52:45 +0200 | [diff] [blame] | 134 | #if !CONFIG_IS_ENABLED(DM_I2C) /* TODO(maintainer): Convert to driver model */ |
Piotr Wilczek | 2b3c92a | 2013-09-20 15:01:27 +0200 | [diff] [blame] | 135 | int chrg; |
| 136 | struct power_battery *pb; |
| 137 | struct pmic *p_chrg, *p_muic, *p_fg, *p_bat; |
| 138 | |
Piotr Wilczek | 97ae183 | 2013-12-18 15:43:37 +0100 | [diff] [blame] | 139 | pmic_init_max77693(I2C_10); /* I2C adapter 10 - bus name soft1 */ |
| 140 | power_muic_init(I2C_10); /* I2C adapter 10 - bus name soft1 */ |
| 141 | power_fg_init(I2C_9); /* I2C adapter 9 - bus name soft0 */ |
Piotr Wilczek | 2b3c92a | 2013-09-20 15:01:27 +0200 | [diff] [blame] | 142 | power_bat_init(0); |
| 143 | |
| 144 | p_chrg = pmic_get("MAX77693_PMIC"); |
| 145 | if (!p_chrg) { |
| 146 | puts("MAX77693_PMIC: Not found\n"); |
| 147 | return -ENODEV; |
| 148 | } |
| 149 | |
| 150 | p_muic = pmic_get("MAX77693_MUIC"); |
| 151 | if (!p_muic) { |
| 152 | puts("MAX77693_MUIC: Not found\n"); |
| 153 | return -ENODEV; |
| 154 | } |
| 155 | |
| 156 | p_fg = pmic_get("MAX77693_FG"); |
| 157 | if (!p_fg) { |
| 158 | puts("MAX17042_FG: Not found\n"); |
| 159 | return -ENODEV; |
| 160 | } |
| 161 | |
| 162 | if (p_chrg->chrg->chrg_bat_present(p_chrg) == 0) |
| 163 | puts("No battery detected\n"); |
| 164 | |
| 165 | p_bat = pmic_get("BAT_TRATS2"); |
| 166 | if (!p_bat) { |
| 167 | puts("BAT_TRATS2: Not found\n"); |
| 168 | return -ENODEV; |
| 169 | } |
| 170 | |
| 171 | p_fg->parent = p_bat; |
| 172 | p_chrg->parent = p_bat; |
| 173 | p_muic->parent = p_bat; |
| 174 | |
| 175 | p_bat->pbat->battery_init(p_bat, p_fg, p_chrg, p_muic); |
| 176 | |
| 177 | pb = p_bat->pbat; |
| 178 | chrg = p_muic->chrg->chrg_type(p_muic); |
| 179 | debug("CHARGER TYPE: %d\n", chrg); |
| 180 | |
| 181 | if (!p_chrg->chrg->chrg_bat_present(p_chrg)) { |
| 182 | puts("No battery detected\n"); |
Przemyslaw Marczak | dd0c48e | 2014-06-10 16:55:08 +0200 | [diff] [blame] | 183 | return 0; |
Piotr Wilczek | 2b3c92a | 2013-09-20 15:01:27 +0200 | [diff] [blame] | 184 | } |
| 185 | |
| 186 | p_fg->fg->fg_battery_check(p_fg, p_bat); |
| 187 | |
| 188 | if (pb->bat->state == CHARGE && chrg == CHARGER_USB) |
| 189 | puts("CHARGE Battery !\n"); |
Simon Glass | 7bbb7d9 | 2016-11-23 06:34:40 -0700 | [diff] [blame] | 190 | #endif |
Piotr Wilczek | 2b3c92a | 2013-09-20 15:01:27 +0200 | [diff] [blame] | 191 | return 0; |
| 192 | } |
| 193 | |
Piotr Wilczek | 0c2ba4c | 2013-11-21 15:46:45 +0100 | [diff] [blame] | 194 | #ifdef CONFIG_USB_GADGET |
| 195 | static int s5pc210_phy_control(int on) |
| 196 | { |
Igor Opaniuk | f7c9176 | 2021-02-09 13:52:45 +0200 | [diff] [blame] | 197 | #if !CONFIG_IS_ENABLED(DM_I2C) /* TODO(maintainer): Convert to driver model */ |
Piotr Wilczek | 0c2ba4c | 2013-11-21 15:46:45 +0100 | [diff] [blame] | 198 | int ret = 0; |
| 199 | unsigned int val; |
| 200 | struct pmic *p, *p_pmic, *p_muic; |
| 201 | |
| 202 | p_pmic = pmic_get("MAX77686_PMIC"); |
| 203 | if (!p_pmic) |
| 204 | return -ENODEV; |
| 205 | |
| 206 | if (pmic_probe(p_pmic)) |
| 207 | return -1; |
| 208 | |
| 209 | p_muic = pmic_get("MAX77693_MUIC"); |
| 210 | if (!p_muic) |
| 211 | return -ENODEV; |
| 212 | |
| 213 | if (pmic_probe(p_muic)) |
| 214 | return -1; |
| 215 | |
| 216 | if (on) { |
| 217 | ret = max77686_set_ldo_mode(p_pmic, 12, OPMODE_ON); |
| 218 | if (ret) |
| 219 | return -1; |
| 220 | |
| 221 | p = pmic_get("MAX77693_PMIC"); |
| 222 | if (!p) |
| 223 | return -ENODEV; |
| 224 | |
| 225 | if (pmic_probe(p)) |
| 226 | return -1; |
| 227 | |
| 228 | /* SAFEOUT */ |
| 229 | ret = pmic_reg_read(p, MAX77693_SAFEOUT, &val); |
| 230 | if (ret) |
| 231 | return -1; |
| 232 | |
| 233 | val |= MAX77693_ENSAFEOUT1; |
| 234 | ret = pmic_reg_write(p, MAX77693_SAFEOUT, val); |
| 235 | if (ret) |
| 236 | return -1; |
| 237 | |
| 238 | /* PATH: USB */ |
| 239 | ret = pmic_reg_write(p_muic, MAX77693_MUIC_CONTROL1, |
| 240 | MAX77693_MUIC_CTRL1_DN1DP2); |
| 241 | |
| 242 | } else { |
| 243 | ret = max77686_set_ldo_mode(p_pmic, 12, OPMODE_LPM); |
| 244 | if (ret) |
| 245 | return -1; |
| 246 | |
| 247 | /* PATH: UART */ |
| 248 | ret = pmic_reg_write(p_muic, MAX77693_MUIC_CONTROL1, |
| 249 | MAX77693_MUIC_CTRL1_UT1UR2); |
| 250 | } |
| 251 | |
| 252 | if (ret) |
| 253 | return -1; |
Simon Glass | 7bbb7d9 | 2016-11-23 06:34:40 -0700 | [diff] [blame] | 254 | #endif |
Piotr Wilczek | 0c2ba4c | 2013-11-21 15:46:45 +0100 | [diff] [blame] | 255 | return 0; |
| 256 | } |
| 257 | |
Marek Vasut | 6939aca | 2015-12-04 02:23:29 +0100 | [diff] [blame] | 258 | struct dwc2_plat_otg_data s5pc210_otg_data = { |
Piotr Wilczek | 0c2ba4c | 2013-11-21 15:46:45 +0100 | [diff] [blame] | 259 | .phy_control = s5pc210_phy_control, |
| 260 | .regs_phy = EXYNOS4X12_USBPHY_BASE, |
| 261 | .regs_otg = EXYNOS4X12_USBOTG_BASE, |
| 262 | .usb_phy_ctrl = EXYNOS4X12_USBPHY_CONTROL, |
| 263 | .usb_flags = PHY0_SLEEP, |
| 264 | }; |
| 265 | |
| 266 | int board_usb_init(int index, enum usb_init_type init) |
| 267 | { |
| 268 | debug("USB_udc_probe\n"); |
Marek Vasut | 01b61fa | 2015-12-04 02:26:33 +0100 | [diff] [blame] | 269 | return dwc2_udc_probe(&s5pc210_otg_data); |
Piotr Wilczek | 0c2ba4c | 2013-11-21 15:46:45 +0100 | [diff] [blame] | 270 | } |
| 271 | |
Mateusz Zalega | 21fe3f7 | 2014-04-30 13:07:48 +0200 | [diff] [blame] | 272 | int g_dnl_board_usb_cable_connected(void) |
Piotr Wilczek | 0c2ba4c | 2013-11-21 15:46:45 +0100 | [diff] [blame] | 273 | { |
Igor Opaniuk | f7c9176 | 2021-02-09 13:52:45 +0200 | [diff] [blame] | 274 | #if !CONFIG_IS_ENABLED(DM_I2C) /* TODO(maintainer): Convert to driver model */ |
Piotr Wilczek | 0c2ba4c | 2013-11-21 15:46:45 +0100 | [diff] [blame] | 275 | struct pmic *muic = pmic_get("MAX77693_MUIC"); |
| 276 | if (!muic) |
| 277 | return 0; |
| 278 | |
| 279 | return !!muic->chrg->chrg_type(muic); |
Simon Glass | 7bbb7d9 | 2016-11-23 06:34:40 -0700 | [diff] [blame] | 280 | #else |
| 281 | return false; |
| 282 | #endif |
Piotr Wilczek | 0c2ba4c | 2013-11-21 15:46:45 +0100 | [diff] [blame] | 283 | } |
| 284 | #endif |
Piotr Wilczek | 0c2ba4c | 2013-11-21 15:46:45 +0100 | [diff] [blame] | 285 | |
Piotr Wilczek | 2b3c92a | 2013-09-20 15:01:27 +0200 | [diff] [blame] | 286 | /* |
| 287 | * LCD |
| 288 | */ |
| 289 | |
| 290 | #ifdef CONFIG_LCD |
Piotr Wilczek | 87d2e78 | 2014-03-07 14:59:49 +0100 | [diff] [blame] | 291 | int mipi_power(void) |
Piotr Wilczek | 2b3c92a | 2013-09-20 15:01:27 +0200 | [diff] [blame] | 292 | { |
Igor Opaniuk | f7c9176 | 2021-02-09 13:52:45 +0200 | [diff] [blame] | 293 | #if !CONFIG_IS_ENABLED(DM_I2C) /* TODO(maintainer): Convert to driver model */ |
Piotr Wilczek | 2b3c92a | 2013-09-20 15:01:27 +0200 | [diff] [blame] | 294 | struct pmic *p = pmic_get("MAX77686_PMIC"); |
| 295 | |
| 296 | /* LDO8 VMIPI_1.0V_AP */ |
| 297 | max77686_set_ldo_mode(p, 8, OPMODE_ON); |
| 298 | /* LDO10 VMIPI_1.8V_AP */ |
| 299 | max77686_set_ldo_mode(p, 10, OPMODE_ON); |
Simon Glass | 7bbb7d9 | 2016-11-23 06:34:40 -0700 | [diff] [blame] | 300 | #endif |
Piotr Wilczek | 2b3c92a | 2013-09-20 15:01:27 +0200 | [diff] [blame] | 301 | |
| 302 | return 0; |
| 303 | } |
| 304 | |
| 305 | void exynos_lcd_power_on(void) |
| 306 | { |
Igor Opaniuk | f7c9176 | 2021-02-09 13:52:45 +0200 | [diff] [blame] | 307 | #if !CONFIG_IS_ENABLED(DM_I2C) /* TODO(maintainer): Convert to driver model */ |
Piotr Wilczek | 2b3c92a | 2013-09-20 15:01:27 +0200 | [diff] [blame] | 308 | struct pmic *p = pmic_get("MAX77686_PMIC"); |
| 309 | |
Piotr Wilczek | 2b3c92a | 2013-09-20 15:01:27 +0200 | [diff] [blame] | 310 | /* LCD_2.2V_EN: GPC0[1] */ |
Simon Glass | 4f83d3d | 2014-10-20 19:48:39 -0600 | [diff] [blame] | 311 | gpio_request(EXYNOS4X12_GPIO_C01, "lcd_2v2_en"); |
Akshay Saraswat | 1376cdd | 2014-05-13 10:30:14 +0530 | [diff] [blame] | 312 | gpio_set_pull(EXYNOS4X12_GPIO_C01, S5P_GPIO_PULL_UP); |
| 313 | gpio_direction_output(EXYNOS4X12_GPIO_C01, 1); |
Piotr Wilczek | 2b3c92a | 2013-09-20 15:01:27 +0200 | [diff] [blame] | 314 | |
| 315 | /* LDO25 VCC_3.1V_LCD */ |
| 316 | pmic_probe(p); |
| 317 | max77686_set_ldo_voltage(p, 25, 3100000); |
| 318 | max77686_set_ldo_mode(p, 25, OPMODE_LPM); |
Simon Glass | 7bbb7d9 | 2016-11-23 06:34:40 -0700 | [diff] [blame] | 319 | #endif |
Piotr Wilczek | 2b3c92a | 2013-09-20 15:01:27 +0200 | [diff] [blame] | 320 | } |
| 321 | |
| 322 | void exynos_reset_lcd(void) |
| 323 | { |
Piotr Wilczek | 2b3c92a | 2013-09-20 15:01:27 +0200 | [diff] [blame] | 324 | /* reset lcd */ |
Simon Glass | 4f83d3d | 2014-10-20 19:48:39 -0600 | [diff] [blame] | 325 | gpio_request(EXYNOS4X12_GPIO_F21, "lcd_reset"); |
Akshay Saraswat | 1376cdd | 2014-05-13 10:30:14 +0530 | [diff] [blame] | 326 | gpio_direction_output(EXYNOS4X12_GPIO_F21, 0); |
Piotr Wilczek | 2b3c92a | 2013-09-20 15:01:27 +0200 | [diff] [blame] | 327 | udelay(10); |
Akshay Saraswat | 1376cdd | 2014-05-13 10:30:14 +0530 | [diff] [blame] | 328 | gpio_set_value(EXYNOS4X12_GPIO_F21, 1); |
Piotr Wilczek | 2b3c92a | 2013-09-20 15:01:27 +0200 | [diff] [blame] | 329 | } |
| 330 | |
Piotr Wilczek | 87d2e78 | 2014-03-07 14:59:49 +0100 | [diff] [blame] | 331 | void exynos_lcd_misc_init(vidinfo_t *vid) |
Piotr Wilczek | 2b3c92a | 2013-09-20 15:01:27 +0200 | [diff] [blame] | 332 | { |
Piotr Wilczek | 2b3c92a | 2013-09-20 15:01:27 +0200 | [diff] [blame] | 333 | #ifdef CONFIG_TIZEN |
| 334 | get_tizen_logo_info(vid); |
| 335 | #endif |
Piotr Wilczek | 87d2e78 | 2014-03-07 14:59:49 +0100 | [diff] [blame] | 336 | #ifdef CONFIG_S6E8AX0 |
Piotr Wilczek | 2b3c92a | 2013-09-20 15:01:27 +0200 | [diff] [blame] | 337 | s6e8ax0_init(); |
Przemyslaw Marczak | d87efc9 | 2014-01-22 11:24:19 +0100 | [diff] [blame] | 338 | #endif |
Piotr Wilczek | 2b3c92a | 2013-09-20 15:01:27 +0200 | [diff] [blame] | 339 | } |
Piotr Wilczek | 87d2e78 | 2014-03-07 14:59:49 +0100 | [diff] [blame] | 340 | #endif /* LCD */ |