Changeset 294 in xtideuniversalbios for trunk/XTIDE_Universal_BIOS/Src/Handlers/Int13h.asm


Ignore:
Timestamp:
Mar 4, 2012, 1:35:10 AM (12 years ago)
Author:
krille_n_@…
google:author:
krille_n_@hotmail.com
Message:

Commit 2/2 (BIOS):

  • Fixed a bug in AH1h_HStatus.asm.
  • Minor optimizations.
  • Fixed spelling and did some cleaning.
File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/XTIDE_Universal_BIOS/Src/Handlers/Int13h.asm

    r277 r294  
    2626
    2727    call    RamVars_GetSegmentToDS
    28        
     28
    2929    call    DriveXlate_ToOrBack
    3030    mov     [RAMVARS.xlateVars+XLATEVARS.bXlatedDrv], dl
    31        
     31
    3232    call    FindDPT_ForDriveNumberInDL              ; DS:DI points to our DPT, or NULL if not our drive
    3333    jnc     SHORT .OurFunction                      ; DPT found, this is one of our drives, and thus our function
    3434
    35     cmp     ah, 0
    36     jz      short .OurFunction                      ; we handle all function 0h requests (resets)
     35    test    ah, ah
     36    jz      SHORT .OurFunction                      ; we handle all function 0h requests (resets)
    3737    cmp     ah, 8
    38     jnz     SHORT Int13h_DirectCallToAnotherBios    ; non-8h function, handled by foreign bios
     38    jne     SHORT Int13h_DirectCallToAnotherBios    ; non-8h function, handled by foreign bios
    3939
    4040%ifndef MODULE_SERIAL_FLOPPY
    41 ; With floppy support, we handle all traffic for function 08h, as we need to wrap both hard disk and 
    42 ; floppy drive counts.  Without floppy support, we handle only hard disk traffic for function 08h, 
     41; With floppy support, we handle all traffic for function 08h, as we need to wrap both hard disk and
     42; floppy drive counts.  Without floppy support, we handle only hard disk traffic for function 08h,
    4343; and thus need the check below.
    4444;
    45     test    dl, dl                             
     45    test    dl, dl
    4646    jns     SHORT Int13h_DirectCallToAnotherBios
    47 %endif     
    48                
    49 .OurFunction:   
     47%endif
     48
     49.OurFunction:
    5050    ; Jump to correct BIOS function
    5151    eMOVZX  bx, ah
     
    141141    test    dl, dl
    142142    js      short Int13h_UnsupportedFunction
    143     mov     ah, 0
     143    xor     ah, ah
    144144    jmp     short Int13h_ReturnFromHandlerAfterStoringErrorCodeFromAH
    145145%endif
     
    172172%ifdef MODULE_SERIAL_FLOPPY
    173173    mov     al, [bp+IDEPACK.intpack+INTPACK.dl]
    174 Int13h_ReturnFromHandlerAfterStoringErrorCodeFromAH_ALHasDriveNumber:   
     174Int13h_ReturnFromHandlerAfterStoringErrorCodeFromAH_ALHasDriveNumber:
    175175    call    Int13h_SetErrorCodeToBdaAndToIntpackInSSBPfromAH_ALHasDriveNumber
    176176%else
     
    191191;   Returns:
    192192;       Depends on function
    193 ;       NOTE: ES:DI needs to be returned from the previous interrupt 
     193;       NOTE: ES:DI needs to be returned from the previous interrupt
    194194;             handler, for floppy DPT in function 08h
    195195;   Corrupts registers:
     
    251251.HardDisk:
    252252    LOAD_BDA_SEGMENT_TO ds, di
    253     mov     [bx], ah       
     253    mov     [bx], ah
    254254%else
    255255Int13h_SetErrorCodeToBdaAndToIntpackInSSBPfromAH:
    256256    ; Store error code to BDA
    257     LOAD_BDA_SEGMENT_TO ds, di     
     257    LOAD_BDA_SEGMENT_TO ds, di
    258258    mov     [BDA.bHDLastSt], ah
    259259%endif
Note: See TracChangeset for help on using the changeset viewer.