* [Qemu-devel] [PATCH for 1.7] exec: fix breakpoint_invalidate when pc may not be translated
@ 2013-10-28 0:43 Max Filippov
2013-11-06 18:23 ` Max Filippov
0 siblings, 1 reply; 3+ messages in thread
From: Max Filippov @ 2013-10-28 0:43 UTC (permalink / raw)
To: qemu-devel; +Cc: pbonzini, qemu-stable, Max Filippov
This fixes qemu abort with the following message:
include/qemu/int128.h:22: int128_get64: Assertion `!a.hi' failed.
which happens due to attempt to invalidate breakpoint by virtual address
for which get_phys_page_debug couldn't find mapping.
For more details see
http://lists.nongnu.org/archive/html/qemu-devel/2013-09/msg04582.html
Cc: qemu-stable@nongnu.org
Signed-off-by: Max Filippov <jcmvbkbc@gmail.com>
---
exec.c | 6 ++++--
1 file changed, 4 insertions(+), 2 deletions(-)
diff --git a/exec.c b/exec.c
index 2e31ffc..9150430 100644
--- a/exec.c
+++ b/exec.c
@@ -409,8 +409,10 @@ static void breakpoint_invalidate(CPUState *cpu, target_ulong pc)
#else
static void breakpoint_invalidate(CPUState *cpu, target_ulong pc)
{
- tb_invalidate_phys_addr(cpu_get_phys_page_debug(cpu, pc) |
- (pc & ~TARGET_PAGE_MASK));
+ hwaddr phys = cpu_get_phys_page_debug(cpu, pc);
+ if (phys != -1) {
+ tb_invalidate_phys_addr(phys | (pc & ~TARGET_PAGE_MASK));
+ }
}
#endif
#endif /* TARGET_HAS_ICE */
--
1.8.1.4
^ permalink raw reply related [flat|nested] 3+ messages in thread
* Re: [Qemu-devel] [PATCH for 1.7] exec: fix breakpoint_invalidate when pc may not be translated
2013-10-28 0:43 [Qemu-devel] [PATCH for 1.7] exec: fix breakpoint_invalidate when pc may not be translated Max Filippov
@ 2013-11-06 18:23 ` Max Filippov
2013-11-07 9:52 ` Paolo Bonzini
0 siblings, 1 reply; 3+ messages in thread
From: Max Filippov @ 2013-11-06 18:23 UTC (permalink / raw)
To: qemu-devel; +Cc: Paolo Bonzini, qemu-stable, Max Filippov
On Mon, Oct 28, 2013 at 4:43 AM, Max Filippov <jcmvbkbc@gmail.com> wrote:
> This fixes qemu abort with the following message:
>
> include/qemu/int128.h:22: int128_get64: Assertion `!a.hi' failed.
>
> which happens due to attempt to invalidate breakpoint by virtual address
> for which get_phys_page_debug couldn't find mapping.
>
> For more details see
> http://lists.nongnu.org/archive/html/qemu-devel/2013-09/msg04582.html
Ping^2?
> Cc: qemu-stable@nongnu.org
> Signed-off-by: Max Filippov <jcmvbkbc@gmail.com>
> ---
> exec.c | 6 ++++--
> 1 file changed, 4 insertions(+), 2 deletions(-)
>
> diff --git a/exec.c b/exec.c
> index 2e31ffc..9150430 100644
> --- a/exec.c
> +++ b/exec.c
> @@ -409,8 +409,10 @@ static void breakpoint_invalidate(CPUState *cpu, target_ulong pc)
> #else
> static void breakpoint_invalidate(CPUState *cpu, target_ulong pc)
> {
> - tb_invalidate_phys_addr(cpu_get_phys_page_debug(cpu, pc) |
> - (pc & ~TARGET_PAGE_MASK));
> + hwaddr phys = cpu_get_phys_page_debug(cpu, pc);
> + if (phys != -1) {
> + tb_invalidate_phys_addr(phys | (pc & ~TARGET_PAGE_MASK));
> + }
> }
> #endif
> #endif /* TARGET_HAS_ICE */
> --
> 1.8.1.4
>
--
Thanks.
-- Max
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [Qemu-devel] [PATCH for 1.7] exec: fix breakpoint_invalidate when pc may not be translated
2013-11-06 18:23 ` Max Filippov
@ 2013-11-07 9:52 ` Paolo Bonzini
0 siblings, 0 replies; 3+ messages in thread
From: Paolo Bonzini @ 2013-11-07 9:52 UTC (permalink / raw)
To: Max Filippov; +Cc: qemu-devel, qemu-stable
Il 06/11/2013 19:23, Max Filippov ha scritto:
> On Mon, Oct 28, 2013 at 4:43 AM, Max Filippov <jcmvbkbc@gmail.com> wrote:
>> This fixes qemu abort with the following message:
>>
>> include/qemu/int128.h:22: int128_get64: Assertion `!a.hi' failed.
>>
>> which happens due to attempt to invalidate breakpoint by virtual address
>> for which get_phys_page_debug couldn't find mapping.
>>
>> For more details see
>> http://lists.nongnu.org/archive/html/qemu-devel/2013-09/msg04582.html
>
> Ping^2?
Reviewed-by: Paolo Bonzini <pbonzini@redhat.com>
>> Cc: qemu-stable@nongnu.org
>> Signed-off-by: Max Filippov <jcmvbkbc@gmail.com>
>> ---
>> exec.c | 6 ++++--
>> 1 file changed, 4 insertions(+), 2 deletions(-)
>>
>> diff --git a/exec.c b/exec.c
>> index 2e31ffc..9150430 100644
>> --- a/exec.c
>> +++ b/exec.c
>> @@ -409,8 +409,10 @@ static void breakpoint_invalidate(CPUState *cpu, target_ulong pc)
>> #else
>> static void breakpoint_invalidate(CPUState *cpu, target_ulong pc)
>> {
>> - tb_invalidate_phys_addr(cpu_get_phys_page_debug(cpu, pc) |
>> - (pc & ~TARGET_PAGE_MASK));
>> + hwaddr phys = cpu_get_phys_page_debug(cpu, pc);
>> + if (phys != -1) {
>> + tb_invalidate_phys_addr(phys | (pc & ~TARGET_PAGE_MASK));
>> + }
>> }
>> #endif
>> #endif /* TARGET_HAS_ICE */
>> --
>> 1.8.1.4
>>
>
>
>
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2013-11-07 9:52 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2013-10-28 0:43 [Qemu-devel] [PATCH for 1.7] exec: fix breakpoint_invalidate when pc may not be translated Max Filippov
2013-11-06 18:23 ` Max Filippov
2013-11-07 9:52 ` Paolo Bonzini
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).