summaryrefslogtreecommitdiff
path: root/src/class
diff options
context:
space:
mode:
Diffstat (limited to 'src/class')
-rw-r--r--src/class/hid/hid_device.c2
-rw-r--r--src/class/msc/msc_device.c1
2 files changed, 2 insertions, 1 deletions
diff --git a/src/class/hid/hid_device.c b/src/class/hid/hid_device.c
index 949fd183d..572f2cad2 100644
--- a/src/class/hid/hid_device.c
+++ b/src/class/hid/hid_device.c
@@ -178,7 +178,7 @@ bool hidd_open(uint8_t rhport, tusb_desc_interface_t const * desc_itf, uint16_t
p_hid->boot_mode = false; // default mode is REPORT
p_hid->itf_num = desc_itf->bInterfaceNumber;
- p_hid->reprot_desc_len = desc_hid->wReportLength;
+ memcpy(&p_hid->reprot_desc_len, &desc_hid->wReportLength, 2);
*p_len = sizeof(tusb_desc_interface_t) + sizeof(tusb_hid_descriptor_hid_t) + desc_itf->bNumEndpoints*sizeof(tusb_desc_endpoint_t);
diff --git a/src/class/msc/msc_device.c b/src/class/msc/msc_device.c
index 2ec8962ae..a77282ed5 100644
--- a/src/class/msc/msc_device.c
+++ b/src/class/msc/msc_device.c
@@ -44,6 +44,7 @@ enum
typedef struct
{
+ // TODO optimize alignment
CFG_TUSB_MEM_ALIGN msc_cbw_t cbw;
CFG_TUSB_MEM_ALIGN msc_csw_t csw;