qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
From: "Philippe Mathieu-Daudé" <philmd@redhat.com>
To: Alexander Bulekov <alxndr@bu.edu>, qemu-devel@nongnu.org
Cc: darren.kenny@oracle.com, bsd@redhat.com,
	Richard Henderson <rth@twiddle.net>,
	stefanha@redhat.com, Paolo Bonzini <pbonzini@redhat.com>
Subject: Re: [RFC PATCH 3/3] fuzz: Add callbacks for dma-access functions
Date: Wed, 24 Jun 2020 11:46:31 +0200	[thread overview]
Message-ID: <f4d61f60-6065-24a6-c085-a613a3a335de@redhat.com> (raw)
In-Reply-To: <20200611055651.13784-4-alxndr@bu.edu>

On 6/11/20 7:56 AM, Alexander Bulekov wrote:
> Signed-off-by: Alexander Bulekov <alxndr@bu.edu>
> ---
>  exec.c                                | 17 ++++++++++++++++-
>  include/exec/memory.h                 |  8 ++++++++
>  include/exec/memory_ldst_cached.inc.h |  9 +++++++++
>  include/sysemu/dma.h                  |  5 ++++-
>  memory_ldst.inc.c                     | 12 ++++++++++++
>  5 files changed, 49 insertions(+), 2 deletions(-)
> 
> diff --git a/exec.c b/exec.c
> index be4be2df3a..2ed724ab54 100644
> --- a/exec.c
> +++ b/exec.c
> @@ -3247,7 +3247,10 @@ MemTxResult address_space_read_full(AddressSpace *as, hwaddr addr,
>  {
>      MemTxResult result = MEMTX_OK;
>      FlatView *fv;
> -
> +#ifdef CONFIG_FUZZ
> +    if(as->root == get_system_memory())

Since it is local to exec.c, you can directly use system_memory.

But why restrict this to the system memory anyway?

> +        dma_read_cb(addr, len);
> +#endif



  parent reply	other threads:[~2020-06-24  9:50 UTC|newest]

Thread overview: 14+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-06-11  5:56 [RFC PATCH 0/3] fuzz: add generic fuzzer Alexander Bulekov
2020-06-11  5:56 ` [RFC PATCH 1/3] fuzz: add a general fuzzer for any qemu arguments Alexander Bulekov
2020-06-11  5:56 ` [RFC PATCH 2/3] fuzz: add support for fuzzing DMA regions Alexander Bulekov
2020-06-11  5:56 ` [RFC PATCH 3/3] fuzz: Add callbacks for dma-access functions Alexander Bulekov
2020-06-23 14:14   ` Stefan Hajnoczi
2020-06-23 14:55     ` Alexander Bulekov
2020-06-26 15:44       ` Stefan Hajnoczi
2020-07-09 23:48     ` Alexander Bulekov
2020-07-13 11:41       ` Stefan Hajnoczi
2020-07-13 11:52         ` Alexander Bulekov
2020-06-24  9:46   ` Philippe Mathieu-Daudé [this message]
2020-06-11  6:55 ` [RFC PATCH 0/3] fuzz: add generic fuzzer no-reply
2020-06-23 14:16 ` Stefan Hajnoczi
2020-06-25 15:30   ` Dima Stepanov

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=f4d61f60-6065-24a6-c085-a613a3a335de@redhat.com \
    --to=philmd@redhat.com \
    --cc=alxndr@bu.edu \
    --cc=bsd@redhat.com \
    --cc=darren.kenny@oracle.com \
    --cc=pbonzini@redhat.com \
    --cc=qemu-devel@nongnu.org \
    --cc=rth@twiddle.net \
    --cc=stefanha@redhat.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
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).