[RFT] pwm: stmpe: Fix wrong register offset for hwpwm=2 case

Message ID 20171107051853.14492-1-axel.lin@ingics.com
State New
Headers show
Series
  • [RFT] pwm: stmpe: Fix wrong register offset for hwpwm=2 case
Related show

Commit Message

Axel Lin Nov. 7, 2017, 5:18 a.m.
Fix trivial copy/paste bug.

Signed-off-by: Axel Lin <axel.lin@ingics.com>
---
Hi Linus,
I don't have this h/w to test.
Appreciate if you can review and test this patch.

Thanks,
Axel
 drivers/pwm/pwm-stmpe.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

Comments

Linus Walleij Nov. 9, 2017, 8:45 a.m. | #1
On Tue, Nov 7, 2017 at 6:18 AM, Axel Lin <axel.lin@ingics.com> wrote:

> Fix trivial copy/paste bug.
>
> Signed-off-by: Axel Lin <axel.lin@ingics.com>
> ---
> Hi Linus,
> I don't have this h/w to test.
> Appreciate if you can review and test this patch.

Reviewed-by: Linus Walleij <linus.walleij@linaro.org>

This is an obvious copy/paste bug indeed.

Yours,
Linus Walleij
--
To unsubscribe from this list: send the line "unsubscribe linux-pwm" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Patch

diff --git a/drivers/pwm/pwm-stmpe.c b/drivers/pwm/pwm-stmpe.c
index e464582a390a..3439f1e902cb 100644
--- a/drivers/pwm/pwm-stmpe.c
+++ b/drivers/pwm/pwm-stmpe.c
@@ -145,7 +145,7 @@  static int stmpe_24xx_pwm_config(struct pwm_chip *chip, struct pwm_device *pwm,
 		break;
 
 	case 2:
-		offset = STMPE24XX_PWMIC1;
+		offset = STMPE24XX_PWMIC2;
 		break;
 
 	default: