Source-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[src/trunk]: src/sys/arch/aarch64/aarch64 Add a KASSERT



details:   https://anonhg.NetBSD.org/src/rev/c818abcaac92
branches:  trunk
changeset: 1023941:c818abcaac92
user:      skrll <skrll%NetBSD.org@localhost>
date:      Mon Oct 04 09:39:18 2021 +0000

description:
Add a KASSERT

diffstat:

 sys/arch/aarch64/aarch64/cpu.c |  5 +++--
 1 files changed, 3 insertions(+), 2 deletions(-)

diffs (26 lines):

diff -r e38a214bb562 -r c818abcaac92 sys/arch/aarch64/aarch64/cpu.c
--- a/sys/arch/aarch64/aarch64/cpu.c    Mon Oct 04 07:04:39 2021 +0000
+++ b/sys/arch/aarch64/aarch64/cpu.c    Mon Oct 04 09:39:18 2021 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: cpu.c,v 1.61 2021/08/30 22:57:33 jmcneill Exp $ */
+/* $NetBSD: cpu.c,v 1.62 2021/10/04 09:39:18 skrll Exp $ */
 
 /*
  * Copyright (c) 2017 Ryo Shimizu <ryo%nerv.org@localhost>
@@ -27,7 +27,7 @@
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(1, "$NetBSD: cpu.c,v 1.61 2021/08/30 22:57:33 jmcneill Exp $");
+__KERNEL_RCSID(1, "$NetBSD: cpu.c,v 1.62 2021/10/04 09:39:18 skrll Exp $");
 
 #include "locators.h"
 #include "opt_arm_debug.h"
@@ -681,6 +681,7 @@
 cpu_hatch(struct cpu_info *ci)
 {
        KASSERT(curcpu() == ci);
+       KASSERT((reg_tcr_el1_read() & TCR_EPD0) != 0);
 
        mutex_enter(&cpu_hatch_lock);
 



Home | Main Index | Thread Index | Old Index