On Wednesday, January 06, 2016 at 09:53:17 PM, Fabio Estevam wrote:
> From: Fabio Estevam <fabio.este...@nxp.com>
> 
> Since commit ff3e077bd2 ("dm: pci: Add a uclass for PCI") the following
> error message is seen:
> 
> => pci 0
> Scanning PCI devices on bus 0
> BusDevFun  VendorId   DeviceId   Device Class       Sub-Class
> _____________________________________________________________
> 00.01.00   0x16c3     0xabcd     Bridge device           0x04
> Cannot read bus configuration: -1
> 
> We can avoid this error by using the same approach as done in the
> linux kernel PCI designware driver: (drivers/pci/host/pcie-designware.c)
> 
> static int dw_pcie_rd_conf(struct pci_bus *bus, u32 devfn, int where,
>                       int size, u32 *val)
> {
>       struct pcie_port *pp = bus->sysdata;
>       int ret;
> 
>       if (dw_pcie_valid_config(pp, bus, PCI_SLOT(devfn)) == 0) {
>               *val = 0xffffffff;
>               return PCIBIOS_DEVICE_NOT_FOUND;
>       }
> 
> ,where PCIBIOS_DEVICE_NOT_FOUND is returned when an invalid address
> is given.
> 
> Signed-off-by: Fabio Estevam <fabio.este...@nxp.com>

Acked-by: Marek Vasut <ma...@denx.de>

Best regards,
Marek Vasut
_______________________________________________
U-Boot mailing list
U-Boot@lists.denx.de
http://lists.denx.de/mailman/listinfo/u-boot

Reply via email to