From: Antonio Ospite Date: Tue, 24 Jun 2014 11:28:40 +0000 (+0200) Subject: HID: sony: Use the SIXAXIS_CONTROLLER constant when possible X-Git-Tag: firefly_0821_release~176^2~3465^2^8~4 X-Git-Url: http://demsky.eecs.uci.edu/git/?a=commitdiff_plain;h=50764650c9e6e8498d273ad714f68ee8eec96692;p=firefly-linux-kernel-4.4.55.git HID: sony: Use the SIXAXIS_CONTROLLER constant when possible Instead of checking for SIXAXIS_CONTROLLER_USB and SIXAXIS_CONTROLLER_BT separately, a check on SIXAXIS_CONTROLLER can be used when setting connect_mask. Signed-off-by: Antonio Ospite Signed-off-by: Jiri Kosina --- diff --git a/drivers/hid/hid-sony.c b/drivers/hid/hid-sony.c index 2259eaa8b988..a77269b06880 100644 --- a/drivers/hid/hid-sony.c +++ b/drivers/hid/hid-sony.c @@ -1830,9 +1830,7 @@ static int sony_probe(struct hid_device *hdev, const struct hid_device_id *id) if (sc->quirks & VAIO_RDESC_CONSTANT) connect_mask |= HID_CONNECT_HIDDEV_FORCE; - else if (sc->quirks & SIXAXIS_CONTROLLER_USB) - connect_mask |= HID_CONNECT_HIDDEV_FORCE; - else if (sc->quirks & SIXAXIS_CONTROLLER_BT) + else if (sc->quirks & SIXAXIS_CONTROLLER) connect_mask |= HID_CONNECT_HIDDEV_FORCE; ret = hid_hw_start(hdev, connect_mask);