From: Konstantin Porotchkin Date: Wed, 5 Apr 2017 14:42:33 +0000 (+0300) Subject: arm64: mvebu: Trigger PCI devices scan at early init stage X-Git-Tag: v2017.07-rc1~389^2~21 X-Git-Url: https://git.sur5r.net/?a=commitdiff_plain;h=f4f194e864e879896e630594448b31cc672a4934;p=u-boot arm64: mvebu: Trigger PCI devices scan at early init stage Add PCIe initialization at early init stage. This operation has a side effect of detecting all PCIe plug-in cards, so the operator is not obligated to issue "pci enum" command though CLI for this purpose. Signed-off-by: Konstantin Porotchkin Cc: Stefan Roese Cc: Igal Liberman Cc: Nadav Haklai Reviewed-by: Stefan Roese --- diff --git a/arch/arm/mach-mvebu/arm64-common.c b/arch/arm/mach-mvebu/arm64-common.c index 2ef5726905..c2c176e3d4 100644 --- a/arch/arm/mach-mvebu/arm64-common.c +++ b/arch/arm/mach-mvebu/arm64-common.c @@ -8,6 +8,7 @@ #include #include #include +#include #include #include #include @@ -147,5 +148,10 @@ 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 + return 0; }