From: Blue Swirl <blauwirbel@gmail.com>
To: qemu-devel@nongnu.org
Subject: Re: [Qemu-devel] [PATCH] 64 bit I/O v3
Date: Thu, 26 Feb 2009 21:07:02 +0200 [thread overview]
Message-ID: <f43fc5580902261107o28b9c69w33c4b49f8ffb7c97@mail.gmail.com> (raw)
In-Reply-To: <49A68893.7090102@earthlink.net>
On 2/26/09, Robert Reif <reif@earthlink.net> wrote:
> This is the third version of adding 64 bit I/O support to QEMU.
> int cpu_register_io_memory(int io_index,
> CPUReadMemoryFunc **mem_read,
> CPUWriteMemoryFunc **mem_write,
> void *opaque)
> {
> - int i, subwidth = 0;
> + if (io_index <= 0) {
> + io_index = get_free_io_mem_idx();
> + if (io_index == -1)
> + return io_index;
> + } else {
> + if (io_index >= IO_MEM_NB_ENTRIES)
> + return -1;
> + }
>
> + io_mem_read[io_index].b = mem_read[0];
> + io_mem_write[io_index].b = mem_write[0];
> +
> + io_mem_read[io_index].w = mem_read[1];
> + io_mem_write[io_index].w = mem_write[1];
> +
> + io_mem_read[io_index].l = mem_read[2];
> + io_mem_write[io_index].l = mem_write[2];
> +
> + io_mem_read[io_index].q = NULL;
> + io_mem_write[io_index].q = NULL;
> +
> + io_mem_opaque[io_index] = opaque;
> + return (io_index << IO_MEM_SHIFT) | IO_MEM_SUBWIDTH;
> +}
I think for 64 bit accesses the default should be emulation using two
32 bit accesses instead of NULL (unassigned).
next prev parent reply other threads:[~2009-02-26 19:07 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2009-02-26 12:18 [Qemu-devel] [PATCH] 64 bit I/O v3 Robert Reif
2009-02-26 19:07 ` Blue Swirl [this message]
2009-02-27 1:24 ` Robert Reif
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=f43fc5580902261107o28b9c69w33c4b49f8ffb7c97@mail.gmail.com \
--to=blauwirbel@gmail.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 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).