Hello,
I would like to read the MAC address from PCIe ECAM space under SeaBIOS, I have been able to read from the PCI standard registers with the pci_config_read(w-l-b) functions, but I have seen that there are no functions to read from the ECAM space.
According to the PCIe standards there is a base address and an offset for each PCIe device where to read from, but it seems there are no examples or other implementation in the source codes except for QEMU.
Any help would be appreciated.
Regards Ugo
On Wed, Nov 09, 2022 at 06:01:15AM -0800, Ugo Cirmignani wrote:
Hello,
I would like to read the MAC address from PCIe ECAM space under SeaBIOS, I have been able to read from the PCI standard registers with the pci_config_read(w-l-b) functions, but I have seen that there are no functions to read from the ECAM space.
pci_config_read() will read from ecam when configured accordingly (i.e. mmconfig variable in src/hw/pci.c is set properly), which is the case for qemu with q35 machine type.
HTH, Gerd