From: Fabio Baltieri <fabiobaltieri@chromium.org>
To: Krzysztof Kozlowski <krzk@kernel.org>
Cc: Dmitry Torokhov <dmitry.torokhov@gmail.com>,
Rob Herring <robh@kernel.org>,
Krzysztof Kozlowski <krzk+dt@kernel.org>,
Conor Dooley <conor+dt@kernel.org>,
Benson Leung <bleung@chromium.org>,
Guenter Roeck <groeck@chromium.org>,
Tzung-Bi Shih <tzungbi@kernel.org>,
Simon Glass <sjg@chromium.org>,
linux-input@vger.kernel.org, devicetree@vger.kernel.org,
chrome-platform@lists.linux.dev, linux-kernel@vger.kernel.org
Subject: Re: [PATCH v3 1/2] dt-bindings: google,cros-ec-keyb: add has-fn-map prop
Date: Mon, 5 Jan 2026 10:55:51 +0000 [thread overview]
Message-ID: <aVuYt24q6nihC4t0@google.com> (raw)
In-Reply-To: <20260105-helpful-ocelot-of-eternity-6bb1ee@quoll>
On Mon, Jan 05, 2026 at 08:52:56AM +0100, Krzysztof Kozlowski wrote:
> On Wed, Dec 31, 2025 at 02:35:37PM +0000, Fabio Baltieri wrote:
> > Add binding documentation for the has-fn-map property.
> >
> > Signed-off-by: Fabio Baltieri <fabiobaltieri@chromium.org>
> > ---
> > .../devicetree/bindings/input/google,cros-ec-keyb.yaml | 8 ++++++++
> > 1 file changed, 8 insertions(+)
> >
> > diff --git a/Documentation/devicetree/bindings/input/google,cros-ec-keyb.yaml b/Documentation/devicetree/bindings/input/google,cros-ec-keyb.yaml
> > index fefaaf46a240..fa24b1cbc788 100644
> > --- a/Documentation/devicetree/bindings/input/google,cros-ec-keyb.yaml
> > +++ b/Documentation/devicetree/bindings/input/google,cros-ec-keyb.yaml
> > @@ -44,6 +44,14 @@ properties:
> > where the lower 16 bits are reserved. This property is specified only
> > when the keyboard has a custom design for the top row keys.
> >
> > + google,has-fn-map:
> > + description: |
> > + The keymap has function key layer. This allows defining an extra set of
> > + codes that are sent if a key is pressed while the KEY_FN is held pressed
> > + as well. The function codes have to be defined in the linux,keymap
> > + property with an offset of keypad,num-rows from the normal ones.
> > + type: boolean
>
> You still did not answer to my previous question, why this is not
> deducible from the key map (presence of KEY_FN in the map).
The driver behaves differently with the fn layer is present, has to make
extra space for the extra codes and enable the logic to use it. I can
certainly detect it in runtime, would have to always allocate the extra
space even if not needed and check not only that there is an FN key but
if there's anything in the second half of the map.
I'm not overly enthusiastic about it, it's a bit wasteful on memory
(probably no big deal, half a kb of RAM I guess) and somewhat less
defensive to misconfigurations and in general I don't like the new logic
to be enabled magically, as a side effect. It'd be extra complexity for
the sake of saving one boolean property, but sure if you think that's
the way to go then I guess I can implement it that way.
next prev parent reply other threads:[~2026-01-05 10:55 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-12-31 14:35 [PATCH v3 0/2] Input: cros_ec_keyb: add function key support Fabio Baltieri
2025-12-31 14:35 ` [PATCH v3 1/2] dt-bindings: google,cros-ec-keyb: add has-fn-map prop Fabio Baltieri
2026-01-05 7:52 ` Krzysztof Kozlowski
2026-01-05 10:55 ` Fabio Baltieri [this message]
2026-01-06 7:27 ` Krzysztof Kozlowski
2026-01-06 11:01 ` Fabio Baltieri
2025-12-31 14:35 ` [PATCH v3 2/2] Input: cros_ec_keyb - add function key support Fabio Baltieri
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=aVuYt24q6nihC4t0@google.com \
--to=fabiobaltieri@chromium.org \
--cc=bleung@chromium.org \
--cc=chrome-platform@lists.linux.dev \
--cc=conor+dt@kernel.org \
--cc=devicetree@vger.kernel.org \
--cc=dmitry.torokhov@gmail.com \
--cc=groeck@chromium.org \
--cc=krzk+dt@kernel.org \
--cc=krzk@kernel.org \
--cc=linux-input@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=robh@kernel.org \
--cc=sjg@chromium.org \
--cc=tzungbi@kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox