Re: [Qemu-devel] [PATCH] exec: fix tlb_vaddr_to_host()

2016-09-22 Thread Aurelien Jarno
On 2016-09-21 19:06, Laurent Vivier wrote: > When used in linux-user mode, tlb_vaddr_to_host(..., addr, ...)) > should return "g2h(addr)", but instead it returns "g2h(vaddr)". > As "vaddr" is "typedef uint64_t", the result of "g2h(vaddr)" is > "((void *)((unsigned long)(target_ulong)(uint64_t) +

Re: [Qemu-devel] [PATCH] exec: fix tlb_vaddr_to_host()

2016-09-22 Thread Laurent Vivier
Already fixed by a Ben's non applied patch: http://patchwork.ozlabs.org/patch/655238/ Laurent On 21/09/2016 19:06, Laurent Vivier wrote: > When used in linux-user mode, tlb_vaddr_to_host(..., addr, ...)) > should return "g2h(addr)", but instead it returns "g2h(vaddr)". > As "vaddr" is

[Qemu-devel] [PATCH] exec: fix tlb_vaddr_to_host()

2016-09-21 Thread Laurent Vivier
When used in linux-user mode, tlb_vaddr_to_host(..., addr, ...)) should return "g2h(addr)", but instead it returns "g2h(vaddr)". As "vaddr" is "typedef uint64_t", the result of "g2h(vaddr)" is "((void *)((unsigned long)(target_ulong)(uint64_t) + guest_base))". This bug has been found trying to