소스 검색

[romprefix] Do not preserve unused register %di

Since some PnP BIOSes fail to set %es:di to point to the PnP signature
on entry, we identify a PnP BIOS by scanning through the top 64kB of
base memory looking for the PnP structure.  We therefore don't
actually use the values of %es:di provided to the initialisation entry
point, and so there is no need to preserve them.

Signed-off-by: Michael Brown <mcb30@ipxe.org>
tags/v1.20.1
Michael Brown 9 년 전
부모
커밋
16e235987f
1개의 변경된 파일1개의 추가작업 그리고 8개의 파일을 삭제
  1. 1
    8
      src/arch/i386/prefix/romprefix.S

+ 1
- 8
src/arch/i386/prefix/romprefix.S 파일 보기

@@ -208,15 +208,8 @@ init:
208 208
 	pushw	%cs
209 209
 	popw	%ds
210 210
 
211
-	/* Shuffle some registers around.  We need %di available for
212
-	 * the print_xxx functions, and in a register that's
213
-	 * addressable from %es, so shuffle as follows:
214
-	 *
215
-	 *    %di (pointer to PnP structure) => %bx
216
-	 *    %bx (runtime segment address, for PCI 3.0) => %gs
217
-	 */
211
+	/* Store PCI 3.0 runtime segment address for later use */
218 212
 	movw	%bx, %gs
219
-	movw	%di, %bx
220 213
 
221 214
 	/* Store PCI bus:dev.fn address */
222 215
 	movw	%ax, init_pci_busdevfn

Loading…
취소
저장