Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/trunk]: src/sys/arch/arm/arm Some preemption updates - still not being u...
details: https://anonhg.NetBSD.org/src/rev/60bcbc1d3bd0
branches: trunk
changeset: 952915:60bcbc1d3bd0
user: skrll <skrll%NetBSD.org@localhost>
date: Sun Feb 21 08:46:28 2021 +0000
description:
Some preemption updates - still not being used (yet)
diffstat:
sys/arch/arm/arm/arm_machdep.c | 12 +++++++++---
1 files changed, 9 insertions(+), 3 deletions(-)
diffs (46 lines):
diff -r 492cb49f2e16 -r 60bcbc1d3bd0 sys/arch/arm/arm/arm_machdep.c
--- a/sys/arch/arm/arm/arm_machdep.c Sun Feb 21 08:31:36 2021 +0000
+++ b/sys/arch/arm/arm/arm_machdep.c Sun Feb 21 08:46:28 2021 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: arm_machdep.c,v 1.65 2020/12/01 02:43:13 rin Exp $ */
+/* $NetBSD: arm_machdep.c,v 1.66 2021/02/21 08:46:28 skrll Exp $ */
/*
* Copyright (c) 2001 Wasabi Systems, Inc.
@@ -80,7 +80,7 @@
#include <sys/param.h>
-__KERNEL_RCSID(0, "$NetBSD: arm_machdep.c,v 1.65 2020/12/01 02:43:13 rin Exp $");
+__KERNEL_RCSID(0, "$NetBSD: arm_machdep.c,v 1.66 2021/02/21 08:46:28 skrll Exp $");
#include <sys/atomic.h>
#include <sys/cpu.h>
@@ -223,6 +223,8 @@
cpu_need_resched(struct cpu_info *ci, struct lwp *l, int flags)
{
+ KASSERT(kpreempt_disabled());
+
if (flags & RESCHED_IDLE) {
#ifdef MULTIPROCESSOR
/*
@@ -322,13 +324,17 @@
bool
cpu_kpreempt_enter(uintptr_t where, int s)
{
+
+ KASSERT(kpreempt_disabled());
+
return s == IPL_NONE;
}
void
cpu_kpreempt_exit(uintptr_t where)
{
- atomic_and_uint(&curcpu()->ci_astpending, (unsigned int)~__BIT(1));
+
+ /* do nothing */
}
bool
Home |
Main Index |
Thread Index |
Old Index