Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/trunk]: src/sys/arch/i386/i386 It looks like Xen cpu_hatch() calls cpu_s...
details: https://anonhg.NetBSD.org/src/rev/597e1a915d5b
branches: trunk
changeset: 847990:597e1a915d5b
user: ad <ad%NetBSD.org@localhost>
date: Mon Jan 13 12:03:41 2020 +0000
description:
It looks like Xen cpu_hatch() calls cpu_switchto() with prevlwp=NULL,
instead of calling idle_loop() directly. I can't test a change to
cpu_hatch() right now so allow for prevlwp=NULL.
diffstat:
sys/arch/i386/i386/locore.S | 8 ++++++--
1 files changed, 6 insertions(+), 2 deletions(-)
diffs (33 lines):
diff -r 7b5d02066e78 -r 597e1a915d5b sys/arch/i386/i386/locore.S
--- a/sys/arch/i386/i386/locore.S Mon Jan 13 11:53:24 2020 +0000
+++ b/sys/arch/i386/i386/locore.S Mon Jan 13 12:03:41 2020 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: locore.S,v 1.175 2020/01/08 17:38:41 ad Exp $ */
+/* $NetBSD: locore.S,v 1.176 2020/01/13 12:03:41 ad Exp $ */
/*
* Copyright-o-rama!
@@ -128,7 +128,7 @@
*/
#include <machine/asm.h>
-__KERNEL_RCSID(0, "$NetBSD: locore.S,v 1.175 2020/01/08 17:38:41 ad Exp $");
+__KERNEL_RCSID(0, "$NetBSD: locore.S,v 1.176 2020/01/13 12:03:41 ad Exp $");
#include "opt_copy_symtab.h"
#include "opt_ddb.h"
@@ -1316,10 +1316,14 @@
movl 20(%esp),%edi /* newlwp */
movl 24(%esp),%edx /* returning */
+ testl %esi,%esi /* oldlwp = NULL ? */
+ jz skip_save
+
/* Save old context. */
movl L_PCB(%esi),%eax
movl %esp,PCB_ESP(%eax)
movl %ebp,PCB_EBP(%eax)
+skip_save:
/* Switch to newlwp's stack. */
movl L_PCB(%edi),%ebx
Home |
Main Index |
Thread Index |
Old Index