mirror of
https://github.com/reactos/reactos.git
synced 2025-01-03 21:09:19 +00:00
[FREELDR/AMD64]
Save parameter registers (rcx, rdx) before calling CallRealMode. Patch by andy-123, applied to a secondary location by me. CORE-10511 #resolve #comment Thanks. I added the same fix to PnpBiosGet below. svn path=/trunk/; revision=70407
This commit is contained in:
parent
03e066f2f1
commit
cf2573f733
1 changed files with 14 additions and 0 deletions
|
@ -104,10 +104,18 @@ pnp_not_found:
|
|||
PUBLIC PnpBiosGetDeviceNodeCount
|
||||
PnpBiosGetDeviceNodeCount:
|
||||
|
||||
/* Save param-regs */
|
||||
push rcx
|
||||
push rdx
|
||||
|
||||
/* Call the real mode function */
|
||||
mov bx, FNID_PnpBiosGetDeviceNodeCount
|
||||
call CallRealMode
|
||||
|
||||
/* Restore param-regs */
|
||||
pop rdx
|
||||
pop rcx
|
||||
|
||||
xor eax, eax
|
||||
mov ax, [BSS_PnpNodeSize]
|
||||
mov [rcx], eax
|
||||
|
@ -140,10 +148,16 @@ PnpBiosGetDeviceNode:
|
|||
and eax, HEX(0f)
|
||||
mov word ptr [BSS_PnpBiosBufferOffset], ax
|
||||
|
||||
/* Save rcx */
|
||||
push rcx
|
||||
|
||||
/* Call the real mode function */
|
||||
mov bx, FNID_PnpBiosGetDeviceNode
|
||||
call CallRealMode
|
||||
|
||||
/* Restore rcx */
|
||||
pop rcx
|
||||
|
||||
/* update node number */
|
||||
mov al, byte ptr [BSS_PnpNodeNumber]
|
||||
mov [rcx], al
|
||||
|
|
Loading…
Reference in a new issue