瀏覽代碼

exynos: Allow PWM0 pinmux to be set up

This is commonly used for LCD backlight control. Add pinmux support for it
on exynos5250 and 5420.

Signed-off-by: Simon Glass <sjg@chromium.org>
Signed-off-by: Minkyu Kang <mk7.kang@samsung.com>
Simon Glass 9 年之前
父節點
當前提交
af5b5eae53
共有 1 個文件被更改,包括 6 次插入0 次删除
  1. 6 0
      arch/arm/mach-exynos/pinmux.c

+ 6 - 0
arch/arm/mach-exynos/pinmux.c

@@ -506,6 +506,9 @@ static int exynos5_pinmux_config(int peripheral, int flags)
 		 */
 		 */
 		gpio_set_pull(EXYNOS5_GPIO_X07, S5P_GPIO_PULL_NONE);
 		gpio_set_pull(EXYNOS5_GPIO_X07, S5P_GPIO_PULL_NONE);
 		break;
 		break;
+	case PERIPH_ID_PWM0:
+		gpio_cfg_pin(EXYNOS5_GPIO_B20, S5P_GPIO_FUNC(2));
+		break;
 	default:
 	default:
 		debug("%s: invalid peripheral %d", __func__, peripheral);
 		debug("%s: invalid peripheral %d", __func__, peripheral);
 		return -1;
 		return -1;
@@ -548,6 +551,9 @@ static int exynos5420_pinmux_config(int peripheral, int flags)
 	case PERIPH_ID_I2C10:
 	case PERIPH_ID_I2C10:
 		exynos5420_i2c_config(peripheral);
 		exynos5420_i2c_config(peripheral);
 		break;
 		break;
+	case PERIPH_ID_PWM0:
+		gpio_cfg_pin(EXYNOS5420_GPIO_B20, S5P_GPIO_FUNC(2));
+		break;
 	default:
 	default:
 		debug("%s: invalid peripheral %d", __func__, peripheral);
 		debug("%s: invalid peripheral %d", __func__, peripheral);
 		return -1;
 		return -1;