Source-Changes-HG archive

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

[src/trunk]: src/lib/libpthread/arch/sh3 Add _INITCONTEXT_U_MD, we need to cl...



details:   https://anonhg.NetBSD.org/src/rev/feb70ab1bb84
branches:  trunk
changeset: 555546:feb70ab1bb84
user:      uwe <uwe%NetBSD.org@localhost>
date:      Thu Nov 20 17:38:08 2003 +0000

description:
Add _INITCONTEXT_U_MD, we need to clean _REG_SR.

diffstat:

 lib/libpthread/arch/sh3/pthread_md.h |  8 +++++++-
 1 files changed, 7 insertions(+), 1 deletions(-)

diffs (22 lines):

diff -r 7c01c40f9d42 -r feb70ab1bb84 lib/libpthread/arch/sh3/pthread_md.h
--- a/lib/libpthread/arch/sh3/pthread_md.h      Thu Nov 20 17:16:41 2003 +0000
+++ b/lib/libpthread/arch/sh3/pthread_md.h      Thu Nov 20 17:38:08 2003 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: pthread_md.h,v 1.1 2003/06/23 19:34:45 uwe Exp $ */
+/*     $NetBSD: pthread_md.h,v 1.2 2003/11/20 17:38:08 uwe Exp $ */
 
 /*
  * Copyright 2003 Wasabi Systems, Inc.
@@ -50,6 +50,12 @@
 #define pthread__uc_sp(ucp) ((ucp)->uc_mcontext.__gregs[_REG_R15])
 #define pthread__uc_pc(ucp) ((ucp)->uc_mcontext.__gregs[_REG_PC])
 
+/*
+ * Set initial, sane values for registers whose values aren't just
+ * "don't care".
+ */
+#define _INITCONTEXT_U_MD(ucp)                                         \
+       (ucp)->uc_mcontext.__gregs[_REG_SR] = 0;
 
 /*
  * SH3 requires no extra stack space



Home | Main Index | Thread Index | Old Index