All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] dt-bindings: input: matrix-keymap: Add common 'linux,no-autorepeat' property
@ 2022-05-23 17:04 Rob Herring
  2022-05-23 18:47 ` Dmitry Torokhov
  0 siblings, 1 reply; 5+ messages in thread
From: Rob Herring @ 2022-05-23 17:04 UTC (permalink / raw)
  To: Robin van der Gracht, Miguel Ojeda, Krzysztof Kozlowski,
	Dmitry Torokhov, Olof Johansson
  Cc: devicetree, linux-kernel, linux-input

'linux,no-autorepeat' is a common property used in multiple bindings,
but doesn't have a common type definition nor description. Add a common
definition and drop the now redundant description from
holtek,ht16k33.yaml.

Signed-off-by: Rob Herring <robh@kernel.org>
---
 .../devicetree/bindings/auxdisplay/holtek,ht16k33.yaml        | 3 +--
 Documentation/devicetree/bindings/input/matrix-keymap.yaml    | 4 ++++
 2 files changed, 5 insertions(+), 2 deletions(-)

diff --git a/Documentation/devicetree/bindings/auxdisplay/holtek,ht16k33.yaml b/Documentation/devicetree/bindings/auxdisplay/holtek,ht16k33.yaml
index fc4873deb76f..f4579e9f44a1 100644
--- a/Documentation/devicetree/bindings/auxdisplay/holtek,ht16k33.yaml
+++ b/Documentation/devicetree/bindings/auxdisplay/holtek,ht16k33.yaml
@@ -39,8 +39,7 @@ properties:
 
   linux,keymap: true
 
-  linux,no-autorepeat:
-    description: Disable keyrepeat
+  linux,no-autorepeat: true
 
   default-brightness-level:
     minimum: 1
diff --git a/Documentation/devicetree/bindings/input/matrix-keymap.yaml b/Documentation/devicetree/bindings/input/matrix-keymap.yaml
index 6699d5e32dca..9f703bb51e12 100644
--- a/Documentation/devicetree/bindings/input/matrix-keymap.yaml
+++ b/Documentation/devicetree/bindings/input/matrix-keymap.yaml
@@ -27,6 +27,10 @@ properties:
       column and linux key-code. The 32-bit big endian cell is packed as:
           row << 24 | column << 16 | key-code
 
+  linux,no-autorepeat:
+    type: boolean
+    description: Disable keyrepeat
+
   keypad,num-rows:
     $ref: /schemas/types.yaml#/definitions/uint32
     description: Number of row lines connected to the keypad controller.
-- 
2.34.1


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

* Re: [PATCH] dt-bindings: input: matrix-keymap: Add common 'linux,no-autorepeat' property
  2022-05-23 17:04 [PATCH] dt-bindings: input: matrix-keymap: Add common 'linux,no-autorepeat' property Rob Herring
@ 2022-05-23 18:47 ` Dmitry Torokhov
  2022-05-23 19:45   ` Rob Herring
  0 siblings, 1 reply; 5+ messages in thread
From: Dmitry Torokhov @ 2022-05-23 18:47 UTC (permalink / raw)
  To: Rob Herring
  Cc: Robin van der Gracht, Miguel Ojeda, Krzysztof Kozlowski,
	Olof Johansson, devicetree, linux-kernel, linux-input

On Mon, May 23, 2022 at 12:04:49PM -0500, Rob Herring wrote:
> 'linux,no-autorepeat' is a common property used in multiple bindings,
> but doesn't have a common type definition nor description. Add a common
> definition and drop the now redundant description from
> holtek,ht16k33.yaml.

We have "autorepeat" in the common input binding description, should we
not promote it over "no-autorepeat"?

Thanks.

-- 
Dmitry

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

* Re: [PATCH] dt-bindings: input: matrix-keymap: Add common 'linux,no-autorepeat' property
  2022-05-23 18:47 ` Dmitry Torokhov
@ 2022-05-23 19:45   ` Rob Herring
  2022-05-23 22:02     ` Dmitry Torokhov
  0 siblings, 1 reply; 5+ messages in thread
From: Rob Herring @ 2022-05-23 19:45 UTC (permalink / raw)
  To: Dmitry Torokhov
  Cc: Robin van der Gracht, Miguel Ojeda, Krzysztof Kozlowski,
	Olof Johansson, devicetree, linux-kernel, linux-input

On Mon, May 23, 2022 at 11:47:01AM -0700, Dmitry Torokhov wrote:
> On Mon, May 23, 2022 at 12:04:49PM -0500, Rob Herring wrote:
> > 'linux,no-autorepeat' is a common property used in multiple bindings,
> > but doesn't have a common type definition nor description. Add a common
> > definition and drop the now redundant description from
> > holtek,ht16k33.yaml.
> 
> We have "autorepeat" in the common input binding description, should we
> not promote it over "no-autorepeat"?

We're kind of stuck with it I think. We can't just deprecate one and 
switch existing users as what would neither property present mean?

Hopefully, documented in input.yaml vs. matrix-keypad.yaml is enough to 
say which one is preferred for new users. 

Rob


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

* Re: [PATCH] dt-bindings: input: matrix-keymap: Add common 'linux,no-autorepeat' property
  2022-05-23 19:45   ` Rob Herring
@ 2022-05-23 22:02     ` Dmitry Torokhov
  2022-05-24 13:31       ` Rob Herring
  0 siblings, 1 reply; 5+ messages in thread
From: Dmitry Torokhov @ 2022-05-23 22:02 UTC (permalink / raw)
  To: Rob Herring
  Cc: Robin van der Gracht, Miguel Ojeda, Krzysztof Kozlowski,
	Olof Johansson, devicetree, linux-kernel, linux-input

On Mon, May 23, 2022 at 02:45:03PM -0500, Rob Herring wrote:
> On Mon, May 23, 2022 at 11:47:01AM -0700, Dmitry Torokhov wrote:
> > On Mon, May 23, 2022 at 12:04:49PM -0500, Rob Herring wrote:
> > > 'linux,no-autorepeat' is a common property used in multiple bindings,
> > > but doesn't have a common type definition nor description. Add a common
> > > definition and drop the now redundant description from
> > > holtek,ht16k33.yaml.
> > 
> > We have "autorepeat" in the common input binding description, should we
> > not promote it over "no-autorepeat"?
> 
> We're kind of stuck with it I think. We can't just deprecate one and 
> switch existing users as what would neither property present mean?

I agree, we should not change existng bindings.

> 
> Hopefully, documented in input.yaml vs. matrix-keypad.yaml is enough to 
> say which one is preferred for new users. 

So this is what I have issue with, as I think it will introduce
confusion: we have drivers/input/matrix-keymap.c and corresponding
binding Documentation/devicetree/bindings/input/matrix-keymap.yaml that
deals with parsing keymap-related properties for various matrix keypads.
It does not specify autorepeat handling one way or another. Then we have
drivers/input/keyboard/matrix_keypad.c that is one implementation of
matrix keypads, and it does have linux,no-autorepeat, but it does not
mean that other devices resembling matrix keypad are forced to use
linux,no-autorepeat. And that is why I think putting this property into
the generic binding
Documentation/devicetree/bindings/input/matrix-keymap.yaml is not a good
idea.

Thanks.

-- 
Dmitry

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

* Re: [PATCH] dt-bindings: input: matrix-keymap: Add common 'linux,no-autorepeat' property
  2022-05-23 22:02     ` Dmitry Torokhov
@ 2022-05-24 13:31       ` Rob Herring
  0 siblings, 0 replies; 5+ messages in thread
From: Rob Herring @ 2022-05-24 13:31 UTC (permalink / raw)
  To: Dmitry Torokhov
  Cc: Robin van der Gracht, Miguel Ojeda, Krzysztof Kozlowski,
	Olof Johansson, devicetree, linux-kernel, linux-input

On Mon, May 23, 2022 at 03:02:42PM -0700, Dmitry Torokhov wrote:
> On Mon, May 23, 2022 at 02:45:03PM -0500, Rob Herring wrote:
> > On Mon, May 23, 2022 at 11:47:01AM -0700, Dmitry Torokhov wrote:
> > > On Mon, May 23, 2022 at 12:04:49PM -0500, Rob Herring wrote:
> > > > 'linux,no-autorepeat' is a common property used in multiple bindings,
> > > > but doesn't have a common type definition nor description. Add a common
> > > > definition and drop the now redundant description from
> > > > holtek,ht16k33.yaml.
> > > 
> > > We have "autorepeat" in the common input binding description, should we
> > > not promote it over "no-autorepeat"?
> > 
> > We're kind of stuck with it I think. We can't just deprecate one and 
> > switch existing users as what would neither property present mean?
> 
> I agree, we should not change existng bindings.
> 
> > 
> > Hopefully, documented in input.yaml vs. matrix-keypad.yaml is enough to 
> > say which one is preferred for new users. 
> 
> So this is what I have issue with, as I think it will introduce
> confusion: we have drivers/input/matrix-keymap.c and corresponding
> binding Documentation/devicetree/bindings/input/matrix-keymap.yaml that
> deals with parsing keymap-related properties for various matrix keypads.
> It does not specify autorepeat handling one way or another. Then we have
> drivers/input/keyboard/matrix_keypad.c that is one implementation of
> matrix keypads, and it does have linux,no-autorepeat, but it does not
> mean that other devices resembling matrix keypad are forced to use
> linux,no-autorepeat. And that is why I think putting this property into
> the generic binding
> Documentation/devicetree/bindings/input/matrix-keymap.yaml is not a good
> idea.

You are right. As it looks like there are only 3 users of 
linux,no-autorepeat, we can live with multiple definitions. Looks like 
we have a variety of other autorepeat properties too.

Rob

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

end of thread, other threads:[~2022-05-24 13:31 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-05-23 17:04 [PATCH] dt-bindings: input: matrix-keymap: Add common 'linux,no-autorepeat' property Rob Herring
2022-05-23 18:47 ` Dmitry Torokhov
2022-05-23 19:45   ` Rob Herring
2022-05-23 22:02     ` Dmitry Torokhov
2022-05-24 13:31       ` Rob Herring

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.