Ignore:
Timestamp:
Apr 12, 2014, 12:05:10 AM (11 years ago)
Author:
Ben Rietbroek
Message:

Created Bitfield functions (auxdebug on) [2012-02-21]

WARNING!!

All commits upto and including the commit of [2012-05-13] contain
a severe bug!! Building from these sources and then disabling
the 'force LBA' feature while also using the drive-letter feature or
editing the label can DESTROY THE MBR on ALL ATTACHED DISKS!!
DO NOT DISABLE 'FORCE LBA USAGE' WHEN BUILT FROM THE THESE COMMITS!!

New

o Functions to insert/retrieve bitfields

Let's see if we can compress the hideparttable...

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/BOOTCODE/REGULAR/DEBUG.ASM

    r43 r44  
    190190        ;~ call    DEBUG_DumpGeo
    191191
    192 
     192        call    DEBUG_CheckBitFields
    193193
    194194        popa
     
    226226        popf
    227227        ret
    228 
    229 
    230228DEBUG_DumpBSSSectors    EndP
    231229
    232230
    233 
     231DEBUG_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
     264DEBUG_CheckBitFields    EndP
    234265
    235266;
     
    237268;
    238269DEBUG_Dump2     Proc  Near
    239         pushf
    240         pusha
    241 
    242 
    243         call    AuxIO_TeletypeNL
    244         call    AuxIO_TeletypeNL
    245 
    246 
    247         mov     si,offset db_config
    248         call    AuxIO_Print
    249 
    250         mov     si,offset db_cfgparts
    251         call    AuxIO_Print
    252         mov     al,[CFG_Partitions]
    253         call    AuxIO_TeletypeHexByte
    254         call    AuxIO_TeletypeNL
    255 
    256         mov     si,offset db_cfgpartdef
    257         call    AuxIO_Print
    258         mov     al,[CFG_PartDefault]
    259         call    AuxIO_TeletypeHexByte
    260         call    AuxIO_TeletypeNL
    261 
    262         mov     si,offset db_cfgpartlast
    263         call    AuxIO_Print
    264         mov     al,[CFG_PartLast]
    265         call    AuxIO_TeletypeHexByte
    266         call    AuxIO_TeletypeNL
    267         call    AuxIO_TeletypeNL
    268 
    269 
    270 
    271         mov     si,offset db_vars
    272         call    AuxIO_Print
    273 
    274         mov     si,offset db_newpart
    275         call    AuxIO_Print
    276         mov     si,offset NewPartTable
    277         call    AuxIO_DumpSector
    278         call    AuxIO_TeletypeNL
    279         add     si,512
    280         call    AuxIO_DumpSector
    281         call    AuxIO_TeletypeNL
    282         call    AuxIO_TeletypeNL
    283 
    284         mov     si,offset db_newhide
    285         call    AuxIO_Print
    286         mov     si,offset NewHidePartTable
    287         call    AuxIO_DumpSector
    288         call    AuxIO_TeletypeNL
    289         add     si,512
    290         call    AuxIO_DumpSector
    291         call    AuxIO_TeletypeNL
    292         call    AuxIO_TeletypeNL
    293 
    294         mov     si,offset db_dletters
    295         call    AuxIO_Print
    296         mov     si,offset NewDriveLetters
    297         call    AuxIO_DumpParagraph
    298         call    AuxIO_TeletypeNL
    299         add     si,16
    300         call    AuxIO_DumpParagraph
    301         call    AuxIO_TeletypeNL
    302         call    AuxIO_TeletypeNL
    303 
    304         mov     si,offset db_tmpec
    305         call    AuxIO_Print
    306         mov     si,offset TmpSector
    307         call    AuxIO_DumpSector
    308         call    AuxIO_TeletypeNL
    309         call    AuxIO_TeletypeNL
    310 
    311         mov     si,offset db_partsec
    312         call    AuxIO_Print
    313         mov     si,offset PartitionSector
    314         call    AuxIO_DumpSector
    315         call    AuxIO_TeletypeNL
    316         call    AuxIO_TeletypeNL
    317 
    318         popa
    319         popf
     270        ;~ 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
    320351        ret
    321352DEBUG_Dump2     EndP
Note: See TracChangeset for help on using the changeset viewer.