PERFORCE change 93799 for review
Kip Macy
kmacy at FreeBSD.org
Wed Mar 22 17:11:44 UTC 2006
http://perforce.freebsd.org/chv.cgi?CH=93799
Change 93799 by kmacy at kmacy_storage:sun4vtmp on 2006/03/22 17:02:49
fix signal handling - trapframe and mcontext need to match up
si_addr should point to trap pc
Affected files ...
.. //depot/projects/kmacy_sun4v/src/sys/sun4v/include/frame.h#3 edit
.. //depot/projects/kmacy_sun4v/src/sys/sun4v/sun4v/machdep.c#17 edit
Differences ...
==== //depot/projects/kmacy_sun4v/src/sys/sun4v/include/frame.h#3 (text+ko) ====
@@ -39,16 +39,22 @@
struct trapframe {
uint64_t tf_global[8];
uint64_t tf_out[8];
- uint64_t tf_pad[8];
uint64_t tf_fprs;
uint64_t tf_fsr;
uint64_t tf_gsr;
+ uint64_t tf_pad0[1];
uint64_t tf_pil;
+ uint64_t tf_pad1[3];
+ uint64_t tf_tnpc;
uint64_t tf_tpc;
- uint64_t tf_tnpc;
uint64_t tf_tstate;
+ uint64_t tf_pad2[2];
uint64_t tf_wstate;
+ uint64_t tf_pad3[2];
};
+/* extra padding can go away once we re-shuffle user-land mcontext
+ */
+
#define tf_sp tf_out[6]
#define TF_DONE(tf) do { \
==== //depot/projects/kmacy_sun4v/src/sys/sun4v/sun4v/machdep.c#17 (text+ko) ====
@@ -515,11 +515,8 @@
tf->tf_out[4] = (register_t)catcher;
/* Fill siginfo structure. */
sf.sf_si = ksi->ksi_info;
-#ifdef notyet
- sf.sf_si.si_addr = (void *)tf->tf_sfar; /* XXX */
-#else
- printf("sendsig %d to %s\n", sig, p->p_comm);
-#endif
+ sf.sf_si.si_addr = (void *)tf->tf_tpc;
+
/* Copy the sigframe out to the user's stack. */
if (rwindow_save(td) != 0 || copyout(&sf, sfp, sizeof(*sfp)) != 0 ||
suword(&fp->fr_in[6], tf->tf_out[6]) != 0) {
More information about the p4-projects
mailing list