Pasted as Plain Text [Remove this paste ]
Description: No description
URL: http://rafb.ath.cx/pastes/qBfBC762.html
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
.intel_syntax noprefix
.code16
.section .text
.global smp_start, smp_start_len
 
smp_start:
	cli
	mov esi, 0xDEADBEEF
	xor ax, ax
	mov ds, ax
	mov ss, ax
	mov eax, 0x8000 + (gdtr - smp_start)
	lgdt [eax]
	jmp 8:0x8000 + pmode - smp_start
 
.code32
pmode:
 
	inc eax
	hlt
	jmp pmode
 
gdt:
	.quad 0x0
	.quad 0x00CF9A000000FFFF
	.quad 0x00CF92000000FFFF
 
gdtr:
	.word 1474
	.long 0x8000 + (gdt - smp_start)
 
.equ smp_start_len, . - smp_start