summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorhathach <[email protected]>2018-12-19 13:16:42 +0700
committerhathach <[email protected]>2018-12-19 13:16:42 +0700
commit426064201a2a28bf9c21f2cb05f9bd0fe2213ac7 (patch)
tree1eaebd80ec069d6a26104da6ad7cbfc78e2b5f0f /src
parent902697ca079a179221da92f8cb9f873768a5d0d7 (diff)
fix samd build
Diffstat (limited to 'src')
-rw-r--r--src/portable/microchip/samd21/dcd_samd21.c2
-rw-r--r--src/portable/microchip/samd51/dcd_samd51.c2
2 files changed, 2 insertions, 2 deletions
diff --git a/src/portable/microchip/samd21/dcd_samd21.c b/src/portable/microchip/samd21/dcd_samd21.c
index 0865f2bda..be1f4495c 100644
--- a/src/portable/microchip/samd21/dcd_samd21.c
+++ b/src/portable/microchip/samd21/dcd_samd21.c
@@ -127,7 +127,7 @@ void dcd_set_config (uint8_t rhport, uint8_t config_num)
uint32_t dcd_get_microframe(uint8_t rhport)
{
(void) rhport;
- return USB->DEVICE.FNUM & (TU_BIT(14) - 1);
+ return USB->DEVICE.FNUM.reg & (TU_BIT(14) - 1);
}
/*------------------------------------------------------------------*/
diff --git a/src/portable/microchip/samd51/dcd_samd51.c b/src/portable/microchip/samd51/dcd_samd51.c
index fc3d31dea..3dd6c88d0 100644
--- a/src/portable/microchip/samd51/dcd_samd51.c
+++ b/src/portable/microchip/samd51/dcd_samd51.c
@@ -132,7 +132,7 @@ void dcd_set_config (uint8_t rhport, uint8_t config_num)
uint32_t dcd_get_microframe(uint8_t rhport)
{
(void) rhport;
- return USB->DEVICE.FNUM & (TU_BIT(14) - 1);
+ return USB->DEVICE.FNUM.reg & (TU_BIT(14) - 1);
}
/*------------------------------------------------------------------*/