History log of /linux-master/drivers/hid/hid-cougar.c
Revision Date Author Comments
# 8e3cd922 22-Sep-2021 Cai Huoqing <caihuoqing@baidu.com>

HID: cougar: Make use of the helper function devm_add_action_or_reset()

The helper function devm_add_action_or_reset() will internally
call devm_add_action(), and if devm_add_action() fails then it will
execute the action mentioned and return the error code. So
use devm_add_action_or_reset() instead of devm_add_action()
to simplify the error handling, reduce the code.

Signed-off-by: Cai Huoqing <caihuoqing@baidu.com>
Signed-off-by: Jiri Kosina <jkosina@suse.cz>


# 857ce8c1 27-Jul-2020 Rikard Falkeborn <rikard.falkeborn@gmail.com>

HID: cougar: Constify cougar_id_table

cougar_id_table[] is not changed and can be made const to allow the
compiler to put it in read-only memory.

Signed-off-by: Rikard Falkeborn <rikard.falkeborn@gmail.com>
Signed-off-by: Jiri Kosina <jkosina@suse.cz>


# 87fcb6a6 12-Aug-2019 Benjamin Tissoires <benjamin.tissoires@redhat.com>

HID: do not call hid_set_drvdata(hdev, NULL) in drivers

This is a common pattern in the HID drivers to reset the drvdata. Some
do it properly, some do it only in case of failure.

But, this is actually already handled by driver core, so there is no need
to do it manually.

[for hid-sensor-hub.c]
Acked-by: Srinivas Pandruvada <srinivas.pandruvada@linux.intel.com>
[For hid-picolcd_core.c]
Acked-by: Bruno Prémont <bonbons@linux-vserver.org>
Signed-off-by: Benjamin Tissoires <benjamin.tissoires@redhat.com>


# aeed35fa 18-Nov-2018 Daniel M. Lambea <dmlambea@gmail.com>

HID: cougar: Add support for Cougar 700K Gaming Keyboard

Add USB ID 060b:700a to the list of valid USB IDS for the
cougar hid driver.

Signed-off-by: Daniel M. Lambea <dmlambea@gmail.com>
Signed-off-by: Benjamin Tissoires <benjamin.tissoires@redhat.com>


# 75f1f19b 27-Jul-2018 Daniel M. Lambea <dmlambea@gmail.com>

HID: cougar: Stop processing vendor events on hid-core

Special key events received by the custom vendor's hdev are
translated to key events on the kbd iface's input device, so
their processing must not continue. Return -EPERM from
raw_event handler to effectively stop source events from
being processed in hid-core.

Signed-off-by: Daniel M. Lambea <dmlambea@gmail.com>
Signed-off-by: Jiri Kosina <jkosina@suse.cz>


# 6b003a8d 27-Jul-2018 Daniel M. Lambea <dmlambea@gmail.com>

HID: cougar: Make parameter 'g6_is_space' dinamically settable

Parameter g6_is_space instructs the driver to map G6 keypresses
to KEY_SPACE (true) or to KEY_F18 (false). Make the parameter
configurable via module_param_cb to allow users to change its
value without reloading the module.

Signed-off-by: Daniel M. Lambea <dmlambea@gmail.com>
Signed-off-by: Jiri Kosina <jkosina@suse.cz>


# b8e759b8 17-Jul-2018 Daniel M. Lambea <dmlambea@gmail.com>

HID: cougar: Add support for the Cougar 500k Gaming Keyboard

Cougar 500k Gaming Keyboard have some special function keys that
make the keyboard stop responding once pressed. Implement the custom
vendor interface that deals with the extended keypresses to fix.

The bug can be reproduced by plugging in the keyboard, then pressing the
rightmost part of the spacebar.

Signed-off-by: Daniel M. Lambea <dmlambea@gmail.com>
Reviewed-by: Benjamin Tissoires <benjamin.tissoires@redhat.com>
Signed-off-by: Jiri Kosina <jkosina@suse.cz>