Ignore:
Timestamp:
Mar 29, 2012, 9:29:28 AM (12 years ago)
Author:
gregli@…
google:author:
gregli@hotmail.com
Message:

Removed align directives for initalization code and added define for align in boot-time calls to the assembly library (defaulting to 1), resulting in a significant savings for the AT and 386 builds. Fixed a bug with switch command line handling in the serial server. Put in CR characters in licesnse.txt, so that it properly displays on Windows. In the configurator, added default values for user supplied CHS and LBA values, defaulting to values within range when those features are enabled. Updated the copyright message in the configurator as the literal word Copyright is important.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/XTIDE_Universal_BIOS_Configurator_v2/Src/Menupages/MasterSlaveMenu.asm

    r360 r369  
    7070    at  MENUITEM.itemValue + ITEM_VALUE.rgszValueToStringLookup,    dw  g_rgszValueToStringLookupForFlagBooleans
    7171    at  MENUITEM.itemValue + ITEM_VALUE.wValueBitmask,              dw  FLG_DRVPARAMS_USERCHS
     72    at  MENUITEM.itemValue + ITEM_VALUE.fnValueWriter,              dw  MasterSlaveMenu_WriteCHSFlag       
    7273iend
    7374
     
    8586    at  MENUITEM.itemValue + ITEM_VALUE.wMinValue,                  dw  1
    8687    at  MENUITEM.itemValue + ITEM_VALUE.wMaxValue,                  dw  16383
     88%define                 MASTERSLAVE_CYLINDERS_DEFAULT                   65
    8789iend
    8890
     
    100102    at  MENUITEM.itemValue + ITEM_VALUE.wMinValue,                  dw  1
    101103    at  MENUITEM.itemValue + ITEM_VALUE.wMaxValue,                  dw  16
     104%define                 MASTERSLAVE_HEADS_DEFAULT                       16     
    102105iend
    103106
     
    115118    at  MENUITEM.itemValue + ITEM_VALUE.wMinValue,                  dw  1
    116119    at  MENUITEM.itemValue + ITEM_VALUE.wMaxValue,                  dw  63
     120%define                 MASTERSLAVE_SECTORS_DEFAULT                     63
    117121iend
    118122
     
    131135    at  MENUITEM.itemValue + ITEM_VALUE.rgszValueToStringLookup,    dw  g_rgszValueToStringLookupForFlagBooleans
    132136    at  MENUITEM.itemValue + ITEM_VALUE.wValueBitmask,              dw  FLG_DRVPARAMS_USERLBA
     137    at  MENUITEM.itemValue + ITEM_VALUE.fnValueWriter,              dw  MasterSlaveMenu_WriteLBAFlag               
    133138iend
    134139
     
    148153    at  MENUITEM.itemValue + ITEM_VALUE.fnValueReader,              dw  ValueReaderForUserLbaValue
    149154    at  MENUITEM.itemValue + ITEM_VALUE.fnValueWriter,              dw  ValueWriterForUserLbaValue
     155%define             MASTERSLAVE_USERLBA_DEFAULT                     1
    150156iend
    151157
     
    384390    pop     dx
    385391    ret                     ; AX will be stored by our menu system
     392
     393;
     394; No change to CHS flag, but we use this opportunity to change defaults stored in the CHS values if we are
     395; changing in/out of user CHS settings (since we use these bytes in different ways with the LBA setting).
     396;
     397ALIGN JUMP_ALIGN       
     398MasterSlaveMenu_WriteCHSFlag:
     399        test    word [es:di], FLG_DRVPARAMS_USERCHS
     400        jnz     .alreadySet
     401
     402        push    ax
     403        push    di
     404        push    si
     405
     406        mov     ax, MASTERSLAVE_CYLINDERS_DEFAULT
     407        mov     si, g_MenuitemMasterSlaveCylinders
     408        call    Menuitem_StoreValueFromAXtoMenuitemInDSSI
     409       
     410        mov     ax, MASTERSLAVE_HEADS_DEFAULT       
     411        mov     si, g_MenuitemMasterSlaveHeads
     412        call    Menuitem_StoreValueFromAXtoMenuitemInDSSI       
     413
     414        mov     ax, MASTERSLAVE_SECTORS_DEFAULT                     
     415        mov     si, g_MenuitemMasterSlaveSectors
     416        call    Menuitem_StoreValueFromAXtoMenuitemInDSSI       
     417       
     418        pop     si                     
     419        pop     di
     420        pop     ax
     421
     422.alreadySet:
     423        ret
     424
     425;
     426; No change to LBA flag, but we use this opportunity to change defaults stored in the LBA value if we are
     427; changing in/out of user LBA settings (since we use these bytes in different ways with the CHS setting).
     428;
     429ALIGN JUMP_ALIGN                       
     430MasterSlaveMenu_WriteLBAFlag:
     431        test    word [es:di], FLG_DRVPARAMS_USERLBA
     432        jnz     .alreadySet
     433
     434        push    ax
     435        push    di
     436        push    si
     437
     438        mov     ax, MASTERSLAVE_USERLBA_DEFAULT
     439        mov     si, g_MenuitemMasterSlaveUserLbaValue
     440        call    Menuitem_StoreValueFromAXtoMenuitemInDSSI               
     441
     442        pop     si
     443        pop     di
     444        pop     ax
     445                       
     446.alreadySet:
     447        ret     
Note: See TracChangeset for help on using the changeset viewer.