linux-input.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH v2 RESEND] input: keyboard: snvs_pwrkey: Fix SNVS_HPVIDR1 register address
@ 2022-09-27  6:25 Sebastian Krzyszkowiak
  2022-09-27  8:12 ` Mattijs Korpershoek
  2022-09-27 14:19 ` Dmitry Torokhov
  0 siblings, 2 replies; 3+ messages in thread
From: Sebastian Krzyszkowiak @ 2022-09-27  6:25 UTC (permalink / raw)
  To: Dmitry Torokhov, linux-input
  Cc: Sebastian Krzyszkowiak, Robin van der Gracht, linux-kernel,
	kernel, Uwe Kleine-König, stable, Martin Kepplinger

Both i.MX6 and i.MX8 reference manuals list 0xBF8 as SNVS_HPVIDR1
(chapters 57.9 and 6.4.5 respectively).

Without this, trying to read the revision number results in 0 on
all revisions, causing the i.MX6 quirk to apply on all platforms,
which in turn causes the driver to synthesise power button release
events instead of passing the real one as they happen even on
platforms like i.MX8 where that's not wanted.

Fixes: 1a26c920717a ("Input: snvs_pwrkey - send key events for i.MX6 S, DL and Q")
Cc: <stable@vger.kernel.org>
Tested-by: Martin Kepplinger <martin.kepplinger@puri.sm>
Signed-off-by: Sebastian Krzyszkowiak <sebastian.krzyszkowiak@puri.sm>
---
Resent <20220321171755.656750-1-sebastian.krzyszkowiak@puri.sm>
v2: augmented commit message; added cc: stable and tested-by
---
 drivers/input/keyboard/snvs_pwrkey.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/input/keyboard/snvs_pwrkey.c b/drivers/input/keyboard/snvs_pwrkey.c
index 65286762b02a..ad8660be0127 100644
--- a/drivers/input/keyboard/snvs_pwrkey.c
+++ b/drivers/input/keyboard/snvs_pwrkey.c
@@ -20,7 +20,7 @@
 #include <linux/mfd/syscon.h>
 #include <linux/regmap.h>
 
-#define SNVS_HPVIDR1_REG	0xF8
+#define SNVS_HPVIDR1_REG	0xBF8
 #define SNVS_LPSR_REG		0x4C	/* LP Status Register */
 #define SNVS_LPCR_REG		0x38	/* LP Control Register */
 #define SNVS_HPSR_REG		0x14
-- 
2.35.1





^ permalink raw reply related	[flat|nested] 3+ messages in thread

* Re: [PATCH v2 RESEND] input: keyboard: snvs_pwrkey: Fix SNVS_HPVIDR1 register address
  2022-09-27  6:25 [PATCH v2 RESEND] input: keyboard: snvs_pwrkey: Fix SNVS_HPVIDR1 register address Sebastian Krzyszkowiak
@ 2022-09-27  8:12 ` Mattijs Korpershoek
  2022-09-27 14:19 ` Dmitry Torokhov
  1 sibling, 0 replies; 3+ messages in thread
From: Mattijs Korpershoek @ 2022-09-27  8:12 UTC (permalink / raw)
  To: Sebastian Krzyszkowiak, Dmitry Torokhov, linux-input
  Cc: Sebastian Krzyszkowiak, Robin van der Gracht, linux-kernel,
	kernel, Uwe Kleine-König, stable, Martin Kepplinger

On Tue, Sep 27, 2022 at 08:25, Sebastian Krzyszkowiak <sebastian.krzyszkowiak@puri.sm> wrote:

> Both i.MX6 and i.MX8 reference manuals list 0xBF8 as SNVS_HPVIDR1
> (chapters 57.9 and 6.4.5 respectively).
>
> Without this, trying to read the revision number results in 0 on
> all revisions, causing the i.MX6 quirk to apply on all platforms,
> which in turn causes the driver to synthesise power button release
> events instead of passing the real one as they happen even on
> platforms like i.MX8 where that's not wanted.
>
> Fixes: 1a26c920717a ("Input: snvs_pwrkey - send key events for i.MX6 S, DL and Q")
> Cc: <stable@vger.kernel.org>
> Tested-by: Martin Kepplinger <martin.kepplinger@puri.sm>
> Signed-off-by: Sebastian Krzyszkowiak <sebastian.krzyszkowiak@puri.sm>

Reviewed-by: Mattijs Korpershoek <mkorpershoek@baylibre.com>

> ---
> Resent <20220321171755.656750-1-sebastian.krzyszkowiak@puri.sm>
> v2: augmented commit message; added cc: stable and tested-by
> ---
>  drivers/input/keyboard/snvs_pwrkey.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/drivers/input/keyboard/snvs_pwrkey.c b/drivers/input/keyboard/snvs_pwrkey.c
> index 65286762b02a..ad8660be0127 100644
> --- a/drivers/input/keyboard/snvs_pwrkey.c
> +++ b/drivers/input/keyboard/snvs_pwrkey.c
> @@ -20,7 +20,7 @@
>  #include <linux/mfd/syscon.h>
>  #include <linux/regmap.h>
>  
> -#define SNVS_HPVIDR1_REG	0xF8
> +#define SNVS_HPVIDR1_REG	0xBF8
>  #define SNVS_LPSR_REG		0x4C	/* LP Status Register */
>  #define SNVS_LPCR_REG		0x38	/* LP Control Register */
>  #define SNVS_HPSR_REG		0x14
> -- 
> 2.35.1

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: [PATCH v2 RESEND] input: keyboard: snvs_pwrkey: Fix SNVS_HPVIDR1 register address
  2022-09-27  6:25 [PATCH v2 RESEND] input: keyboard: snvs_pwrkey: Fix SNVS_HPVIDR1 register address Sebastian Krzyszkowiak
  2022-09-27  8:12 ` Mattijs Korpershoek
@ 2022-09-27 14:19 ` Dmitry Torokhov
  1 sibling, 0 replies; 3+ messages in thread
From: Dmitry Torokhov @ 2022-09-27 14:19 UTC (permalink / raw)
  To: Sebastian Krzyszkowiak
  Cc: linux-input, Robin van der Gracht, linux-kernel, kernel,
	Uwe Kleine-König, stable, Martin Kepplinger

On Tue, Sep 27, 2022 at 08:25:12AM +0200, Sebastian Krzyszkowiak wrote:
> Both i.MX6 and i.MX8 reference manuals list 0xBF8 as SNVS_HPVIDR1
> (chapters 57.9 and 6.4.5 respectively).
> 
> Without this, trying to read the revision number results in 0 on
> all revisions, causing the i.MX6 quirk to apply on all platforms,
> which in turn causes the driver to synthesise power button release
> events instead of passing the real one as they happen even on
> platforms like i.MX8 where that's not wanted.
> 
> Fixes: 1a26c920717a ("Input: snvs_pwrkey - send key events for i.MX6 S, DL and Q")
> Cc: <stable@vger.kernel.org>
> Tested-by: Martin Kepplinger <martin.kepplinger@puri.sm>
> Signed-off-by: Sebastian Krzyszkowiak <sebastian.krzyszkowiak@puri.sm>

Applied, thank you.

-- 
Dmitry

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2022-09-27 14:19 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-09-27  6:25 [PATCH v2 RESEND] input: keyboard: snvs_pwrkey: Fix SNVS_HPVIDR1 register address Sebastian Krzyszkowiak
2022-09-27  8:12 ` Mattijs Korpershoek
2022-09-27 14:19 ` Dmitry Torokhov

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).