search for: sectorsize_lg2

Displaying 1 result from an estimated 1 matches for "sectorsize_lg2".

2007 Aug 28
2
memdisk patch
...cmp dword [es:si+12],0 ; LBA too large? jne .overrun movzx ecx, word [es:si+2] ; Sectors to transfer - mov edi,[es:si+8] ; Starting sector - mov eax,edi + mov esi,[es:si+8] ; Starting sector + mov eax,esi add eax,ecx jc .overrun cmp eax,[DiskSize] ja .overrun shl ecx,SECTORSIZE_LG2-2 ; Convert to dwords - shl edi,SECTORSIZE_LG2 ; Convert to an offset - add edi,[DiskBuf] + shl esi,SECTORSIZE_LG2 ; Convert to an offset + add esi,[DiskBuf] + mov edi,ebx pop es ret