diff options
author | Peng Fan <Peng.Fan@freescale.com> | 2015-03-09 10:53:49 +0800 |
---|---|---|
committer | Peng Fan <Peng.Fan@freescale.com> | 2015-04-29 14:56:22 +0800 |
commit | d84cb3e1cf93b4f06068797c7eb606ab19ab14b6 (patch) | |
tree | 95dcb06b4f7b048b91120773a31792ed57885b7b /arch | |
parent | 6466e025ff0bf4277dda8bbdc0cc008283fb6eb4 (diff) | |
download | u-boot-imx-d84cb3e1cf93b4f06068797c7eb606ab19ab14b6.zip u-boot-imx-d84cb3e1cf93b4f06068797c7eb606ab19ab14b6.tar.gz u-boot-imx-d84cb3e1cf93b4f06068797c7eb606ab19ab14b6.tar.bz2 |
MLK-10176-5 imx: mx7: Update IOMUX v3 driver for LPSR
Since mx7d introduces some LPSR IOMUX pins, add new base to IOMUX v3
driver for these LPSR pins.
This patch also include commit
b83bb7b6cf26a4bb8983ae89c284fb4018c89870
Signed-off-by: Fugang Duan <B38611@freescale.com>
Signed-off-by: Ye.Li <B37916@freescale.com>
(cherry picked from commit 8aa92b831955c968f802286de561825227e761ce)
Diffstat (limited to 'arch')
-rw-r--r-- | arch/arm/imx-common/iomux-v3.c | 20 |
1 files changed, 17 insertions, 3 deletions
diff --git a/arch/arm/imx-common/iomux-v3.c b/arch/arm/imx-common/iomux-v3.c index e88e6e2..50877d5 100644 --- a/arch/arm/imx-common/iomux-v3.c +++ b/arch/arm/imx-common/iomux-v3.c @@ -4,7 +4,7 @@ * Copyright (C) 2009 by Jan Weitzel Phytec Messtechnik GmbH, * <armlinux@phytec.de> * - * Copyright (C) 2004-2011 Freescale Semiconductor, Inc. + * Copyright (C) 2004-2015 Freescale Semiconductor, Inc. * * SPDX-License-Identifier: GPL-2.0+ */ @@ -41,8 +41,16 @@ void imx_iomux_v3_setup_pad(iomux_v3_cfg_t pad) } #endif - if (mux_ctrl_ofs) - __raw_writel(mux_mode, base + mux_ctrl_ofs); +#ifdef CONFIG_IOMUX_LPSR + u32 lpsr = (pad & MUX_MODE_LPSR) >> MUX_MODE_SHIFT; + + if (lpsr == IOMUX_CONFIG_LPSR) { + base = (void *)IOMUXC_LPSR_BASE_ADDR; + mux_mode &= ~IOMUX_CONFIG_LPSR; + } +#endif + + __raw_writel(mux_mode, base + mux_ctrl_ofs); if (sel_input_ofs) __raw_writel(sel_input, base + sel_input_ofs); @@ -55,6 +63,12 @@ void imx_iomux_v3_setup_pad(iomux_v3_cfg_t pad) if (!(pad_ctrl & NO_PAD_CTRL) && pad_ctrl_ofs) __raw_writel(pad_ctrl, base + pad_ctrl_ofs); #endif + +#ifdef CONFIG_IOMUX_LPSR + if (lpsr == IOMUX_CONFIG_LPSR) + base = (void *)IOMUXC_BASE_ADDR; +#endif + } /* configures a list of pads within declared with IOMUX_PADS macro */ |