* [Qemu-devel] [PATCH] linux-user/signal.c: Use target address instead of host address for microblaze restorer
@ 2016-03-29 14:13 chengang
2016-05-04 16:05 ` Peter Maydell
2016-05-04 17:46 ` Laurent Vivier
0 siblings, 2 replies; 6+ messages in thread
From: chengang @ 2016-03-29 14:13 UTC (permalink / raw)
To: rth, peter.maydell, cmetcalf, laurent, edgar.iglesias
Cc: walt, Chen Gang, riku.voipio, qemu-devel, Chen Gang
From: Chen Gang <chengang@emindsoft.com.cn>
The return address is in target space, so the restorer address needs to
be target space, too.
Signed-off-by: Chen Gang <gang.chen.5i5j@gmail.com>
---
linux-user/signal.c | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/linux-user/signal.c b/linux-user/signal.c
index 4157154..c0a6f7e 100644
--- a/linux-user/signal.c
+++ b/linux-user/signal.c
@@ -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 */
--
1.9.3
^ permalink raw reply related [flat|nested] 6+ messages in thread
* Re: [Qemu-devel] [PATCH] linux-user/signal.c: Use target address instead of host address for microblaze restorer
2016-03-29 14:13 [Qemu-devel] [PATCH] linux-user/signal.c: Use target address instead of host address for microblaze restorer chengang
@ 2016-05-04 16:05 ` Peter Maydell
2016-05-05 14:48 ` Chen Gang
2016-05-04 17:46 ` Laurent Vivier
1 sibling, 1 reply; 6+ messages in thread
From: Peter Maydell @ 2016-05-04 16:05 UTC (permalink / raw)
To: Chen Gang
Cc: Richard Henderson, Chris Metcalf, Laurent Vivier,
Edgar E. Iglesias, walt@tilera.com, Riku Voipio, QEMU Developers,
Chen Gang
On 29 March 2016 at 15:13, <chengang@emindsoft.com.cn> wrote:
> From: Chen Gang <chengang@emindsoft.com.cn>
>
> The return address is in target space, so the restorer address needs to
> be target space, too.
>
> Signed-off-by: Chen Gang <gang.chen.5i5j@gmail.com>
> ---
> linux-user/signal.c | 3 ++-
> 1 file changed, 2 insertions(+), 1 deletion(-)
>
> diff --git a/linux-user/signal.c b/linux-user/signal.c
> index 4157154..c0a6f7e 100644
> --- a/linux-user/signal.c
> +++ b/linux-user/signal.c
> @@ -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 <peter.maydell@linaro.org>
thanks
-- PMM
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: [Qemu-devel] [PATCH] linux-user/signal.c: Use target address instead of host address for microblaze restorer
2016-03-29 14:13 [Qemu-devel] [PATCH] linux-user/signal.c: Use target address instead of host address for microblaze restorer chengang
2016-05-04 16:05 ` Peter Maydell
@ 2016-05-04 17:46 ` Laurent Vivier
1 sibling, 0 replies; 6+ messages in thread
From: Laurent Vivier @ 2016-05-04 17:46 UTC (permalink / raw)
To: chengang, rth, peter.maydell, cmetcalf, edgar.iglesias
Cc: walt, riku.voipio, qemu-devel, Chen Gang
Le 29/03/2016 à 16:13, chengang@emindsoft.com.cn a écrit :
> From: Chen Gang <chengang@emindsoft.com.cn>
>
> The return address is in target space, so the restorer address needs to
> be target space, too.
>
> Signed-off-by: Chen Gang <gang.chen.5i5j@gmail.com>
> ---
> linux-user/signal.c | 3 ++-
> 1 file changed, 2 insertions(+), 1 deletion(-)
>
> diff --git a/linux-user/signal.c b/linux-user/signal.c
> index 4157154..c0a6f7e 100644
> --- a/linux-user/signal.c
> +++ b/linux-user/signal.c
> @@ -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: Laurent Vivier <laurent@vivier.eu>
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: [Qemu-devel] [PATCH] linux-user/signal.c: Use target address instead of host address for microblaze restorer
2016-05-04 16:05 ` Peter Maydell
@ 2016-05-05 14:48 ` Chen Gang
2016-05-05 16:11 ` Edgar E. Iglesias
0 siblings, 1 reply; 6+ messages in thread
From: Chen Gang @ 2016-05-05 14:48 UTC (permalink / raw)
To: Peter Maydell
Cc: Richard Henderson, Chris Metcalf, Laurent Vivier,
Edgar E. Iglesias, walt@tilera.com, Riku Voipio, QEMU Developers,
Chen Gang
On 5/5/16 00:05, Peter Maydell wrote:
> On 29 March 2016 at 15:13, <chengang@emindsoft.com.cn> wrote:
>> From: Chen Gang <chengang@emindsoft.com.cn>
>>
>> The return address is in target space, so the restorer address needs to
>> be target space, too.
>>
>> Signed-off-by: Chen Gang <gang.chen.5i5j@gmail.com>
>> ---
>> linux-user/signal.c | 3 ++-
>> 1 file changed, 2 insertions(+), 1 deletion(-)
>>
>> diff --git a/linux-user/signal.c b/linux-user/signal.c
>> index 4157154..c0a6f7e 100644
>> --- a/linux-user/signal.c
>> +++ b/linux-user/signal.c
>> @@ -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 <peter.maydell@linaro.org>
>
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.
--
Chen Gang (陈刚)
Managing Natural Environments is the Duty of Human Beings.
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: [Qemu-devel] [PATCH] linux-user/signal.c: Use target address instead of host address for microblaze restorer
2016-05-05 14:48 ` Chen Gang
@ 2016-05-05 16:11 ` Edgar E. Iglesias
2016-05-14 3:19 ` Chen Gang
0 siblings, 1 reply; 6+ messages in thread
From: Edgar E. Iglesias @ 2016-05-05 16:11 UTC (permalink / raw)
To: Chen Gang
Cc: Peter Maydell, Richard Henderson, Chris Metcalf, Laurent Vivier,
walt@tilera.com, Riku Voipio, QEMU Developers, Chen Gang
On Thu, May 05, 2016 at 10:48:57PM +0800, Chen Gang wrote:
> On 5/5/16 00:05, Peter Maydell wrote:
> > On 29 March 2016 at 15:13, <chengang@emindsoft.com.cn> wrote:
> >> From: Chen Gang <chengang@emindsoft.com.cn>
> >>
> >> The return address is in target space, so the restorer address needs to
> >> be target space, too.
> >>
> >> Signed-off-by: Chen Gang <gang.chen.5i5j@gmail.com>
> >> ---
> >> linux-user/signal.c | 3 ++-
> >> 1 file changed, 2 insertions(+), 1 deletion(-)
> >>
> >> diff --git a/linux-user/signal.c b/linux-user/signal.c
> >> index 4157154..c0a6f7e 100644
> >> --- a/linux-user/signal.c
> >> +++ b/linux-user/signal.c
> >> @@ -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 <peter.maydell@linaro.org>
> >
>
> 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 <edgar.iglesias@xilinx.com>
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: [Qemu-devel] [PATCH] linux-user/signal.c: Use target address instead of host address for microblaze restorer
2016-05-05 16:11 ` Edgar E. Iglesias
@ 2016-05-14 3:19 ` Chen Gang
0 siblings, 0 replies; 6+ messages in thread
From: Chen Gang @ 2016-05-14 3:19 UTC (permalink / raw)
To: Edgar E. Iglesias, Chen Gang
Cc: Peter Maydell, Richard Henderson, Chris Metcalf, Laurent Vivier,
walt@tilera.com, Riku Voipio, QEMU Developers, Chen Gang
On 5/6/16 00:11, Edgar E. Iglesias wrote:
> On Thu, May 05, 2016 at 10:48:57PM +0800, Chen Gang wrote:
>> On 5/5/16 00:05, Peter Maydell wrote:
>>> On 29 March 2016 at 15:13, <chengang@emindsoft.com.cn> wrote:
>>>> From: Chen Gang <chengang@emindsoft.com.cn>
>>>>
>>>> The return address is in target space, so the restorer address needs to
>>>> be target space, too.
>>>>
>>>> Signed-off-by: Chen Gang <gang.chen.5i5j@gmail.com>
>>>> ---
>>>> linux-user/signal.c | 3 ++-
>>>> 1 file changed, 2 insertions(+), 1 deletion(-)
>>>>
>>>> diff --git a/linux-user/signal.c b/linux-user/signal.c
>>>> index 4157154..c0a6f7e 100644
>>>> --- a/linux-user/signal.c
>>>> +++ b/linux-user/signal.c
>>>> @@ -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 <peter.maydell@linaro.org>
>>>
>>
>> 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 <edgar.iglesias@xilinx.com>
>
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.
--
Chen Gang (陈刚)
Managing Natural Environments is the Duty of Human Beings.
^ permalink raw reply [flat|nested] 6+ messages in thread
end of thread, other threads:[~2016-05-14 3:14 UTC | newest]
Thread overview: 6+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2016-03-29 14:13 [Qemu-devel] [PATCH] linux-user/signal.c: Use target address instead of host address for microblaze restorer chengang
2016-05-04 16:05 ` Peter Maydell
2016-05-05 14:48 ` Chen Gang
2016-05-05 16:11 ` Edgar E. Iglesias
2016-05-14 3:19 ` Chen Gang
2016-05-04 17:46 ` Laurent Vivier
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).