e0post.asm
来自「惠普公司bios完整源代码大机密!」· 汇编 代码 · 共 2,296 行 · 第 1/5 页
ASM
2,296 行
; []===========================================================[]
;
; NOTICE: THIS PROGRAM BELONGS TO AWARD SOFTWARE INTERNATIONAL(R)
; INC. IT IS CONSIDERED A TRADE SECRET AND IS NOT TO BE
; DIVULGED OR USED BY PARTIES WHO HAVE NOT RECEIVED
; WRITTEN AUTHORIZATION FROM THE OWNER.
;
; []===========================================================[]
;
; PAGE 60,132
; TITLE POST -- 386 ROM/BIOS POST
;----------------------------------------------------------------------------
;Rev Date Name Description
;---------------------------------------------------------------------------
;OEM03 06/01/00 AVN Fixed when ps2 keyboard and ps2 mouse was swap and
; no keyboard error message under VIA686A no keyboard/
; ps2 swap function.
;OEM02 05/12/00 JEF Added define to shorten POST time.
;OEM01 04/10/00 AVN Remove the beep after VGA init.
;R340 03/23/00 RAX Fixed if VGA share memory and BIOS.CFG define
; "NO_MEM_TEST_IF_QUICKPOST", memory size show at wrong
; position.
;R315A 03/20/00 AVN Fixed "Wait_Key_Timer" function timer countdown fail.
;R339 03/17/00 KVN Added a switch "Choice_Full_Logo_by_customer" that
; customer can choice maximum to 8 full screen logo by
; return from 'Choice_customer_Full_Logo' procedure
;R317A 03/17/00 RCH Fixed K7 CPU detection error if PhoenixNext is
; supported.
;R338 03/13/00 STV Fixed CheckSum Error load FlashROM CMOS.
;R332A 03/09/00 ATY Fixed system hang when memory test before continuous to
; press Key [DEL].
;R337 03/07/00 RAY Call fPROC_Show_PRating_Or_MHz in CPUPOST.ASM instead
; of calling the Try_Show_PRating then SysCfg_CPU_Clock1
; in order to keep consistency in POST & summary table
; Also save some codes.
;
;R324A 03/06/00 PHI Remove R324.
;R336 03/06/00 PHI Add a define "Chipset_Hook_Before_Mem_Count".It can
; enable a new hook Ct_Before_Mem_Count, Because some
; chipset (like ArtX) can't hidden it's share memory
; so we must do something befor mem counting.
;R335 03/06/00 RIC Support PCI Reset of VIA 8231 SouthBridge.
;R334 03/06/00 AVN Added define 'NO_VGA_ERROR_BEEP' for some custom do
; not need beep even VIDEO fail.
;R333 03/03/00 RAY Support Cyrix III PR-Rating
;R238B 03/03/00 STV Fixed R238 Show Full Screen Logo Color Error (16 mode),
; Not over 7 colors.
;R302B 03/02/00 STV Fixed "TEMP_MEM" change to use "Temp_VGA_Seg".
;R332 02/25/00 TNY Fix system hang if [ESC] pressed when memory test.
;R331 02/22/00 ALU Added Voice alarm function.
;R330A 02/22/00 STV Fixed R330.Temp_CBROM_Segment change to POST_Decompress_Seg
;R330 02/21/00 STV Auto detect BMP screen high then show post msg.If no
; define "No_Show_Graphic_POST_MSG".
;R309A 02/17/00 KEN Patching the undesired beep (keyboard overrun) is done
; in POSTINT9.ASM, and the exact causation is that BIOS
; is defined with "EARLY_RESET_KB".
;R329 02/17/00 RCH No keyboard typematic control for legacy free platform
;
;R328 02/14/00 RCH Added an option to assign IRQs for PCI devices
; earlier for handling USB legacy by IRQ instead of SMI.
;R327 02/11/00 RCH Fixed CPU message string is override by number of
; processor message for dual CPU BIOS.
;R326 02/02/00 BAR Added define post flash write use XDGROUP code
; POST_FLASH_IN_XGROUP EQU 1
;R321C 01/31/00 GAR Fixed compile error
;R321B 01/28/00 GAR Fixed SCO-UNIX setup hang.
;R325 01/28/00 AVN Fixed switch to text mode under graphics post, and
; share memory size was lost.
;R324 01/27/99 JSN Added Skip_Graphic_RAM_Test definition for some chips
; NVRAM to use top memory (ARTX), otherwise screen
; display will fail.
;R321A 01/24/00 GAR Fixed SCO-UNIX setup hang.
;R227A 01/21/00 KVN Recovery attrib of charactor to normal after Show TCAV
; version.
;R323 01/20/00 KVN Fixed system hang for POST_67S on some M/B(2A5LEF2A)
;R322 01/18/00 RAY Problem:
;
; Due to unknown problem, the PCI_VGA_FOUND[bp] is
; cleared(will be investigate later). This causes
; VGA BIOS with size larger than 32K, the first 32K
; of C000 shadow is set to R/W after boot up.
;
; Fix:
;
; Temporary use flag PCI_VGA_INFO[bp] instead of
; PCI_VGA_FOUND[bp] to identify if PCI VGA is found.
;
;R318A 01/13/00 RAY More enhancement of R318 to solve problem:
;
; Year shown as 2098 (but actually the year is 2000)
; in CMOS setup.
;
;R294A 01/13/00 MIL Include R294 code in Graphics_Post definition.
; (for SIS540, SIS630 Internal VGA Chip)
;R321 01/10/00 GAR Fixed SCO-UNIX setup hang.
;R320 01/07/00 KVN Added a switch "Early_Build_DMI_Pool" to support read
; DMI data during POST
;R319 01/04/00 KVN Remove some code to E000-E800 area from f000 to reduce
; code size of F000 shadow area
;R318 01/03/00 RAY Load year as 2000 if RTC fail. The 2000 value is
; defined in COMMON.EQU as "DEFAULT_RTC_YEAR EQU 00h"
;
;R317 12/28/99 RAY Support PhoenixNet
;R316 12/17/99 RAX Rewrite try report error.
; 1.To shorten this routine.
; 2.Expand error report function for more customize
; request of error report and some kind of request
; have to implement at error report stage.
; 3.Expand maximum error halt type from 4 to 8.
; 4.Add "OEM_Wait_bypass_Key" define for customize
; "Show_bypass_msg" and "Wait_bypass_Key" in OEMPOST.ASM
;R299B 12/13/99 RCH Show two digits of FSB frequency if the clock is under
; 100Mhz.
;R315 12/09/99 RAX Removed un-use code and rewrite wait key code.
; Add "Wait_Key_Timer" define, and unit is second.
;R314 12/07/99 GAR Add for legancy keyboard detection if define
; USB_MOUSE_SUPPORT
;R310A 12/06/99 JMS Fixed always report 65535Kb max DIMM size if define
; "INT15_88_Always_Max", When use 32MB DIMM
;R313 12/04/99 RCH Fixed compile error if USB mouse legacy support is
; enabled.
;
;R312 12/03/99 RAY Do not call Try_Shadow & Try_Other_Shadow if it is
; PCI BUS. All these things are already handled by
; PCIPOST.ASM
;R311 12/02/99 JDN Fixed MMO CPU Boot fail when cache disable.
;R299A 12/01/99 RCH Fixed wrong clock ratio display if the raio is x10
; or above.
;R310 11/30/99 JMS added define "INT15_88_Always_Max" for fix Viper chipset
; plug two UDMA66 HDD on Primary & secondary and
; use AMD "EDID Diag(EIDE test tool) " test fail
;R309 11/30/99 RCH Fixed undesired beep (keyboard overrun) if USB mouse
; legacy support is enabled.
;R308 11/16/99 GAR Add No_Support_FDD_Swap for NS serial I/O because
; they don't support floppy swap
;R274D 11/16/99 CEC Fixed no CDROM information in setup.
;R307 11/10/99 RAY All "ABS" external reference to PCIPOST.ASM
; "extrn ????:ABS" are moved to a new file: STACK.DEF
; which is included by COMMON.EQU
;R293A 11/03/99 STV Fixed R293 still error when added define "Trend_AntiVirus"
;R306a 10/27/99 JRY Fixed same bugs in function Get_VBE_Info
;R306 10/25/99 JRY Added Get VESA VBE Information function for Special
; Shift Bank of Super VGA Card.
;R302A 10/22/99 KVN Fixed screen not be enabled when show 256 color logo
;R167F 10/19/99 RIC Don't Cut IRQ12 When No PS2 Pluged because it will
; cause some platform no pluged PS2 mouse hang in WinNT
; in VIA 596 chip series.
;R305 10/18/99 RCH Support platform without KBC for legacy free system
;R304 10/18/99 RCH Fixed assembler error if there is no super I/O chip
; supported.
;R280A 10/14/99 DNL Fix that cause yellow bang mark on the keyboard device
; while no legacy keyboard pluged under Win2K
;R303 10/12/99 DNL Clear PS2 mouse flag for ACPI mode if system is
; legacy free mode or no PS2 mouse exist
;R302 10/01/99 STV Added Full screen logo support 256 colors BMP.
; With cbrom.exe V2.03 later.
;R301 09/29/99 KVN Rewrite "show_color_logo" subroutine for modular
;R300 09/23/99 KVN Remove TEMP_BP to another location for run time used.
;R299 09/16/99 RCH Display CPU front side bus frequency and clock ratio
; onto POST screen.
;R298 09/16/99 DNL Added Alert On LAN 2 BIOS support
;R297 09/15/99 PAL Added "Patch_RT52039D" definition to support RT52039D
;R296 08/31/99 RAY Do not scan 7000h for onboard VGA because it is only
; used by very very old version of CBROM.EXE
;R295 08/30/99 KVN Fixed display error message of POST became abnormal
; string when screen scroll up.This case is AX be destoried
; by Vcrlf procedure when execute screen scroll.
;R294 08/26/99 MIL Added Two Definitio:
; 1. VGA_Share_Memory_Above_64M : Change system show
; Video memory size base on ?Mega byte.
; 2. Show_VGA_Local_Memory_Size : Show system onboard
; Local memory in the POST stage.
; (for SIS540, SIS630 Internal VGA Chip)
;R293 08/03/99 STV Fixed Full Screen Logo change to Text mode not show
; IDE Detect Info when post_127S had post error.
;R292 08/03/99 PAL Move device suppport for VID control chip or others
; from E8POST.ASM
;R291 08/03/99 DRS This function depends on ALWAYS_MEMORY_TEST definition
;R290A 07/15/99 GAR Fixed compile error
;R290 07/12/99 GAR Fixed compile error if Password_ON_NOW_SUPPORT,
; MOUSE_BUTTON_ON_SUPPORT and Superio_On_Now_Function
; exist at the same time
;R253C 07/06/99 MIL Turn On CPU Cache before System detect PS2 mouse,
; for speed-up the detection progress.(for 2A6IN)
;R289 06/25/99 DRS This function depends on Multi_LOGO_Combined definition
; You can choose one logo to be decompressed from several
; bios combined logos.
;R288 06/22/99 KVN Fixed system hang at decompress processing of POST_103s
; when ACPI function enabled.This problem occur on BIOS
; is 64k block and decompress code locate at 2000:e000-efff
;R281A 06/17/99 GAR Correct R281. Make primary connector is keyboard if
; no kB/Mouse was detected
;R287 06/11/99 RAY 1. POST_35 do too many things in one post code. Split
; them into pieces & put from POST 35 to 38
; 2. Extract the VGA init code in POST_41, rewrite it
; to make it more readable & place it in POST 43
;R286 06/11/99 RAY Kill some legacy stuffs: Special_for_GIANTEC
; Special_for_Weitek
; Turbo_Pin_Handler
;R274C 06/11/99 KVN Fixed still enter setup while IDE HDD detecting
;R274B 05/31/99 STV Fixed R274A cause it's too short time to enter setup
; screen,because not add "Enter_Setup_Check" func.
; Now,delete "No_Enter_Setup_When_HDD_Detect" define.
;R285 05/24/99 KVN Change BIOS version string to "Award Medallion Modular"
; when bios define 'Bar_Menu_Setup'
;R284 05/22/99 RAX Add Intel VBU support.
;R283 05/06/99 MIL Add definition: SPECIAL_PATCH_FOR_EARLY_INIT_VGA
; :
; The purpose of this hook to add customization codes
; in chipset dependent files.
; (add define in BIOS.CFG & add hook in CHIPPOST.ASM)
; :
;R281 05/05/99 GAR Add code for swap kb/mouse for super I/O
;R280 05/04/99 DNL Fix that cause yellow bang mark on the keyboard device
; while no legacy keyboard pluged under Win2K
;R225A 04/28/99 BAR Add Flash_64K_Unit autmaticlly load
; awdflash.exe in Post & BootBlock.
;R253B 04/27/99 KVN Fixed system shadow write data abnormally by R253.
; This reason is CPU cache be enabled while memory test
; and not be disabled until POST_97S.That will cause
; write IDE HDD parameter wrong data.Now we diabled CPU
; cache after memory test.This case occur at 2A41800E
;R279 04/20/99 RAY Prepare CMOS info in stack in POST 28 instead of
; POST 35 so that CT_EARLY_PM_INIT (POST_29) can use [BP]
;
;R278A 04/20/99 RAY Change the CLIP of POST in USERINT.ASM instead
;R278 04/19/99 RAY Fix message cannot be displayed under full_screen_logo
;R274A 03/25/99 TNY R274 cause it's too short time to enter setup screen.
; , so I add a option for R274.
; "(No_Enter_Setup_When_HDD_Detect)"
;R277 03/22/99 GAR Enable PS2 mouse in post_105s if support on_now_function
;R276 03/16/99 RAY NO "Check_K6_CPU" if it is not 586 BIOS
;R275 03/12/99 TNY Move initial clock generator hook after PCI initaial
; for patching ICH (Intel).
;R274 03/10/99 RAX Added flag to prevent HDD detect not ready then enter
; setup.
;R273 02/26/99 RIC Fixed that "NO_CPU_CLOCK_DISPLAY" definition is not
; available.
;R255C 02/10/99 RAX Fixed memory test fail, coz by clear memory range
; wrong.
;R270 02/03/99 RCH Move password clearring message display from POST 45
; to POST 83 to prevent POST screen corrupt for UMA
; platform.
;R268 02/03/99 KVN Fixed screen display wrong when none EPA be combined
;R255B 02/03/99 KVN Fixed decompress data of source be destroyed while
; memory test (POST_82S)
;R267 02/01/99 RAY Kill all codes defined by NOT_USE_CBROM_EPALOGO
;R266 02/01/99 KVN Cancle some not use code for BIOS V6.0
;R265 01/29/99 PAL Move Ct_early_shadow hook after Init_Onboard_Generator
; for disable pci device can not be assigned resource
;R255A 01/29/99 STV Not define "linear_rom_support",Because BIOS ROM is Linear ROM.
;R264 01/29/99 TNY Fix display screen error if 2GB memory installed.
;R263 01/25/99 RCH Added switch "NO_BIOS_DATE_CODE_DISPLAY" to not
; display BIOS date code onto POST screen.
;R262 01/22/99 PAL Remove "Bootblock_16K_Support" definition to use
; Automatic_Load_Awdflash option in FLASH_64k_Unit
;R261 01/14/99 PAL Added RTM_Turbo_Freq hook for e0post.asm in order to
; avoid show freq. error in POST
;R260 12/31/98 KVN Support 4M BIOS structure
;R259 12/24/98 PHI Add new function ,that when CMOS checksum error
; the date default is the date that when BIOS made.
; Please define Date_DEFAULT_IS_BIOS_MAKE_DAY
;R258 12/12/98 RCH Discard "Video BIOS Shadow" setup item for platform
; without ISA Bus support like Intel/i820 & i810 chipset
;R257 12/11/98 KEN Fixed bug that the mouse cursor is displayed abnormal
; while using Microsoft IntelliMouse (socalled scroll
; function or wheel control mouse) in Win98 safe mode,
; when usb mouse support is enabled and no usb mouse
; is installed.
;R256 11/30/98 RCH Patch NSTL Generic Interrupt Handler(GIH) testing
; failure for IRQ 0 ( INT 8H ).
;
;R255 11/26/98 STV Fixed BIOS ROM change to Linear ROM define "linear_rom_support".
;R167E 11/19/98 RIC If not define "No_Cut_IRQ12_When_No_PS2_Pluged"
; ,force define "Disable_VIA_PS2_In_PCI_RESET" to make
; system be stable in PCI Reset.
;R167D 11/17/98 RIC Add "Disable_VIA_PS2_In_PCI_RESET" for VIA_PCI_Reset
; to fix system hang at PCI Reset in SMC I/O chip.
;R254 11/16/98 BAR Enable "PopUp_BootMenu_Accept" before hdinstall
; have more time to press "ESC" key into PopUp_Menu
;R253 10/20/98 BAR Modify QuickPost memory test only show counter
; No used pattren tabel.
; Clear memory turn on cpu cache to speed up .
; If Quick Post must test memory please define
; " QuickPost_ExtMem_Test_Used_Pattern_Tbl " .
;R252 10/13/98 GAR move init ps2 mouse command to pmupost.asm for power
; off
;R46B 10/02/98 RCH Modify memory high limit to support DRAM up to 2GB
; The Intel 440GX chipset support memory up to 2GB.
;R251 09/28/98 KEN Added the setup item checking of USB mouse if
; PS2_SETUPABLE and USB_MOUSE_SUPPORT are defined.
;R246 09/09/98 DNL Initial ACPI table and AML code late to fix VIA IRQ
; assign incorrectly problem
;R167C 03/05/98 RIC Add VIA 596 South Bridge chip Support.
; (Fixed that System can't reboot/PCI Reset in POST05h)
;R238A 09/04/98 KVN Don't fix 16th color for POST message in graphics POST
; when BIOS.CFG define "No_Show_Graphic_POST_MSG"
;R245 09/03/98 DNL Fixed some motherboard device no initial while BIOS
; support simple boot and system restart from WIN 98
; ACPI mode
;R244 09/03/98 DNL Fixed Intel TESTVIEW utility report memory size error
;R221E 08/12/98 KVN Added some feature for Acer request
;R240 08/05/98 TNY Fix some chipset WOL fail.
;R235B 07/29/98 BAR Resegmentaion E0POST .
;R239 07/28/98 RCH Fixed system reset after shutdown from Netware SMP
; OS if the CPU ID is 0651H for MP platform, due to
; data stored in segment 4100H was destoried by P6
; micro codes that are decompressed to 4000:0
;R221D 07/28/98 KVN Fixed coding mistake that will cause no report battery
; fail error message
;R238 07/28/98 KVN Let full screen logo show speed up
;R235A 07/27/98 BAR Resegmentaion E0POST .
;R237 07/24/98 RCH Added MediaGX DSTN LCD controller 9210 display support.
;R236 07/23/98 KVN Change method of decompressing in protect mode
;R235 07/20/98 BAR Resegmentaion E0POST .
;717 07/17/98 KVN Reset base memory map of POST
;R234 07/16/98 TNY Add "WAIT_10_SEC_IF_KB_ERR" option
;R233 07/16/98 KVN Fixed memory test fail or floppy seek error on switch
; to text mode from full screen logo
;R221C 07/16/98 KVN Request for Acer OEM
;R232 07/11/98 RAY Add BIOS.CFG switch: CLEAR_SCREEN_BEFORE_SHOWING_ERRORS
;R230 07/06/98 KVN Added "NO_EPA_LOGO" switch for graphics post to reduce
; POST and EPA pattern code size
;R221B 07/03/98 KVN 1. Added one more error condition for LS120 that not
; only Check LS120 drive but also verify bootable
; diskette have in LS120 drive.
; 2. Added enter setup message for CMOS checksum or
; battery fail error occur
;R228 07/01/98 BAR Rewrite int 19.
;R227 06/29/98 KVN Show TCAV version in POST screen
;R226 06/29/98 KEN Correct the codes to clear base memory at POST_49s
; for that the USBRAM used by USB BIOS in base memory is
; destroyed. But, if 2M flash ROM is used, the USB BIOS
; can't use base memory anyway.
;R225 06/26/98 DRS Add No_Automatic_Load_Awdflash_InPOST definition
; Some customers want to automatically load awdflash.exe,
; but they don't want this function during POST.
; They just want to autmaticlly load awdflash.exe in BootBlock.
;R224 06/24/98 TNY Add "WAIT_KEY_10_SEC" option.
;R221A 06/23/98 KVN Modified post error screen for acer OEM request
;R185E 06/18/98 KVN Change show award logo method in graphics post to
; save POST spent time
.386P
;[]-----------------------------------[]
;
; Award Software 386/486 BIOS
; Power-On Self-Test located in E0000-E7FFF area
;
; Copyright (C) 1996
; Award Software, Inc.
; All Rights Reserved
;[]-----------------------------------[]
.XLIST
INCLUDE BIOS.CFG
ifndef No_Support_4_IDE ;support 4 HDDs as default
Support_4_IDE EQU 1
endif ;No_Support_4_IDE
INCLUDE BTROMSEG.EQU
INCLUDE COMMON.EQU
INCLUDE POST.EQU
INCLUDE ATORGS.EQU
INCLUDE PORT61.EQU
INCLUDE 8042.EQU
INCLUDE 8259.EQU
INCLUDE COMMON.MAC
INCLUDE POST.MAC
INCLUDE USERINT.MAC
ifdef RPB_ENABLED
INCLUDE rpb_err.equ
endif ;RPB_ENABLED
;R314 - start
ifdef USB_SUPPORT
ifdef USB_MOUSE_SUPPORT
EARLY_RESET_KB EQU 1
endif ;USB_MOUSE_SUPPORT
;R328 - start
ifdef USB_LEGACY_BY_IRQ
extrn EarlyPCI_IRQ_Assign:far
endif;USB_LEGACY_BY_IRQ
;R328 - end
endif ;USB_SUPPORT
;R314 - end
;R331_START
ifdef W5280_Voice_Chip
extrn Send_Voice_Alarm:near
endif;W5280_Voice_Chip
;R311_END
extrn fProc_Disp_Byte_Int2:far ;R299A
ifdef Multi_LOGO_Combined ;R289
extrn Get_LOGO_Pointer:near ;R289
endif ;Multi_LOGO_Combined ;R289
ifdef Early_Build_DMI_Pool ;R320
extrn build_dmi_pool:far ;R320
endif ;Early_Build_DMI_Pool ;R320
extrn Prg_Peripheral_Device:near ;R292
ifdef PCI_BUS ;R240
extrn Patch_LanBoot:near ;R240
ifdef AOL_SUPPORT ;R298
include AOL.EQU ;R298
extrn Update_WDMessage:near ;R298
endif ;AOL_SUPPORT ;R298
endif; PCI_BUS ;R240
ifdef Show_PS2_UnConnect_Message
EXTRN MOUSE_ERR_STR:NEAR
endif ;Show_PS2_UnConnect_Message
;R316 start
ifdef OEM_Wait_bypass_Key
extrn Show_bypass_msg:near
extrn Wait_bypass_Key:near
endif ;OEM_Wait_bypass_Key
extrn Get_OEM_ERROR_TBL:near
;R316 end
ifdef New_Swap_Fdd_Method
extrn Fdd_Item:near
endif ;New_Swap_Fdd_Method
;R262ifdef Bootblock_16K_Support
ifdef Automatic_Load_Awdflash
ifNdef No_Automatic_Load_Awdflash_InPOST ;R225
extrn POST_Awdflash_Check:near
extrn TO_ENTER_Awdflash:near
ifdef Graphics_Post
extrn TO_ENTER_Awdflash1:near
endif ;Graphics_Post
endif ;No_Automatic_Load_Awdflash_InPOST ;R225
endif ;Automatic_Load_Awdflash
;R262endif ;Bootblock_16K_Support
ifdef CMOS_Default_in_Flash
;R338 extrn XCALL_PROC:near
;R338 EXTRN Search_CMOS_label:near
;R338 EXTRN Check_Flash_CMOS:near
;R338 extrn DRAM2FLASH:near ;;;05/05
;R338 extrn CMOS_DRAM_CHECKSUM:near ;;;05/05
extrn Check_Flash_CMOS:near ;R338
endif ;CMOS_Default_in_Flash
extrn POST_decompress:near
ifdef HPM_Support
extrn Init_HPM:Near
extrn Post_init_hpm:Near
extrn Check_HPM_Resume:Near
endif ;HPM_Support
ifdef VSA_VGA
ifdef DSTN_9210_Support ;R237
extrn New_DSTN_Panel:far ;R237
endif ;DSTN_9210_Support ;R237
⌨️ 快捷键说明
复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?