linux-user/signal.c: Use target address instead of host address for microblaze restorer
PATCH 1/1 linux-user/signal.c: Use target address instead of host address for microblaze restorer
From: Chen Gang <[email protected]>
The return address is in target space, so the restorer address needs to be target space, too.
--- linux-user/signal.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-)
linux-user/signal.c +2 -1
@@ -3532,7 +3532,8 @@ static void setup_frame(int sig, struct target_sigaction *ka,/* Return from sighandler will jump to the tramp. Negative 8 offset because return is rtsd r15, 8 */ - env->regs[15 ] = ((unsigned long )frame->tramp) -8 ; + env->regs[15 ] = frame_addr + offsetof(struct target_signal_frame , tramp) + -8 ; }/* Set up registers for signal handler */
Signature · 1 line
1.9.3
Quoted 15 lines · On 29 March 2016 at 15:13, <[email protected]> wrote:
From: Chen Gang <[email protected]>
The return address is in target space, so the restorer address needs to be target space, too.
Signed-off-by Chen Gang <[email protected]>--- linux-user/signal.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-)linux-user/signal.c +0
-0
linux-user/signal.c static void setup_frame(int sig, struct target_sigaction *ka, · line 3539
Quoted 9 lines
linux-user/signal.c +2
-1@@ -3532,7 +3532,8 @@ static void setup_frame(int sig, struct target_sigaction *ka,/* Return from sighandler will jump to the tramp. Negative 8 offset because return is rtsd r15, 8 */ - env->regs[15 ] = ((unsigned long )frame->tramp) -8 ; + env->regs[15 ] = frame_addr + offsetof(struct target_signal_frame , tramp) + -8 ; }/* Set up registers for signal handler */
thanks
-- PMM
Quoted 24 lines · Peter Maydell
Quoted 23 lines · On 29 March 2016 at 15:13, <[email protected]> wrote:
From: Chen Gang <[email protected]>
The return address is in target space, so the restorer address needs to be target space, too.
Signed-off-by Chen Gang <[email protected]>--- linux-user/signal.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-)linux-user/signal.c +2
-1@@ -3532,7 +3532,8 @@ static void setup_frame(int sig, struct target_sigaction *ka,/* Return from sighandler will jump to the tramp. Negative 8 offset because return is rtsd r15, 8 */ - env->regs[15 ] = ((unsigned long )frame->tramp) -8 ; + env->regs[15 ] = frame_addr + offsetof(struct target_signal_frame , tramp) + -8 ; }
Quoted 4 lines
linux-user/signal.c static void setup_frame(int sig, struct target_sigaction *ka, · line 3539
Quoted 1 line
linux-user/signal.c +0
-0/* Set up registers for signal handler */ Reviewed-by Peter Maydell <[email protected]>
Thank all of you for the 2 patches reviewing.
I guess, this month, I may have free time (at least, will not be as busy as the previous month), I shall finish tilegx floating point insns (it has been delayed too long).
Thanks.
Signature · 3 lines
Chen Gang (陈刚) Managing Natural Environments is the Duty of Human Beings.
Edgar E. Iglesias
Reviewed-byQuoted 30 lines · Chen Gang
Quoted 24 lines · Peter Maydell
Quoted 23 lines · On 29 March 2016 at 15:13, <[email protected]> wrote:
From: Chen Gang <[email protected]>
The return address is in target space, so the restorer address needs to be target space, too.
Signed-off-by Chen Gang <[email protected]>--- linux-user/signal.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-)linux-user/signal.c +2
-1@@ -3532,7 +3532,8 @@ static void setup_frame(int sig, struct target_sigaction *ka,/* Return from sighandler will jump to the tramp. Negative 8 offset because return is rtsd r15, 8 */ - env->regs[15 ] = ((unsigned long )frame->tramp) -8 ; + env->regs[15 ] = frame_addr + offsetof(struct target_signal_frame , tramp) + -8 ; }Quoted 4 lines
linux-user/signal.c static void setup_frame(int sig, struct target_sigaction *ka, · line 3539
Quoted 1 line
linux-user/signal.c +0
-0/* Set up registers for signal handler */ Reviewed-by Peter Maydell <[email protected]>
Quoted 5 lines
Thank all of you for the 2 patches reviewing.
I guess, this month, I may have free time (at least, will not be as busy as the previous month), I shall finish tilegx floating point insns (it has been delayed too long).
Quoted 31 lines · Edgar E. Iglesias
Quoted 30 lines · Chen Gang
Quoted 28 lines · Peter Maydell
Quoted 15 lines · On 29 March 2016 at 15:13, <[email protected]> wrote:
From: Chen Gang <[email protected]>
The return address is in target space, so the restorer address needs to be target space, too.
Signed-off-by Chen Gang <[email protected]>--- linux-user/signal.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-)linux-user/signal.c +0
-0linux-user/signal.c static void setup_frame(int sig, struct target_sigaction *ka, · line 3539
Quoted 9 lines
linux-user/signal.c +2
-1@@ -3532,7 +3532,8 @@ static void setup_frame(int sig, struct target_sigaction *ka,/* Return from sighandler will jump to the tramp. Negative 8 offset because return is rtsd r15, 8 */ - env->regs[15 ] = ((unsigned long )frame->tramp) -8 ; + env->regs[15 ] = frame_addr + offsetof(struct target_signal_frame , tramp) + -8 ; }/* Set up registers for signal handler */ Reviewed-by Peter Maydell <[email protected]>
Quoted 8 lines
Quoted 5 lines
Thank all of you for the 2 patches reviewing.
I guess, this month, I may have free time (at least, will not be as busy as the previous month), I shall finish tilegx floating point insns (it has been delayed too long).
Reviewed-by Edgar E. Iglesias <[email protected]>
OK, thank you for your work.
And now (finally), I guess, I should have free time for open source, and I should try to finish tilegx floating point insns within this month.
Thanks.
Signature · 3 lines
Chen Gang (陈刚) Managing Natural Environments is the Duty of Human Beings.
Quoted 16 lines · Le 29/03/2016 à 16:13, [email protected] a écrit :
From: Chen Gang <[email protected]>
The return address is in target space, so the restorer address needs to be target space, too.
Signed-off-by Chen Gang <[email protected]>--- linux-user/signal.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-)linux-user/signal.c +0
-0
linux-user/signal.c static void setup_frame(int sig, struct target_sigaction *ka, · line 3539
Quoted 9 lines
linux-user/signal.c +2
-1@@ -3532,7 +3532,8 @@ static void setup_frame(int sig, struct target_sigaction *ka,/* Return from sighandler will jump to the tramp. Negative 8 offset because return is rtsd r15, 8 */ - env->regs[15 ] = ((unsigned long )frame->tramp) -8 ; + env->regs[15 ] = frame_addr + offsetof(struct target_signal_frame , tramp) + -8 ; }/* Set up registers for signal handler */