diff options
Diffstat (limited to 'src')
-rw-r--r-- | src/northbridge/intel/haswell/fffcbf28.asm | 20 | ||||
-rw-r--r-- | src/northbridge/intel/haswell/mrc.asm | 41 | ||||
-rw-r--r-- | src/northbridge/intel/haswell/mrc_misc.c | 15 | ||||
-rw-r--r-- | src/northbridge/intel/haswell/mrc_misc.h | 4 |
4 files changed, 44 insertions, 36 deletions
diff --git a/src/northbridge/intel/haswell/fffcbf28.asm b/src/northbridge/intel/haswell/fffcbf28.asm index ce8479be18..54e79a1d4f 100644 --- a/src/northbridge/intel/haswell/fffcbf28.asm +++ b/src/northbridge/intel/haswell/fffcbf28.asm @@ -4,11 +4,11 @@ extern MrcFastBootPermitted extern MrcRestoreNonTrainingValues extern MrcMcCapabilityPreSpd extern MrcSpdProcessing -extern fcn_fffa782c -extern fcn_fffa7a1c -extern fcn_fffa56ac -extern fcn_fffc7720 -extern fcn_fffbd7da +extern MrcSetOverrides +extern MrcMcCapability +extern MrcMcConfiguration +extern MrcSetMemoryMap +extern MrcResetSequence extern fcn_fffb8c0b extern fcn_fffb3f6c extern fcn_fffab4c0 @@ -69,19 +69,19 @@ dd 0xff3f0000 dd MrcSpdProcessing dd 0x0003dd20 dd 0xff310000 -dd fcn_fffa782c +dd MrcSetOverrides dd 0x0006dd21 dd 0xff3f0000 -dd fcn_fffa7a1c +dd MrcMcCapability dd 0x0007dd22 dd 0xff3f0000 -dd fcn_fffa56ac +dd MrcMcConfiguration dd 0x0008dd23 dd 0xff3f0000 -dd fcn_fffc7720 +dd MrcSetMemoryMap dd 0x0009dd24 dd 0xff3f0000 -dd fcn_fffbd7da +dd MrcResetSequence dd 0x000add26 dd 0xff330000 dd fcn_fffb8c0b diff --git a/src/northbridge/intel/haswell/mrc.asm b/src/northbridge/intel/haswell/mrc.asm index d6b890f952..7d6ab291b7 100644 --- a/src/northbridge/intel/haswell/mrc.asm +++ b/src/northbridge/intel/haswell/mrc.asm @@ -68,7 +68,7 @@ global ref_fffcd4e4 extern locate_hob extern fcn_fffa1d20 -global fcn_fffa56ac +global MrcMcConfiguration ;fcn_fffa56ac global fcn_fffa7e71 global fcn_fffa7ecd global fcn_fffa8fb6 @@ -111,7 +111,7 @@ global fcn_fffba408 global fcn_fffbb819 global fcn_fffbd4c2 global fcn_fffbd5ac -global fcn_fffbd7da +global MrcResetSequence extern fcn_fffc6438 extern mrc_get_timestamp @@ -2246,7 +2246,7 @@ pop edi pop ebp ret -fcn_fffa56ac: ; not directly referenced +MrcMcConfiguration: push ebp mov ecx, 9 mov ebp, esp @@ -9088,7 +9088,7 @@ cmp dword [ebp - 0x36c], 0 je short loc_fffac104 ; je 0xfffac104 sub esp, 0xc push dword [ebp + 8] -call fcn_fffbd7da ; call 0xfffbd7da +call MrcResetSequence ; call 0xfffbd7da add esp, 0x10 jmp short loc_fffac104 ; jmp 0xfffac104 @@ -9873,7 +9873,7 @@ or eax, edx mov edx, dword [ebx + 0x103f] mov dword [edx + 0x390c], eax push ebx -call fcn_fffbd7da ; call 0xfffbd7da +call MrcResetSequence ; call 0xfffbd7da mov al, byte [ebp - 0x358] add esp, 0x10 movzx esi, byte [ebp - 0x358] @@ -10414,7 +10414,7 @@ push 0 call fcn_fffc83fc ; call 0xfffc83fc add esp, 0x14 push dword [ebp + 8] -call fcn_fffbd7da ; call 0xfffbd7da +call MrcResetSequence ; call 0xfffbd7da mov dword [ebp - 0x358], eax add esp, 0x10 jmp short loc_fffad341 ; jmp 0xfffad341 @@ -10533,7 +10533,7 @@ jne short loc_fffad3c5 ; jne 0xfffad3c5 sub esp, 0xc xor si, si push ebx -call fcn_fffbd7da ; call 0xfffbd7da +call MrcResetSequence ; call 0xfffbd7da add esp, 0x10 mov byte [ebp - 0x29], 0 @@ -10645,7 +10645,7 @@ push 0 push 0 call fcn_fffafeda ; call 0xfffafeda mov dword [esp], ebx -call fcn_fffbd7da ; call 0xfffbd7da +call MrcResetSequence ; call 0xfffbd7da add esp, 0x10 lea esp, [ebp - 0xc] pop ebx @@ -11380,7 +11380,7 @@ mov dword [eax + 0x4598], 0 loc_fffadd76: ; not directly referenced sub esp, 0xc push ebx -call fcn_fffbd7da ; call 0xfffbd7da +call MrcResetSequence ; call 0xfffbd7da jmp short loc_fffaddcc ; jmp 0xfffaddcc loc_fffadd81: ; not directly referenced @@ -11489,7 +11489,7 @@ push 0 call fcn_fffc0a00 ; call 0xfffc0a00 add esp, 0x14 push esi -call fcn_fffbd7da ; call 0xfffbd7da +call MrcResetSequence ; call 0xfffbd7da add esp, 0x10 cmp dword [esi + 0x297c], 2 jne short loc_fffadebe ; jne 0xfffadebe @@ -11530,7 +11530,7 @@ push eax mov eax, esi call fcn_fffafeda ; call 0xfffafeda mov dword [esp], esi -call fcn_fffbd7da ; call 0xfffbd7da +call MrcResetSequence ; call 0xfffbd7da add edi, dword [ebp - 0x2c] sub ebx, dword [ebp - 0x2c] lea edx, [esi + 0x2734] @@ -23865,7 +23865,7 @@ loc_fffb8316: ; not directly referenced sub esp, 0xc lea esi, [ebx + 0x2974] push ebx -call fcn_fffbd7da ; call 0xfffbd7da +call MrcResetSequence ; call 0xfffbd7da lea eax, [ebp - 0x158] mov dword [esp], eax push 0x36 @@ -23878,7 +23878,7 @@ push dword [ebp - 0x170] call fcn_fffc0a00 ; call 0xfffc0a00 add esp, 0x14 push ebx -call fcn_fffbd7da ; call 0xfffbd7da +call MrcResetSequence ; call 0xfffbd7da mov dword [ebp - 0x184], eax lea edx, [ebp - 0x148] mov eax, ebx @@ -30009,7 +30009,8 @@ pop edi pop ebp ret -fcn_fffbd7da: ; not directly referenced +; fcn_fffbd7da +MrcResetSequence: push ebp mov ebp, esp push edi @@ -33925,7 +33926,7 @@ push 0 push esi call fcn_fffafeda ; call 0xfffafeda mov dword [esp], edi -call fcn_fffbd7da ; call 0xfffbd7da +call MrcResetSequence ; call 0xfffbd7da add esp, 0x10 jmp short loc_fffc0de0 ; jmp 0xfffc0de0 @@ -34555,7 +34556,7 @@ add esp, 0x10 loc_fffc1459: ; not directly referenced sub esp, 0xc push edi -call fcn_fffbd7da ; call 0xfffbd7da +call MrcResetSequence ; call 0xfffbd7da add esp, 0x10 cmp dword [ebp + 0x20], 0 je short loc_fffc148d ; je 0xfffc148d @@ -34849,7 +34850,7 @@ add esp, 0x10 loc_fffc176a: ; not directly referenced sub esp, 0xc push edi -call fcn_fffbd7da ; call 0xfffbd7da +call MrcResetSequence ; call 0xfffbd7da add esp, 0x10 lea esp, [ebp - 0xc] pop ebx @@ -34918,7 +34919,7 @@ cmp esi, 2 jne short loc_fffc17e9 ; jne 0xfffc17e9 sub esp, 0xc push edi -call fcn_fffbd7da ; call 0xfffbd7da +call MrcResetSequence ; call 0xfffbd7da add esp, 0xc lea eax, [ebp - 0x27] push 0 @@ -37825,7 +37826,7 @@ pop ebx pop esi pop edi pop ebp -jmp near fcn_fffbd7da ; jmp 0xfffbd7da +jmp near MrcResetSequence ; jmp 0xfffbd7da fcn_fffc46d6: ; not directly referenced push ebp @@ -37953,7 +37954,7 @@ cmp dword [ebp - 0x1c], 2 jne loc_fffc4710 ; jne 0xfffc4710 sub esp, 0xc push dword [ebp - 0x20] -call fcn_fffbd7da ; call 0xfffbd7da +call MrcResetSequence ; call 0xfffbd7da lea esp, [ebp - 0xc] pop ebx pop esi diff --git a/src/northbridge/intel/haswell/mrc_misc.c b/src/northbridge/intel/haswell/mrc_misc.c index 04707677cd..7f2b177321 100644 --- a/src/northbridge/intel/haswell/mrc_misc.c +++ b/src/northbridge/intel/haswell/mrc_misc.c @@ -140,8 +140,9 @@ int MrcFastBootPermitted(void *ram_data) return 0; } -int fcn_fffa782c(void *ram_data); -int fcn_fffa782c(void *ram_data) +// fffa782c +int MrcSetOverrides(void *ram_data); +int MrcSetOverrides(void *ram_data) { u32 reg; u16 v1, v2; @@ -199,6 +200,7 @@ static const uint8_t gdata2[12] = { 0xa1, 0x0c, 0xa1, 0x00, 0x08, 0x0d, 0xef, 0x00, 0x1e, 0x0a, 0xad, 0x00 }; +// fcn_fffb8c0b int fcn_fffb8c0b(void *ram_data); int fcn_fffb8c0b(void *ram_data) { @@ -1253,7 +1255,8 @@ int MrcSpdProcessing(void *ramdata) } while (true); } -int fcn_fffa7a1c(void *ramdata) +// fffa7a1c +int MrcMcCapability(void *ramdata) { void *iVar2; uint32_t uVar3; @@ -1455,7 +1458,8 @@ int fcn_fffa7a1c(void *ramdata) } while (true); } -int fcn_fffc7720(void *ramdata) +// fffc7720 +int MrcSetMemoryMap(void *ramdata) { uint32_t uVar1; uint32_t uVar2; @@ -1471,6 +1475,7 @@ int fcn_fffc7720(void *ramdata) PRINT_FUNC; + // inline function: MrcTotalMemory *(uint32_t *)(ramdata + 0x1700) = 0; for (int i = 0; i < 2; i++) { ptr0 = (ramdata + i * 0x1347 + 0x297c); @@ -1490,6 +1495,8 @@ int fcn_fffc7720(void *ramdata) *(int *)(ramdata + 0x1700) = *(int *)(ramdata + 0x1700) + tmp; } } + //////////////////////////////// + uVar2 = *(uint32_t*)(ramdata + 0x1700); uVar8 = *(uint32_t*)(ramdata + 0x1053); uVar1 = uVar2 - *(int *)(ramdata + 0x104f); diff --git a/src/northbridge/intel/haswell/mrc_misc.h b/src/northbridge/intel/haswell/mrc_misc.h index 37ca1ec67d..85a9e89bb2 100644 --- a/src/northbridge/intel/haswell/mrc_misc.h +++ b/src/northbridge/intel/haswell/mrc_misc.h @@ -54,8 +54,8 @@ DECL_CB1(fcn_fffb7acc); DECL_CB1(fcn_fffb7866); int MrcSpdProcessing(void *ramdata); -int fcn_fffa7a1c(void *ramdata); -int fcn_fffc7720(void *ramdata); +int MrcMcCapability(void *ramdata); +int MrcSetMemoryMap(void *ramdata); int MRCABI wait_5030(void *ramdata); int MRCABI wait_5084(void *ramdata); int fcn_fffa7e78(void *ramdata); |