summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorOnlyoutzZ <[email protected]>2026-08-28 16:57:57 +0800
committersakumisu <[email protected]>2026-08-29 15:37:44 +0800
commit347c06cecfdf6f3156edd93ce90770192b7b92af (patch)
tree6e25587f05f15976f7eb89dc4fd7a76f632de578
parent0cf4d87b8fefc81ffd680434411e627f44758f6f (diff)
port/fsdev: log error when USBFS clock divider has no match
Report an error through USB_LOG_ERR when SystemCoreClock does not match any supported 48/96/144/192/240 MHz divider case, instead of silently leaving the USBFS prescaler unconfigured.
-rw-r--r--port/fsdev/usb_glue_nation.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/port/fsdev/usb_glue_nation.c b/port/fsdev/usb_glue_nation.c
index ef190dd8..0ab539a2 100644
--- a/port/fsdev/usb_glue_nation.c
+++ b/port/fsdev/usb_glue_nation.c
@@ -100,6 +100,8 @@ static void Set_USBClock(void)
break;
default:
+ USB_LOG_ERR("Unsupported system clock %u Hz for USBFS 48 MHz clock (supported: 48/96/144/192/240 MHz)\r\n",
+ (unsigned int)SystemCoreClock);
break;
}
}