From: Dmitry Torokhov Date: Thu, 24 May 2012 08:10:20 +0000 (-0700) Subject: Input: matrix-keymap - fix building keymaps X-Git-Tag: v3.5-rc1~103^2^2 X-Git-Url: https://openfabrics.org/gitweb/?a=commitdiff_plain;h=86809173ce32ef03bd4d0389dfc72df0c805e9c4;p=~emulex%2Finfiniband.git Input: matrix-keymap - fix building keymaps Keymaps used by drivers based on matrix-keymap facilities are arrays of unsigned shorts, not chars. Treating them otherwise produces corrupted keymaps. Reported-by: Sourav Poddar Signed-off-by: Dmitry Torokhov --- diff --git a/drivers/input/matrix-keymap.c b/drivers/input/matrix-keymap.c index db92c1ebfc5..443ad64b7f2 100644 --- a/drivers/input/matrix-keymap.c +++ b/drivers/input/matrix-keymap.c @@ -29,7 +29,7 @@ static bool matrix_keypad_map_key(struct input_dev *input_dev, unsigned int rows, unsigned int cols, unsigned int row_shift, unsigned int key) { - unsigned char *keymap = input_dev->keycode; + unsigned short *keymap = input_dev->keycode; unsigned int row = KEY_ROW(key); unsigned int col = KEY_COL(key); unsigned short code = KEY_VAL(key);