Move CR4.PGE enabling code after paging is enabled via CR0.PG based on
the description (2.5. CONTROL REGISTERS) of Intel developer's manual at: ftp://download.intel.com/design/PentiumII/manuals/24319202.pdf Reviewed by: peter, bde, tlambert2@mindspring.com Pointed-out by: "Shin'ya Kumabuchi" <kumabu@t3.rim.or.jp> MFC after: 1 week
This commit is contained in:
parent
f5c34b17b4
commit
a847e062d6
@ -374,6 +374,12 @@ begin:
|
||||
movl IdlePTD,%esi
|
||||
movl %esi,PCB_CR3(%eax)
|
||||
|
||||
testl $CPUID_PGE, R(cpu_feature)
|
||||
jz 1f
|
||||
movl %cr4, %eax
|
||||
orl $CR4_PGE, %eax
|
||||
movl %eax, %cr4
|
||||
1:
|
||||
pushl physfree /* value of first for init386(first) */
|
||||
call init386 /* wire 386 chip for unix operation */
|
||||
|
||||
@ -719,13 +725,6 @@ trycpuid: /* Use the `cpuid' instruction. */
|
||||
|
||||
create_pagetables:
|
||||
|
||||
testl $CPUID_PGE, R(cpu_feature)
|
||||
jz 1f
|
||||
movl %cr4, %eax
|
||||
orl $CR4_PGE, %eax
|
||||
movl %eax, %cr4
|
||||
1:
|
||||
|
||||
/* Find end of kernel image (rounded up to a page boundary). */
|
||||
movl $R(_end),%esi
|
||||
|
||||
|
@ -374,6 +374,12 @@ begin:
|
||||
movl IdlePTD,%esi
|
||||
movl %esi,PCB_CR3(%eax)
|
||||
|
||||
testl $CPUID_PGE, R(cpu_feature)
|
||||
jz 1f
|
||||
movl %cr4, %eax
|
||||
orl $CR4_PGE, %eax
|
||||
movl %eax, %cr4
|
||||
1:
|
||||
pushl physfree /* value of first for init386(first) */
|
||||
call init386 /* wire 386 chip for unix operation */
|
||||
|
||||
@ -719,13 +725,6 @@ trycpuid: /* Use the `cpuid' instruction. */
|
||||
|
||||
create_pagetables:
|
||||
|
||||
testl $CPUID_PGE, R(cpu_feature)
|
||||
jz 1f
|
||||
movl %cr4, %eax
|
||||
orl $CR4_PGE, %eax
|
||||
movl %eax, %cr4
|
||||
1:
|
||||
|
||||
/* Find end of kernel image (rounded up to a page boundary). */
|
||||
movl $R(_end),%esi
|
||||
|
||||
|
@ -374,6 +374,12 @@ begin:
|
||||
movl IdlePTD,%esi
|
||||
movl %esi,PCB_CR3(%eax)
|
||||
|
||||
testl $CPUID_PGE, R(cpu_feature)
|
||||
jz 1f
|
||||
movl %cr4, %eax
|
||||
orl $CR4_PGE, %eax
|
||||
movl %eax, %cr4
|
||||
1:
|
||||
pushl physfree /* value of first for init386(first) */
|
||||
call init386 /* wire 386 chip for unix operation */
|
||||
|
||||
@ -719,13 +725,6 @@ trycpuid: /* Use the `cpuid' instruction. */
|
||||
|
||||
create_pagetables:
|
||||
|
||||
testl $CPUID_PGE, R(cpu_feature)
|
||||
jz 1f
|
||||
movl %cr4, %eax
|
||||
orl $CR4_PGE, %eax
|
||||
movl %eax, %cr4
|
||||
1:
|
||||
|
||||
/* Find end of kernel image (rounded up to a page boundary). */
|
||||
movl $R(_end),%esi
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user