summaryrefslogtreecommitdiffstats
path: root/drivers/usb/host
diff options
context:
space:
mode:
authorMichael Hennerich <michael.hennerich@analog.com>2009-12-21 12:53:24 -0500
committerGreg Kroah-Hartman <gregkh@suse.de>2010-03-02 14:53:26 -0800
commit8ca5bfab154487fd75a946e6e95d3519eb74be6a (patch)
treef2bb7bb04734e1742f78bc682beb8f8a3bd790b5 /drivers/usb/host
parent6ebb7d1b4b98162e332ff43a8739c2c1c690b140 (diff)
downloadop-kernel-dev-8ca5bfab154487fd75a946e6e95d3519eb74be6a.zip
op-kernel-dev-8ca5bfab154487fd75a946e6e95d3519eb74be6a.tar.gz
USB: host: SL811: fix unaligned accesses
Signed-off-by: Michael Hennerich <michael.hennerich@analog.com> Signed-off-by: Bryan Wu <cooloney@kernel.org> Signed-off-by: Mike Frysinger <vapier@gentoo.org> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Diffstat (limited to 'drivers/usb/host')
-rw-r--r--drivers/usb/host/sl811-hcd.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/drivers/usb/host/sl811-hcd.c b/drivers/usb/host/sl811-hcd.c
index 5b22a4d..e11cc3a 100644
--- a/drivers/usb/host/sl811-hcd.c
+++ b/drivers/usb/host/sl811-hcd.c
@@ -51,6 +51,7 @@
#include <asm/irq.h>
#include <asm/system.h>
#include <asm/byteorder.h>
+#include <asm/unaligned.h>
#include "../core/hcd.h"
#include "sl811.h"
@@ -1272,12 +1273,12 @@ sl811h_hub_control(
sl811h_hub_descriptor(sl811, (struct usb_hub_descriptor *) buf);
break;
case GetHubStatus:
- *(__le32 *) buf = cpu_to_le32(0);
+ put_unaligned_le32(0, buf);
break;
case GetPortStatus:
if (wIndex != 1)
goto error;
- *(__le32 *) buf = cpu_to_le32(sl811->port1);
+ put_unaligned_le32(sl811->port1, buf);
#ifndef VERBOSE
if (*(u16*)(buf+2)) /* only if wPortChange is interesting */
OpenPOWER on IntegriCloud