Changeset 44
- Timestamp:
- Apr 12, 2014, 12:05:10 AM (11 years ago)
- Location:
- trunk
- Files:
-
- 1 deleted
- 8 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/BOOTCODE/AIR-BOOT.ASM
r43 r44 358 358 359 359 ; ID String, Date (DD,MM,CC,YY), Version Number, Language ID 360 db 'AiRBOOT', 2 0h, 02h, 20h, 12h, 01h, 08h, TXT_LanguageID360 db 'AiRBOOT', 21h, 02h, 20h, 12h, 01h, 08h, TXT_LanguageID 361 361 362 362 ; Total Sectors Count. … … 1743 1743 PartitionPointers dw 52 dup (?) ; Maximum is 52 entries till now 1744 1744 PartitionPointerCount db ? ; Count of total Partition Pointers 1745 PartitionXref db partition_count dup (?) ; X-Reference Table 1745 PartitionXref db partition_count dup (?) ; X-Reference Table (holds new partnr, index is old part nr) 1746 1746 PartitionVolumeLetters db partition_count dup (?) ; Volume-Letters 1747 1747 ; 0 - no LVM support … … 1888 1888 ; (excluding the size word at the start). 1889 1889 1890 ott db 512 dup(?) 1891 1890 1892 eobss: 1891 1893 -
trunk/BOOTCODE/BLDDATE.ASM
r43 r44 1 1 IFDEF JWASM 2 BUILD_DATE db 'Build Date: 2 0 Feb 2012 at 19:30:00 [JWasm]',02 BUILD_DATE db 'Build Date: 21 Feb 2012 at 11:30:00 [JWasm]',0 3 3 ENDIF 4 4 IFDEF TASM 5 BUILD_DATE db 'Build Date: 2 0 Feb 2012 at 19:30:00 [Tasm]',05 BUILD_DATE db 'Build Date: 21 Feb 2012 at 11:30:00 [Tasm]',0 6 6 ENDIF -
trunk/BOOTCODE/REGULAR/AUXIO.ASM
r43 r44 71 71 72 72 73 ; In: AL - Single Char to send to Com Port74 ; DL - Port number; 0 for com1, etc.75 ; Destroyed: None76 AuxIO_PrintSingleChar Proc Near Uses ax es di77 nop78 AuxIO_PrintSingleChar EndP79 80 73 81 74 ; Print char to com-port (teletype style) -
trunk/BOOTCODE/REGULAR/CONV.ASM
r43 r44 168 168 ret 169 169 CONV_ToUpper EndP 170 171 172 ; 173 ; The bitfield functions below are used to pack values into arrays. 174 ; A buffer needs to be provided, a bitfield width and an index into the array. 175 ; These functions are used to pack the hidden partition-table which is 176 ; too small in the 45-partition version. 177 ; 178 179 180 ; IN: DL = Index to store bitfield 181 ; DH = Bitfield width (1-8) 182 ; BX = Pointer to bitfield array 183 ; OUT: AL = Value of requested bitfield 184 ; AH = Mask value 185 CONV_GetBitfieldValue Proc Near Uses bx cx dx 186 ; Normalize bit-width in DH. 187 dec dh ; Decrement bitfield width to mask invalid values. 188 and dh,07h ; Only 3 bits are significant to determine width. 189 mov cl,dh ; Save for later use to calculate mask. 190 inc dh ; Put back to normalized value. 191 192 ; Calculate corresponding AND-mask in CH. 193 mov ch,2 ; Were going to shift 2... 194 shl ch,cl ; to obtain the mask corresponding... 195 dec ch ; to the bitfield width. 196 197 ; Calculate byte-index. 198 mov al,dl ; Index in AL. 199 inc al ; Increment for calculations. 200 mul dh ; Multiply by bitfield width to get bits. 201 mov cl,8 ; Nr. of bits in a byte. 202 div cl ; Divide to get byte index. 203 204 ; Advance pointer to byte-index. 205 add bl,al ; Advance pointer... 206 adc bh,0 ; to byte index. 207 208 ; Determine if we need 1 or 2 byte access to extract the bitfield. 209 mov cl,ah ; Get remainder in CL. 210 sub cl,dh ; Substract bitfield width to get shift-count. 211 mov ah,0 ; Prepare upper=0 when field snaps no byte bound. 212 213 ; Jump if the bitfield does not span byte boundaries. 214 ; (Remainder - bitfield width >= 0) 215 jae CONV_GetBitfieldValue_nospan 216 217 ; Bit-field spans byte boundaries, so adjust shift-count 218 ; and use AH to get first part of bitfield. 219 add cl,8 ; Adjust shift-count. 220 mov ah,[bx] ; Get byte into AH instead. 221 dec bx ; Prepare pointer to load rest of bitfield. 222 CONV_GetBitfieldValue_nospan: 223 mov al,[bx] ; Load (rest of) bitfield into AL. 224 shr ax,cl ; Shift bitfield to the right. 225 mov ah,ch ; Get mask in AH. 226 and al,ah ; Mask value. 227 ret 228 CONV_GetBitfieldValue EndP 229 230 231 232 233 ; IN: AL = Value to store 234 ; DL = Index to store bitfield 235 ; DH = Bitfield width (1-8) 236 ; BX = Pointer to bitfield array 237 ; OUT: AL = Value of stored bitfield 238 ; AH = Mask value 239 CONV_SetBitfieldValue Proc Near Uses bx cx dx 240 ; Push value for later use. 241 push ax 242 243 ; Normalize bit-width in DH. 244 dec dh ; Decrement bitfield width to mask invalid values. 245 and dh,07h ; Only 3 bits are significant to determine width. 246 mov cl,dh ; Save for later use to calculate mask. 247 inc dh ; Put back to normalized value. 248 249 ; Calculate corresponding AND-mask in CH. 250 mov ch,2 ; Were going to shift 2... 251 shl ch,cl ; to obtain the mask corresponding... 252 dec ch ; to the bitfield width. 253 254 ; Calculate byte-index. 255 mov al,dl ; Index in AL. 256 inc al ; Increment for calculations. 257 mul dh ; Multiply by bitfield width to get bits. 258 mov cl,8 ; Nr. of bits in a byte. 259 div cl ; Divide to get byte index. 260 261 ; Advance pointer to byte-index. 262 add bl,al ; Advance pointer... 263 adc bh,0 ; to byte index. 264 265 ; Determine if we need 1 or 2 byte access to extract the bitfield. 266 mov cl,ah ; Get remainder in CL. 267 sub cl,dh ; Substract bitfield width to get shift-count. 268 269 ; Restore value. 270 pop ax 271 272 273 ; Jump if the bitfield does not span byte boundaries. 274 ; (Remainder - bitfield width >= 0) 275 jae CONV_SetBitfieldValue_nospan 276 277 ; Bit-field spans byte boundaries, so adjust shift-count 278 ; and use 16-bit access. 279 add cl,8 ; Adjust shift-count. 280 281 ; Merge the bitfield to the array. 282 push cx ; Save mask (CH) and shift-count (CL). 283 push ax ; Save value to store. 284 mov ah,0 ; Clear upper byte so we can shift in it. 285 and al,ch ; Mask value. 286 shl ax,cl ; Move the bitfield to the proper location. 287 mov dh,[bx] ; Get 1st part of bitfield from array. 288 dec bx ; Adjust pointer. 289 mov dl,[bx] ; Get 2nd part of bitfield from array. 290 push bx ; We need BX so save it. 291 mov bh,0 ; Clear upper byte so we can shift in it. 292 mov bl,ch ; Put mask in BL. 293 shl bx,cl ; Shift mask to proper location. 294 not bx ; Complement it to mask-out the required bitfield. 295 and dx,bx ; Mask-out the required bitfield. 296 pop bx ; Restore pointer. 297 or ax,dx ; Merge the bitfields. 298 mov [bx],al ; Store lower byte. 299 inc bx ; Adjust pointer. 300 mov [bx],ah ; Store upper byte. 301 pop ax ; Restore value. 302 pop cx ; Restore mask and shift-count. 303 304 ; Done. 305 jmp CONV_SetBitfieldValue_end 306 307 308 CONV_SetBitfieldValue_nospan: 309 ; Merge the bitfield to the array. 310 push cx ; Save mask (CH) and shift-count (CL). 311 push ax ; Save value to store. 312 and al,ch ; Mask value. 313 shl al,cl ; Move the bitfield to the proper location. 314 mov dl,[bx] ; Get byte containing bitfield. 315 shl ch,cl ; Shift mask to proper location. 316 not ch ; Complement it to mask-out the required bitfield. 317 and dl,ch ; Mask-out the required bitfield. 318 or al,dl ; Merge the bitfields. 319 mov [bx],al ; Store byte containing bitfield. 320 pop ax ; Restore value. 321 pop cx ; Restore mask and shift-count. 322 323 CONV_SetBitfieldValue_end: 324 mov ah,ch ; Get mask in AH. 325 and al,ah ; Mask value. 326 ret 327 CONV_SetBitfieldValue EndP 328 -
trunk/BOOTCODE/REGULAR/DEBUG.ASM
r43 r44 190 190 ;~ call DEBUG_DumpGeo 191 191 192 192 call DEBUG_CheckBitFields 193 193 194 194 popa … … 226 226 popf 227 227 ret 228 229 230 228 DEBUG_DumpBSSSectors EndP 231 229 232 230 233 231 DEBUG_CheckBitFields Proc 232 pushf 233 pusha 234 235 mov bx,offset [ott] 236 237 mov al,0 238 mov dl,0 239 mov dh,6 240 DEBUG_CheckBitFields_next_write: 241 call CONV_SetBitfieldValue 242 inc al 243 inc dl 244 ;~ cmp dl,70 245 jnz DEBUG_CheckBitFields_next_write 246 247 mov dl,0 248 mov dh,6 249 DEBUG_CheckBitFields_next_read: 250 mov al,dl 251 call AuxIO_TeletypeHexByte 252 mov al,':' 253 call AuxIO_Teletype 254 call CONV_GetBitfieldValue 255 call AuxIO_TeletypeHexWord 256 call AuxIO_TeletypeNL 257 inc dl 258 ;~ cmp dl,70 259 jnz DEBUG_CheckBitFields_next_read 260 261 popa 262 popf 263 ret 264 DEBUG_CheckBitFields EndP 234 265 235 266 ; … … 237 268 ; 238 269 DEBUG_Dump2 Proc Near 239 pushf240 pusha241 242 243 call AuxIO_TeletypeNL244 call AuxIO_TeletypeNL245 246 247 mov si,offset db_config248 call AuxIO_Print249 250 mov si,offset db_cfgparts251 call AuxIO_Print252 mov al,[CFG_Partitions]253 call AuxIO_TeletypeHexByte254 call AuxIO_TeletypeNL255 256 mov si,offset db_cfgpartdef257 call AuxIO_Print258 mov al,[CFG_PartDefault]259 call AuxIO_TeletypeHexByte260 call AuxIO_TeletypeNL261 262 mov si,offset db_cfgpartlast263 call AuxIO_Print264 mov al,[CFG_PartLast]265 call AuxIO_TeletypeHexByte266 call AuxIO_TeletypeNL267 call AuxIO_TeletypeNL268 269 270 271 mov si,offset db_vars272 call AuxIO_Print273 274 mov si,offset db_newpart275 call AuxIO_Print276 mov si,offset NewPartTable277 call AuxIO_DumpSector278 call AuxIO_TeletypeNL279 add si,512280 call AuxIO_DumpSector281 call AuxIO_TeletypeNL282 call AuxIO_TeletypeNL283 284 mov si,offset db_newhide285 call AuxIO_Print286 mov si,offset NewHidePartTable287 call AuxIO_DumpSector288 call AuxIO_TeletypeNL289 add si,512290 call AuxIO_DumpSector291 call AuxIO_TeletypeNL292 call AuxIO_TeletypeNL293 294 mov si,offset db_dletters295 call AuxIO_Print296 mov si,offset NewDriveLetters297 call AuxIO_DumpParagraph298 call AuxIO_TeletypeNL299 add si,16300 call AuxIO_DumpParagraph301 call AuxIO_TeletypeNL302 call AuxIO_TeletypeNL303 304 mov si,offset db_tmpec305 call AuxIO_Print306 mov si,offset TmpSector307 call AuxIO_DumpSector308 call AuxIO_TeletypeNL309 call AuxIO_TeletypeNL310 311 mov si,offset db_partsec312 call AuxIO_Print313 mov si,offset PartitionSector314 call AuxIO_DumpSector315 call AuxIO_TeletypeNL316 call AuxIO_TeletypeNL317 318 popa319 popf270 ;~ pushf 271 ;~ pusha 272 ;~ 273 ;~ 274 ;~ call AuxIO_TeletypeNL 275 ;~ call AuxIO_TeletypeNL 276 ;~ 277 ;~ 278 ;~ mov si,offset db_config 279 ;~ call AuxIO_Print 280 ;~ 281 ;~ mov si,offset db_cfgparts 282 ;~ call AuxIO_Print 283 ;~ mov al,[CFG_Partitions] 284 ;~ call AuxIO_TeletypeHexByte 285 ;~ call AuxIO_TeletypeNL 286 ;~ 287 ;~ mov si,offset db_cfgpartdef 288 ;~ call AuxIO_Print 289 ;~ mov al,[CFG_PartDefault] 290 ;~ call AuxIO_TeletypeHexByte 291 ;~ call AuxIO_TeletypeNL 292 ;~ 293 ;~ mov si,offset db_cfgpartlast 294 ;~ call AuxIO_Print 295 ;~ mov al,[CFG_PartLast] 296 ;~ call AuxIO_TeletypeHexByte 297 ;~ call AuxIO_TeletypeNL 298 ;~ call AuxIO_TeletypeNL 299 ;~ 300 ;~ 301 ;~ 302 ;~ mov si,offset db_vars 303 ;~ call AuxIO_Print 304 ;~ 305 ;~ mov si,offset db_newpart 306 ;~ call AuxIO_Print 307 ;~ mov si,offset NewPartTable 308 ;~ call AuxIO_DumpSector 309 ;~ call AuxIO_TeletypeNL 310 ;~ add si,512 311 ;~ call AuxIO_DumpSector 312 ;~ call AuxIO_TeletypeNL 313 ;~ call AuxIO_TeletypeNL 314 ;~ 315 ;~ mov si,offset db_newhide 316 ;~ call AuxIO_Print 317 ;~ mov si,offset NewHidePartTable 318 ;~ call AuxIO_DumpSector 319 ;~ call AuxIO_TeletypeNL 320 ;~ add si,512 321 ;~ call AuxIO_DumpSector 322 ;~ call AuxIO_TeletypeNL 323 ;~ call AuxIO_TeletypeNL 324 ;~ 325 ;~ mov si,offset db_dletters 326 ;~ call AuxIO_Print 327 ;~ mov si,offset NewDriveLetters 328 ;~ call AuxIO_DumpParagraph 329 ;~ call AuxIO_TeletypeNL 330 ;~ add si,16 331 ;~ call AuxIO_DumpParagraph 332 ;~ call AuxIO_TeletypeNL 333 ;~ call AuxIO_TeletypeNL 334 ;~ 335 ;~ mov si,offset db_tmpec 336 ;~ call AuxIO_Print 337 ;~ mov si,offset TmpSector 338 ;~ call AuxIO_DumpSector 339 ;~ call AuxIO_TeletypeNL 340 ;~ call AuxIO_TeletypeNL 341 ;~ 342 ;~ mov si,offset db_partsec 343 ;~ call AuxIO_Print 344 ;~ mov si,offset PartitionSector 345 ;~ call AuxIO_DumpSector 346 ;~ call AuxIO_TeletypeNL 347 ;~ call AuxIO_TeletypeNL 348 ;~ 349 ;~ popa 350 ;~ popf 320 351 ret 321 352 DEBUG_Dump2 EndP -
trunk/BOOTCODE/REGULAR/PARTMAIN.ASM
r43 r44 1622 1622 IFDEF AUX_DEBUG 1623 1623 call DEBUG_Dump2 1624 call DEBUG_DumpBSSSectors1624 ;~ call DEBUG_DumpBSSSectors 1625 1625 ENDIF 1626 1626 -
trunk/BOOTCODE/REGULAR/PARTSCAN.ASM
r43 r44 197 197 je PSSP_IgnorePartition 198 198 ; Ignore these partitions, because there are no real Partitions 199 call DEBUG_DumpBSSSectors199 ;~ call DEBUG_DumpBSSSectors 200 200 call PARTSCAN_CheckThisPartition 201 call DEBUG_DumpBSSSectors201 ;~ call DEBUG_DumpBSSSectors 202 202 PSSP_IgnorePartition: 203 203 ; Lscht das Boot-Able Flag... -
trunk/BOOTCODE/REGULAR/STD_TEXT.ASM
r43 r44 42 42 ;Copyright db ' AiR-BOOT v1.0.8 - (c) 2012 M. Kiewitz <<Release Candidate 1>> (bld: 20120124)', 0 43 43 ;Copyright db ' AiR-BOOT v1.0.8 - (c) 2012 M. Kiewitz <<Release Candidate 2>> (bld: 20120214)', 0 44 Copyright db ' AiR-BOOT v1.0.8 - (c) 2012 M. Kiewitz <<Internal Release 2 f>> (bld: 20120220)', 044 Copyright db ' AiR-BOOT v1.0.8 - (c) 2012 M. Kiewitz <<Internal Release 2g>> (bld: 20120221)', 0 45 45 ;Copyright db ' AiR-BOOT v1.0.8 - (c) 1998-2012 M. Kiewitz, Dedicated to Gerd Kiewitz', 0 46 46
Note:
See TracChangeset
for help on using the changeset viewer.