summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorsakumisu <[email protected]>2024-07-13 10:13:29 +0800
committersakumisu <[email protected]>2024-07-13 10:13:37 +0800
commit9c14ea19a931fea0252a1368b9454972e09c0283 (patch)
treed0892755efa2873dedbd72fa391e1cb7377e7df0
parent218fa8e85dbd9aa4737c28e5cf468545d75b46d1 (diff)
fix(port/bl): fix test mode api
-rw-r--r--port/bouffalolab/usb_dc_bl.c5
1 files changed, 2 insertions, 3 deletions
diff --git a/port/bouffalolab/usb_dc_bl.c b/port/bouffalolab/usb_dc_bl.c
index 542297df..6c9df09c 100644
--- a/port/bouffalolab/usb_dc_bl.c
+++ b/port/bouffalolab/usb_dc_bl.c
@@ -1042,12 +1042,11 @@ void USBD_IRQHandler(uint8_t busid)
}
#ifdef CONFIG_USBDEV_TEST_MODE
-void usbd_execute_test_mode(struct usb_setup_packet *setup)
+void usbd_execute_test_mode(uint8_t busid, uint8_t test_mode)
{
uint32_t regval;
- uint8_t index = setup->wIndex >> 8;
- switch (index) {
+ switch (test_mode) {
case 1: // Test_J
{
regval = getreg32(BFLB_USB_BASE + USB_PHY_TST_OFFSET);