aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/input/serio/hyperv-keyboard.c (follow)
AgeCommit message (Collapse)AuthorFilesLines
2019-08-20Input: hyperv-keyboard: Use in-place iterator API in the channel callbackDexuan Cui1-29/+6
Simplify the ring buffer handling with the in-place API. Also avoid the dynamic allocation and the memory leak in the channel callback function. Signed-off-by: Dexuan Cui <decui@microsoft.com> Acked-by: Dmitry Torokhov <dmitry.torokhov@gmail.com> Signed-off-by: Sasha Levin <sashal@kernel.org>
2019-07-15Input: hyperv-keyboard - remove dependencies on PAGE_SIZE for ring bufferMaya Nakamura1-2/+2
Define the ring buffer size as a constant expression because it should not depend on the guest page size. Signed-off-by: Maya Nakamura <m.maya.nakamura@gmail.com> Reviewed-by: Michael Kelley <mikelley@microsoft.com> Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
2019-06-05treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 288Thomas Gleixner1-9/+1
Based on 1 normalized pattern(s): this program is free software you can redistribute it and or modify it under the terms and conditions of the gnu general public license version 2 as published by the free software foundation this program is distributed in the hope it will be useful but without any warranty without even the implied warranty of merchantability or fitness for a particular purpose see the gnu general public license for more details extracted by the scancode license scanner the SPDX license identifier GPL-2.0-only has been chosen to replace the boilerplate/reference in 263 file(s). Signed-off-by: Thomas Gleixner <tglx@linutronix.de> Reviewed-by: Allison Randal <allison@lohutok.net> Reviewed-by: Alexios Zavras <alexios.zavras@intel.com> Cc: linux-spdx@vger.kernel.org Link: https://lkml.kernel.org/r/20190529141901.208660670@linutronix.de Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2019-04-23Input: hyperv-keyboard - add module descriptionJoseph Salisbury1-0/+2
Signed-off-by: Joseph Salisbury <joseph.salisbury@microsoft.com> Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
2018-12-04Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/dtor/inputLinus Torvalds1-1/+1
Pull input updates from Dmitry Torokhov: "Mostly new IDs for Elan/Synaptics touchpads, plus a few small fixups" * 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/dtor/input: Input: omap-keypad - fix keyboard debounce configuration Input: xpad - quirk all PDP Xbox One gamepads Input: synaptics - enable SMBus for HP 15-ay000 Input: synaptics - add PNP ID for ThinkPad P50 to SMBus Input: elan_i2c - add ACPI ID for Lenovo IdeaPad 330-15ARR Input: elan_i2c - add support for ELAN0621 touchpad Input: hyper-v - fix wakeup from suspend-to-idle Input: atkbd - clean up indentation issue Input: st1232 - convert to SPDX identifiers Input: migor_ts - convert to SPDX identifiers Input: dt-bindings - fix a typo in file input-reset.txt Input: cros_ec_keyb - fix button/switch capability reports Input: elan_i2c - add ELAN0620 to the ACPI table Input: matrix_keypad - check for errors from of_get_named_gpio()
2018-11-15Input: hyper-v - fix wakeup from suspend-to-idleVitaly Kuznetsov1-1/+1
It makes little sense but still possible to put Hyper-V guests into suspend-to-idle state. To wake them up two wakeup sources were registered in the past: hyperv-keyboard and hid-hyperv. However, since commit eed4d47efe95 ("ACPI / sleep: Ignore spurious SCI wakeups from suspend-to-idle") pm_wakeup_event() from these devices is ignored. Switch to pm_wakeup_hard_event() API as these devices are actually the only possible way to wakeup Hyper-V guests. Fixes: eed4d47efe95 (ACPI / sleep: Ignore spurious SCI wakeups from suspend-to-idle) Reviewed-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> Acked-by: K. Y. Srinivasan <kys@microsoft.com> Acked-by: Jiri Kosina <jkosina@suse.cz> Signed-off-by: Vitaly Kuznetsov <vkuznets@redhat.com> Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
2018-07-03use the new async probing feature for the hyperv driversArjan van de Ven1-0/+3
Recent kernels support asynchronous probing; most hyperv drivers can be probed async easily so set the required flag for this. Signed-off-by: Arjan van de Ven <arjan@linux.intel.com> Signed-off-by: Stephen Hemminger <sthemmin@microsoft.com> Signed-off-by: K. Y. Srinivasan <kys@microsoft.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2017-01-21Input: serio - drop unnecessary calls to device_init_wakeupGuenter Roeck1-1/+0
Calling device_init_wakeup in the remove function is unnecessary since the device is going away, and thus won't be able to cause any wakeups under any circumstances. Besides, the driver cleanup code already handles the necessary cleanup. Similarly, disabling wakeup in the probe error path is unnecessary, as is disabling wakeup in the probe function in the first place. Signed-off-by: Guenter Roeck <linux@roeck-us.net> Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
2015-12-21Drivers: hv: vmbus: fix the building warning with hyperv-keyboardDexuan Cui1-10/+0
With the recent change af3ff643ea91ba64dd8d0b1cbed54d44512f96cd (Drivers: hv: vmbus: Use uuid_le type consistently), we always get this warning: CC [M] drivers/input/serio/hyperv-keyboard.o drivers/input/serio/hyperv-keyboard.c:427:2: warning: missing braces around initializer [-Wmissing-braces] { HV_KBD_GUID, }, ^ drivers/input/serio/hyperv-keyboard.c:427:2: warning: (near initialization for .id_table[0].guid.b.) [-Wmissing-braces] The patch fixes the warning. Signed-off-by: Dexuan Cui <decui@microsoft.com> Signed-off-by: K. Y. Srinivasan <kys@microsoft.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-08-06Input: hyperv-keyboard - register as a wakeup sourceDexuan Cui1-0/+13
With this patch, we can press a key to wake up the VM after the VM executes "echo freeze > /sys/power/state". Signed-off-by: Dexuan Cui <decui@microsoft.com> Signed-off-by: K. Y. Srinivasan <kys@microsoft.com> Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
2014-01-12Input: hyperv-keyboard - pass through 0xE1 prefixK. Y. Srinivasan1-1/+3
Pass through the 0xE1 prefix so atkbd can properly parse the scancode data. Signed-off-by: K. Y. Srinivasan <kys@microsoft.com> Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
2013-09-19Input: add a driver to support Hyper-V synthetic keyboardK. Y. Srinivasan1-0/+437
Add a new driver to support synthetic keyboard. On the next generation Hyper-V guest firmware, many legacy devices will not be emulated and this driver will be required. I would like to thank Vojtech Pavlik <vojtech@suse.cz> for helping me with the details of the AT keyboard driver. I would also like to thank Dan Carpenter <dan.carpenter@oracle.com> and Dmitry Torokhov <dmitry.torokhov@gmail.com> for their detailed review of this driver. Signed-off-by: K. Y. Srinivasan <kys@microsoft.com> Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>