Commit 7b5d3312fbfbb21d2fc7de94e0db66cfdf8b0055
1 parent
1afaab90e8
Exists in
master
and in
39 other branches
Input: gamecon - reference correct input device in NES mode
We moved input devices from 'struct gc' to individial pads (struct gc-pad), but gc_nes_process_packet() was still trying to use old ones and crashing. Cc: stable@kernel.org Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
Showing 1 changed file with 1 additions and 2 deletions Side-by-side Diff
drivers/input/joystick/gamecon.c
... | ... | @@ -89,7 +89,6 @@ |
89 | 89 | struct gc { |
90 | 90 | struct pardevice *pd; |
91 | 91 | struct gc_pad pads[GC_MAX_DEVICES]; |
92 | - struct input_dev *dev[GC_MAX_DEVICES]; | |
93 | 92 | struct timer_list timer; |
94 | 93 | int pad_count[GC_MAX]; |
95 | 94 | int used; |
... | ... | @@ -387,7 +386,7 @@ |
387 | 386 | for (i = 0; i < GC_MAX_DEVICES; i++) { |
388 | 387 | |
389 | 388 | pad = &gc->pads[i]; |
390 | - dev = gc->dev[i]; | |
389 | + dev = pad->dev; | |
391 | 390 | s = gc_status_bit[i]; |
392 | 391 | |
393 | 392 | switch (pad->type) { |