diff options
author | Ian Campbell <icampbell@arcom.com> | 2005-10-28 10:26:42 -0400 |
---|---|---|
committer | Russell King <rmk+kernel@arm.linux.org.uk> | 2005-10-28 10:26:42 -0400 |
commit | 63a4b52c9ddca944afc1b78aacbf641c650780d7 (patch) | |
tree | bc782e17f3f13de7fd6a7543c9806eaeec692f8f /drivers/usb/gadget | |
parent | a0e0adb96ebe6bf0b8b3fe4cd6c214b1e8964609 (diff) |
[ARM] 3044/1: Fix sparse warnings about incompatible pointer types for register defined in pxa-regs.h
Patch from Ian Campbell
The sparse warning initially surfaced in sound/arm/pxa2xx-ac97.c
because it was using u32 * variables to hold the unsigned long *
register addresses.
I submitted an ALSA patch for this http://thread.gmane.org/gmane.linux.alsa.devel/27804 issue and it was suggested that it might be preferable to change the register
definitions to use u32.
Most other subarches seem to use u32 for their register type, at least
the ones which use a __REG macro (like the PXA) do. Nico indicated in
the thread above that he wouldn't mind this patch.
Changing the type required fixes for opposite warnings in the pxa2xx usb
gadget code but that was the only new warning introduced on defconfig
or lubbock, mainstone and our own PXA255 boards.
Signed-off-by: Ian Campbell <icampbell@arcom.com>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
Diffstat (limited to 'drivers/usb/gadget')
-rw-r--r-- | drivers/usb/gadget/pxa2xx_udc.c | 2 | ||||
-rw-r--r-- | drivers/usb/gadget/pxa2xx_udc.h | 8 |
2 files changed, 5 insertions, 5 deletions
diff --git a/drivers/usb/gadget/pxa2xx_udc.c b/drivers/usb/gadget/pxa2xx_udc.c index 73f8c9404156..feae7c0c5dd9 100644 --- a/drivers/usb/gadget/pxa2xx_udc.c +++ b/drivers/usb/gadget/pxa2xx_udc.c | |||
@@ -422,7 +422,7 @@ static inline void ep0_idle (struct pxa2xx_udc *dev) | |||
422 | } | 422 | } |
423 | 423 | ||
424 | static int | 424 | static int |
425 | write_packet(volatile unsigned long *uddr, struct pxa2xx_request *req, unsigned max) | 425 | write_packet(volatile u32 *uddr, struct pxa2xx_request *req, unsigned max) |
426 | { | 426 | { |
427 | u8 *buf; | 427 | u8 *buf; |
428 | unsigned length, count; | 428 | unsigned length, count; |
diff --git a/drivers/usb/gadget/pxa2xx_udc.h b/drivers/usb/gadget/pxa2xx_udc.h index a58f3e6e71f1..19a883f7d1b8 100644 --- a/drivers/usb/gadget/pxa2xx_udc.h +++ b/drivers/usb/gadget/pxa2xx_udc.h | |||
@@ -69,11 +69,11 @@ struct pxa2xx_ep { | |||
69 | * UDDR = UDC Endpoint Data Register (the fifo) | 69 | * UDDR = UDC Endpoint Data Register (the fifo) |
70 | * DRCM = DMA Request Channel Map | 70 | * DRCM = DMA Request Channel Map |
71 | */ | 71 | */ |
72 | volatile unsigned long *reg_udccs; | 72 | volatile u32 *reg_udccs; |
73 | volatile unsigned long *reg_ubcr; | 73 | volatile u32 *reg_ubcr; |
74 | volatile unsigned long *reg_uddr; | 74 | volatile u32 *reg_uddr; |
75 | #ifdef USE_DMA | 75 | #ifdef USE_DMA |
76 | volatile unsigned long *reg_drcmr; | 76 | volatile u32 *reg_drcmr; |
77 | #define drcmr(n) .reg_drcmr = & DRCMR ## n , | 77 | #define drcmr(n) .reg_drcmr = & DRCMR ## n , |
78 | #else | 78 | #else |
79 | #define drcmr(n) | 79 | #define drcmr(n) |