From 03decc0c5e988ce9af20ebe1e3e52e495251d0a5 Mon Sep 17 00:00:00 2001 From: Patrick Georgi Date: Tue, 30 Jun 2015 12:48:45 +0200 Subject: intel/sandybridge: initialize variable Otherwise cache_base may be uninitialized. Change-Id: Ie91f9567cea24114723a5362f52052d6ec22a6b8 Signed-off-by: Patrick Georgi Reviewed-on: http://review.coreboot.org/10724 Tested-by: build bot (Jenkins) Reviewed-by: Paul Menzel Reviewed-by: Stefan Reinauer --- src/northbridge/intel/sandybridge/mrccache.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'src') diff --git a/src/northbridge/intel/sandybridge/mrccache.c b/src/northbridge/intel/sandybridge/mrccache.c index 94a7c396fb..f89fc0fa98 100644 --- a/src/northbridge/intel/sandybridge/mrccache.c +++ b/src/northbridge/intel/sandybridge/mrccache.c @@ -72,7 +72,8 @@ static u32 get_mrc_cache_region(struct mrc_data_container **mrc_region_ptr) if (fmap_locate_area_as_rdev("RW_MRC_CACHE", &rdev) == 0) { region_size = region_device_sz(&rdev); *mrc_region_ptr = rdev_mmap_full(&rdev); - } + } else + *mrc_region_ptr = NULL; } else { *mrc_region_ptr = cbfs_boot_map_with_leak("mrc.cache", CBFS_TYPE_MRC_CACHE, -- cgit v1.2.3