linux-input.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Tony Lindgren <tony@atomide.com>
To: Dmitry Torokhov <dmitry.torokhov@gmail.com>
Cc: Dan Carpenter <dan.carpenter@oracle.com>,
	Komal Shah <komal_shah802003@yahoo.com>,
	"linux-input@vger.kernel.org" <linux-input@vger.kernel.org>,
	Janusz Krzysztofik <jkrzyszt@tis.icnet.pl>,
	Aaro Koskinen <aaro.koskinen@iki.fi>,
	linux-omap@vger.kernel.org
Subject: Re: [PATCH] OMAP: Add keypad driver
Date: Thu, 7 Jan 2016 16:10:53 -0800	[thread overview]
Message-ID: <20160108001052.GQ12777@atomide.com> (raw)
In-Reply-To: <20160107232228.GA20533@dtor-ws>

* Dmitry Torokhov <dmitry.torokhov@gmail.com> [160107 15:23]:
> On Thu, Jan 07, 2016 at 12:13:17PM -0800, Tony Lindgren wrote:
> > 
> > Sounds like the check is not needed if it has not been used for
> > past five years, so my preference is option #1 then.
> 
> OK, how about the below then?

Looks good to me thanks: Acked-by: Tony Lindgren <tony@atomide.com>

I've also corrected Aaro's email address, he may have some keyboard
input too.

Regards,

Tony


> Input: omap-keypad - remove dead check
> 
> From: Dmitry Torokhov <dmitry.torokhov@gmail.com>
> 
> Commit da1f026b532ce944d74461497dc6d8c16456466e ("Keyboard: omap-keypad:
> use matrix_keypad.h") switched the driver to use matrix keypad
> infrastructure, which made array of keycodes to be unsigned short, and
> caused the test for negativity never trigger. This leads to the following
> static checker warning:
> 
> 	drivers/input/keyboard/omap-keypad.c:158 omap_kp_tasklet()
> 	warn: 'keycodes[]' is never negative.
> 
> Given that we did not care about this check for a few years already let's
> simply remove it.
> 
> Reported-by: Dan Carpenter <dan.carpenter@oracle.com>
> Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
> ---
>  drivers/input/keyboard/omap-keypad.c |    8 --------
>  1 file changed, 8 deletions(-)
> 
> diff --git a/drivers/input/keyboard/omap-keypad.c b/drivers/input/keyboard/omap-keypad.c
> index 75ad666..e0d72c8 100644
> --- a/drivers/input/keyboard/omap-keypad.c
> +++ b/drivers/input/keyboard/omap-keypad.c
> @@ -155,14 +155,6 @@ static void omap_kp_tasklet(unsigned long data)
>  			       "pressed" : "released");
>  #else
>  			key = keycodes[MATRIX_SCAN_CODE(row, col, row_shift)];
> -			if (key < 0) {
> -				printk(KERN_WARNING
> -				      "omap-keypad: Spurious key event %d-%d\n",
> -				       col, row);
> -				/* We scan again after a couple of seconds */
> -				spurious = 1;
> -				continue;
> -			}
>  
>  			if (!(kp_cur_group == (key & GROUP_MASK) ||
>  			      kp_cur_group == -1))

  parent reply	other threads:[~2016-01-08  0:10 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-01-07  9:37 [PATCH] OMAP: Add keypad driver Dan Carpenter
2016-01-07 18:54 ` Dmitry Torokhov
2016-01-07 20:13   ` Tony Lindgren
2016-01-07 23:22     ` Dmitry Torokhov
2016-01-08  0:08       ` Koskinen, Aaro (Nokia - FI/Espoo)
2016-01-08  0:13         ` Tony Lindgren
2016-01-08  0:10       ` Tony Lindgren [this message]
2016-01-08  1:41       ` Janusz Krzysztofik
2016-01-08  6:38         ` Dmitry Torokhov

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=20160108001052.GQ12777@atomide.com \
    --to=tony@atomide.com \
    --cc=aaro.koskinen@iki.fi \
    --cc=dan.carpenter@oracle.com \
    --cc=dmitry.torokhov@gmail.com \
    --cc=jkrzyszt@tis.icnet.pl \
    --cc=komal_shah802003@yahoo.com \
    --cc=linux-input@vger.kernel.org \
    --cc=linux-omap@vger.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;
as well as URLs for NNTP newsgroup(s).