[U-Boot] [PATCH 3/4] USB: Fix anti-aliasing complaints in OHCI-HCD

Mike Frysinger vapier at gentoo.org
Sat Aug 20 20:07:49 CEST 2011


On Saturday, August 20, 2011 09:28:43 Marek Vasut wrote:
> -	__u32 datab[4];
> +	__u8 datab[16] __attribute__((aligned(4)));
>  	__u8 *data_buf = (__u8 *)datab;

leverage a union to avoid attributes:
union {
	__u32 u32[4];
	__u8 u8[16];
} datab;
__u8 *data_buf = datab.u8;

also, it isn't "anti-aliasing complaints", it's "fix strict aliasing 
violations".  "anti-aliasing" is something completely different in the 
computing world :p.
-mike
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 836 bytes
Desc: This is a digitally signed message part.
Url : http://lists.denx.de/pipermail/u-boot/attachments/20110820/46c7a751/attachment.pgp 


More information about the U-Boot mailing list