summaryrefslogtreecommitdiff
path: root/src/portable
diff options
context:
space:
mode:
authorhathach <[email protected]>2022-09-13 11:04:48 +0700
committerhathach <[email protected]>2022-09-13 11:04:48 +0700
commit7a48b1f0d191093caa59c4fcb5c4f85fa2e53323 (patch)
tree501a36c11a37590b6f19d95b8ba91772ba101aec /src/portable
parentb624664f52df9454755a8a67518b2a11b06cfb8b (diff)
re-added code in pr 1438 to fix compile with h7 with 1 usb otg
Diffstat (limited to 'src/portable')
-rw-r--r--src/portable/synopsys/dwc2/dwc2_stm32.h4
1 files changed, 4 insertions, 0 deletions
diff --git a/src/portable/synopsys/dwc2/dwc2_stm32.h b/src/portable/synopsys/dwc2/dwc2_stm32.h
index 1187e0d6e..337f611d8 100644
--- a/src/portable/synopsys/dwc2/dwc2_stm32.h
+++ b/src/portable/synopsys/dwc2/dwc2_stm32.h
@@ -64,6 +64,10 @@
// NOTE: H7 with only 1 USB port: H72x / H73x / H7Ax / H7Bx
// USB_OTG_FS_PERIPH_BASE and OTG_FS_IRQn not defined
+ #if (! defined USB2_OTG_FS)
+ #define USB_OTG_FS_PERIPH_BASE USB1_OTG_HS_PERIPH_BASE
+ #define OTG_FS_IRQn OTG_HS_IRQn
+ #endif
#elif CFG_TUSB_MCU == OPT_MCU_STM32F7
#include "stm32f7xx.h"