Changeset 175


Ignore:
Timestamp:
Apr 8, 2017, 12:28:12 AM (8 years ago)
Author:
Ben Rietbroek
Message:

Reenable interrupts after disk i/o -- trac #11 [v1.1.1-testing]

Some old or quirky BIOSses return with interrupts disabled after INT13
and/or INT13X calls. That blocks the timer interrupt which makes
AiR-BOOT wait forever when building the BOOT-MENU.
This should fix trac issue #11:
http://trac.netlabs.org/air-boot/ticket/11

CAUTION:
This is a testbuild !
AirBoot uses the BIOS to access disks and a small coding error can trash
partition tables or other vital disk structures. You are advised to make
backups of TRACK0 and EBRs before using this testbuild. More info at:
https://rousseaux.github.io/netlabs.air-boot/pdf/AirBoot-v1.1.0-manual.pdf

Location:
trunk/bootcode
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • trunk/bootcode/airboot.asm

    r173 r175  
    11361136        mov     ah, 03h                 ; BIOS write disk (legacy)
    11371137        int     13h                     ; Call BIOS
     1138        sti                             ; Enable ints
    11381139        ;!
    11391140        ;! TODO: Check success
  • trunk/bootcode/airboot.md5

    r174 r175  
    1 1e73b211b994373d8d30cee041699a94  airboot.bin
     18cf5e60c163921dd44a401115ca72682  airboot.bin
  • trunk/bootcode/regular/driveio.asm

    r170 r175  
    3535        mov     dl, [BIOS_BootDisk]     ; We check using the boot-disk
    3636        int     13h
     37        sti
    3738
    3839IFDEF   AUX_DEBUG
     
    4748            mov     ah, 48h
    4849            int     13h
     50            sti
    4951            call    DEBUG_DumpRegisters
    5052            ;~ call    AuxIO_DumpSector
     
    9799        mov     ax, 0201h                     ; Function 02, read 1 sector...
    98100        int     13h
     101        sti                                   ; Enable ints
    99102        jnc     DIOLC_NoError
    100103        call    MBR_LoadError                 ; Will Abort BootUp
     
    165168;!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
    166169        int     13h
     170        sti
    167171        jnc     DIOSC_NoError
    168172        call    MBR_SaveError                 ; Will Abort BootUp
     
    179183        xor     dl, dl
    180184        int     13h
     185        sti
    181186        xor     dx, dx                         ; Cylinder=0, Head=0
    182187        mov     cx,  1                         ; Sector=1, Drive=0
     
    248253        mov     ah, 08h
    249254        int     13h            ; DISK - GET DRIVE PARAMETERS
     255        sti                    ; Enable ints
    250256        mov     ah, 0FBh       ; Assume 255 heads/63 sectors, if error
    251257        jc      DIOILUT_Error
     
    802808        mov     ax, 0201h                  ; Function 2 - Load Sector
    803809        int     13h
     810        sti                                ; enable ints
    804811        jnc     DIOLS_Success
    805812        dec     di                         ; decrement retry count
     
    991998        mov     ah, 42h                                 ; read function
    992999        int     13h                                     ; transfer to bios
     1000        sti                                             ; enable ints
    9931001
    9941002        ; Error occured
     
    10631071        mov     ah, 43h                                 ; write function
    10641072        int     13h                                     ; transfer to bios
     1073        sti                                             ; enable ints
    10651074
    10661075        ; Error occured
     
    15011510        mov     ax, 0301h                  ; Function 3 - Write Sector
    15021511        int     13h
     1512        sti                                ; Enable ints
    15031513        jnc     DIOSS_Success
    15041514        dec     di                         ; decrement retry count
     
    16841694        mov     ah, 08h                         ; Get Disk Parameters
    16851695        int     13h                             ; Call BIOS
     1696        sti                                     ; Enable ints
    16861697
    16871698        ; CF=1 or AH!=0 indicates error
     
    17221733        mov     ah, 48h                         ; Get Extended Disk Parameters
    17231734        int     13h                             ; Call BIOS
     1735        sti                                     ; Enable ints
    17241736
    17251737        ; CF=1 or AH!=0 indicates error
Note: See TracChangeset for help on using the changeset viewer.