summaryrefslogtreecommitdiff
path: root/src/southbridge/intel/bd82x6x/finalize.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/southbridge/intel/bd82x6x/finalize.c')
-rw-r--r--src/southbridge/intel/bd82x6x/finalize.c10
1 files changed, 10 insertions, 0 deletions
diff --git a/src/southbridge/intel/bd82x6x/finalize.c b/src/southbridge/intel/bd82x6x/finalize.c
index 90932e16bc..c9296fd949 100644
--- a/src/southbridge/intel/bd82x6x/finalize.c
+++ b/src/southbridge/intel/bd82x6x/finalize.c
@@ -16,11 +16,15 @@
#include <arch/io.h>
#include <console/post_codes.h>
+#include <cpu/x86/smm.h>
#include "pch.h"
#include <spi-generic.h>
void intel_pch_finalize_smm(void)
{
+ u16 tco1_cnt;
+ u16 pmbase;
+
if (CONFIG_LOCK_SPI_ON_RESUME_RO || CONFIG_LOCK_SPI_ON_RESUME_NO_ACCESS) {
/* Copy flash regions from FREG0-4 to PR0-4
and enable write protection bit31 */
@@ -66,6 +70,12 @@ void intel_pch_finalize_smm(void)
pci_write_config32(PCI_DEV(0, 27, 0), 0x74,
pci_read_config32(PCI_DEV(0, 27, 0), 0x74));
+ /* TCO_Lock */
+ pmbase = smm_get_pmbase();
+ tco1_cnt = inw(pmbase + TCO1_CNT);
+ tco1_cnt |= TCO_LOCK;
+ outw(tco1_cnt, pmbase + TCO1_CNT);
+
/* Indicate finalize step with post code */
outb(POST_OS_BOOT, 0x80);
}