Skip to contentSkip to conversation

USB: usb.h: tweak struct urb to remove wasted space

DISCUSSION Oliver Neukum 1 participant 1 message Mar 2, 2019 USB

lore
Share & tools
lore
#0 lore raw
Quoted 10 lines · Greg Kroah-Hartman
Quoted 6 lines · Oliver Neukum
Quoted 2 lines · Greg Kroah-Hartman

By moving one field around in 'struct urb' we reduce the size of the structure by 8 bytes.

If you are going for this I have to ask why unlink and status are full size ints anyway.

History, they hold a "normal" negative error code. I guess we could turn them into s16, if it really matters, but that feels odd to me.

Returning internal error codes to user space is a bug.

Regards
Oliver