![background image](http://html1.mh-extra.com/html/ibm/thinkpad-560z/thinkpad-560z_supplementary-manual_3424226120.webp)
@@:
;
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