exynos: Add support for the DisplayPort hotplug detect
authorSimon Glass <sjg@chromium.org>
Fri, 3 Jul 2015 00:16:13 +0000 (18:16 -0600)
committerSimon Glass <sjg@chromium.org>
Thu, 6 Aug 2015 03:06:14 +0000 (21:06 -0600)
Allow this function to be selected using the pinmux API.

Signed-off-by: Simon Glass <sjg@chromium.org>
arch/arm/cpu/armv7/exynos/pinmux.c
arch/arm/include/asm/arch-exynos/periph.h

index be43e224fa37074bf2a939ad3e486f3268833910..e97cb376ffc7ca8ba4806755d7ba241325fc15f3 100644 (file)
@@ -496,6 +496,16 @@ static int exynos5_pinmux_config(int peripheral, int flags)
        case PERIPH_ID_SPI4:
                exynos5_spi_config(peripheral);
                break;
+       case PERIPH_ID_DPHPD:
+               /* Set Hotplug detect for DP */
+               gpio_cfg_pin(EXYNOS5_GPIO_X07, S5P_GPIO_FUNC(0x3));
+
+               /*
+                * Hotplug detect should have an external pullup; disable the
+                * internal pulldown so they don't fight.
+                */
+               gpio_set_pull(EXYNOS5_GPIO_X07, S5P_GPIO_PULL_NONE);
+               break;
        default:
                debug("%s: invalid peripheral %d", __func__, peripheral);
                return -1;
index 5c1c3d4a93c58805d5b5767eff8cfd336d402ab6..fdc9e87c6918c35d58620d93c46198eb5c6e4318 100644 (file)
@@ -53,6 +53,7 @@ enum periph_id {
        PERIPH_ID_PWM2,
        PERIPH_ID_PWM3,
        PERIPH_ID_PWM4,
+       PERIPH_ID_DPHPD,
        PERIPH_ID_I2C10 = 203,
 
        PERIPH_ID_NONE = -1,