ARM_MMU_EXTENDED support.
This commit is contained in:
parent
47494f6774
commit
fa0e082493
@ -1,4 +1,4 @@
|
||||
/* $NetBSD: arm32_kvminit.c,v 1.24 2014/03/05 02:17:21 matt Exp $ */
|
||||
/* $NetBSD: arm32_kvminit.c,v 1.25 2014/03/28 21:56:45 matt Exp $ */
|
||||
|
||||
/*
|
||||
* Copyright (c) 2002, 2003, 2005 Genetec Corporation. All rights reserved.
|
||||
@ -122,7 +122,7 @@
|
||||
*/
|
||||
|
||||
#include <sys/cdefs.h>
|
||||
__KERNEL_RCSID(0, "$NetBSD: arm32_kvminit.c,v 1.24 2014/03/05 02:17:21 matt Exp $");
|
||||
__KERNEL_RCSID(0, "$NetBSD: arm32_kvminit.c,v 1.25 2014/03/28 21:56:45 matt Exp $");
|
||||
|
||||
#include <sys/param.h>
|
||||
#include <sys/device.h>
|
||||
@ -371,7 +371,7 @@ arm32_kernel_vm_init(vaddr_t kernel_vm_base, vaddr_t vectors, vaddr_t iovbase,
|
||||
{
|
||||
struct bootmem_info * const bmi = &bootmem_info;
|
||||
#ifdef MULTIPROCESSOR
|
||||
const size_t cpu_num = arm_cpu_max + 1;
|
||||
const size_t cpu_num = arm_cpu_max;
|
||||
#else
|
||||
const size_t cpu_num = 1;
|
||||
#endif
|
||||
@ -903,11 +903,12 @@ arm32_kernel_vm_init(vaddr_t kernel_vm_base, vaddr_t vectors, vaddr_t iovbase,
|
||||
* tables.
|
||||
*/
|
||||
|
||||
#if defined(VERBOSE_INIT_ARM) && 0
|
||||
#if defined(VERBOSE_INIT_ARM)
|
||||
printf("TTBR0=%#x", armreg_ttbr_read());
|
||||
#ifdef _ARM_ARCH_6
|
||||
printf(" TTBR1=%#x TTBCR=%#x",
|
||||
armreg_ttbr1_read(), armreg_ttbcr_read());
|
||||
printf(" TTBR1=%#x TTBCR=%#x CONTEXTIDR=%#x",
|
||||
armreg_ttbr1_read(), armreg_ttbcr_read(),
|
||||
armreg_contextidr_read());
|
||||
#endif
|
||||
printf("\n");
|
||||
#endif
|
||||
@ -931,6 +932,7 @@ arm32_kernel_vm_init(vaddr_t kernel_vm_base, vaddr_t vectors, vaddr_t iovbase,
|
||||
/*
|
||||
* TTBCR should have been initialized by the MD start code.
|
||||
*/
|
||||
KASSERT((armreg_contextidr_read() & 0xff) == 0);
|
||||
KASSERT(armreg_ttbcr_read() == __SHIFTIN(1, TTBCR_S_N));
|
||||
/*
|
||||
* Disable lookups via TTBR0 until there is an activated pmap.
|
||||
@ -951,6 +953,20 @@ arm32_kernel_vm_init(vaddr_t kernel_vm_base, vaddr_t vectors, vaddr_t iovbase,
|
||||
#else
|
||||
printf(" (TTBR0=%#x)", armreg_ttbr_read());
|
||||
#endif
|
||||
#endif
|
||||
|
||||
#ifdef MULTIPROCESSOR
|
||||
/*
|
||||
* Kick the secondaries to load the TTB. After which they'll go
|
||||
* back to sleep to wait for the final kick so they will hatch.
|
||||
*/
|
||||
#ifdef VERBOSE_INIT_ARM
|
||||
printf(" hatchlings");
|
||||
#endif
|
||||
cpu_boot_secondary_processors();
|
||||
#endif
|
||||
|
||||
#ifdef VERBOSE_INIT_ARM
|
||||
printf(" OK\n");
|
||||
#endif
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user