feat(usb/host): Add option to choose peripheral for USB host library

Starting with ESP32-P4 we can have targets that have more than 1 USB-OTG peripheral.
This commit adds an option to choose which peripherals will be used by USB Host lib.

Internally, we will still have only 1 Root HUB but with multiple Root ports.

# Conflicts:
#	components/usb/host_test/usb_host_layer_test/main/usb_host_install_unit_test.cpp
#	components/usb/hub.c
#	components/usb/test_apps/common/phy_common.c
#	components/usb/test_apps/common/phy_common.h
#	components/usb/test_apps/hcd/main/test_hcd_common.c
#	components/usb/test_apps/usb_host/main/test_app_main.c
#	components/usb/usb_host.c
This commit is contained in:
Tomas Rezucha
2025-06-30 14:45:59 +08:00
committed by BOT
parent 02447c9e0d
commit 4addf21286
9 changed files with 120 additions and 64 deletions
+1 -1
View File
@@ -106,9 +106,9 @@ extern const usb_dwc_info_t usb_dwc_info;
/* ------------------------------- Deprecated ------------------------------- */
/* Todo: Remove in ESP-IDF v6.0 (IDF-9052) */
#include <stdint.h>
#include "soc/periph_defs.h"
#if SOC_USB_OTG_SUPPORTED
#include "soc/periph_defs.h"
/*
Stores a bunch of USB-peripheral data.