Maverick SRU, Input: fix typo in keycode validation supporting large scancodes
Stefan Bader
stefan.bader at canonical.com
Mon Jan 31 09:09:03 UTC 2011
Seems to have been introduced by (2.6.37-rc1:
commit 8613e4c2872a87cc309a42de2c7091744dc54d0e
Author: Mauro Carvalho Chehab <mchehab at redhat.com>
Date: Thu Sep 9 21:54:22 2010 -0700
Input: add support for large scancodes
though we got it through:
commit bcbfc24ead6935714a001ab6f1f725763075f98c
Author: Jarod Wilson <jarod at redhat.com>
Date: Wed Aug 18 11:16:41 2010 -0600
UBUNTU: SAUCE: Update ir-core to linuxtv/other which should be merged for
2.6.36
On 01/28/2011 07:55 PM, Tim Gardner wrote:
> The following changes since commit ae86ab8935c91281dac1ab943f0ca353bc68ed79:
> Mattia Dongili (1):
> Input: fix typo in keycode validation supporting large scancodes
>
> are available in the git repository at:
>
> git://kernel.ubuntu.com/rtg/ubuntu-maverick.git vaio-backlight-lp658198
>
>
> From ae86ab8935c91281dac1ab943f0ca353bc68ed79 Mon Sep 17 00:00:00 2001
> From: Mattia Dongili <malattia at linux.it>
> Date: Thu, 18 Nov 2010 09:06:43 -0800
> Subject: [PATCH] Input: fix typo in keycode validation supporting large scancodes
>
> BugLink: http://bugs.launchpad.net/bugs/658198
>
> Backported from de391d12500ede13faa7ecadbe900a8de1f76cfa
> by Tim Gardner <tim.gardner at canonical.com>
>
> Check the input_keymap_entry keycode size (u32) instead of the device's
> (void*) when validating that keycode value can be stored in the keymap.
>
> Fixes: https://bugzilla.kernel.org/show_bug.cgi?id=22722
>
> Signed-off-by: Mattia Dongili <malattia at linux.it>
> Tested-by: Norbert Preining <preining at logic.at>
> Signed-off-by: Dmitry Torokhov <dtor at mail.ru>
> Signed-off-by: Tim Gardner <tim.gardner at canonical.com>
Acked-by: Stefan Bader <stefan.bader at canonical.com>
> ---
> drivers/input/input.c | 2 +-
> 1 files changed, 1 insertions(+), 1 deletions(-)
>
> diff --git a/drivers/input/input.c b/drivers/input/input.c
> index e6395bf..577a40a 100644
> --- a/drivers/input/input.c
> +++ b/drivers/input/input.c
> @@ -681,7 +681,7 @@ static int input_default_setkeycode(struct input_dev *dev,
> if (!dev->keycodesize)
> return -EINVAL;
>
> - if (dev->keycodesize < sizeof(dev->keycode) &&
> + if (dev->keycodesize < sizeof(kt_entry->keycode) &&
> (kt_entry->keycode >> (dev->keycodesize * 8)))
> return -EINVAL;
>
More information about the kernel-team
mailing list