On 08/05/2016 10:59 AM, Lluís Vilanova wrote:
> QEMU detects when the guest uses 'mmap' on hypertrace's control channel
> file, and then uses 'mprotect' to detect accesses to it, which are used
> to trigger traceing event "guest_hypertrace".

s/traceing/tracing/

I'll probably leave the technical review to others, though



> +++ b/bsd-user/mmap.c
> @@ -21,6 +21,7 @@
>  #include "qemu.h"
>  #include "qemu-common.h"
>  #include "bsd-mman.h"
> +#include "hypertrace/user.h"
>  
>  //#define DEBUG_MMAP
>  
> @@ -407,6 +408,7 @@ abi_long target_mmap(abi_ulong start, abi_ulong len, int 
> prot,
>          }
>      }
>   the_end1:
> +    hypertrace_guest_mmap(fd, (void *)g2h(start));

Why is the cast to void* needed?



-- 
Eric Blake   eblake redhat com    +1-919-301-3266
Libvirt virtualization library http://libvirt.org

Attachment: signature.asc
Description: OpenPGP digital signature

Reply via email to