summaryrefslogtreecommitdiff
path: root/src/portable/synopsys
diff options
context:
space:
mode:
authorhathach <[email protected]>2024-10-11 15:21:32 +0700
committerhathach <[email protected]>2024-10-11 15:31:49 +0700
commitd997f0071ea5d2d07e340d183fffb97e09526773 (patch)
treed796bbf0db3b860f506554029f4fe019ed892936 /src/portable/synopsys
parent92602b9de3675c2d3e240bcd0838082e1a07b13b (diff)
change dcd_init() to take rhport struct
Diffstat (limited to 'src/portable/synopsys')
-rw-r--r--src/portable/synopsys/dwc2/dcd_dwc2.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/portable/synopsys/dwc2/dcd_dwc2.c b/src/portable/synopsys/dwc2/dcd_dwc2.c
index 1ba3507ef..580960e24 100644
--- a/src/portable/synopsys/dwc2/dcd_dwc2.c
+++ b/src/portable/synopsys/dwc2/dcd_dwc2.c
@@ -650,9 +650,10 @@ static bool check_dwc2(dwc2_regs_t* dwc2) {
return true;
}
-void dcd_init(uint8_t rhport) {
+void dcd_init(const tusb_rhport_init_t* rh_init) {
// Programming model begins in the last section of the chapter on the USB
// peripheral in each Reference Manual.
+ const uint8_t rhport = rh_init->rhport;
dwc2_regs_t* dwc2 = DWC2_REG(rhport);
// Check Synopsys ID register, failed if controller clock/power is not enabled