From patchwork Tue Dec 31 19:34:44 2013 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Dmitry Torokhov X-Patchwork-Id: 3422491 Return-Path: X-Original-To: patchwork-linux-input@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork2.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.19.201]) by patchwork2.web.kernel.org (Postfix) with ESMTP id 4E378C02DC for ; Tue, 31 Dec 2013 19:34:51 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id 6EC1120120 for ; Tue, 31 Dec 2013 19:34:50 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id 8DB5F2011E for ; Tue, 31 Dec 2013 19:34:49 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1756513Ab3LaTes (ORCPT ); Tue, 31 Dec 2013 14:34:48 -0500 Received: from mail-pa0-f49.google.com ([209.85.220.49]:34544 "EHLO mail-pa0-f49.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1756438Ab3LaTer (ORCPT ); Tue, 31 Dec 2013 14:34:47 -0500 Received: by mail-pa0-f49.google.com with SMTP id kx10so12851422pab.8 for ; Tue, 31 Dec 2013 11:34:47 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=date:from:to:cc:subject:message-id:mime-version:content-type :content-disposition:user-agent; bh=s2ccYrdK2mWDNEollsnkfFzt+oJkNbh9EYb95k94s2s=; b=FlWVcUPHnuK6nfzI7XB0JurfdIXP46FW7W6RkGjYq1JcMyS2pKz9buyRV5n+U8JSx/ oMHcniLIT2SnFFCkl1h/3tJt4Z+n3Yxil6Ty+pPozmMr6cfEh6JNEth0599ibSPHPhNV P7beHYaMsRtMsxblhTISU/riYbRjPM2czz+Ywl2weAvM9gv3QdvZMrzFGzKipdz+3rP7 s/LRb0ozBgFWUEWeF/bDO0qFceHEVixW4aG3leqGqWSE4wMx+M7hU/qBeea4z2MpG9vW CNXr1u+A0PEG2/e5wqLCeyIYt6sLlm6WL+kb5HROhPpaAFBtBy6nfiQ1vW+2zuo9TVBi fzWA== X-Received: by 10.68.108.194 with SMTP id hm2mr78353861pbb.22.1388518487274; Tue, 31 Dec 2013 11:34:47 -0800 (PST) Received: from mailhub.coreip.homeip.net (c-67-188-112-76.hsd1.ca.comcast.net. [67.188.112.76]) by mx.google.com with ESMTPSA id pa1sm118297196pac.17.2013.12.31.11.34.45 for (version=TLSv1 cipher=RC4-SHA bits=128/128); Tue, 31 Dec 2013 11:34:46 -0800 (PST) Date: Tue, 31 Dec 2013 11:34:44 -0800 From: Dmitry Torokhov To: linux-input@vger.kernel.org Cc: Simon Glass , Vincent Palatin , Luigi Semenzato , Doug Anderson , linux-kernel@vger.kernel.org Subject: [PATCH] Input: cros_ec_keyb - switch from using uint8_t to u8 Message-ID: <20131231193442.GA25208@core.coreip.homeip.net> MIME-Version: 1.0 Content-Disposition: inline User-Agent: Mutt/1.5.21 (2010-09-15) Sender: linux-input-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-input@vger.kernel.org X-Spam-Status: No, score=-6.9 required=5.0 tests=BAYES_00, DKIM_ADSP_CUSTOM_MED, DKIM_SIGNED, FREEMAIL_FROM, RCVD_IN_DNSWL_HI, RP_MATCHES_RCVD, T_DKIM_INVALID, UNPARSEABLE_RELAY autolearn=ham version=3.3.1 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on mail.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP u8 is proper in-kernel type for unsigned byte data. Signed-off-by: Dmitry Torokhov --- drivers/input/keyboard/cros_ec_keyb.c | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-) diff --git a/drivers/input/keyboard/cros_ec_keyb.c b/drivers/input/keyboard/cros_ec_keyb.c index 4083796..d44c5d4 100644 --- a/drivers/input/keyboard/cros_ec_keyb.c +++ b/drivers/input/keyboard/cros_ec_keyb.c @@ -50,7 +50,7 @@ struct cros_ec_keyb { int row_shift; const struct matrix_keymap_data *keymap_data; bool ghost_filter; - uint8_t *old_kb_state; + u8 *old_kb_state; struct device *dev; struct input_dev *idev; @@ -60,7 +60,7 @@ struct cros_ec_keyb { static bool cros_ec_keyb_row_has_ghosting(struct cros_ec_keyb *ckdev, - uint8_t *buf, int row) + u8 *buf, int row) { int pressed_in_row = 0; int row_has_teeth = 0; @@ -89,7 +89,7 @@ static bool cros_ec_keyb_row_has_ghosting(struct cros_ec_keyb *ckdev, * 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 row; @@ -132,7 +132,7 @@ static bool cros_ec_keyb_has_ghosting(struct cros_ec_keyb *ckdev, uint8_t *buf) * per column) */ static void cros_ec_keyb_process(struct cros_ec_keyb *ckdev, - uint8_t *kb_state, int len) + u8 *kb_state, int len) { struct input_dev *idev = ckdev->idev; int col, row; @@ -189,19 +189,19 @@ static void cros_ec_keyb_close(struct input_dev *dev) &ckdev->notifier); } -static int cros_ec_keyb_get_state(struct cros_ec_keyb *ckdev, uint8_t *kb_state) +static int cros_ec_keyb_get_state(struct cros_ec_keyb *ckdev, u8 *kb_state) { return ckdev->ec->command_recv(ckdev->ec, EC_CMD_MKBP_STATE, kb_state, ckdev->cols); } static int cros_ec_keyb_work(struct notifier_block *nb, - unsigned long state, void *_notify) + unsigned long state, void *_notify) { int ret; struct cros_ec_keyb *ckdev = container_of(nb, struct cros_ec_keyb, notifier); - uint8_t kb_state[ckdev->cols]; + u8 kb_state[ckdev->cols]; ret = cros_ec_keyb_get_state(ckdev, kb_state); if (ret >= 0) @@ -282,8 +282,8 @@ static int cros_ec_keyb_probe(struct platform_device *pdev) /* Clear any keys in the buffer */ static void cros_ec_keyb_clear_keyboard(struct cros_ec_keyb *ckdev) { - uint8_t old_state[ckdev->cols]; - uint8_t new_state[ckdev->cols]; + u8 old_state[ckdev->cols]; + u8 new_state[ckdev->cols]; unsigned long duration; int i, ret;