Lenovo ThinkPad 560E TP 560Z Technical Reference Manual - Page 120
Checksum is OK?, Restore Direction flags
View all Lenovo ThinkPad 560E manuals
Add to My Manuals
Save this manual to your list of manuals |
Page 120 highlights
@@: ; mov ; pushf cld mov xor movzx @@: lodsb add loop popf cmp cmc FindSmapiFin: pop pop pop pop ret FindSmapi Find Smapi Head dx, BIOS_SEG Calculate Checksum.. next. ; Save Direction flag ; Clear it si, bx ax, ax cx,byte ptr ds:[bx].@SMBHDR_LEN ah, al @b ah, 1 ; Restore Direction flags ; Checksum is OK? ds si cx eax Endp A-58 ThinkPad 560Z SMAPI BIOS
@@:
;
Find Smapi Head
mov
dx, BIOS_SEG
;
Calculate Checksum.. next.
pushf
; Save Direction flag
cld
; Clear it
mov
si, bx
xor
ax, ax
movzx
cx,byte ptr ds:
[
bx
]
.@SMBHDR_LEN
@@:
lodsb
add
ah, al
loop
@b
popf
; Restore Direction flags
cmp
ah, 1
; Checksum is OK?
cmc
FindSmapiFin:
pop
ds
pop
si
pop
cx
pop
eax
ret
FindSmapi
Endp
A-58
ThinkPad 560Z SMAPI BIOS