diff options
author | Chris Ruehl <chris.ruehl@gtsys.com.hk> | 2014-01-21 22:14:51 -0500 |
---|---|---|
committer | Linus Walleij <linus.walleij@linaro.org> | 2014-02-03 03:07:52 -0500 |
commit | 795779df22afc8bdee4e9fbe5c18c47e44974d75 (patch) | |
tree | a0dc19694c8a8e98ead984065f8b21ec4200c024 /drivers/pinctrl/pinctrl-imx1-core.c | |
parent | b0dcfd87323ea86501e93d0fa2a98d2fd3579bcf (diff) |
pinctrl: imx27: fix wrong offset to ICONFB
The offset to ICONFB was incorrect, this patch set the correct value 0x14.
dev_dbg in function imx1_write_2bit print the wrong address and had been
moved after address calculation.
Cc: stable@vger.kernel.org
Signed-off-by: Chris Ruehl <chris.ruehl@gtsys.com.hk>
Reviewed-by: Markus Pargmann <mpa@pengutronix.de>
Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
Diffstat (limited to 'drivers/pinctrl/pinctrl-imx1-core.c')
-rw-r--r-- | drivers/pinctrl/pinctrl-imx1-core.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/drivers/pinctrl/pinctrl-imx1-core.c b/drivers/pinctrl/pinctrl-imx1-core.c index 17aecde1b51d..9e7893fe96e0 100644 --- a/drivers/pinctrl/pinctrl-imx1-core.c +++ b/drivers/pinctrl/pinctrl-imx1-core.c | |||
@@ -45,7 +45,7 @@ struct imx1_pinctrl { | |||
45 | #define MX1_DDIR 0x00 | 45 | #define MX1_DDIR 0x00 |
46 | #define MX1_OCR 0x04 | 46 | #define MX1_OCR 0x04 |
47 | #define MX1_ICONFA 0x0c | 47 | #define MX1_ICONFA 0x0c |
48 | #define MX1_ICONFB 0x10 | 48 | #define MX1_ICONFB 0x14 |
49 | #define MX1_GIUS 0x20 | 49 | #define MX1_GIUS 0x20 |
50 | #define MX1_GPR 0x38 | 50 | #define MX1_GPR 0x38 |
51 | #define MX1_PUEN 0x40 | 51 | #define MX1_PUEN 0x40 |
@@ -97,13 +97,13 @@ static void imx1_write_2bit(struct imx1_pinctrl *ipctl, unsigned int pin_id, | |||
97 | u32 old_val; | 97 | u32 old_val; |
98 | u32 new_val; | 98 | u32 new_val; |
99 | 99 | ||
100 | dev_dbg(ipctl->dev, "write: register 0x%p offset %d value 0x%x\n", | ||
101 | reg, offset, value); | ||
102 | |||
103 | /* Use the next register if the pin's port pin number is >=16 */ | 100 | /* Use the next register if the pin's port pin number is >=16 */ |
104 | if (pin_id % 32 >= 16) | 101 | if (pin_id % 32 >= 16) |
105 | reg += 0x04; | 102 | reg += 0x04; |
106 | 103 | ||
104 | dev_dbg(ipctl->dev, "write: register 0x%p offset %d value 0x%x\n", | ||
105 | reg, offset, value); | ||
106 | |||
107 | /* Get current state of pins */ | 107 | /* Get current state of pins */ |
108 | old_val = readl(reg); | 108 | old_val = readl(reg); |
109 | old_val &= mask; | 109 | old_val &= mask; |