coreboot
coreboot is an Open Source project aimed at replacing the proprietary BIOS found in most computers.
finalize.c
Go to the documentation of this file.
1 /* SPDX-License-Identifier: GPL-2.0-only */
2 
3 #include <device/pci_ops.h>
4 #include "sandybridge.h"
5 
7 {
20 
21  mchbar_setbits32(PAVP_MSG, 1 << 0); /* PAVP */
22  mchbar_setbits32(SAPMCTL, 1 << 31); /* SA PM */
23  mchbar_setbits32(UMAGFXCTL, 1 << 0); /* UMA GFX */
24  mchbar_setbits32(VTDTRKLCK, 1 << 0); /* VTDTRK */
25  mchbar_setbits32(REQLIM, 1 << 31);
26  mchbar_setbits32(DMIVCLIM, 1 << 31);
27  mchbar_setbits32(CRDTLCK, 1 << 0);
28 
29  /* Memory Controller Lockdown */
30  mchbar_write8(MC_LOCK, 0x8f);
31 
32  /* Read+write the following */
36 }
#define REMAPLIMIT
Definition: e7505.h:36
#define REMAPBASE
Definition: e7505.h:35
#define mchbar_setbits32(addr, set)
Definition: fixed_bars.h:58
static __always_inline void mchbar_write8(const uintptr_t offset, const uint8_t value)
Definition: fixed_bars.h:26
#define GGC
Definition: host_bridge.h:9
#define TOLUD
Definition: host_bridge.h:61
#define TOUUD
Definition: host_bridge.h:57
#define BDSM
Definition: host_bridge.h:58
#define PAVPC
Definition: host_bridge.h:26
#define TOM
Definition: host_bridge.h:56
#define DPR
Definition: host_bridge.h:27
#define BGSM
Definition: host_bridge.h:59
#define SAPMCTL
Definition: mchbar.h:65
#define VDMBDFBARPAVP
Definition: mchbar.h:70
#define VDMBDFBARKVM
Definition: mchbar.h:69
#define REQLIM
Definition: mchbar.h:72
#define UMAGFXCTL
Definition: mchbar.h:68
#define HDAUDRID
Definition: mchbar.h:67
#define VTDTRKLCK
Definition: mchbar.h:71
#define DMIVCLIM
Definition: mchbar.h:73
#define MC_LOCK
Definition: mchbar.h:16
#define CRDTLCK
Definition: mchbar.h:74
static __always_inline void pci_or_config32(const struct device *dev, u16 reg, u32 ormask)
Definition: pci_ops.h:191
static __always_inline void pci_or_config16(const struct device *dev, u16 reg, u16 ormask)
Definition: pci_ops.h:180
void intel_sandybridge_finalize_smm(void)
Definition: finalize.c:6
#define MESEG_MASK
Definition: host_bridge.h:27
#define TSEGMB
Definition: host_bridge.h:48
#define MELCK
Definition: host_bridge.h:28
#define PAVP_MSG
Definition: mchbar.h:495
@ HOST_BRIDGE
Definition: reg_access.h:23