public inbox for linux-input@vger.kernel.org
 help / color / mirror / Atom feed
From: Dmitry Torokhov <dmitry.torokhov@gmail.com>
To: Fabio Baltieri <fabiobaltieri@chromium.org>,
	Benson Leung <bleung@chromium.org>
Cc: Guenter Roeck <groeck@chromium.org>,
	Simon Glass <sjg@chromium.org>,
	Tzung-Bi Shih <tzungbi@kernel.org>,
	linux-input@vger.kernel.org, chrome-platform@lists.linux.dev,
	linux-kernel@vger.kernel.org
Subject: [PATCH 3/7] Input: cros_ec_keyb - use u8 instead of uint8_t
Date: Sat, 21 Feb 2026 16:37:11 -0800	[thread overview]
Message-ID: <20260222003717.471977-3-dmitry.torokhov@gmail.com> (raw)
In-Reply-To: <20260222003717.471977-1-dmitry.torokhov@gmail.com>

In the kernel u8/u16/u32 are preferred to the uint*_t variants.

Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
---
 drivers/input/keyboard/cros_ec_keyb.c | 11 +++++------
 1 file changed, 5 insertions(+), 6 deletions(-)

diff --git a/drivers/input/keyboard/cros_ec_keyb.c b/drivers/input/keyboard/cros_ec_keyb.c
index bdbfd219f2e8..2f78a19521ab 100644
--- a/drivers/input/keyboard/cros_ec_keyb.c
+++ b/drivers/input/keyboard/cros_ec_keyb.c
@@ -59,8 +59,8 @@ struct cros_ec_keyb {
 	unsigned int cols;
 	int row_shift;
 	bool ghost_filter;
-	uint8_t *valid_keys;
-	uint8_t *old_kb_state;
+	u8 *valid_keys;
+	u8 *old_kb_state;
 
 	struct device *dev;
 	struct cros_ec_device *ec;
@@ -145,11 +145,11 @@ static const struct cros_ec_bs_map cros_ec_keyb_bs[] = {
  * Returns true when there is at least one combination of pressed keys that
  * results in ghosting.
  */
-static bool cros_ec_keyb_has_ghosting(struct cros_ec_keyb *ckdev, uint8_t *buf)
+static bool cros_ec_keyb_has_ghosting(struct cros_ec_keyb *ckdev, u8 *buf)
 {
 	int col1, col2, buf1, buf2;
 	struct device *dev = ckdev->dev;
-	uint8_t *valid_keys = ckdev->valid_keys;
+	u8 *valid_keys = ckdev->valid_keys;
 
 	/*
 	 * Ghosting happens if for any pressed key X there are other keys
@@ -259,8 +259,7 @@ static void cros_ec_keyb_process_key_fn_map(struct cros_ec_keyb *ckdev,
  * press/release events accordingly.  The keyboard state is one byte
  * per column.
  */
-static void cros_ec_keyb_process(struct cros_ec_keyb *ckdev,
-			 uint8_t *kb_state, int len)
+static void cros_ec_keyb_process(struct cros_ec_keyb *ckdev, u8 *kb_state, int len)
 {
 	int col, row;
 	int new_state;
-- 
2.53.0.345.g96ddfc5eaa-goog


  parent reply	other threads:[~2026-02-22  0:37 UTC|newest]

Thread overview: 20+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-02-22  0:37 [PATCH 1/7] Input: export input_default_setkeycode Dmitry Torokhov
2026-02-22  0:37 ` [PATCH 2/7] Input: cros_ec_keyb - add function key support Dmitry Torokhov
2026-02-22 10:46   ` Tzung-Bi Shih
2026-02-23  3:47     ` Dmitry Torokhov
2026-02-23 12:24   ` Fabio Baltieri
2026-02-22  0:37 ` Dmitry Torokhov [this message]
2026-02-22 10:47   ` [PATCH 3/7] Input: cros_ec_keyb - use u8 instead of uint8_t Tzung-Bi Shih
2026-02-22  0:37 ` [PATCH 4/7] Input: cros_ec_keyb - use BIT() macro instead of open-coding shifts Dmitry Torokhov
2026-02-22 10:47   ` Tzung-Bi Shih
2026-02-22  0:37 ` [PATCH 5/7] Input: cros_ec_keyb - simplify cros_ec_keyb_work() Dmitry Torokhov
2026-02-22 10:47   ` Tzung-Bi Shih
2026-02-23  3:49     ` Dmitry Torokhov
2026-02-23  4:41       ` Tzung-Bi Shih
2026-02-22  0:37 ` [PATCH 6/7] Input: cros_ec_keyb - do not allocate keyboard state separately Dmitry Torokhov
2026-02-22 10:48   ` Tzung-Bi Shih
2026-02-22  0:37 ` [PATCH 7/7] Input: cros_ec_keyb - factor out column processing Dmitry Torokhov
2026-02-22 10:48   ` Tzung-Bi Shih
2026-02-23  3:51     ` Dmitry Torokhov
2026-02-23  4:40       ` Tzung-Bi Shih
2026-02-22 10:46 ` [PATCH 1/7] Input: export input_default_setkeycode Tzung-Bi Shih

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=20260222003717.471977-3-dmitry.torokhov@gmail.com \
    --to=dmitry.torokhov@gmail.com \
    --cc=bleung@chromium.org \
    --cc=chrome-platform@lists.linux.dev \
    --cc=fabiobaltieri@chromium.org \
    --cc=groeck@chromium.org \
    --cc=linux-input@vger.kernel.org \
    --cc=linux-kernel@vger.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