ChangeSet 1.1500.8.2, 2004/01/29 16:04:08-08:00, akpm@osdl.org

[PATCH] USB: gcc-3.5: drivers/usb/input/hid-core.c

drivers/usb/input/hid-core.c: In function `fetch_item':
drivers/usb/input/hid-core.c:605: error: invalid lvalue in increment
drivers/usb/input/hid-core.c:612: error: invalid lvalue in increment


 drivers/usb/input/hid-core.c |    6 ++++--
 1 files changed, 4 insertions(+), 2 deletions(-)


diff -Nru a/drivers/usb/input/hid-core.c b/drivers/usb/input/hid-core.c
--- a/drivers/usb/input/hid-core.c	Mon Feb  9 14:42:58 2004
+++ b/drivers/usb/input/hid-core.c	Mon Feb  9 14:42:58 2004
@@ -602,14 +602,16 @@
 		case 2:
 			if ((end - start) < 2) 
 				return NULL;
-			item->data.u16 = le16_to_cpu(get_unaligned(((__u16*)start)++));
+			item->data.u16 = le16_to_cpu(get_unaligned((__u16*)start));
+			start = (__u8 *)((__u16 *)start + 1);
 			return start;
 
 		case 3:
 			item->size++;
 			if ((end - start) < 4)
 				return NULL;
-			item->data.u32 = le32_to_cpu(get_unaligned(((__u32*)start)++));
+			item->data.u32 = le32_to_cpu(get_unaligned((__u32*)start));
+			start = (__u8 *)((__u32 *)start + 1);
 			return start;
 	}
 
