|
probe_loop:
lodsb # 把si中的值放入al中,si每次地址加1
cbtw # extend to word 将al扩展成ax
movw %ax, sectors
cmpw $disksizes+4, %si
jae got_sectors # If all else fails, try 9
xchgw %cx, %ax # %cx = track and sector,将ax放入cx中,作为int0x13的参数
xorw %dx, %dx # drive 0, head 0
movw $0x0200, %bx # address = 512, in INITSEG (%es = %cs)
movw $0x0201, %ax # service 2, 1 sector ,INT 13,2 - Read Disk Sectors
int $0x13
jc probe_loop # try next value CF=1说明读扇区失败
got_sectors: # 读指针位置并写loading字符到屏幕上
movb $0x03, %ah # read cursor pos,INT 10,3 - Read Cursor Position and Size
xorb %bh, %bh
int $0x10
请教高人,这段代码中的
cmpw $disksizes+4, %si
这一句有什么意义? |
|