qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
From: Joe Komlodi <joe.komlodi@xilinx.com>
To: <qemu-devel@nongnu.org>
Cc: edgari@xilinx.com
Subject: [PATCH v1 2/3] target/microblaze: use MMUAccessType instead of int in mmu_translate
Date: Thu, 21 Jan 2021 16:18:54 -0800	[thread overview]
Message-ID: <1611274735-303873-3-git-send-email-komlodi@xilinx.com> (raw)
In-Reply-To: <1611274735-303873-1-git-send-email-komlodi@xilinx.com>

Using MMUAccessType makes it more clear what the variable's use is.
No functional change.

Signed-off-by: Joe Komlodi <komlodi@xilinx.com>
---
 target/microblaze/mmu.c | 2 +-
 target/microblaze/mmu.h | 2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/target/microblaze/mmu.c b/target/microblaze/mmu.c
index 1e42696..cc40f27 100644
--- a/target/microblaze/mmu.c
+++ b/target/microblaze/mmu.c
@@ -74,7 +74,7 @@ static void mmu_change_pid(CPUMBState *env, unsigned int newpid)
 
 /* rw - 0 = read, 1 = write, 2 = fetch.  */
 unsigned int mmu_translate(MicroBlazeCPU *cpu, MicroBlazeMMULookup *lu,
-                           target_ulong vaddr, int rw, int mmu_idx)
+                           target_ulong vaddr, MMUAccessType rw, int mmu_idx)
 {
     MicroBlazeMMU *mmu = &cpu->env.mmu;
     unsigned int i, hit = 0;
diff --git a/target/microblaze/mmu.h b/target/microblaze/mmu.h
index 09e4075..b6b4b9a 100644
--- a/target/microblaze/mmu.h
+++ b/target/microblaze/mmu.h
@@ -84,7 +84,7 @@ typedef struct {
 } MicroBlazeMMULookup;
 
 unsigned int mmu_translate(MicroBlazeCPU *cpu, MicroBlazeMMULookup *lu,
-                           target_ulong vaddr, int rw, int mmu_idx);
+                           target_ulong vaddr, MMUAccessType rw, int mmu_idx);
 uint32_t mmu_read(CPUMBState *env, bool ea, uint32_t rn);
 void mmu_write(CPUMBState *env, bool ea, uint32_t rn, uint32_t v);
 void mmu_init(MicroBlazeMMU *mmu);
-- 
2.7.4



  parent reply	other threads:[~2021-01-22  0:36 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-01-22  0:18 [PATCH v1 0/3] target/microblaze: Add memattrs on transactions Joe Komlodi
2021-01-22  0:18 ` [PATCH v1 1/3] target/microblaze: Add use-non-secure property Joe Komlodi
2021-01-26 11:16   ` Edgar E. Iglesias
2021-01-22  0:18 ` Joe Komlodi [this message]
2021-01-22 20:54   ` [PATCH v1 2/3] target/microblaze: use MMUAccessType instead of int in mmu_translate Richard Henderson
2021-01-26 11:16   ` Edgar E. Iglesias
2021-01-22  0:18 ` [PATCH v1 3/3] target/microblaze: Add security attributes on memory transactions Joe Komlodi
2021-01-26 11:16   ` Edgar E. Iglesias

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=1611274735-303873-3-git-send-email-komlodi@xilinx.com \
    --to=joe.komlodi@xilinx.com \
    --cc=edgari@xilinx.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).