From 32169720bb6756faba38148d2425c0a85df117c1 Mon Sep 17 00:00:00 2001 From: Felix Held Date: Fri, 14 Jul 2023 19:41:06 +0200 Subject: soc/amd/common/data_fabric/domain: report non-PCI MMIO resources Call read_non_pci_resources from amd_pci_domain_read_resources to tell the resource allocator about the non-PCI MMIO regions within the data fabric MMIO regions so that the allocator won't place any PCI MMIO in the same areas. TEST=On Mandolin 3 new non-PCI resources get reported to the allocator: avoid_fixed_resources: DOMAIN: 0000 04 base fd100000 limit fd1fffff mem (fixed) avoid_fixed_resources: DOMAIN: 0000 05 base fd000000 limit fd0fffff mem (fixed) avoid_fixed_resources: DOMAIN: 0000 20000120 base fec01000 limit fec01fff mem (fixed) Signed-off-by: Felix Held Change-Id: I7f69b86e376e3368d4f156ccf93791cc00886489 Reviewed-on: https://review.coreboot.org/c/coreboot/+/76599 Tested-by: build bot (Jenkins) Reviewed-by: Matt DeVillier Reviewed-by: Arthur Heymans Reviewed-by: Eric Lai --- src/soc/amd/common/block/data_fabric/Kconfig | 1 + src/soc/amd/common/block/data_fabric/domain.c | 3 +++ 2 files changed, 4 insertions(+) (limited to 'src') diff --git a/src/soc/amd/common/block/data_fabric/Kconfig b/src/soc/amd/common/block/data_fabric/Kconfig index c98bac48ee15..4c4f7b34e1a6 100644 --- a/src/soc/amd/common/block/data_fabric/Kconfig +++ b/src/soc/amd/common/block/data_fabric/Kconfig @@ -7,6 +7,7 @@ config SOC_AMD_COMMON_BLOCK_DATA_FABRIC config SOC_AMD_COMMON_BLOCK_DATA_FABRIC_DOMAIN bool depends on SOC_AMD_COMMON_BLOCK_DATA_FABRIC + select SOC_AMD_COMMON_BLOCK_ROOT_COMPLEX help Select this option to add functionality to the build to tell the resource allocator about the MMIO regions configured in the data diff --git a/src/soc/amd/common/block/data_fabric/domain.c b/src/soc/amd/common/block/data_fabric/domain.c index c032fdb4bbcf..c7290b1490fc 100644 --- a/src/soc/amd/common/block/data_fabric/domain.c +++ b/src/soc/amd/common/block/data_fabric/domain.c @@ -3,6 +3,7 @@ #include #include #include +#include #include #include #include @@ -159,6 +160,8 @@ void amd_pci_domain_read_resources(struct device *domain) add_io_regions(domain, &idx); add_data_fabric_mmio_regions(domain, &idx); + + read_non_pci_resources(domain, &idx); } static void write_ssdt_domain_io_producer_range_helper(const char *domain_name, -- cgit v1.2.3