aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJohan Hovold <jhovold@gmail.com>2013-08-11 10:49:20 -0400
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2013-08-12 16:52:35 -0400
commitd551ec9b690f3de65b0091a2e767f1382adc792d (patch)
tree7e5ea67cdcfec07feea1a46dc732788a3beaa4e5
parent6c1ee66a0b2bdbd64c078fba684d640cf2fd38a9 (diff)
USB: mos7840: fix big-endian probe
Fix bug in device-type detection on big-endian machines originally introduced by commit 0eafe4de ("USB: serial: mos7840: add support for MCS7810 devices") which always matched on little-endian product ids. Reported-by: kbuild test robot <fengguang.wu@intel.com> Cc: stable@vger.kernel.org Signed-off-by: Johan Hovold <jhovold@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
-rw-r--r--drivers/usb/serial/mos7840.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/usb/serial/mos7840.c b/drivers/usb/serial/mos7840.c
index d953d674f222..3bac4693c038 100644
--- a/drivers/usb/serial/mos7840.c
+++ b/drivers/usb/serial/mos7840.c
@@ -2193,7 +2193,7 @@ static int mos7810_check(struct usb_serial *serial)
2193static int mos7840_probe(struct usb_serial *serial, 2193static int mos7840_probe(struct usb_serial *serial,
2194 const struct usb_device_id *id) 2194 const struct usb_device_id *id)
2195{ 2195{
2196 u16 product = serial->dev->descriptor.idProduct; 2196 u16 product = le16_to_cpu(serial->dev->descriptor.idProduct);
2197 u8 *buf; 2197 u8 *buf;
2198 int device_type; 2198 int device_type;
2199 2199