[U-Boot] [PATCH v4] USB: Add align(4) in __attribute__ ((packed)) for struct ehci_hccr and ehci_hcor

Wolfgang Denk wd at denx.de
Fri Aug 26 13:50:57 CEST 2011


Dear Joel A Fernandes,

In message <1313097765-3206-1-git-send-email-agnel.joel at gmail.com> you wrote:
> From: Jason Kridner <jkridner at beagleboard.org>
> 
> Switched to align(4) to prevent byte access to soc registers in some gcc versions.
...
> -} __attribute__ ((packed));
> +} __attribute__ ((packed, aligned(4)));

Can we not rather get rid of this "packed" attribute alltogether?

I know there has been a long discussion around this on lak and lkml,
see for example here:

http://thread.gmane.org/gmane.linux.kernel/1132033/focus=120777

And like for example Arnd I feel that this patch is not a cleanup.

Best regards,

Wolfgang Denk

-- 
DENX Software Engineering GmbH,     MD: Wolfgang Denk & Detlev Zundel
HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany
Phone: (+49)-8142-66989-10 Fax: (+49)-8142-66989-80 Email: wd at denx.de
It is easier to change the specification to fit the program than vice
versa.


More information about the U-Boot mailing list