diff options
author | Ye.Li <B37916@freescale.com> | 2015-02-01 23:02:09 +0800 |
---|---|---|
committer | Frank Li <Frank.Li@freescale.com> | 2015-02-04 21:53:30 +0800 |
commit | 8aa92b831955c968f802286de561825227e761ce (patch) | |
tree | da09e51e3d57e4d0f4103c187411b60b0f0deadf /arch | |
parent | 47d65aa6bdd109fd9141b5a5d64ab9deeb9dd2b3 (diff) | |
download | u-boot-imx-8aa92b831955c968f802286de561825227e761ce.zip u-boot-imx-8aa92b831955c968f802286de561825227e761ce.tar.gz u-boot-imx-8aa92b831955c968f802286de561825227e761ce.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.
Signed-off-by: Fugang Duan <B38611@freescale.com>
Signed-off-by: Ye.Li <B37916@freescale.com>
Diffstat (limited to 'arch')
-rw-r--r-- | arch/arm/imx-common/iomux-v3.c | 17 |
1 files changed, 16 insertions, 1 deletions
diff --git a/arch/arm/imx-common/iomux-v3.c b/arch/arm/imx-common/iomux-v3.c index 11cfc33..0bfe474 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+ */ @@ -30,6 +30,15 @@ void imx_iomux_v3_setup_pad(iomux_v3_cfg_t pad) (pad & MUX_PAD_CTRL_OFS_MASK) >> MUX_PAD_CTRL_OFS_SHIFT; u32 pad_ctrl = (pad & MUX_PAD_CTRL_MASK) >> MUX_PAD_CTRL_SHIFT; +#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 + if (mux_ctrl_ofs) __raw_writel(mux_mode, base + mux_ctrl_ofs); @@ -44,6 +53,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 + } void imx_iomux_v3_setup_multiple_pads(iomux_v3_cfg_t const *pad_list, |