diff --git a/boards/arm/bcm958402m2_a72/bcm958402m2_a72_defconfig b/boards/arm/bcm958402m2_a72/bcm958402m2_a72_defconfig index 0082b12677a..ad7a1370a79 100644 --- a/boards/arm/bcm958402m2_a72/bcm958402m2_a72_defconfig +++ b/boards/arm/bcm958402m2_a72/bcm958402m2_a72_defconfig @@ -23,5 +23,5 @@ CONFIG_UART_CONSOLE=y # Enable PCIe EP CONFIG_PCIE_ENDPOINT=y -CONFIG_PCIE_EP_BCM_IPROC=y -CONFIG_PCIE_EP_BCM_IPROC_V2=y +CONFIG_PCIE_EP_IPROC=y +CONFIG_PCIE_EP_IPROC_V2=y diff --git a/drivers/pcie/endpoint/CMakeLists.txt b/drivers/pcie/endpoint/CMakeLists.txt index 40edaf83044..781652b31e1 100644 --- a/drivers/pcie/endpoint/CMakeLists.txt +++ b/drivers/pcie/endpoint/CMakeLists.txt @@ -2,4 +2,4 @@ zephyr_sources(pcie_ep_common.c) -zephyr_sources_ifdef(CONFIG_PCIE_EP_BCM_IPROC pcie_ep_bcm_iproc.c) +zephyr_sources_ifdef(CONFIG_PCIE_EP_IPROC pcie_ep_iproc.c) diff --git a/drivers/pcie/endpoint/Kconfig b/drivers/pcie/endpoint/Kconfig index fe77a9740bb..12b7e560fb0 100644 --- a/drivers/pcie/endpoint/Kconfig +++ b/drivers/pcie/endpoint/Kconfig @@ -16,6 +16,6 @@ source "subsys/logging/Kconfig.template.log_config" comment "PCIe Endpoint Drivers" -source "drivers/pcie/endpoint/Kconfig.bcm_iproc" +source "drivers/pcie/endpoint/Kconfig.iproc" endif # PCIE_ENDPOINT diff --git a/drivers/pcie/endpoint/Kconfig.bcm_iproc b/drivers/pcie/endpoint/Kconfig.iproc similarity index 70% rename from drivers/pcie/endpoint/Kconfig.bcm_iproc rename to drivers/pcie/endpoint/Kconfig.iproc index eb08be49f81..bb5cb13f958 100644 --- a/drivers/pcie/endpoint/Kconfig.bcm_iproc +++ b/drivers/pcie/endpoint/Kconfig.iproc @@ -3,20 +3,20 @@ # Copyright 2020 Broadcom # SPDX-License-Identifier: Apache-2.0 -menuconfig PCIE_EP_BCM_IPROC +menuconfig PCIE_EP_IPROC bool "Broadcom iProc PCIe EP driver" default n help This option enables Broadcom iProc PCIe EP driver. -if PCIE_EP_BCM_IPROC +if PCIE_EP_IPROC -config PCIE_EP_BCM_IPROC_INIT_CFG +config PCIE_EP_IPROC_INIT_CFG bool "Re-initialize PCIe MSI/MSIX configurations" default n -config PCIE_EP_BCM_IPROC_V2 +config PCIE_EP_IPROC_V2 bool "Version-2 of iProc PCIe EP controller" default n -endif # PCIE_EP_BCM_IPROC +endif # PCIE_EP_IPROC diff --git a/drivers/pcie/endpoint/pcie_ep_bcm_iproc.c b/drivers/pcie/endpoint/pcie_ep_iproc.c similarity index 98% rename from drivers/pcie/endpoint/pcie_ep_bcm_iproc.c rename to drivers/pcie/endpoint/pcie_ep_iproc.c index e64e04e0e0f..62543972ac0 100644 --- a/drivers/pcie/endpoint/pcie_ep_bcm_iproc.c +++ b/drivers/pcie/endpoint/pcie_ep_iproc.c @@ -12,8 +12,8 @@ LOG_MODULE_REGISTER(iproc_pcie); #include -#include "pcie_ep_bcm_iproc.h" -#include "pcie_ep_bcm_iproc_regs.h" +#include "pcie_ep_iproc.h" +#include "pcie_ep_iproc_regs.h" #define DT_DRV_COMPAT brcm_iproc_pcie_ep @@ -150,7 +150,7 @@ static int iproc_pcie_generate_msi(const struct device *dev, const uint32_t msi_num) { int ret = 0; -#ifdef CONFIG_PCIE_EP_BCM_IPROC_V2 +#ifdef CONFIG_PCIE_EP_IPROC_V2 uint64_t addr; uint32_t data; @@ -402,7 +402,7 @@ static void iproc_pcie_reset_config(const struct device *dev) #endif } -#ifdef CONFIG_PCIE_EP_BCM_IPROC_INIT_CFG +#ifdef PCIE_EP_IPROC_INIT_CFG static void iproc_pcie_msix_config(const struct device *dev) { /* @@ -459,7 +459,7 @@ static int iproc_pcie_ep_init(const struct device *dev) LOG_INF("PCIe linkup width 0x%x\n", ((data >> PCIE_LINKWIDTH_SHIFT) & PCIE_LINKWIDTH_MASK)); -#ifdef CONFIG_PCIE_EP_BCM_IPROC_INIT_CFG +#ifdef PCIE_EP_IPROC_INIT_CFG iproc_pcie_msi_config(dev); iproc_pcie_msix_config(dev); #endif diff --git a/drivers/pcie/endpoint/pcie_ep_bcm_iproc.h b/drivers/pcie/endpoint/pcie_ep_iproc.h similarity index 92% rename from drivers/pcie/endpoint/pcie_ep_bcm_iproc.h rename to drivers/pcie/endpoint/pcie_ep_iproc.h index b7e1ee1e1cf..bad21870993 100644 --- a/drivers/pcie/endpoint/pcie_ep_bcm_iproc.h +++ b/drivers/pcie/endpoint/pcie_ep_iproc.h @@ -4,8 +4,8 @@ * SPDX-License-Identifier: Apache-2.0 */ -#ifndef ZEPHYR_INCLUDE_DRIVERS_PCIE_EP_BCM_IPROC_H_ -#define ZEPHYR_INCLUDE_DRIVERS_PCIE_EP_BCM_IPROC_H_ +#ifndef ZEPHYR_INCLUDE_DRIVERS_PCIE_EP_IPROC_H_ +#define ZEPHYR_INCLUDE_DRIVERS_PCIE_EP_IPROC_H_ #include @@ -78,4 +78,4 @@ struct iproc_pcie_ep_ctx { void *reset_data[PCIE_RESET_MAX]; }; -#endif /* ZEPHYR_INCLUDE_DRIVERS_PCIE_EP_BCM_IPROC_H_ */ +#endif /* ZEPHYR_INCLUDE_DRIVERS_PCIE_EP_IPROC_H_ */ diff --git a/drivers/pcie/endpoint/pcie_ep_bcm_iproc_regs.h b/drivers/pcie/endpoint/pcie_ep_iproc_regs.h similarity index 98% rename from drivers/pcie/endpoint/pcie_ep_bcm_iproc_regs.h rename to drivers/pcie/endpoint/pcie_ep_iproc_regs.h index fbe207d29b2..7526f6bd2dd 100644 --- a/drivers/pcie/endpoint/pcie_ep_bcm_iproc_regs.h +++ b/drivers/pcie/endpoint/pcie_ep_iproc_regs.h @@ -4,15 +4,15 @@ * SPDX-License-Identifier: Apache-2.0 */ -#ifndef ZEPHYR_INCLUDE_DRIVERS_PCIE_EP_BCM_IPROC_REGS_H_ -#define ZEPHYR_INCLUDE_DRIVERS_PCIE_EP_BCM_IPROC_REGS_H_ +#ifndef ZEPHYR_INCLUDE_DRIVERS_PCIE_EP_IPROC_REGS_H_ +#define ZEPHYR_INCLUDE_DRIVERS_PCIE_EP_IPROC_REGS_H_ struct paxb_64 { uint32_t lower; uint32_t upper; }; -#ifdef CONFIG_PCIE_EP_BCM_IPROC_V2 +#ifdef CONFIG_PCIE_EP_IPROC_V2 struct paxb_imap { uint32_t lower; uint32_t upper; @@ -362,4 +362,4 @@ static inline uint32_t pcie_read32(uint32_t *addr) { return sys_read32((mem_addr_t)addr); } -#endif /* ZEPHYR_INCLUDE_DRIVERS_PCIE_EP_BCM_IPROC_REGS_H_ */ +#endif /* ZEPHYR_INCLUDE_DRIVERS_PCIE_EP_IPROC_REGS_H_ */