Loading Documentation/devicetree/bindings/input/rotary-encoder.txt +4 −0 Original line number Diff line number Diff line Loading @@ -20,6 +20,8 @@ Optional properties: 2: Half-period mode 4: Quarter-period mode - wakeup-source: Boolean, rotary encoder can wake up the system. - rotary-encoder,encoding: String, the method used to encode steps. Supported are "gray" (the default and more common) and "binary". Deprecated properties: - rotary-encoder,half-period: Makes the driver work on half-period mode. Loading @@ -34,6 +36,7 @@ Example: compatible = "rotary-encoder"; gpios = <&gpio 19 1>, <&gpio 20 0>; /* GPIO19 is inverted */ linux,axis = <0>; /* REL_X */ rotary-encoder,encoding = "gray"; rotary-encoder,relative-axis; }; Loading @@ -42,5 +45,6 @@ Example: gpios = <&gpio 21 0>, <&gpio 22 0>; linux,axis = <1>; /* ABS_Y */ rotary-encoder,steps = <24>; rotary-encoder,encoding = "binary"; rotary-encoder,rollover; }; Documentation/devicetree/bindings/input/touchscreen/silead_gsl1680.txt 0 → 100644 +36 −0 Original line number Diff line number Diff line * GSL 1680 touchscreen controller Required properties: - compatible : "silead,gsl1680" - reg : I2C slave address of the chip (0x40) - interrupt-parent : a phandle pointing to the interrupt controller serving the interrupt for this chip - interrupts : interrupt specification for the gsl1680 interrupt - power-gpios : Specification for the pin connected to the gsl1680's shutdown input. This needs to be driven high to take the gsl1680 out of its low power state - touchscreen-size-x : See touchscreen.txt - touchscreen-size-y : See touchscreen.txt Optional properties: - touchscreen-inverted-x : See touchscreen.txt - touchscreen-inverted-y : See touchscreen.txt - touchscreen-swapped-x-y : See touchscreen.txt - silead,max-fingers : maximum number of fingers the touchscreen can detect Example: i2c@00000000 { gsl1680: touchscreen@40 { compatible = "silead,gsl1680"; reg = <0x40>; interrupt-parent = <&pio>; interrupts = <6 11 IRQ_TYPE_EDGE_FALLING>; power-gpios = <&pio 1 3 GPIO_ACTIVE_HIGH>; touchscreen-size-x = <480>; touchscreen-size-y = <800>; touchscreen-inverted-x; touchscreen-swapped-x-y; silead,max-fingers = <5>; }; }; Documentation/devicetree/bindings/input/touchscreen/sis_i2c.txt 0 → 100644 +33 −0 Original line number Diff line number Diff line * SiS I2C Multiple Touch Controller Required properties: - compatible: must be "sis,9200-ts" - reg: i2c slave address - interrupt-parent: the phandle for the interrupt controller (see interrupt binding [0]) - interrupts: touch controller interrupt (see interrupt binding [0]) Optional properties: - pinctrl-names: should be "default" (see pinctrl binding [1]). - pinctrl-0: a phandle pointing to the pin settings for the device (see pinctrl binding [1]). - attn-gpios: the gpio pin used as attention line - reset-gpios: the gpio pin used to reset the controller - wakeup-source: touchscreen can be used as a wakeup source [0]: Documentation/devicetree/bindings/interrupt-controller/interrupts.txt [1]: Documentation/devicetree/bindings/pinctrl/pinctrl-bindings.txt Example: sis9255@5c { compatible = "sis,9200-ts"; reg = <0x5c>; pinctrl-names = "default"; pinctrl-0 = <&pinctrl_sis>; interrupt-parent = <&gpio3>; interrupts = <19 IRQ_TYPE_EDGE_FALLING>; irq-gpios = <&gpio3 19 GPIO_ACTIVE_LOW>; reset-gpios = <&gpio2 30 GPIO_ACTIVE_LOW>; }; Documentation/devicetree/bindings/vendor-prefixes.txt +1 −0 Original line number Diff line number Diff line Loading @@ -221,6 +221,7 @@ simtek sii Seiko Instruments, Inc. silergy Silergy Corp. sirf SiRF Technology, Inc. sis Silicon Integrated Systems Corp. sitronix Sitronix Technology Corporation skyworks Skyworks Solutions, Inc. smsc Standard Microsystems Corporation Loading drivers/input/joystick/xpad.c +43 −0 Original line number Diff line number Diff line Loading @@ -115,6 +115,10 @@ static bool sticks_to_null; module_param(sticks_to_null, bool, S_IRUGO); MODULE_PARM_DESC(sticks_to_null, "Do not map sticks at all for unknown pads"); static bool auto_poweroff = true; module_param(auto_poweroff, bool, S_IWUSR | S_IRUGO); MODULE_PARM_DESC(auto_poweroff, "Power off wireless controllers on suspend"); static const struct xpad_device { u16 idVendor; u16 idProduct; Loading Loading @@ -1248,6 +1252,36 @@ static void xpad_stop_input(struct usb_xpad *xpad) usb_kill_urb(xpad->irq_in); } static void xpad360w_poweroff_controller(struct usb_xpad *xpad) { unsigned long flags; struct xpad_output_packet *packet = &xpad->out_packets[XPAD_OUT_CMD_IDX]; spin_lock_irqsave(&xpad->odata_lock, flags); packet->data[0] = 0x00; packet->data[1] = 0x00; packet->data[2] = 0x08; packet->data[3] = 0xC0; packet->data[4] = 0x00; packet->data[5] = 0x00; packet->data[6] = 0x00; packet->data[7] = 0x00; packet->data[8] = 0x00; packet->data[9] = 0x00; packet->data[10] = 0x00; packet->data[11] = 0x00; packet->len = 12; packet->pending = true; /* Reset the sequence so we send out poweroff now */ xpad->last_out_packet = -1; xpad_try_sending_next_out_packet(xpad); spin_unlock_irqrestore(&xpad->odata_lock, flags); } static int xpad360w_start_input(struct usb_xpad *xpad) { int error; Loading Loading @@ -1590,6 +1624,15 @@ static int xpad_suspend(struct usb_interface *intf, pm_message_t message) * or goes away. */ xpad360w_stop_input(xpad); /* * The wireless adapter is going off now, so the * gamepads are going to become disconnected. * Unless explicitly disabled, power them down * so they don't just sit there flashing. */ if (auto_poweroff && xpad->pad_present) xpad360w_poweroff_controller(xpad); } else { mutex_lock(&input->mutex); if (input->users) Loading Loading
Documentation/devicetree/bindings/input/rotary-encoder.txt +4 −0 Original line number Diff line number Diff line Loading @@ -20,6 +20,8 @@ Optional properties: 2: Half-period mode 4: Quarter-period mode - wakeup-source: Boolean, rotary encoder can wake up the system. - rotary-encoder,encoding: String, the method used to encode steps. Supported are "gray" (the default and more common) and "binary". Deprecated properties: - rotary-encoder,half-period: Makes the driver work on half-period mode. Loading @@ -34,6 +36,7 @@ Example: compatible = "rotary-encoder"; gpios = <&gpio 19 1>, <&gpio 20 0>; /* GPIO19 is inverted */ linux,axis = <0>; /* REL_X */ rotary-encoder,encoding = "gray"; rotary-encoder,relative-axis; }; Loading @@ -42,5 +45,6 @@ Example: gpios = <&gpio 21 0>, <&gpio 22 0>; linux,axis = <1>; /* ABS_Y */ rotary-encoder,steps = <24>; rotary-encoder,encoding = "binary"; rotary-encoder,rollover; };
Documentation/devicetree/bindings/input/touchscreen/silead_gsl1680.txt 0 → 100644 +36 −0 Original line number Diff line number Diff line * GSL 1680 touchscreen controller Required properties: - compatible : "silead,gsl1680" - reg : I2C slave address of the chip (0x40) - interrupt-parent : a phandle pointing to the interrupt controller serving the interrupt for this chip - interrupts : interrupt specification for the gsl1680 interrupt - power-gpios : Specification for the pin connected to the gsl1680's shutdown input. This needs to be driven high to take the gsl1680 out of its low power state - touchscreen-size-x : See touchscreen.txt - touchscreen-size-y : See touchscreen.txt Optional properties: - touchscreen-inverted-x : See touchscreen.txt - touchscreen-inverted-y : See touchscreen.txt - touchscreen-swapped-x-y : See touchscreen.txt - silead,max-fingers : maximum number of fingers the touchscreen can detect Example: i2c@00000000 { gsl1680: touchscreen@40 { compatible = "silead,gsl1680"; reg = <0x40>; interrupt-parent = <&pio>; interrupts = <6 11 IRQ_TYPE_EDGE_FALLING>; power-gpios = <&pio 1 3 GPIO_ACTIVE_HIGH>; touchscreen-size-x = <480>; touchscreen-size-y = <800>; touchscreen-inverted-x; touchscreen-swapped-x-y; silead,max-fingers = <5>; }; };
Documentation/devicetree/bindings/input/touchscreen/sis_i2c.txt 0 → 100644 +33 −0 Original line number Diff line number Diff line * SiS I2C Multiple Touch Controller Required properties: - compatible: must be "sis,9200-ts" - reg: i2c slave address - interrupt-parent: the phandle for the interrupt controller (see interrupt binding [0]) - interrupts: touch controller interrupt (see interrupt binding [0]) Optional properties: - pinctrl-names: should be "default" (see pinctrl binding [1]). - pinctrl-0: a phandle pointing to the pin settings for the device (see pinctrl binding [1]). - attn-gpios: the gpio pin used as attention line - reset-gpios: the gpio pin used to reset the controller - wakeup-source: touchscreen can be used as a wakeup source [0]: Documentation/devicetree/bindings/interrupt-controller/interrupts.txt [1]: Documentation/devicetree/bindings/pinctrl/pinctrl-bindings.txt Example: sis9255@5c { compatible = "sis,9200-ts"; reg = <0x5c>; pinctrl-names = "default"; pinctrl-0 = <&pinctrl_sis>; interrupt-parent = <&gpio3>; interrupts = <19 IRQ_TYPE_EDGE_FALLING>; irq-gpios = <&gpio3 19 GPIO_ACTIVE_LOW>; reset-gpios = <&gpio2 30 GPIO_ACTIVE_LOW>; };
Documentation/devicetree/bindings/vendor-prefixes.txt +1 −0 Original line number Diff line number Diff line Loading @@ -221,6 +221,7 @@ simtek sii Seiko Instruments, Inc. silergy Silergy Corp. sirf SiRF Technology, Inc. sis Silicon Integrated Systems Corp. sitronix Sitronix Technology Corporation skyworks Skyworks Solutions, Inc. smsc Standard Microsystems Corporation Loading
drivers/input/joystick/xpad.c +43 −0 Original line number Diff line number Diff line Loading @@ -115,6 +115,10 @@ static bool sticks_to_null; module_param(sticks_to_null, bool, S_IRUGO); MODULE_PARM_DESC(sticks_to_null, "Do not map sticks at all for unknown pads"); static bool auto_poweroff = true; module_param(auto_poweroff, bool, S_IWUSR | S_IRUGO); MODULE_PARM_DESC(auto_poweroff, "Power off wireless controllers on suspend"); static const struct xpad_device { u16 idVendor; u16 idProduct; Loading Loading @@ -1248,6 +1252,36 @@ static void xpad_stop_input(struct usb_xpad *xpad) usb_kill_urb(xpad->irq_in); } static void xpad360w_poweroff_controller(struct usb_xpad *xpad) { unsigned long flags; struct xpad_output_packet *packet = &xpad->out_packets[XPAD_OUT_CMD_IDX]; spin_lock_irqsave(&xpad->odata_lock, flags); packet->data[0] = 0x00; packet->data[1] = 0x00; packet->data[2] = 0x08; packet->data[3] = 0xC0; packet->data[4] = 0x00; packet->data[5] = 0x00; packet->data[6] = 0x00; packet->data[7] = 0x00; packet->data[8] = 0x00; packet->data[9] = 0x00; packet->data[10] = 0x00; packet->data[11] = 0x00; packet->len = 12; packet->pending = true; /* Reset the sequence so we send out poweroff now */ xpad->last_out_packet = -1; xpad_try_sending_next_out_packet(xpad); spin_unlock_irqrestore(&xpad->odata_lock, flags); } static int xpad360w_start_input(struct usb_xpad *xpad) { int error; Loading Loading @@ -1590,6 +1624,15 @@ static int xpad_suspend(struct usb_interface *intf, pm_message_t message) * or goes away. */ xpad360w_stop_input(xpad); /* * The wireless adapter is going off now, so the * gamepads are going to become disconnected. * Unless explicitly disabled, power them down * so they don't just sit there flashing. */ if (auto_poweroff && xpad->pad_present) xpad360w_poweroff_controller(xpad); } else { mutex_lock(&input->mutex); if (input->users) Loading