Pali Rohár a4bc38da27 pci: Add standard PCIe ECAM macros
Lot of PCIe controllers are using ECAM addressing. So add common ECAM
macros into U-Boot's pci.h header file which can be suitable for most
PCI controller drivers.

Replace custom ECAM address macros in every PCI controller driver by new
ECAM macros from U-Boot's pci.h header file.

Similar macros are defined also in Linux kernel. There is a small
difference between Linux and these new U-Boot macros.

U-Boot's PCIE_ECAM_OFFSET() takes device and function numbers in separate
arguments. Linux's PCIE_ECAM_OFFSET() takes device and function numbers
encoded in one argument. The reason is that U-Boot's PCI_DEVFN() macro is
different than Linux's PCI_SLOT() macro. So having device and function
numbers in separate arguments makes code more straightforward.

Signed-off-by: Pali Rohár <pali@kernel.org>
Reviewed-by: Stefan Roese <sr@denx.de>
2021-11-17 17:04:58 -05:00
..
2021-10-31 08:46:44 -04:00
2021-09-25 09:46:15 -06:00
2021-10-05 08:50:15 -04:00
2021-11-07 18:36:56 +01:00
2021-09-27 21:38:34 -04:00
2021-10-31 08:46:44 -04:00
2021-10-20 14:24:09 -04:00
2021-11-12 14:18:17 -05:00
2021-11-17 17:04:58 -05:00
2021-11-17 17:04:58 -05:00
2021-11-09 11:57:22 +09:00
2021-09-04 12:26:02 -04:00
2021-11-10 14:11:30 -05:00
2021-09-13 18:23:13 -04:00
2021-10-01 21:08:18 -04:00
2021-10-31 08:46:44 -04:00
2021-10-31 08:46:44 -04:00