summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorhathach <[email protected]>2026-01-09 10:47:50 +0700
committerhathach <[email protected]>2026-01-09 10:47:50 +0700
commite69494d94a680c7b5aa5310338c206921d57640b (patch)
tree6a4540a8055f1ae874d931fe9b5acd11c706e4dd
parent271edeb35bb0ebf38e79bed4b2bcbf34fd40e326 (diff)
fix pre-commit, clean up tusb_mcu.h, add at32f45x to ci build
-rwxr-xr-x.github/workflows/ci_set_matrix.py3
-rw-r--r--hw/bsp/at32f45x/at32f45x_clock.c2
-rw-r--r--hw/bsp/at32f45x/at32f45x_clock.h1
-rw-r--r--hw/bsp/at32f45x/at32f45x_int.c1
-rw-r--r--hw/bsp/at32f45x/at32f45x_int.h1
-rw-r--r--src/common/tusb_mcu.h22
6 files changed, 4 insertions, 26 deletions
diff --git a/.github/workflows/ci_set_matrix.py b/.github/workflows/ci_set_matrix.py
index c276d5253..237a34b9f 100755
--- a/.github/workflows/ci_set_matrix.py
+++ b/.github/workflows/ci_set_matrix.py
@@ -15,7 +15,8 @@ toolchain_list = [
# family: [supported toolchain]
family_list = {
- "at32f402_405 at32f403a_407 at32f413 at32f415 at32f423 at32f425 at32f435_437 broadcom_32bit da1469x": ["arm-gcc"],
+ "at32f45x at32f402_405 at32f403a_407 at32f413 at32f415 at32f423 at32f425 at32f435_437 broadcom_32bit da1469x": [
+ "arm-gcc"],
"broadcom_64bit": ["aarch64-gcc"],
"ch32v10x ch32v20x ch32v30x fomu gd32vf103 hpmicro": ["riscv-gcc"],
"imxrt": ["arm-gcc", "arm-clang"],
diff --git a/hw/bsp/at32f45x/at32f45x_clock.c b/hw/bsp/at32f45x/at32f45x_clock.c
index 12003cf5a..a6724e23f 100644
--- a/hw/bsp/at32f45x/at32f45x_clock.c
+++ b/hw/bsp/at32f45x/at32f45x_clock.c
@@ -55,7 +55,7 @@ void system_clock_config(void)
/* enable pwc periph clock */
crm_periph_clock_enable(CRM_PWC_PERIPH_CLOCK, TRUE);
-
+
/* config ldo voltage */
pwc_ldo_output_voltage_set(PWC_LDO_OUTPUT_1V3);
diff --git a/hw/bsp/at32f45x/at32f45x_clock.h b/hw/bsp/at32f45x/at32f45x_clock.h
index 1fd2035aa..a372a605b 100644
--- a/hw/bsp/at32f45x/at32f45x_clock.h
+++ b/hw/bsp/at32f45x/at32f45x_clock.h
@@ -42,4 +42,3 @@ void system_clock_config(void);
#endif
#endif
-
diff --git a/hw/bsp/at32f45x/at32f45x_int.c b/hw/bsp/at32f45x/at32f45x_int.c
index 15798e381..15ff90c64 100644
--- a/hw/bsp/at32f45x/at32f45x_int.c
+++ b/hw/bsp/at32f45x/at32f45x_int.c
@@ -98,4 +98,3 @@ void DebugMon_Handler(void)
/**
* @}
*/
-
diff --git a/hw/bsp/at32f45x/at32f45x_int.h b/hw/bsp/at32f45x/at32f45x_int.h
index 64930f29e..3a2667e9d 100644
--- a/hw/bsp/at32f45x/at32f45x_int.h
+++ b/hw/bsp/at32f45x/at32f45x_int.h
@@ -57,4 +57,3 @@ void OTGFS1_WKUP_IRQHandler(void);
#endif
#endif
-
diff --git a/src/common/tusb_mcu.h b/src/common/tusb_mcu.h
index cbdcd2dfc..5b9497b9a 100644
--- a/src/common/tusb_mcu.h
+++ b/src/common/tusb_mcu.h
@@ -635,17 +635,7 @@
#define TUP_USBIP_DWC2_AT32
#define TUP_DCD_ENDPOINT_MAX 4
-#elif TU_CHECK_MCU(OPT_MCU_AT32F435_437)
- #define TUP_USBIP_DWC2
- #define TUP_USBIP_DWC2_AT32
- #define TUP_DCD_ENDPOINT_MAX 8
-
-#elif TU_CHECK_MCU(OPT_MCU_AT32F423)
- #define TUP_USBIP_DWC2
- #define TUP_USBIP_DWC2_AT32
- #define TUP_DCD_ENDPOINT_MAX 8
-
-#elif TU_CHECK_MCU(OPT_MCU_AT32F402_405)
+#elif TU_CHECK_MCU(OPT_MCU_AT32F402_405, OPT_MCU_AT32F423, OPT_MCU_AT32F425, OPT_MCU_AT32F435_437, OPT_MCU_AT32F45X)
#define TUP_USBIP_DWC2
#define TUP_USBIP_DWC2_AT32
#define TUP_DCD_ENDPOINT_MAX 8
@@ -657,16 +647,6 @@
#define TUP_RHPORT_HIGHSPEED 1 // Port0: FS, Port1: HS
#endif
-#elif TU_CHECK_MCU(OPT_MCU_AT32F425)
- #define TUP_USBIP_DWC2
- #define TUP_USBIP_DWC2_AT32
- #define TUP_DCD_ENDPOINT_MAX 8
-
-#elif TU_CHECK_MCU(OPT_MCU_AT32F45X)
- #define TUP_USBIP_DWC2
- #define TUP_USBIP_DWC2_AT32
- #define TUP_DCD_ENDPOINT_MAX 8
-
//--------------------------------------------------------------------+
// HPMicro
//--------------------------------------------------------------------+