Use the packed attribute for the descriptor on the wire
This commit is contained in:
parent
a3f1512fc7
commit
db8ea5a2fa
@ -296,6 +296,8 @@ __CONCAT(dname,_detach)(self, flags) \
|
||||
#define clalloc(p, s, x) (clist_alloc_cblocks((p), (s), (s)), 0)
|
||||
#define clfree(p) clist_free_cblocks((p))
|
||||
|
||||
#define UPACKED __attribute__ ((packed))
|
||||
|
||||
#define PWR_RESUME 0
|
||||
#define PWR_SUSPEND 1
|
||||
|
||||
|
@ -1,4 +1,4 @@
|
||||
/* $NetBSD: usbhid.h,v 1.4 1999/04/22 01:57:01 augustss Exp $ */
|
||||
/* $NetBSD: usbhid.h,v 1.8 2000/05/30 10:10:18 augustss Exp $ */
|
||||
/* $FreeBSD$ */
|
||||
|
||||
/*
|
||||
@ -64,7 +64,7 @@ typedef struct usb_hid_descriptor {
|
||||
uByte bDescriptorType;
|
||||
uWord wDescriptorLength;
|
||||
} descrs[1];
|
||||
} usb_hid_descriptor_t;
|
||||
} UPACKED usb_hid_descriptor_t;
|
||||
#define USB_HID_DESCRIPTOR_SIZE(n) (9+(n)*3)
|
||||
|
||||
/* Usage pages */
|
||||
|
Loading…
Reference in New Issue
Block a user