lkml.org 
[lkml]   [2004]   [Jun]   [26]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: drivers/block/ub.c
On Sat, 26 Jun 2004 22:35:15 +0200
Oliver Neukum <oliver@neukum.org> wrote:

>
> > +/* command block wrapper */
> > +struct bulk_cb_wrap {
> > + u32 Signature; /* contains 'USBC' */
> > + u32 Tag; /* unique per command id */
> > + u32 DataTransferLength; /* size of data */
> > + u8 Flags; /* direction in bit 0 */
> > + u8 Lun; /* LUN normally 0 */
> > + u8 Length; /* of of the CDB */
> > + u8 CDB[MAX_CDB_SIZE]; /* max command */
> > +};
>
> should be packed attributed

Only when necessary, and I do not belive any platform Linux supports
needs it in this case.

Packed attributing is _BAD_ when it isn't needed because it forces GCC
to output multiple byte-sized loads in order to access larger than
byte-sized elements because it cannot assume the proper alignment on RISC
systems.
-
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: 2005-03-22 14:04    [W:1.280 / U:0.044 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site