summaryrefslogtreecommitdiff
path: root/src/soc
diff options
context:
space:
mode:
authorArthur Heymans <arthur@aheymans.xyz>2019-05-25 10:22:09 +0200
committerPatrick Georgi <pgeorgi@google.com>2019-05-29 20:05:26 +0000
commit9456d60f6597cea314be09be7cd053a631a31948 (patch)
tree3a0daa4427d10ca761306b7c7b1345aae99768e8 /src/soc
parent84e22e37e89e3384782c40379cc7f2b18faa2099 (diff)
soc/intel/common/gspi: Don't use CAR_GLOBAL
All platforms using this code have NO_CAR_GLOBAL_MIGRATION. Change-Id: I5dfbc718fd82f0511b0049383e4e93c6f15ee932 Signed-off-by: Arthur Heymans <arthur@aheymans.xyz> Reviewed-on: https://review.coreboot.org/c/coreboot/+/32999 Reviewed-by: Kyösti Mälkki <kyosti.malkki@gmail.com> Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Diffstat (limited to 'src/soc')
-rw-r--r--src/soc/intel/common/block/gspi/gspi.c11
1 files changed, 4 insertions, 7 deletions
diff --git a/src/soc/intel/common/block/gspi/gspi.c b/src/soc/intel/common/block/gspi/gspi.c
index 81eb7eedec..7fd7d0f9ae 100644
--- a/src/soc/intel/common/block/gspi/gspi.c
+++ b/src/soc/intel/common/block/gspi/gspi.c
@@ -14,7 +14,6 @@
* GNU General Public License for more details.
*/
-#include <arch/early_variables.h>
#include <device/mmio.h>
#include <assert.h>
#include <console/console.h>
@@ -262,15 +261,13 @@ static uint32_t gspi_get_bus_clk_mhz(unsigned int gspi_bus)
return cfg[gspi_bus].speed_mhz;
}
-static uintptr_t gspi_base[CONFIG_SOC_INTEL_COMMON_BLOCK_GSPI_MAX] CAR_GLOBAL;
+static uintptr_t gspi_base[CONFIG_SOC_INTEL_COMMON_BLOCK_GSPI_MAX];
static uintptr_t gspi_get_bus_base_addr(unsigned int gspi_bus)
{
- uintptr_t *base = car_get_var_ptr(gspi_base);
+ if (!gspi_base[gspi_bus])
+ gspi_base[gspi_bus] = gspi_calc_base_addr(gspi_bus);
- if (!base[gspi_bus])
- base[gspi_bus] = gspi_calc_base_addr(gspi_bus);
-
- return base[gspi_bus];
+ return gspi_base[gspi_bus];
}
/* Parameters for GSPI controller operation. */