All of lore.kernel.org
 help / color / mirror / Atom feed
From: Artyom Tarasenko <atar4qemu@gmail.com>
To: liq3ea@163.com
Cc: Paolo Bonzini <pbonzini@redhat.com>,
	lersek@redhat.com, marcandre.lureau@gmail.com,
	Eduardo Habkost <ehabkost@redhat.com>,
	"Michael S. Tsirkin" <mst@redhat.com>,
	Peter Maydell <peter.maydell@linaro.org>,
	ppandit@redhat.com, liq3ea@gmail.com,
	qemu-devel <qemu-devel@nongnu.org>
Subject: Re: [Qemu-devel] [PATCH 7/8] hw: sun4c: add read memory region callback
Date: Wed, 12 Sep 2018 21:22:34 +0200	[thread overview]
Message-ID: <CACXAS8CwxjB1YGHrs8uUarw4VxvNcXPBra+P_91YYkhGYzDccQ@mail.gmail.com> (raw)
In-Reply-To: <20180912160118.21158-8-liq3ea@163.com>

Please correct the typo in the subject. I was scared that someone dug
out the sun4c zombie emulation.

In the particular case of sun4u, I think the proper way is not to have
the read callback, but throw an 'Unassigned memory access' exception

Regards,
Artyom
On Wed, Sep 12, 2018 at 6:09 PM Li Qiang <liq3ea@163.com> wrote:
>
> From: Li Qiang <liq3ea@gmail.com>
>
> Signed-off-by: Li Qiang <liq3ea@gmail.com>
> ---
>  hw/sparc64/sun4u.c | 6 ++++++
>  1 file changed, 6 insertions(+)
>
> diff --git a/hw/sparc64/sun4u.c b/hw/sparc64/sun4u.c
> index d16843b30e..74c55a82f4 100644
> --- a/hw/sparc64/sun4u.c
> +++ b/hw/sparc64/sun4u.c
> @@ -212,6 +212,11 @@ typedef struct PowerDevice {
>      MemoryRegion power_mmio;
>  } PowerDevice;
>
> +static uint64_t power_mem_read(void *opaque, hwaddr addr, unsigned size)
> +{
> +    return 0;
> +}
> +
>  /* Power */
>  static void power_mem_write(void *opaque, hwaddr addr,
>                              uint64_t val, unsigned size)
> @@ -223,6 +228,7 @@ static void power_mem_write(void *opaque, hwaddr addr,
>  }
>
>  static const MemoryRegionOps power_mem_ops = {
> +    .read = power_mem_read,
>      .write = power_mem_write,
>      .endianness = DEVICE_NATIVE_ENDIAN,
>      .valid = {
> --
> 2.17.1
>
>
>


-- 
Regards,
Artyom Tarasenko

SPARC and PPC PReP under qemu blog: http://tyom.blogspot.com/search/label/qemu

  reply	other threads:[~2018-09-12 19:29 UTC|newest]

Thread overview: 16+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-09-12 16:01 [Qemu-devel] [PATCH 0/8] Add missed read callback for some memory region Li Qiang
2018-09-12 16:01 ` [Qemu-devel] [PATCH 1/8] fw_cfg_mem: add read memory region callback Li Qiang
2018-09-12 16:48   ` Eric Blake
2018-09-12 16:01 ` [Qemu-devel] [PATCH 2/8] hw: debugexit: add read callback Li Qiang
2018-09-12 16:01 ` [Qemu-devel] [PATCH 3/8] hw: hyperv_testdev: " Li Qiang
2018-09-12 16:01 ` [Qemu-devel] [PATCH 4/8] hw: pc-testdev: add read memory region callback Li Qiang
2018-09-12 16:01 ` [Qemu-devel] [PATCH 5/8] hw: designware: " Li Qiang
2018-09-13 15:12   ` Paolo Bonzini
2018-09-14  5:08     ` Li Qiang
2018-09-12 16:01 ` [Qemu-devel] [PATCH 6/8] hw: pvrdma: " Li Qiang
2018-09-12 16:01 ` [Qemu-devel] [PATCH 7/8] hw: sun4c: " Li Qiang
2018-09-12 19:22   ` Artyom Tarasenko [this message]
2018-09-12 16:01 ` [Qemu-devel] [PATCH 8/8] exec: add read callback for notdirty memory region Li Qiang
2018-09-13 10:53   ` Paolo Bonzini
2018-09-12 16:13 ` [Qemu-devel] [PATCH 0/8] Add missed read callback for some " Philippe Mathieu-Daudé
2018-09-13  1:41   ` Li Qiang

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=CACXAS8CwxjB1YGHrs8uUarw4VxvNcXPBra+P_91YYkhGYzDccQ@mail.gmail.com \
    --to=atar4qemu@gmail.com \
    --cc=ehabkost@redhat.com \
    --cc=lersek@redhat.com \
    --cc=liq3ea@163.com \
    --cc=liq3ea@gmail.com \
    --cc=marcandre.lureau@gmail.com \
    --cc=mst@redhat.com \
    --cc=pbonzini@redhat.com \
    --cc=peter.maydell@linaro.org \
    --cc=ppandit@redhat.com \
    --cc=qemu-devel@nongnu.org \
    /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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.