Skip to content

Commit

Permalink
Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel…
Browse files Browse the repository at this point in the history
…/git/dtor/input

Pull input updates from Dmitry Torokhov:

 - new driver for PhoenixRC Flight Controller Adapter

 - new driver for RAVE SP Power button

 - fixes for autosuspend-related deadlocks in a few unput USB dirvers

 - support for 2nd wheel in ATech PS/2 mouse

 - fix for ALPS trackpoint detection on Thinkpad L570 and Latitude 7370

 - bunch of cleanups in various in PS/2 protocols

 - other assorted changes and fixes

* 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/dtor/input: (35 commits)
  Input: i8042 - enable MUX on Sony VAIO VGN-CS series to fix touchpad
  Input: stmfts, s6sy761 - update my e-mail
  Input: stmfts - use async probe & suspend/resume to avoid 2s delay
  Input: ALPS - fix TrackStick detection on Thinkpad L570 and Latitude 7370
  Input: xpad - add PDP device id 0x02a4
  Input: alps - report pressure of v3 and v7 trackstick
  Input: pxrc - new driver for PhoenixRC Flight Controller Adapter
  Input: usbtouchscreen - do not rely on input_dev->users
  Input: usbtouchscreen - fix deadlock in autosuspend
  Input: pegasus_notetaker - do not rely on input_dev->users
  Input: pagasus_notetaker - fix deadlock in autosuspend
  Input: synaptics_usb - do not rely on input_dev->users
  Input: synaptics_usb - fix deadlock in autosuspend
  Input: gpio-keys - add support for wakeup event action
  Input: appletouch - use true and false for boolean values
  Input: silead - add Chuwi Hi8 support
  Input: analog - use get_cycles() on PPC
  Input: stmpe-keypad - remove VLA usage
  Input: i8042 - add Lenovo ThinkPad L460 to i8042 reset list
  Input: add RAVE SP Powerbutton driver
  ...
  • Loading branch information
Linus Torvalds committed Apr 5, 2018
2 parents 672a9c1 + 664b0ba commit 5414ab3
Show file tree
Hide file tree
Showing 34 changed files with 1,358 additions and 491 deletions.
8 changes: 8 additions & 0 deletions Documentation/devicetree/bindings/input/gpio-keys.txt
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,14 @@ Optional subnode-properties:
If not specified defaults to 5.
- wakeup-source: Boolean, button can wake-up the system.
(Legacy property supported: "gpio-key,wakeup")
- wakeup-event-action: Specifies whether the key should wake the
system when asserted, when deasserted, or both. This property is
only valid for keys that wake up the system (e.g., when the
"wakeup-source" property is also provided).
Supported values are defined in linux-event-codes.h:
EV_ACT_ASSERTED - asserted
EV_ACT_DEASSERTED - deasserted
EV_ACT_ANY - both asserted and deasserted
- linux,can-disable: Boolean, indicates that button is connected
to dedicated (not shared) interrupt which can be disabled to
suppress events from the button.
Expand Down
22 changes: 22 additions & 0 deletions Documentation/devicetree/bindings/input/zii,rave-sp-pwrbutton.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
Zodiac Inflight Innovations RAVE Supervisory Processor Power Button Bindings

RAVE SP input device is a "MFD cell" device corresponding to power
button functionality of RAVE Supervisory Processor. It is expected
that its Device Tree node is specified as a child of the node
corresponding to the parent RAVE SP device (as documented in
Documentation/devicetree/bindings/mfd/zii,rave-sp.txt)

Required properties:

- compatible: Should be "zii,rave-sp-pwrbutton"

Example:

rave-sp {
compatible = "zii,rave-sp-rdu1";
current-speed = <38400>;

pwrbutton {
compatible = "zii,rave-sp-pwrbutton";
};
}
57 changes: 57 additions & 0 deletions Documentation/input/devices/pxrc.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1,57 @@
=======================================================
pxrc - PhoenixRC Flight Controller Adapter
=======================================================

:Author: Marcus Folkesson <marcus.folkesson@gmail.com>

This driver let you use your own RC controller plugged into the
adapter that comes with PhoenixRC [1]_ or other compatible adapters.

The adapter supports 7 analog channels and 1 digital input switch.

Notes
=====

Many RC controllers is able to configure which stick goes to which channel.
This is also configurable in most simulators, so a matching is not necessary.

The driver is generating the following input event for analog channels:

+---------+----------------+
| Channel | Event |
+=========+================+
| 1 | ABS_X |
+---------+----------------+
| 2 | ABS_Y |
+---------+----------------+
| 3 | ABS_RX |
+---------+----------------+
| 4 | ABS_RY |
+---------+----------------+
| 5 | ABS_RUDDER |
+---------+----------------+
| 6 | ABS_THROTTLE |
+---------+----------------+
| 7 | ABS_MISC |
+---------+----------------+

The digital input switch is generated as an `BTN_A` event.

Manual Testing
==============

To test this driver's functionality you may use `input-event` which is part of
the `input layer utilities` suite [2]_.

For example::

> modprobe pxrc
> input-events <devnr>

To print all input events from input `devnr`.

References
==========

.. [1] http://www.phoenix-sim.com/
.. [2] https://www.kraxel.org/cgit/input/
10 changes: 10 additions & 0 deletions drivers/input/joystick/Kconfig
Original file line number Diff line number Diff line change
Expand Up @@ -351,4 +351,14 @@ config JOYSTICK_PSXPAD_SPI_FF

To drive rumble motor a dedicated power supply is required.

config JOYSTICK_PXRC
tristate "PhoenixRC Flight Controller Adapter"
depends on USB_ARCH_HAS_HCD
select USB
help
Say Y here if you want to use the PhoenixRC Flight Controller Adapter.

To compile this driver as a module, choose M here: the
module will be called pxrc.

endif
1 change: 1 addition & 0 deletions drivers/input/joystick/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,7 @@ obj-$(CONFIG_JOYSTICK_JOYDUMP) += joydump.o
obj-$(CONFIG_JOYSTICK_MAGELLAN) += magellan.o
obj-$(CONFIG_JOYSTICK_MAPLE) += maplecontrol.o
obj-$(CONFIG_JOYSTICK_PSXPAD_SPI) += psxpad-spi.o
obj-$(CONFIG_JOYSTICK_PXRC) += pxrc.o
obj-$(CONFIG_JOYSTICK_SIDEWINDER) += sidewinder.o
obj-$(CONFIG_JOYSTICK_SPACEBALL) += spaceball.o
obj-$(CONFIG_JOYSTICK_SPACEORB) += spaceorb.o
Expand Down
2 changes: 1 addition & 1 deletion drivers/input/joystick/analog.c
Original file line number Diff line number Diff line change
Expand Up @@ -163,7 +163,7 @@ static unsigned int get_time_pit(void)
#define GET_TIME(x) do { x = (unsigned int)rdtsc(); } while (0)
#define DELTA(x,y) ((y)-(x))
#define TIME_NAME "TSC"
#elif defined(__alpha__) || defined(CONFIG_ARM) || defined(CONFIG_ARM64) || defined(CONFIG_RISCV)
#elif defined(__alpha__) || defined(CONFIG_ARM) || defined(CONFIG_ARM64) || defined(CONFIG_PPC) || defined(CONFIG_RISCV)
#define GET_TIME(x) do { x = get_cycles(); } while (0)
#define DELTA(x,y) ((y)-(x))
#define TIME_NAME "get_cycles"
Expand Down
Loading

0 comments on commit 5414ab3

Please sign in to comment.