diff --git a/components/hal/CMakeLists.txt b/components/hal/CMakeLists.txt index 1aa677b0b0..deb55e1ea1 100644 --- a/components/hal/CMakeLists.txt +++ b/components/hal/CMakeLists.txt @@ -126,7 +126,7 @@ if(NOT BOOTLOADER_BUILD) "esp32s2/cp_dma_hal.c" "esp32s2/touch_sensor_hal.c" "esp32s2/dac_hal.c" - "usbh_hal.c") + "usb_dwc_hal.c") endif() if(${target} STREQUAL "esp32s3") @@ -143,7 +143,7 @@ if(NOT BOOTLOADER_BUILD) "esp32s3/hmac_hal.c" "esp32s3/touch_sensor_hal.c" "esp32s3/rtc_cntl_hal.c" - "usbh_hal.c") + "usb_dwc_hal.c") endif() if(${target} STREQUAL "esp32c3") diff --git a/components/hal/include/hal/usbh_hal.h b/components/hal/include/hal/usb_dwc_hal.h similarity index 99% rename from components/hal/include/hal/usbh_hal.h rename to components/hal/include/hal/usb_dwc_hal.h index 5326deb2dc..6fd2123a84 100644 --- a/components/hal/include/hal/usbh_hal.h +++ b/components/hal/include/hal/usb_dwc_hal.h @@ -17,8 +17,8 @@ NOTE: Thread safety is the responsibility fo the HAL user. All USB Host HAL #include #include -#include "soc/usbh_struct.h" -#include "hal/usbh_ll.h" +#include "soc/usb_dwc_struct.h" +#include "hal/usb_dwc_ll.h" #include "hal/usb_types_private.h" #include "hal/assert.h" diff --git a/components/hal/include/hal/usbh_ll.h b/components/hal/include/hal/usb_dwc_ll.h similarity index 99% rename from components/hal/include/hal/usbh_ll.h rename to components/hal/include/hal/usb_dwc_ll.h index 4320ead0a3..47d03868bb 100644 --- a/components/hal/include/hal/usbh_ll.h +++ b/components/hal/include/hal/usb_dwc_ll.h @@ -12,7 +12,7 @@ extern "C" { #include #include -#include "soc/usbh_struct.h" +#include "soc/usb_dwc_struct.h" #include "hal/usb_types_private.h" #include "hal/misc.h" diff --git a/components/hal/usbh_hal.c b/components/hal/usb_dwc_hal.c similarity index 99% rename from components/hal/usbh_hal.c rename to components/hal/usb_dwc_hal.c index b4a10ca5c5..47c0f6fee6 100644 --- a/components/hal/usbh_hal.c +++ b/components/hal/usb_dwc_hal.c @@ -8,8 +8,8 @@ #include #include #include "sdkconfig.h" -#include "hal/usbh_hal.h" -#include "hal/usbh_ll.h" +#include "hal/usb_dwc_hal.h" +#include "hal/usb_dwc_ll.h" #include "hal/assert.h" // ------------------------------------------------ Macros and Types --------------------------------------------------- diff --git a/components/soc/esp32s2/include/soc/usbh_struct.h b/components/soc/esp32s2/include/soc/usb_dwc_struct.h similarity index 98% rename from components/soc/esp32s2/include/soc/usbh_struct.h rename to components/soc/esp32s2/include/soc/usb_dwc_struct.h index 182a6034d1..a1a48f9157 100644 --- a/components/soc/esp32s2/include/soc/usbh_struct.h +++ b/components/soc/esp32s2/include/soc/usb_dwc_struct.h @@ -1,16 +1,8 @@ -// Copyright 2015-2020 Espressif Systems (Shanghai) PTE LTD -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. +/* + * SPDX-FileCopyrightText: 2015-2022 Espressif Systems (Shanghai) CO LTD + * + * SPDX-License-Identifier: Apache-2.0 + */ #pragma once diff --git a/components/soc/esp32s3/include/soc/usbh_struct.h b/components/soc/esp32s3/include/soc/usb_dwc_struct.h similarity index 98% rename from components/soc/esp32s3/include/soc/usbh_struct.h rename to components/soc/esp32s3/include/soc/usb_dwc_struct.h index 3a52bf9952..ffae18fb0a 100644 --- a/components/soc/esp32s3/include/soc/usbh_struct.h +++ b/components/soc/esp32s3/include/soc/usb_dwc_struct.h @@ -1,16 +1,8 @@ -// Copyright 2015-2020 Espressif Systems (Shanghai) PTE LTD -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. +/* + * SPDX-FileCopyrightText: 2015-2022 Espressif Systems (Shanghai) CO LTD + * + * SPDX-License-Identifier: Apache-2.0 + */ #pragma once diff --git a/components/usb/CMakeLists.txt b/components/usb/CMakeLists.txt index 35f5d24277..5ff63af4d7 100644 --- a/components/usb/CMakeLists.txt +++ b/components/usb/CMakeLists.txt @@ -7,7 +7,7 @@ set(priv_include) set(priv_require driver) # usb_phy driver relies on gpio driver API if(CONFIG_USB_OTG_SUPPORTED) - list(APPEND srcs "hcd.c" + list(APPEND srcs "hcd_dwc.c" "hub.c" "usb_helpers.c" "usb_host.c" diff --git a/components/usb/hcd.c b/components/usb/hcd_dwc.c similarity index 99% rename from components/usb/hcd.c rename to components/usb/hcd_dwc.c index 59828b27f8..0cea6859cf 100644 --- a/components/usb/hcd.c +++ b/components/usb/hcd_dwc.c @@ -14,7 +14,7 @@ #include "esp_intr_alloc.h" #include "esp_err.h" #include "esp_rom_gpio.h" -#include "hal/usbh_hal.h" +#include "hal/usb_dwc_hal.h" #include "hal/usb_types_private.h" #include "soc/gpio_pins.h" #include "soc/gpio_sig_map.h"