Changeset 106
- Timestamp:
- Apr 8, 2017, 12:27:03 AM (8 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/bootcode/special/fat16.asm
r57 r106 42 42 mov edx, dptr ds:[si+LocIPT_AbsoluteBegin] 43 43 mov FAT16_AbsPartitionBegin, edx 44 mov DriveIO_DAP_Absolute, edx; Read in Boot-Record of partition45 mov DriveIO_DAP_NumBlocks, 1; 1 Sector to load44 mov INT13X_DAP_Absolute, edx ; Read in Boot-Record of partition 45 mov INT13X_DAP_NumBlocks, 1 ; 1 Sector to load 46 46 mov FAT16_FATCacheSector, 255 ; Sector 255 - So nothing cached 47 47 mov ax, ds 48 48 shl eax, 16 49 49 mov ax, offset FAT16_FATCache 50 mov DriveIO_DAP_Transfer, eax; Transfer to FAT-Cache Area50 mov INT13X_DAP_Transfer, eax ; Transfer to FAT-Cache Area 51 51 call FAT16_LoadSectors 52 52 mov al, bptr [FAT16_FATCache+13] … … 79 79 mov ax, 9000h 80 80 shl eax, 16 ; 9000:0 -> Space for Root 81 mov DriveIO_DAP_Transfer, eax; Transfer to that segment81 mov INT13X_DAP_Transfer, eax ; Transfer to that segment 82 82 mov eax, FAT16_AbsRootBegin 83 mov DriveIO_DAP_Absolute, eax; Read in Root-Entries...83 mov INT13X_DAP_Absolute, eax ; Read in Root-Entries... 84 84 mov ax, FAT16_NumOfRootEntries 85 85 shr ax, 4 ; NumOfRootEntries/16 86 mov DriveIO_DAP_NumBlocks, ax; -> Sectors of Root-Entries86 mov INT13X_DAP_NumBlocks, ax ; -> Sectors of Root-Entries 87 87 call FAT16_LoadSectors ; DONE. 88 88 ret … … 134 134 shl eax, 16 135 135 mov ax, di 136 mov DriveIO_DAP_Transfer, eax; Read to 9000:DI136 mov INT13X_DAP_Transfer, eax ; Read to 9000:DI 137 137 mov ax, dx 138 138 sub ax, 2 ; Everything starts at Cluster 2 … … 145 145 mov dx, ax ; EDX - Relative to Cluster-Start 146 146 add edx, FAT16_AbsClusterBegin ; EDX - Absolute Sector Count 147 mov DriveIO_DAP_Absolute, edx148 mov DriveIO_DAP_NumBlocks, bx; Get a whole cluster147 mov INT13X_DAP_Absolute, edx 148 mov INT13X_DAP_NumBlocks, bx ; Get a whole cluster 149 149 call FAT16_LoadSectors ; DONE. 150 150 pop dx … … 167 167 shl eax, 16 168 168 mov ax, offset FAT16_FATCache 169 mov DriveIO_DAP_Transfer, eax; Transfer to FAT-Cache Area169 mov INT13X_DAP_Transfer, eax ; Transfer to FAT-Cache Area 170 170 movzx edx, dx 171 171 mov eax, FAT16_AbsFATBegin 172 172 add eax, edx 173 mov DriveIO_DAP_Absolute, eax; Read in Boot-Record of partition174 mov DriveIO_DAP_NumBlocks, 1; 1 Sector to load173 mov INT13X_DAP_Absolute, eax ; Read in Boot-Record of partition 174 mov INT13X_DAP_NumBlocks, 1 ; 1 Sector to load 175 175 call FAT16_LoadSectors ; DONE. 176 176 FAT16RC_GotFATsectorAlready: … … 184 184 push cs 185 185 pop ds 186 mov si, offset DriveIO_DAP186 mov si, offset INT13X_DAP 187 187 mov dl, ds:[FAT16_Drive] 188 188 mov ah, 42h ; Extended Read … … 192 192 193 193 FAT16LS_Success: 194 movzx eax, wptr ds:[ DriveIO_DAP_NumBlocks]195 add dptr ds:[ DriveIO_DAP_Absolute+0], eax; Adjust Absolute Offset194 movzx eax, wptr ds:[INT13X_DAP_NumBlocks] 195 add dptr ds:[INT13X_DAP_Absolute+0], eax ; Adjust Absolute Offset 196 196 ret 197 197 FAT16_LoadSectors EndP
Note:
See TracChangeset
for help on using the changeset viewer.