diff options
author | Vikas Manocha <vikas.manocha@st.com> | 2016-02-11 15:47:17 -0800 |
---|---|---|
committer | Tom Rini <trini@konsulko.com> | 2016-02-24 18:42:49 -0500 |
commit | 14cec061139a8fb0461d8748d14a2dbcf8a56f2e (patch) | |
tree | 10fcbecd724fa06c64df250df3802762e45f70b1 /drivers | |
parent | 52dd704bf8eda7ca039cdb398ec0b6895c3ef939 (diff) | |
download | u-boot-14cec061139a8fb0461d8748d14a2dbcf8a56f2e.tar.gz u-boot-14cec061139a8fb0461d8748d14a2dbcf8a56f2e.tar.bz2 u-boot-14cec061139a8fb0461d8748d14a2dbcf8a56f2e.zip |
gpio: stm32_gpio: move clock config from driver to board
This patch removes the gpio clock enable from gpio driver & move it in the
board code, making it possible to use the gpio driver with other socs.
Signed-off-by: Vikas Manocha <vikas.manocha@st.com>
Diffstat (limited to 'drivers')
-rw-r--r-- | drivers/gpio/stm32_gpio.c | 5 |
1 files changed, 0 insertions, 5 deletions
diff --git a/drivers/gpio/stm32_gpio.c b/drivers/gpio/stm32_gpio.c index 75a84e111f..9f9ff48c0a 100644 --- a/drivers/gpio/stm32_gpio.c +++ b/drivers/gpio/stm32_gpio.c @@ -70,8 +70,6 @@ int stm32_gpio_config(const struct stm32_gpio_dsc *dsc, gpio_regs = (struct stm32_gpio_regs *)io_base[dsc->port]; - setbits_le32(&STM32_RCC->ahb1enr, 1 << dsc->port); - i = (dsc->pin & 0x07) * 4; clrsetbits_le32(&gpio_regs->afr[dsc->pin >> 3], 0xF << i, ctl->af << i); @@ -141,9 +139,6 @@ int stm32_gpio_config(const struct stm32_gpio_dsc *dsc, gpio_regs = (struct stm32_gpio_regs *)io_base[dsc->port]; - /* Enable clock for GPIO port */ - setbits_le32(&STM32_RCC->apb2enr, 0x04 << dsc->port); - if (p < 8) { cr = &gpio_regs->crl; crp = p; |