summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/northbridge/intel/haswell/do_raminit_frag.c14
-rw-r--r--src/northbridge/intel/haswell/mrc.asm26
2 files changed, 14 insertions, 26 deletions
diff --git a/src/northbridge/intel/haswell/do_raminit_frag.c b/src/northbridge/intel/haswell/do_raminit_frag.c
index 8287b8d7c2..214edaf823 100644
--- a/src/northbridge/intel/haswell/do_raminit_frag.c
+++ b/src/northbridge/intel/haswell/do_raminit_frag.c
@@ -553,13 +553,19 @@ bar_update32(void *bar, uint32_t offset, uint32_t andv, uint32_t orv)
write32(bar + offset, tmp);
}
-void frag_fffa49a0(void *dmibar, uint8_t t);
-void frag_fffa49a0(void *dmibar, uint8_t t)
+void frag_fffa4962(void *dmibar, u32 v0, u8 t);
+void frag_fffa4962(void *dmibar, u32 v0, u8 t)
{
- printk(BIOS_DEBUG, "frag_fffa49a0: bar is 0x%08x\n", (uint32_t)dmibar);
+ printk(BIOS_DEBUG, "frag_fffa4962: bar is 0x%08x\n", (uint32_t)dmibar);
- u32 v = (t & 1)? 0x40: 0;
if (dmibar) {
+ bar_update32(dmibar, 0xc28, 0xffffffe0, v0);
+ } else {
+ pci_update_config32(PCI_DEV(0, 0, 0), 0xc28, 0xffffffe0, v0);
+ }
+
+ u32 v = (t & 1)? 0x40: 0;
+ if (!dmibar) {
pci_update_config16(PCI_DEV(0, 1, 0), 0xc38, 0xffbf, v);
pci_update_config16(PCI_DEV(0, 1, 1), 0xc38, 0xffbf, v);
pci_update_config16(PCI_DEV(0, 1, 2), 0xc38, 0xffbf, v);
diff --git a/src/northbridge/intel/haswell/mrc.asm b/src/northbridge/intel/haswell/mrc.asm
index f758c300a4..8ea9fc850b 100644
--- a/src/northbridge/intel/haswell/mrc.asm
+++ b/src/northbridge/intel/haswell/mrc.asm
@@ -152,7 +152,7 @@ extern io_fffa44ad
extern io_fffa4575
extern io_fffa45f1
extern io_fffa476b
-extern frag_fffa49a0
+extern frag_fffa4962
extern load_usb
extern fill_pei_ram_data
extern fill_ram_param
@@ -2948,29 +2948,11 @@ mov dword [edx + 0xc24], eax
jmp near loc_fffa5628 ; jmp 0xfffa5628
loc_fffa4962:
-test ebx, ebx
-je short loc_fffa4979 ; je 0xfffa4979
-mov eax, dword [ebx + 0xc28]
-and eax, 0xffffffe0
-or eax, edx
-mov dword [ebx + 0xc28], eax
-jmp short loc_fffa49a0
-
-loc_fffa4979:
-mov ecx, dword [0xf0000060]
-mov eax, dword [0xf0000060]
-and eax, 0xfc000000
-and ecx, 0xfc000000
-mov eax, dword [eax + 0xc28]
-and eax, 0xffffffe0
-or eax, edx
-mov dword [ecx + 0xc28], eax
-
-loc_fffa49a0:
push dword [ebp - 0x658]
+push edx
push ebx
-call frag_fffa49a0
-add esp, 8
+call frag_fffa4962
+add esp, 12
mov ecx, dword [ebp - 0x660]
mov eax, dword [ecx + 0xd]