From: Max Filippov <jcmvbkbc@gmail.com>
To: qemu-devel@nongnu.org
Cc: Max Filippov <jcmvbkbc@gmail.com>
Subject: [Qemu-devel] [PATCH 2/3] target-xtensa: completely clean TLB between MMU tests
Date: Wed, 21 May 2014 01:22:29 +0400 [thread overview]
Message-ID: <1400620950-32297-3-git-send-email-jcmvbkbc@gmail.com> (raw)
In-Reply-To: <1400620950-32297-1-git-send-email-jcmvbkbc@gmail.com>
Signed-off-by: Max Filippov <jcmvbkbc@gmail.com>
---
tests/tcg/xtensa/test_mmu.S | 26 +++++++++++++++++++-------
1 file changed, 19 insertions(+), 7 deletions(-)
diff --git a/tests/tcg/xtensa/test_mmu.S b/tests/tcg/xtensa/test_mmu.S
index 099031f..37174b9 100644
--- a/tests/tcg/xtensa/test_mmu.S
+++ b/tests/tcg/xtensa/test_mmu.S
@@ -4,16 +4,28 @@ test_suite mmu
.purgem test_init
-.macro test_init
- movi a2, 0x00000004
- idtlb a2
- movi a2, 0x00100004
+.macro clean_tlb_way way, page_size, n_entries
+ movi a2, \way
+ movi a3, \page_size
+ movi a4, \n_entries
+ loop a4, 1f
idtlb a2
- movi a2, 0x00200004
+ iitlb a2
+ add a2, a2, a3
+1:
+.endm
+
+.macro test_init
+ clean_tlb_way 0, 0x00001000, 4
+ clean_tlb_way 1, 0x00001000, 4
+ clean_tlb_way 2, 0x00001000, 4
+ clean_tlb_way 3, 0x00001000, 4
+ clean_tlb_way 4, 0x00100000, 4
+ movi a2, 0x00000007
idtlb a2
- movi a2, 0x00300004
+ movi a2, 0x00000008
idtlb a2
- movi a2, 0x00000007
+ movi a2, 0x00000009
idtlb a2
.endm
--
1.8.1.4
next prev parent reply other threads:[~2014-05-20 21:23 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-05-20 21:22 [Qemu-devel] [PATCH 0/3] target-xtensa: fix cross-page jumps/calls at the end of TB Max Filippov
2014-05-20 21:22 ` [Qemu-devel] [PATCH 1/3] " Max Filippov
2014-05-20 21:22 ` Max Filippov [this message]
2014-05-20 21:22 ` [Qemu-devel] [PATCH 3/3] target-xtensa: add tests for cross-page TB Max Filippov
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=1400620950-32297-3-git-send-email-jcmvbkbc@gmail.com \
--to=jcmvbkbc@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).