soc/intel/icelake: Enable caching on SPI memory-mapped boot device unconditionally

Icelake platform doesn't support booting from any other media
(like eMMC on APL/GLK platform) than only booting from SPI device
and on IA platform SPI is memory mapped hence enabling temporarily
cacheing on memory-mapped spi boot media.

Also removed inclusion of unused header in cpu.c file

TEST=Able to build and boot ICL DE board.

Change-Id: I46d9ec054c4804ca756f2101085a55e91b5cc6f0
Signed-off-by: Subrata Banik <subrata.banik@intel.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/36431
Reviewed-by: Aaron Durbin <adurbin@chromium.org>
Reviewed-by: Arthur Heymans <arthur@aheymans.xyz>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
This commit is contained in:
Subrata Banik 2019-10-29 17:23:53 +05:30
parent 376357c107
commit 40964fb4dd
1 changed files with 10 additions and 5 deletions

View File

@ -13,14 +13,19 @@
* GNU General Public License for more details.
*/
#include <intelblocks/cpulib.h>
#include <intelblocks/fast_spi.h>
#include <soc/bootblock.h>
void bootblock_cpu_init(void)
{
/* Temporarily cache the memory-mapped boot media. */
if (CONFIG(BOOT_DEVICE_MEMORY_MAPPED) &&
CONFIG(BOOT_DEVICE_SPI_FLASH))
fast_spi_cache_bios_region();
/*
* Icelake platform doesn't support booting from any other media
* (like eMMC on APL/GLK platform) than only booting from SPI device
* and on IA platform SPI is memory mapped hence enabling temporarily
* cacheing on memory-mapped spi boot media.
*
* This assumption will not hold good for APL/GLK platform where boot
* from eMMC is also possible options.
*/
fast_spi_cache_bios_region();
}