Chapter 10 Initialization
第10章 初始化
?
After a signal on the RESET pin, certain registers of the 80386 are set to predefined values. These values are adequate to enable execution of a bootstrap program, but additional initialization must be performed by software before all the features of the processor can be utilized.
在REST引腳發送信號后,80386的某些寄存器被設置為預定的值。這些值僅夠用來執行啟動(bootstrap)程序,但在所有的處理器特性可以被使用這衫,還必須由軟件執行額外的初始化。
10.1 Processor State After Reset?
重置后的處理器狀態
?
The contents of EAX depend upon the results of the power-up self test. The self-test may be requested externally by assertion of BUSY# at the end of RESET. The EAX register holds zero if the 80386 passed the test. A nonzero value in EAX after self-test indicates that the particular 80386 unit is faulty. If the self-test is not requested, the contents of EAX after RESET is undefined.
EAX的內容取決于加電自檢的結果。自檢可以由外部要求,即在REST之后測試BUSY#。如果80386通過了自檢,EAX中的值是0。自檢后的非0值表明,80386的特定單元有錯誤。如果沒有要求自檢,REST之后的EAX中的值是未定義的。
DX holds a component identifier and revision number after RESET as?Figure 10-1?illustrates. DH contains 3, which indicates an 80386 component. DL contains a unique identifier of the revision level.
REST之后,DX中值是組件的標識和版本號,見圖10-1的解釋。DH中包含3位80386的組件標識。DL中包含一個唯一的版本標識。
?
Control register zero (CR0) contains the values shown in?Figure 10-2?. The ET bit of CR0 is set if an 80387 is present in the configuration (according to the state of the ERROR# pin after RESET). If ET is reset, the configuration either contains an 80287 or does not contain a coprocessor. A software test is required to distinguish between these latter two possibilities.
控制寄存器0(CR0)包含一個圖10-2所示的值。如果配置(根據在REST之后,ERROR#的狀態)中存在80387,則CR0的ET位被置位。如果ET被重置,配置要么包含一個80287,要么不包含協處理器。軟件要通過測試來區分這二者的可能性。
?
The remaining registers and flags are set as follows:
剩余的寄存器和標志被設置成如下所示:
???EFLAGS ????????????=00000002H
???IP ????????????????=0000FFF0H?// 這里是BIOS開始的地方
???CS selector ???????=000H
???DS selector ???????=0000H
???ES selector ???????=0000H
???SS selector ???????=0000H
???FS selector ???????=0000H
???GS selector ???????=0000H
???IDTR:
??????????????base ???=0
??????????????limit ??=03FFH?
All registers not mentioned above are undefined.
所有上面沒有提到的寄存器都是未定義狀態。
These settings imply that the processor begins in real-address mode with interrupts disabled.
這些設置表明,處理器開始在關中斷的實地址模式。