qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
From: Alexander Graf <agraf@suse.de>
To: QEMU-devel Developers <qemu-devel@nongnu.org>
Cc: Anthony PERARD <anthony.perard@citrix.com>,
	Anthony Liguori <aliguori@us.ibm.com>,
	Avi Kivity <avi@redhat.com>
Subject: [Qemu-devel] [PATCH 4/6] exec.c: Use ram_addr_t in cpu_physical_memory_rw(...).
Date: Tue, 19 Jul 2011 04:53:30 +0200	[thread overview]
Message-ID: <1311044012-24288-5-git-send-email-agraf@suse.de> (raw)
In-Reply-To: <1311044012-24288-1-git-send-email-agraf@suse.de>

From: Anthony PERARD <anthony.perard@citrix.com>

As the variable pd and addr1 inside the function cpu_physical_memory_rw
are mean to handle a RAM address, they should be of the ram_addr_t type
instead of unsigned long.

Signed-off-by: Anthony PERARD <anthony.perard@citrix.com>
Acked-by: Paolo Bonzini <pbonzini@redhat.com>
Signed-off-by: Alexander Graf <agraf@suse.de>
---
 exec.c |    4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/exec.c b/exec.c
index 8277900..8ef290e 100644
--- a/exec.c
+++ b/exec.c
@@ -3858,7 +3858,7 @@ void cpu_physical_memory_rw(target_phys_addr_t addr, uint8_t *buf,
     uint8_t *ptr;
     uint32_t val;
     target_phys_addr_t page;
-    unsigned long pd;
+    ram_addr_t pd;
     PhysPageDesc *p;
 
     while (len > 0) {
@@ -3898,7 +3898,7 @@ void cpu_physical_memory_rw(target_phys_addr_t addr, uint8_t *buf,
                     l = 1;
                 }
             } else {
-                unsigned long addr1;
+                ram_addr_t addr1;
                 addr1 = (pd & TARGET_PAGE_MASK) + (addr & ~TARGET_PAGE_MASK);
                 /* RAM case */
                 ptr = qemu_get_ram_ptr(addr1);
-- 
1.6.0.2

  parent reply	other threads:[~2011-07-20 10:25 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-07-19  2:53 [Qemu-devel] [PATCH 0/6] Xen patch queue 2011-07-20 Alexander Graf
2011-07-19  2:53 ` [Qemu-devel] [PATCH 1/6] xen: introduce xen_change_state_handler Alexander Graf
2011-07-19  2:53 ` [Qemu-devel] [PATCH 2/6] xen: add mapcache stubs Alexander Graf
2011-07-20 15:12   ` Avi Kivity
2011-07-20 15:24     ` Alexander Graf
2011-07-20 16:41   ` Stefan Weil
2011-07-20 16:45     ` Alexander Graf
2011-07-19  2:53 ` [Qemu-devel] [PATCH 3/6] xen: Fix xen_enabled() Alexander Graf
2011-07-19  2:53 ` Alexander Graf [this message]
2011-07-19  2:53 ` [Qemu-devel] [PATCH 5/6] xen: remove CONFIG_XEN_MAPCACHE Alexander Graf
2011-07-19  2:53 ` [Qemu-devel] [PATCH 6/6] xen: make xen_enabled even more clever Alexander Graf
2011-07-20 15:10 ` [Qemu-devel] [PATCH 0/6] Xen patch queue 2011-07-20 Alexander Graf

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=1311044012-24288-5-git-send-email-agraf@suse.de \
    --to=agraf@suse.de \
    --cc=aliguori@us.ibm.com \
    --cc=anthony.perard@citrix.com \
    --cc=avi@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 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).