81 if (
CONFIG(NORTHBRIDGE_INTEL_SUBTYPE_I945GC))
132 if (
CONFIG(NORTHBRIDGE_INTEL_SUBTYPE_I945GM))
133 printk(
BIOS_ERR,
"coreboot is compiled for the wrong chipset.\n");
142 printk(
BIOS_INFO,
"Warning: i945 silicon revision A0 might not work correctly.\n");
176 reg8 = *(
volatile u8 *)0xfed40000;
177 }
while (!(reg8 & 0x80));
204 if (
CONFIG(NORTHBRIDGE_INTEL_SUBTYPE_I945GC)) {
219 reg32 &= ~(0x7f << 16);
220 reg32 |= (0x0a << 16);
223 if (
CONFIG(NORTHBRIDGE_INTEL_SUBTYPE_I945GC)) {
318 reg32 &= ~((0x7f << 1) | (7 << 17) | (7 << 24));
319 reg32 |= (0x40 << 1) | (4 << 17) | (1 << 24) | (1 << 31);
329 int activate_aspm = 1;
391 reg32 &= ~(0xff << 2);
392 reg32 |= (0xaa << 2);
415 reg32 &= ~((1 << 11) | (1 << 10));
419 reg32 &= ~(0xff << 12);
420 reg32 |= (0x0d << 12);
426 reg32 &= ~(0x3 << 26);
427 reg32 |= (0x02 << 26);
480 printk(
BIOS_INFO,
"DMI link requires A1 stepping workaround. Rebooting.\n");
497 u8 tmp_secondary = 0x0a;
518 goto disable_pciexpress_x16_link;
519 reg16 |= (1 << 4) | (1 << 0);
549 if (reg32 != 0x00000000 && reg32 != 0xffffffff) {
551 reg32 & 0xffff, reg32 >> 16);
569 if (reg32 != 0x00000000 && reg32 != 0xffffffff) {
571 reg32 & 0xffff, reg32 >> 16);
575 goto disable_pciexpress_x16_link;
591 else if (reg16 == 16)
598 if (reg32 == 0x030000) {
653 static const u32 reglist[] = {
654 0xec0, 0xed4, 0xee8, 0xefc, 0xf10, 0xf24, 0xf38, 0xf4c,
655 0xf60, 0xf74, 0xf88, 0xf9c, 0xfb0, 0xfc4, 0xfd8, 0xfec
675 disable_pciexpress_x16_link:
691 (reg32 & 0x000f0000) && --timeout;)
795 RCBA32(0x2010) |= (1 << 10);
800 int cbmem_was_initted;
819 if (
CONFIG(NORTHBRIDGE_INTEL_SUBTYPE_I945GM))
824 if (
CONFIG(DEBUG_RAM_SETUP))
int cbmem_recovery(int s3resume)
#define printk(level,...)
static __always_inline uint8_t mchbar_read8(const uintptr_t offset)
#define mchbar_setbits32(addr, set)
static __always_inline void mchbar_write16(const uintptr_t offset, const uint16_t value)
static __always_inline uint32_t epbar_read32(const uintptr_t offset)
#define dmibar_clrbits32(addr, clear)
static __always_inline void mchbar_write32(const uintptr_t offset, const uint32_t value)
static __always_inline uint32_t dmibar_read32(const uintptr_t offset)
static __always_inline void dmibar_write32(const uintptr_t offset, const uint32_t value)
static __always_inline uint16_t dmibar_read16(const uintptr_t offset)
#define mchbar_clrbits16(addr, clear)
#define dmibar_setbits32(addr, set)
static __always_inline uint32_t mchbar_read32(const uintptr_t offset)
static __always_inline uint16_t epbar_read16(const uintptr_t offset)
static __always_inline uint8_t dmibar_read8(const uintptr_t offset)
#define mchbar_setbits16(addr, set)
static __always_inline void epbar_write32(const uintptr_t offset, const uint32_t value)
#define epbar_setbits32(addr, set)
void sdram_dump_mchbar_registers(void)
static __always_inline void pci_or_config32(const struct device *dev, u16 reg, u32 ormask)
static __always_inline void pci_write_config32(const struct device *dev, u16 reg, u32 val)
static __always_inline void pci_and_config16(const struct device *dev, u16 reg, u16 andmask)
static __always_inline void pci_update_config32(const struct device *dev, u16 reg, u32 mask, u32 or)
static __always_inline void pci_update_config8(const struct device *dev, u16 reg, u8 mask, u8 or)
static __always_inline void pci_or_config16(const struct device *dev, u16 reg, u16 ormask)
static __always_inline u16 pci_read_config16(const struct device *dev, u16 reg)
static __always_inline u32 pci_read_config32(const struct device *dev, u16 reg)
static __always_inline u8 pci_read_config8(const struct device *dev, u16 reg)
static __always_inline void pci_write_config16(const struct device *dev, u16 reg, u16 val)
static __always_inline void pci_and_config32(const struct device *dev, u16 reg, u32 andmask)
static __always_inline void pci_write_config8(const struct device *dev, u16 reg, u8 val)
#define BIOS_INFO
BIOS_INFO - Expected events.
#define BIOS_DEBUG
BIOS_DEBUG - Verbose output.
#define BIOS_ERR
BIOS_ERR - System in incomplete state.
static void ich7_setup_root_complex_topology(void)
static void i945_setup_egress_port(void)
void i945_early_initialization(void)
static void i945_setup_dmi_rcrb(void)
static void ich7_setup_pci_express(void)
static void i945_setup_pci_express_x16(void)
static void i945_prepare_resume(int s3resume)
static void i945_detect_chipset(void)
static void i945m_detect_chipset(void)
void i945_late_initialization(int s3resume)
static void i945_setup_root_complex_topology(void)
static void ich7_setup_dmi_rcrb(void)
static void i945_setup_bars(void)
int i945_silicon_revision(void)
unsigned int get_uint_option(const char *name, const unsigned int fallback)
#define PCI_CLASS_REVISION
void pci_s_deassert_secondary_reset(pci_devfn_t p2p_bridge)
void pci_s_assert_secondary_reset(pci_devfn_t p2p_bridge)
void pci_s_bridge_set_secondary(pci_devfn_t p2p_bridge, u8 secondary)
#define PCI_DEV(SEGBUS, DEV, FN)
int romstage_handoff_init(int is_s3_resume)