Fixed compilation error
[bochs-mirror.git] / patches / bochs-bios-win32.diff
blob5f6e29c734716afd51ff75f4459d246920527650
1 diff -Nurd bios-orig/rombios32.ld bios/rombios32.ld
2 --- bios-orig/rombios32.ld Sat Jan 26 09:15:27 2008
3 +++ bios/rombios32.ld Sat Mar 22 09:29:24 2008
4 @@ -1,4 +1,3 @@
5 -OUTPUT_FORMAT("elf32-i386", "elf32-i386", "elf32-i386")
6 OUTPUT_ARCH(i386)
7 ENTRY(_start);
8 SECTIONS
9 diff -Nurd bios-orig/rombios32start.S bios/rombios32start.S
10 --- bios-orig/rombios32start.S Sat Jan 26 09:15:27 2008
11 +++ bios/rombios32start.S Sat Mar 22 09:30:49 2008
12 @@ -21,12 +21,12 @@
13 #include "rombios.h"
15 .globl _start
16 -.globl smp_ap_boot_code_start
17 -.globl smp_ap_boot_code_end
18 -.global smm_relocation_start
19 -.global smm_relocation_end
20 -.global smm_code_start
21 -.global smm_code_end
22 +.globl _smp_ap_boot_code_start
23 +.globl _smp_ap_boot_code_end
24 +.global _smm_relocation_start
25 +.global _smm_relocation_end
26 +.global _smm_code_start
27 +.global _smm_code_end
29 _start:
30 /* clear bss section */
31 @@ -36,20 +36,20 @@
32 sub %edi, %ecx
33 rep stosb
35 - jmp rombios32_init
36 + jmp _rombios32_init
38 .code16
39 -smp_ap_boot_code_start:
40 +_smp_ap_boot_code_start:
41 xor %ax, %ax
42 mov %ax, %ds
43 incw CPU_COUNT_ADDR
45 hlt
46 jmp 1b
47 -smp_ap_boot_code_end:
48 +_smp_ap_boot_code_end:
50 /* code to relocate SMBASE to 0xa0000 */
51 -smm_relocation_start:
52 +_smm_relocation_start:
53 mov $0x38000 + 0x7efc, %ebx
54 addr32 mov (%ebx), %al /* revision ID to see if x86_64 or x86 */
55 cmp $0x64, %al
56 @@ -66,10 +66,10 @@
57 movw $0xb3, %dx
58 outb %al, %dx
59 rsm
60 -smm_relocation_end:
61 +_smm_relocation_end:
63 /* minimal SMM code to enable or disable ACPI */
64 -smm_code_start:
65 +_smm_code_start:
66 movw $0xb2, %dx
67 inb %dx, %al
68 cmp $0xf0, %al
69 @@ -95,4 +95,4 @@
72 rsm
73 -smm_code_end:
74 +_smm_code_end: