diff mbox series

[v2,23/32] pci: arm: mvebu: Drop DM_PCI check from

Message ID 20210802005446.2267075-24-sjg@chromium.org
State Accepted
Delegated to: Tom Rini
Headers show
Series pci: Drop all pre-driver model code | expand

Commit Message

Simon Glass Aug. 2, 2021, 12:54 a.m. UTC
We don't need this check anymore since when PCI is enabled, driver model
is always used.

Use CONFIG_PCI instead.

Signed-off-by: Simon Glass <sjg@chromium.org>
---

(no changes since v1)

 arch/arm/mach-mvebu/arm64-common.c | 5 ++---
 1 file changed, 2 insertions(+), 3 deletions(-)

Comments

Tom Rini Aug. 6, 2021, 12:46 p.m. UTC | #1
On Sun, Aug 01, 2021 at 06:54:36PM -0600, Simon Glass wrote:

> We don't need this check anymore since when PCI is enabled, driver model
> is always used.
> 
> Use CONFIG_PCI instead.
> 
> Signed-off-by: Simon Glass <sjg@chromium.org>
> ---
> 
> (no changes since v1)
> 
>  arch/arm/mach-mvebu/arm64-common.c | 5 ++---
>  1 file changed, 2 insertions(+), 3 deletions(-)
> 
> diff --git a/arch/arm/mach-mvebu/arm64-common.c b/arch/arm/mach-mvebu/arm64-common.c
> index fa687d8abbb..06c4994e065 100644
> --- a/arch/arm/mach-mvebu/arm64-common.c
> +++ b/arch/arm/mach-mvebu/arm64-common.c
> @@ -104,10 +104,9 @@ int arch_early_init_r(void)
>  	/* Cause the SATA device to do its early init */
>  	uclass_first_device(UCLASS_AHCI, &dev);
>  
> -#ifdef CONFIG_DM_PCI
>  	/* Trigger PCIe devices detection */
> -	pci_init();
> -#endif
> +	if (IS_ENABLED(PCI))
> +		pci_init();
>  
>  	return 0;
>  }

This needs to be IS_ENABLED(CONFIG_PCI), I've fixed it locally.
Tom Rini Aug. 6, 2021, 9:21 p.m. UTC | #2
On Sun, Aug 01, 2021 at 06:54:36PM -0600, Simon Glass wrote:

> We don't need this check anymore since when PCI is enabled, driver model
> is always used.
> 
> Use CONFIG_PCI instead.
> 
> Signed-off-by: Simon Glass <sjg@chromium.org>

Reworded and fixed as I noted and applied to u-boot/master, thanks!
diff mbox series

Patch

diff --git a/arch/arm/mach-mvebu/arm64-common.c b/arch/arm/mach-mvebu/arm64-common.c
index fa687d8abbb..06c4994e065 100644
--- a/arch/arm/mach-mvebu/arm64-common.c
+++ b/arch/arm/mach-mvebu/arm64-common.c
@@ -104,10 +104,9 @@  int arch_early_init_r(void)
 	/* Cause the SATA device to do its early init */
 	uclass_first_device(UCLASS_AHCI, &dev);
 
-#ifdef CONFIG_DM_PCI
 	/* Trigger PCIe devices detection */
-	pci_init();
-#endif
+	if (IS_ENABLED(PCI))
+		pci_init();
 
 	return 0;
 }