summaryrefslogtreecommitdiff
path: root/src/soc/intel/cannonlake/bootblock
diff options
context:
space:
mode:
authorUsha P <usha.p@intel.com>2019-11-28 10:05:45 +0530
committerPatrick Georgi <pgeorgi@google.com>2019-12-26 10:44:17 +0000
commit33ff4cc137e501b14859bc67cc7e85dd60a863cc (patch)
tree213e74f46592f0a1c029667cb339c80b0561e9ba /src/soc/intel/cannonlake/bootblock
parent5395123b849da143d9621b67a6837defe9501acf (diff)
downloadcoreboot-33ff4cc137e501b14859bc67cc7e85dd60a863cc.tar.xz
soc/intel/cannonlake: Refactor pch_early_init() code
This patch keeps required pch_early_init() function like ABASE programming, GPE and RTC init into bootblock and moves remaining functions like TCO configuration and SMBus init into romstage/pch.c in order to maintain only required chipset programming for bootblock and verstage. Rename the pch_init function to bootblock_pch_init and romstage_pch_init according to the stage it is defined in. TEST=Able to build and boot hatch successfully. Change-Id: Idf7b04edc3fce147f7857561ce7d5b0cd05f43fe Signed-off-by: Usha P <usha.p@intel.com> Reviewed-on: https://review.coreboot.org/c/coreboot/+/37308 Tested-by: build bot (Jenkins) <no-reply@coreboot.org> Reviewed-by: Subrata Banik <subrata.banik@intel.com>
Diffstat (limited to 'src/soc/intel/cannonlake/bootblock')
-rw-r--r--src/soc/intel/cannonlake/bootblock/bootblock.c2
-rw-r--r--src/soc/intel/cannonlake/bootblock/pch.c13
2 files changed, 3 insertions, 12 deletions
diff --git a/src/soc/intel/cannonlake/bootblock/bootblock.c b/src/soc/intel/cannonlake/bootblock/bootblock.c
index 6a6dd8be25..4cc15fca46 100644
--- a/src/soc/intel/cannonlake/bootblock/bootblock.c
+++ b/src/soc/intel/cannonlake/bootblock/bootblock.c
@@ -74,5 +74,5 @@ void bootblock_soc_init(void)
*/
gpi_clear_int_cfg();
report_platform_info();
- pch_early_init();
+ bootblock_pch_init();
}
diff --git a/src/soc/intel/cannonlake/bootblock/pch.c b/src/soc/intel/cannonlake/bootblock/pch.c
index 9ad7e86178..a6e9f9db52 100644
--- a/src/soc/intel/cannonlake/bootblock/pch.c
+++ b/src/soc/intel/cannonlake/bootblock/pch.c
@@ -2,7 +2,7 @@
* This file is part of the coreboot project.
*
* Copyright (C) 2014 Google Inc.
- * Copyright (C) 2017-2018 Intel Corporation.
+ * Copyright (C) 2017-2019 Intel Corporation.
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
@@ -25,8 +25,6 @@
#include <intelblocks/pcr.h>
#include <intelblocks/pmclib.h>
#include <intelblocks/rtc.h>
-#include <intelblocks/smbus.h>
-#include <intelblocks/tco.h>
#include <soc/bootblock.h>
#include <soc/gpio.h>
#include <soc/iomap.h>
@@ -36,7 +34,6 @@
#include <soc/pci_devs.h>
#include <soc/pcr_ids.h>
#include <soc/pm.h>
-#include <soc/smbus.h>
#define PCR_PSF3_TO_SHDW_PMC_REG_BASE_CNP_LP 0x1400
#define PCR_PSF3_TO_SHDW_PMC_REG_BASE_CNP_H 0x0980
@@ -181,7 +178,7 @@ void pch_early_iorange_init(void)
pch_enable_lpc();
}
-void pch_early_init(void)
+void bootblock_pch_init(void)
{
/*
* Enabling ABASE for accessing PM1_STS, PM1_EN, PM1_CNT,
@@ -189,12 +186,6 @@ void pch_early_init(void)
*/
soc_config_acpibase();
- /* Programming TCO_BASE_ADDRESS and TCO Timer Halt */
- tco_configure();
-
- /* Program SMBUS_BASE_ADDRESS and Enable it */
- smbus_common_init();
-
/* Set up GPE configuration */
pmc_gpe_init();