| Age | Commit message (Collapse) | Author | Files | Lines |
|
No functional changes, just a prep patch for the one after.
Signed-off-by: Benjamin Tissoires <[email protected]>
Acked-by: Ping Cheng <[email protected]>
Signed-off-by: Jiri Kosina <[email protected]>
|
|
This will be useful when each remote will be assigned its own input device.
We won't need to unregister each input and sysfs and other elements one
at a time.
Signed-off-by: Benjamin Tissoires <[email protected]>
Acked-by: Ping Cheng <[email protected]>
Signed-off-by: Jiri Kosina <[email protected]>
|
|
The wacom_remote_create_attr_group() and wacom_remote_destroy_attr_group()
functions were both allocating/destroying the sysfs groups but also
initializing the parameters for the remotes. Have proper functions
that can be called and extended.
Signed-off-by: Benjamin Tissoires <[email protected]>
Acked-by: Ping Cheng <[email protected]>
Signed-off-by: Jiri Kosina <[email protected]>
|
|
Thanks to devres management, we don't need to remember a lot of failure
path. One or two is enough.
Signed-off-by: Benjamin Tissoires <[email protected]>
Acked-by: Ping Cheng <[email protected]>
Signed-off-by: Jiri Kosina <[email protected]>
|
|
If we want to have one input device per remote, it's better to have our
own struct wacom_remote which is dynamically allocated.
Signed-off-by: Benjamin Tissoires <[email protected]>
Acked-by: Ping Cheng <[email protected]>
Signed-off-by: Jiri Kosina <[email protected]>
|
|
wacom_remote_status_irq() sends information of addition/removal of EKR.
We want to allocate one input node per remote, so better having this
in a separate worker, not handled in the IRQ directly.
Signed-off-by: Benjamin Tissoires <[email protected]>
Acked-by: Ping Cheng <[email protected]>
Signed-off-by: Jiri Kosina <[email protected]>
|
|
We need to add an action to ensure wacom->led.groups is null when
wacom_led_control() gets called after the resources has been freed.
This also prevents to send a LED command when there is no support
from the device.
Signed-off-by: Benjamin Tissoires <[email protected]>
Acked-by: Ping Cheng <[email protected]>
Signed-off-by: Jiri Kosina <[email protected]>
|
|
wacom_release_shared_data() and wacom_remove_shared_data() are moved up
so they can be referenced in wacom_add_shared_data().
There is no point in explicitly setting wacom_wac1->shared->type to 0 in
wacom_wireless_work() (plus this would give an oops).
Signed-off-by: Benjamin Tissoires <[email protected]>
Acked-by: Ping Cheng <[email protected]>
Signed-off-by: Jiri Kosina <[email protected]>
|
|
We started switching the driver to devres, so we should use it as much
as possible.
Signed-off-by: Benjamin Tissoires <[email protected]>
Acked-by: Ping Cheng <[email protected]>
Signed-off-by: Jiri Kosina <[email protected]>
|
|
The sysfs group was indeed removed by kobject_put(wacom->remote_dir) in
wacom_remove(), but the name of the group was never freed.
Also remove the misplaced kobject_put(wacom->remote_dir) in the error
path of wacom_remote_create_attr_group().
Signed-off-by: Benjamin Tissoires <[email protected]>
Acked-by: Ping Cheng <[email protected]>
Signed-off-by: Jiri Kosina <[email protected]>
|
|
Use our own wacom_devm_sysfs_create_group() as there is currently no
generic one. It has been requested at least twice [1][2] but has been
always rejected.
However, in the Wacom case, for the wirelessly connected devices, we need
to be able to release the created sysfs files without removing the parent
kobject.
[1] https://patchwork.kernel.org/patch/7526551/
[2] https://lkml.org/lkml/2013/3/14/728
Signed-off-by: Benjamin Tissoires <[email protected]>
Acked-by: Ping Cheng <[email protected]>
Signed-off-by: Jiri Kosina <[email protected]>
|
|
We currently have a complex clean_inputs() function while this can be
handled all by devres. Set a group that we can destroy in wireless_work().
Signed-off-by: Benjamin Tissoires <[email protected]>
Acked-by: Ping Cheng <[email protected]>
Signed-off-by: Jiri Kosina <[email protected]>
|
|
Simplifying the error code paths.
We need to keep wacom_clean_inputs() around for now as the wireless
module is using it to dynamically remove the inputs on disconnect.
Signed-off-by: Benjamin Tissoires <[email protected]>
Acked-by: Ping Cheng <[email protected]>
Signed-off-by: Jiri Kosina <[email protected]>
|
|
Simplifying the error code paths.
We need to keep wacom_destroy_battery() around for now as the wireless
module and the remotes are using it to dynamically remove the battery
supply on disconnect.
Signed-off-by: Benjamin Tissoires <[email protected]>
Acked-by: Ping Cheng <[email protected]>
Signed-off-by: Jiri Kosina <[email protected]>
|
|
Looks like the battery hijacked the wireless worker. That's not fair so
use a work queue per task.
Signed-off-by: Benjamin Tissoires <[email protected]>
Acked-by: Ping Cheng <[email protected]>
Signed-off-by: Jiri Kosina <[email protected]>
|
|
Like remotes, LEDs should be handled by themself, not magically behind
the inputs as they have a complete different life.
Signed-off-by: Benjamin Tissoires <[email protected]>
Acked-by: Ping Cheng <[email protected]>
Signed-off-by: Jiri Kosina <[email protected]>
|
|
wacom->remote_dir has nothing to do with inputs, so better not magically
removing it when cleaning inputs.
Signed-off-by: Benjamin Tissoires <[email protected]>
Acked-by: Ping Cheng <[email protected]>
Signed-off-by: Jiri Kosina <[email protected]>
|
|
The type is never set but we check for it in wacom_wireless_irq().
It looks like this is a big hack from the beginning, so fill in the gap
only.
Untested.
Signed-off-by: Benjamin Tissoires <[email protected]>
Acked-by: Ping Cheng <[email protected]>
Signed-off-by: Jiri Kosina <[email protected]>
|
|
Since fd5f92b ("HID: wacom: reuse wacom_parse_and_register() in
wireless_work"), wacom->shared->type is not set.
Send the information of the battery if we have one.
Signed-off-by: Benjamin Tissoires <[email protected]>
Acked-by: Ping Cheng <[email protected]>
Signed-off-by: Jiri Kosina <[email protected]>
|
|
Add MIC mute key which is found on HP Business Slim Keyboard
T: Bus=02 Lev=01 Prnt=01 Port=00 Cnt=01 Dev#= 23 Spd=1.5 MxCh= 0
D: Ver= 2.00 Cls=00(>ifc ) Sub=00 Prot=00 MxPS= 8 #Cfgs= 1
P: Vendor=03f0 ProdID=2f4a Rev=00.10
S: Manufacturer=Chicony
S: Product=HP Business Slim Keyboard
C: #Ifs= 2 Cfg#= 1 Atr=a0 MxPwr=100mA
I: If#= 0 Alt= 0 #EPs= 1 Cls=03(HID ) Sub=01 Prot=01 Driver=usbhid
I: If#= 1 Alt= 0 #EPs= 1 Cls=03(HID ) Sub=00 Prot=00 Driver=usbhid
Signed-off-by: AceLan Kao <[email protected]>
Signed-off-by: Jiri Kosina <[email protected]>
|
|
The new device has 06a3:0cfa as identifiers, and the same quirks as the
other RAT models. It needs this fix in order not to confuse the xorg server
with its tristate button, which is reported as three different buttons, one
of which is always on.
[[email protected]: drop unrelated whitespace hunk]
Signed-off-by: Mayeul Cantan <[email protected]>
Reviewed-by: Benjamin Tissoires <[email protected]>
Signed-off-by: Jiri Kosina <[email protected]>
|
|
The FutureMax Dance Mat claims to be a SixAxis controller
but breaks if descriptor fixups are applied. Detect the
device using its USB product string and disable fixups
when it is detected.
Signed-off-by: Mikko Perttunen <[email protected]>
Reviewed-by: Benjamin Tissoires <[email protected]>
Acked-by: Antonio Ospite <[email protected]>
Signed-off-by: Jiri Kosina <[email protected]>
|
|
The IS_ENABLED() macro checks if a Kconfig symbol has been enabled either
built-in or as a module, use that macro instead of open coding the same.
Using the macro makes the code more readable by helping abstract away some
of the Kconfig built-in and module enable details.
Signed-off-by: Javier Martinez Canillas <[email protected]>
Reviewed-by: Benjamin Tissoires <[email protected]>
Signed-off-by: Jiri Kosina <[email protected]>
|
|
Conflicts:
drivers/hid/hid-thingm.c
|
|
'for-4.8/uhid-offload-hid-device-add' and 'for-4.8/upstream' into for-linus
|
|
A recent commit added barry support to this driver, but that causes
a link failure when CONFIG_POWER_SUPPLY is not set:
drivers/hid/built-in.o: In function `hidpp_battery_get_property':
:(.text+0x1a834): undefined reference to `power_supply_get_drvdata'
drivers/hid/built-in.o: In function `hidpp_raw_event':
:(.text+0x1b10c): undefined reference to `power_supply_changed'
drivers/hid/built-in.o: In function `hidpp_connect_event':
:(.text+0x1bd88): undefined reference to `devm_power_supply_register'
:(.text+0x1be30): undefined reference to `power_supply_powers'
This adds a dependency, identically to the other HID drivers that need this.
Signed-off-by: Arnd Bergmann <[email protected]>
Reviewed-by: Benjamin Tissoires <[email protected]>
Fixes: 5a2b190cddb9 ("HID: logitech-hidpp: add battery support for HID++ 2.0 devices")
Signed-off-by: Jiri Kosina <[email protected]>
|
|
USB device
Vendor 05ac (Apple)
Device 0267 (Magic Keyboard)
This keyboard supports both Bluetooth and USB connections, this patch
only covers USB.
Thanks to Maxime Poulin <[email protected]>
Signed-off-by: Jean-Gabriel Gill-Couture <[email protected]>
Signed-off-by: Jiri Kosina <[email protected]>
|
|
Properly handle this __le16 value on big endian systems.
Signed-off-by: Heiner Kallweit <[email protected]>
Signed-off-by: Jiri Kosina <[email protected]>
|
|
Now that we can create battery power_supply sources, it's better to enable
the connect_event callback unconditionally.
Signed-off-by: Benjamin Tissoires <[email protected]>
Tested-by: Peter Hutterer <[email protected]>
Signed-off-by: Peter Hutterer <[email protected]>
Signed-off-by: Jiri Kosina <[email protected]>
|
|
If the 0x1000 Unified Battery Level Status feature exists, expose the battery
level.
The main drawback is that while a device is plugged in its battery level is 0.
To avoid exposing that as 0% charge we make up a number based on the charging
status.
Signed-off-by: Peter Hutterer <[email protected]>
Signed-off-by: Benjamin Tissoires <[email protected]>
Signed-off-by: Jiri Kosina <[email protected]>
|
|
Add support for Greynut Luxafor. This device has two groups of three
independent LED's each.
Successfully tested with such a device.
Signed-off-by: Heiner Kallweit <[email protected]>
Signed-off-by: Jiri Kosina <[email protected]>
|
|
Add support for the HID-compliant Delcom Visual Signal Indicator
generation 2 devices.
Successfully tested with part no 904000 from the family of these devices.
Signed-off-by: Heiner Kallweit <[email protected]>
Signed-off-by: Jiri Kosina <[email protected]>
|
|
Delcom uses the report id to submit command information. To be able to
use the hidled framework also for Delcom devices we have to remove the
report id from struct hidled_config.
Signed-off-by: Heiner Kallweit <[email protected]>
Signed-off-by: Jiri Kosina <[email protected]>
|
|
The usage Confidence is mandary to Windows Precision Touchpad devices. If
it is examined in input_mapping on a WIndows Precision Touchpad, a new add
quirk MT_QUIRK_CONFIDENCE desgned for such devices will be applied to the
device. A touch with the confidence bit is not set is determined as
invalid.
Tested on Dell XPS13 9343
Cc: [email protected] # v4.5+
Reviewed-by: Benjamin Tissoires <[email protected]>
Tested-by: Andy Lutomirski <[email protected]> # XPS 13 9350, BIOS 1.4.3
Signed-off-by: Allen Hung <[email protected]>
Signed-off-by: Jiri Kosina <[email protected]>
|
|
confidence usage"
This reverts commit 25a84db15b3f ("HID: multitouch: enable palm rejection
if device implements confidence usage")
The commit enables palm rejection for Win8 Precision Touchpad devices but
the quirk MT_QUIRK_VALID_IS_CONFIDENCE it is using is not working very
properly. This quirk is originally designed for some WIn7 touchscreens. Use
of this for a Win8 Precision Touchpad will cause unexpected pointer jumping
problem.
Cc: [email protected] # v4.5+
Reviewed-by: Benjamin Tissoires <[email protected]>
Tested-by: Andy Lutomirski <[email protected]> # XPS 13 9350, BIOS 1.4.3
Signed-off-by: Allen Hung <[email protected]>
Signed-off-by: Jiri Kosina <[email protected]>
|
|
This patch validates the num_values parameter from userland during the
HIDIOCGUSAGES and HIDIOCSUSAGES commands. Previously, if the report id was set
to HID_REPORT_ID_UNKNOWN, we would fail to validate the num_values parameter
leading to a heap overflow.
Cc: [email protected]
Signed-off-by: Scott Bauer <[email protected]>
Signed-off-by: Jiri Kosina <[email protected]>
|
|
Remove an unnecessary codes.
Change input_ivent() function to appropriate function.
Add the device ID of "HID_DEVICE_ID_ALPS_U1_DUAL".
[[email protected]: removed unnecessary bitshifts of values passed
input_report_key() as spotted by Dmitry]
Signed-off-by: Masaki Ota <[email protected]>
Reviewed-by: Dmitry Torokhov <[email protected]>
Signed-off-by: Jiri Kosina <[email protected]>
|
|
Now that support for ThingM blink(1) was merged into the hid-led driver
the dedicated driver for this device can be removed.
Signed-off-by: Heiner Kallweit <[email protected]>
Acked-by: Vivien Didelot <[email protected]>
Signed-off-by: Jiri Kosina <[email protected]>
|
|
Add support for ThingM blink(1) and make the dedicated ThingM driver
obsolete.
Successfully tested with a blink(1) mk2.
Signed-off-by: Heiner Kallweit <[email protected]>
Signed-off-by: Jiri Kosina <[email protected]>
|
|
Add support for reading data from LED devices.
Signed-off-by: Heiner Kallweit <[email protected]>
Signed-off-by: Jiri Kosina <[email protected]>
|
|
Add generic support for devices with multiple independent LED's.
Signed-off-by: Heiner Kallweit <[email protected]>
Signed-off-by: Jiri Kosina <[email protected]>
|
|
Add i2c_hid_shutdown for i2c-hid driver to send suspend cmd & free
irq before device shutdown.
Some HW design (i.e. Umaro, a chromebook model) is that the power to
i2c hid device won't down after device shutdown. Also the i2c-hid driver
do not send suspend cmd to the hid i2c device and free its irq before
shutdown.So if We touch the touchscreen or some other i2c hid device,
the power consumtion will be go up even when the device is in shutdown
state.
Though the root cause maybe a HW issue. But it seems that it is a
good pratice to set power sleep for i2c-hid device before shutdown.
Signed-off-by: Guohua Zhong <[email protected]>
Acked-By: Benjamin Tissoires <[email protected]>
Signed-off-by: Jiri Kosina <[email protected]>
|
|
All devices with ALPS_JP VID are handled by hid-alps driver, hence they require
an entry in hid_have_special_driver[].
Signed-off-by: Jiri Kosina <[email protected]>
|
|
Kernel printf format %*ph allows to print small buffers up to 64 bytes.
Make use of it to simplify the debug output code.
Signed-off-by: Heiner Kallweit <[email protected]>
Signed-off-by: Jiri Kosina <[email protected]>
|
|
Calculating size of the report as sizeof(pointer) always passess the length
corresponding to the pointer type, not the underlying data report.
Reported-by: kbuild test robot <[email protected]>
Signed-off-by: Jiri Kosina <[email protected]>
|
|
... and therefore should be marked static.
Signed-off-by: Jiri Kosina <[email protected]>
|
|
Add support Alps I2C HID Touchpad and Stick device.
Signed-off-by: Masaki Ota <[email protected]>
Signed-off-by: Jiri Kosina <[email protected]>
|
|
The driver port was done carefully not to depend on USB at all, in favor of
being generic HID driver instead. Therefore there is no need to explicitly
talk about USB only in the config.
Signed-off-by: Jiri Kosina <[email protected]>
|
|
This patch migrates the USB LED driver to the HID subsystem.
Supported are Dream Cheeky Webmail Notifier / Friends Alert
and Riso Kagaku Webmail Notifier.
Benefits:
- Avoid using USB low-level calls and use the HID subsystem instead
(as this device provides a USB HID interface)
- Use standard LED subsystem instead of proprietary sysfs entries,
this allows e.g. to use the device with features like triggers
Successfully tested with a Dream Cheeky Webmail Notifier and a
Riso Kagaku Webmail Notifier compatible device.
Signed-off-by: Heiner Kallweit <[email protected]>
Signed-off-by: Jiri Kosina <[email protected]>
|
|
i2c-hid devices' suspend/resume are usually time-consuming process.
For example, the touch controller(i2c-ATML1000:00) on ASUS T100 tablet
takes about 160ms for suspending and 120ms for resuming. This patch
enables i2c-hid devices to suspend/resume asynchronously. This will
take advantage of multicore and speed up system suspend/resume process.
Signed-off-by: Zhonghui Fu <[email protected]>
Acked-by: Benjamin Tissoires <[email protected]>
Signed-off-by: Jiri Kosina <[email protected]>
|