Thread (64 messages) flat view 64 messages, 7 authors, 2011-06-29

[PATCH] USB: ehci: use packed, aligned(4) instead of removing the packed attribute

From: nico@fluxnic.net (Nicolas Pitre)
Date: 2011-06-20 21:03:20
Also in: lkml

On Mon, 20 Jun 2011, Arnd Bergmann wrote:
On Monday 20 June 2011 22:28:49 Nicolas Pitre wrote:
quoted
On Mon, 20 Jun 2011, Arnd Bergmann wrote:
quoted
On Monday 20 June 2011 19:39:34 Alexander Holler wrote:
quoted
That packed without an additional aligned() caused errors on ARM with 
gcc 4.6 is another problem which got (currently) fixed by removing packed.
Packed caused errors because it is *wrong*. The code as it was used undefined
behavior in the language.
I wouldn't call this issue as such, but this is a Red herring.

Could you please provide a pointer to the structure definition so a 
second opinion to the usefulness of __packed there could be provided?  
The structures in question are ehci_caps, ehci_regs and ehci_dbg_port.
OK.  If anyone was still entertaining any doubts, those structures do 
not require any packed attribute what so ever.
The patch that remove the __packed attribute was 139540170 "USB: ehci:
remove structure packing from ehci_def".
Too late for this, but for the record:

Reviewed-by: Nicolas Pitre <redacted>

Hopefully this thread still gathered enough wisdom about proper usage of 
the packed and aligned attributes into the list archive.


Nicolas
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help