lkml.org 
[lkml]   [2006]   [Jan]   [12]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
    /
    Date
    From
    SubjectRe: need for packed attribute
    On Fri, Jan 06, 2006 at 06:38:46PM +0000, Russell King wrote:
    > > /* All standard descriptors have these 2 fields at the beginning */
    > > struct usb_descriptor_header {
    > > __u8 bLength;
    > > __u8 bDescriptorType;
    > > };
    >
    > sizeof(struct usb_descriptor_header) will be 4 on ARM. If this
    > concerns you, you need to pack the structure thusly:

    Interesting. Perhaps we should add -Wpadded to CFLAGS in order to remind
    people, although that might take a fair bit of work to clean up existing
    structure definitions.

    -ben
    --
    "You know, I've seen some crystals do some pretty trippy shit, man."
    Don't Email: <dont@kvack.org>.
    -
    To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
    the body of a message to majordomo@vger.kernel.org
    More majordomo info at http://vger.kernel.org/majordomo-info.html
    Please read the FAQ at http://www.tux.org/lkml/

    \
     
     \ /
      Last update: 2006-01-12 19:38    [W:0.019 / U:1.320 seconds]
    ©2003-2016 Jasper Spaans. hosted at Digital OceanAdvertise on this site