Marcus Folkesson ff0d2cba64 Input: synaptics_usb - do not rely on input_dev->users
If the device is unused and suspended, a call to open will cause the
device to autoresume through the call to usb_autopm_get_interface().

input_dev->users is already incremented by the input subsystem,
therefore this expression will always be evaluated to true:

	if ((input_dev->users || (synusb->flags & SYNUSB_IO_ALWAYS)) &&
	    usb_submit_urb(synusb->urb, GFP_NOIO) < 0) {
		retval = -EIO;
	}

The same URB will then be fail when resubmitted in synusb_open().

Introduce synusb->is_open to keep track of the state instead.

Signed-off-by: Marcus Folkesson <marcus.folkesson@gmail.com>
Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
2018-03-17 11:05:18 -07:00
..
2018-02-06 09:59:40 -08:00
2018-02-15 14:50:32 -08:00
2018-03-01 08:41:27 -07:00
2018-02-07 11:22:44 -08:00
2018-03-02 10:44:44 +01:00
2018-02-02 10:01:04 -08:00
2018-02-26 09:28:35 -08:00
2018-03-02 09:35:36 -08:00
2018-02-24 16:05:50 -08:00
2018-02-01 10:31:17 -08:00
2018-03-02 10:19:57 -08:00
2018-03-02 17:44:39 -08:00
2018-02-20 11:34:54 +00:00
2018-02-01 09:40:49 -08:00
2018-01-30 12:25:59 +00:00
2018-02-05 10:07:40 -08:00
2018-02-15 14:29:27 -08:00
2018-02-06 09:59:40 -08:00
2018-02-23 14:09:43 -08:00
2018-02-28 16:11:04 -08:00
2018-01-22 16:45:26 +01:00
2018-02-22 12:05:43 -08:00
2018-02-22 12:13:01 -08:00
2018-03-02 10:19:57 -08:00
2018-02-01 10:31:17 -08:00
2018-02-06 09:59:40 -08:00