PERFORCE change 28476 for review
Peter Wemm
peter at FreeBSD.org
Mon Apr 7 19:53:14 PDT 2003
http://perforce.freebsd.org/chv.cgi?CH=28476
Change 28476 by peter at peter_daintree on 2003/04/07 19:53:11
Make sure we dont blow up in cpu_switch() for unknown reasons.
Blow up for known reasons instead.
Affected files ...
.. //depot/projects/hammer/sys/x86_64/x86_64/swtch.s#14 edit
Differences ...
==== //depot/projects/hammer/sys/x86_64/x86_64/swtch.s#14 (text+ko) ====
@@ -59,6 +59,10 @@
* 16(%rsp) = newtd
*/
ENTRY(cpu_throw)
+ movq $nothrow, %rdi
+ call serial_puts
+ movq $nothrow, %rdi
+ call panic
xorq %rsi, %rsi
movl PCPU(CPUID), %esi
movq 8(%rsp),%rcx /* Old thread */
@@ -90,6 +94,11 @@
*/
ENTRY(cpu_switch)
+ movq $noswitch, %rdi
+ call serial_puts
+ movq $noswitch, %rdi
+ call panic
+
/* Switch to new thread. First, save context. */
movq 8(%rsp),%rcx
@@ -232,6 +241,8 @@
sw0_3: .asciz "cpu_switch: no newthread supplied"
#endif
+noswitch: .asciz "cpu_switch: called!"
+nothrow: .asciz "cpu_throw: called!"
/*
* savectx(pcb)
* Update pcb, saving current processor state.
More information about the p4-projects
mailing list