好文档就是一把金锄头!
欢迎来到金锄头文库![会员中心]
电子文档交易市场
安卓APP | ios版本
电子文档交易市场
安卓APP | ios版本

BIOS Boot Spec中文.doc

12页
  • 卖家[上传人]:慢***
  • 文档编号:232999528
  • 上传时间:2022-01-01
  • 文档格式:DOC
  • 文档大小:61.50KB
  • / 12 举报 版权申诉 马上下载
  • 文本预览
  • 下载提示
  • 常见问题
    • BIOS boot spec2010-12-18 09:51http://www.wretch.cc/blog/hyper0672/9867131以下为转帖完整的文件可以参考以下为一些重点整理BBS (BIOS Boot Specification) 是用来规范BIOS 如何选择启动装置它包含了1. 辨识系统中的IPL (Initial Program Load) 装置2. 根据用户的选择,寻访每个装置并检视它是否能够启动系统IPL (Initial Program Load) Device:IPL Devie 指的是可以启动加载并执行操作系统的装置他包含了像是Floppy, Hard drives, CD-ROM, PCMCIA conrtollers/cards, PnP Cards, Legacy cards 甚至像是Network, Serial port, Parallel port 等等可开机的实体或虚拟设备所有的IPL 可以被归类成下列三种1. BAID2. PnP Card (可再细分为BCV 和BEV 两种装置)3. Legacy IPL DeviceBAID (BIOS Aware IPL Device):此类IPL 需要BIOS 的程序代码支持,来提供它启动系统的能力。

      通常启动的程序代码内建于INT 19h (BIOS Bootstrap loader) 的服务之中常见的装置如下:First floppy drive, First ATA Hard drive, PCI ATA card drive, ATAPI CD-ROM drive, PCMCIA controller bootable card, Ethernet controller code embedded in BIOSPnP Cards:此类IPL 装置,必须附加option ROM 于C0000h-EFFFFh (2K boundary)而且在Option ROM 中必须有PnP Option ROM Header (Table 2)另外,开机相关信息会被记录在PnP Expansion Header (Table 3),在此表格中,包含了BCV 或BEV 的指标BCV (Boot Connection Vector):BCV 是一个指标,指向Option ROM 中的某一段程序代码这段程序代码负责执行装置的初始化、侦测硬件(例如是否有SCSI 装置连接到系统) 或者在必要时Hook INT 13h 的服务(Disk I/O)。

      常见的有:PnP SCSI card drive, NoN-PnP card PnP Expansion HeaderBEV (Bootstrap Entry Vector):BEV 是一个指标,指向Option ROM 中负责加载操作系统的一段程序代码,并在必要时Hook INT 18h 或INT 19h 的服务通常于网络卡装置的Network Remote Boot 时使用常见的有:PnP Token Ring card, PnP Ethernet card, NoN-PnP card PnP Expansion HeaderLegacy IPL Devices:此类装置为标准的ISA Card,其包含了一个Option ROM 于C0000h-EFFFFh (2K boundary)此类型的装置于Option ROM 并没有PnP Expansion Header 的相关信息在它的Option ROM 被BIOS 找到时,会先执行一段初始化的程序这段程序执行期间,会根据需要来Hook INT 19h, INT 18h 以及INT 13hIPL Table每个BAID 以及BEV 装置必须在IPL Table 中有一个相对应的字段范例0: Floppy A:1: Hard Drive C:2: CD-ROM3: BEV #14: BEV #2IPL PriorityIPL Priority 决定IPL 开机的顺序。

      它存在于非挥发性内存中,并且可以让使用者修改在INT 19h (加载操作系统) 呼叫中,它必须能够被取用,并且根据表格中的顺序来进行开机的程序范例0: 3 (BEV #1)1: 4 (BEV #2)2: 1 (Hard Drive C:)3: 2 (CD-ROM)4: 0 (Floppy A:)IPL Priority PseudocodeCreated at BIOS build time:First few IPL Table entries are filled in by the BAIDs.maxIPLCount = Number of entries in IPL Table.baidCount = Number of BAIDs in the system.maxBEVCount = (maxIPLCount - baidCount).The NV memory space for the IPL Priority is reserved.Assumptions:· The default for the IPL Priority will automatically becreated during POST in case the NV memory gets corrupted.· nvBEVCount = number of BEV devices found last time -stored in NV memory.· postBEVCount = number of BEV devices found this time.Execution at POST time:· All option ROMs with a PnP Expansion Header are identifiedand their initialization entry points are called.· Additional IPL Table entries are filled in with the BEVdevices found.· IF (NV memory is corrupted)· Set default IPL Priority by first placing the BAIDs,and then adding in the BEVs in the order they were found.· ELSE· The IPL Priority is retrieved from NV memory.· deltaBEVCount = (nvBEVCount - postBEVCount).· IF (deltaBEVCount != 0)· IF (deltaBEVCount > 0)· FOR (i = 0; i != deltaBEVCount; ++i)· Add a new BEV device to the end of IPL Priority.· ELSE· For (i = 0; i != deltaBEVCount; --i)· Delete the BEV device nearest the end of IPL Priority.· ENDIF· Save the postBEVCount in NV memory as nvBEVCount.· Save the new IPL Priority in NV memory.· (Optional) - Display a message that the IPL Prioritychanged and allow the user to enter Setup to reconfigurethe IPL Priority.· ENDIF· ENDIF· Invoke INT 19h.BCV Priority在BIOS INT 13h (Disk I/O) 的服务之中,驱动器号00-7Fh 为Floppy Disk, 而80-FFh 为Fixed Disk。

      而这些代号和实体磁盘的对应必须在BIOS 中完成另外值得注意的一点就是,由于只有第一台Floppy 和第一台Fixed Disk 可以用来启动(代号00h 以及80h),所以根据不同的启动设定,也必须将INT 13h Hook 的顺序作调整才能够顺利开机举例来说,如果ATA 硬盘占用掉80h,而SCSI 只能占用81h 之后的驱动器号的话,那么SCSI 硬盘就不能作为开机的硬盘了范例BCV Table0: ATA Drives1: Legacy Cards2: BCV #13: BCV #2BCV Priority0: 2 (BCV #1)1: 0 (ATA Drives)2: 1 (Legacy Cards)3: 3 (BCV #2)INT 13h 支持的装置有下列几种1. ATA Drive2. PnP Cards with BCVs3. Legacy Cards with Option ROMs4. Hard Drive BAID关于INT 13h 的几个重点1. 当INT 13h 被Hook 时,旧的INT 13h Vector 必须被保存2. 已经安装的硬盘数目必须被保存在BDA 0040:00753. 第一个安装的硬盘会得到80h 的代号,这也代表着它是开机硬盘4. 一旦安装到INT 13h 之后,就不能被卸载BCV Post PseudocodeCreated at BIOS build time:· First two BCV Table entries are filled in by ATA support andLegacy option ROMsupport.· The NV memory space for the IPL Priority is reserved.Assumptions:· The default for the BCV Priority will automatically becreated during POST in case the NV memory gets corrupted.1. Call the video option ROM.2. Initialize the first two BCV Table entries with ATA Supportand Legacy Cards respectively. These two entries will alwaysexist in the BCV Table and will always be in that order.3. Identify all option ROMs with BCVs and add any that arefound to the BCV Table.4. Call all the BCV option ROMs in the order they resid。

      点击阅读更多内容
      关于金锄头网 - 版权申诉 - 免责声明 - 诚邀英才 - 联系我们
      手机版 | 川公网安备 51140202000112号 | 经营许可证(蜀ICP备13022795号)
      ©2008-2016 by Sichuan Goldhoe Inc. All Rights Reserved.