diff options
-rw-r--r-- | src/soc/intel/xeon_sp/chip_common.c | 11 | ||||
-rw-r--r-- | src/soc/intel/xeon_sp/cpx/include/soc/soc_util.h | 2 | ||||
-rw-r--r-- | src/soc/intel/xeon_sp/cpx/soc_util.c | 4 | ||||
-rw-r--r-- | src/soc/intel/xeon_sp/skx/include/soc/soc_util.h | 2 | ||||
-rw-r--r-- | src/soc/intel/xeon_sp/skx/soc_util.c | 4 |
5 files changed, 13 insertions, 10 deletions
diff --git a/src/soc/intel/xeon_sp/chip_common.c b/src/soc/intel/xeon_sp/chip_common.c index 5c78780656..47d8f5cc80 100644 --- a/src/soc/intel/xeon_sp/chip_common.c +++ b/src/soc/intel/xeon_sp/chip_common.c @@ -403,6 +403,13 @@ static void assign_stack_resources(struct iiostack_resource *stack_list, } } +static uint8_t is_pci64bit_alloc(void) +{ + const IIO_UDS *hob = get_iio_uds(); + + return hob->PlatformData.Pci64BitResourceAllocation; +} + static void xeonsp_pci_domain_read_resources(struct device *dev) { struct bus *link; @@ -425,8 +432,8 @@ static void xeonsp_pci_domain_read_resources(struct device *dev) xeonsp_pci_dev_iterator(link, xeonsp_reset_pci_op, NULL, NULL); struct iiostack_resource stack_info = {0}; - uint8_t pci64bit_alloc_flag = get_iiostack_info(&stack_info); - if (!pci64bit_alloc_flag) { + get_iiostack_info(&stack_info); + if (!is_pci64bit_alloc()) { /* * Split 32 bit address space between prefetchable and * non-prefetchable windows diff --git a/src/soc/intel/xeon_sp/cpx/include/soc/soc_util.h b/src/soc/intel/xeon_sp/cpx/include/soc/soc_util.h index 649e6b5004..e3c971d49f 100644 --- a/src/soc/intel/xeon_sp/cpx/include/soc/soc_util.h +++ b/src/soc/intel/xeon_sp/cpx/include/soc/soc_util.h @@ -11,7 +11,7 @@ struct iiostack_resource { STACK_RES res[MAX_SOCKET * MAX_LOGIC_IIO_STACK]; }; -uint8_t get_iiostack_info(struct iiostack_resource *info); +void get_iiostack_info(struct iiostack_resource *info); const struct SystemMemoryMapHob *get_system_memory_map(void); diff --git a/src/soc/intel/xeon_sp/cpx/soc_util.c b/src/soc/intel/xeon_sp/cpx/soc_util.c index d2d12d1eba..242fcfe4f2 100644 --- a/src/soc/intel/xeon_sp/cpx/soc_util.c +++ b/src/soc/intel/xeon_sp/cpx/soc_util.c @@ -27,7 +27,7 @@ const struct SystemMemoryMapHob *get_system_memory_map(void) return *memmap_addr; } -uint8_t get_iiostack_info(struct iiostack_resource *info) +void get_iiostack_info(struct iiostack_resource *info) { const IIO_UDS *hob = get_iio_uds(); @@ -42,8 +42,6 @@ uint8_t get_iiostack_info(struct iiostack_resource *info) } } } - - return hob->PlatformData.Pci64BitResourceAllocation; } uint32_t get_socket_stack_busno(uint32_t socket, uint32_t stack) diff --git a/src/soc/intel/xeon_sp/skx/include/soc/soc_util.h b/src/soc/intel/xeon_sp/skx/include/soc/soc_util.h index b42aec0976..0f528110dd 100644 --- a/src/soc/intel/xeon_sp/skx/include/soc/soc_util.h +++ b/src/soc/intel/xeon_sp/skx/include/soc/soc_util.h @@ -11,7 +11,7 @@ struct iiostack_resource { STACK_RES res[CONFIG_MAX_SOCKET * MAX_IIO_STACK]; }; -uint8_t get_iiostack_info(struct iiostack_resource *info); +void get_iiostack_info(struct iiostack_resource *info); void config_reset_cpl3_csrs(void); diff --git a/src/soc/intel/xeon_sp/skx/soc_util.c b/src/soc/intel/xeon_sp/skx/soc_util.c index af6dfcc341..d5e1ae13f4 100644 --- a/src/soc/intel/xeon_sp/skx/soc_util.c +++ b/src/soc/intel/xeon_sp/skx/soc_util.c @@ -55,7 +55,7 @@ const struct SystemMemoryMapHob *get_system_memory_map(void) return memmap_addr; } -uint8_t get_iiostack_info(struct iiostack_resource *info) +void get_iiostack_info(struct iiostack_resource *info) { const IIO_UDS *hob = get_iio_uds(); @@ -71,8 +71,6 @@ uint8_t get_iiostack_info(struct iiostack_resource *info) memcpy(&info->res[info->no_of_stacks++], ri, sizeof(STACK_RES)); } } - - return hob->PlatformData.Pci64BitResourceAllocation; } uint32_t get_socket_stack_busno(uint32_t socket, uint32_t stack) |