qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
From: Thomas Huth <thuth@redhat.com>
To: qemu-devel@nongnu.org
Subject: [Qemu-devel] [PATCH 14/14] tests/boot-serial-test: Add support for the aarch64 virt machine
Date: Thu,  8 Feb 2018 21:09:42 +0100	[thread overview]
Message-ID: <1518120582-26647-15-git-send-email-thuth@redhat.com> (raw)
In-Reply-To: <1518120582-26647-1-git-send-email-thuth@redhat.com>

From: Wei Huang <wei@redhat.com>

This patch adds a small binary kernel to test aarch64 virt machine's
UART.

Signed-off-by: Wei Huang <wei@redhat.com>
[thuth: Fixed contextual conflict with the hppa patch]
Signed-off-by: Thomas Huth <thuth@redhat.com>
---
 tests/Makefile.include   | 1 +
 tests/boot-serial-test.c | 9 +++++++++
 2 files changed, 10 insertions(+)

diff --git a/tests/Makefile.include b/tests/Makefile.include
index 6609276..cc7e7dc 100644
--- a/tests/Makefile.include
+++ b/tests/Makefile.include
@@ -371,6 +371,7 @@ gcov-files-arm-y += hw/timer/arm_mptimer.c
 check-qtest-arm-y += tests/boot-serial-test$(EXESUF)
 
 check-qtest-aarch64-y = tests/numa-test$(EXESUF)
+check-qtest-aarch64-y += tests/boot-serial-test$(EXESUF)
 
 check-qtest-microblazeel-y = $(check-qtest-microblaze-y)
 
diff --git a/tests/boot-serial-test.c b/tests/boot-serial-test.c
index 72873ee..511bf31 100644
--- a/tests/boot-serial-test.c
+++ b/tests/boot-serial-test.c
@@ -55,6 +55,13 @@ static const uint8_t bios_raspi2[] = {
     0x00, 0x10, 0x20, 0x3f,                 /* 0x3f201000 = UART0 base addr */
 };
 
+static const uint8_t kernel_aarch64[] = {
+    0x81, 0x0a, 0x80, 0x52,                 /* mov     w1, #0x54 */
+    0x02, 0x20, 0xa1, 0xd2,                 /* mov     x2, #0x9000000 */
+    0x41, 0x00, 0x00, 0x39,                 /* strb    w1, [x2] */
+    0xfd, 0xff, 0xff, 0x17,                 /* b       -12 (loop) */
+};
+
 typedef struct testdef {
     const char *arch;       /* Target architecture */
     const char *machine;    /* Name of the machine */
@@ -95,6 +102,8 @@ static testdef_t tests[] = {
     { "moxie", "moxiesim", "", "TT", sizeof(bios_moxiesim), 0, bios_moxiesim },
     { "arm", "raspi2", "", "TT", sizeof(bios_raspi2), 0, bios_raspi2 },
     { "hppa", "hppa", "", "SeaBIOS wants SYSTEM HALT" },
+    { "aarch64", "virt", "-cpu cortex-a57", "TT", sizeof(kernel_aarch64),
+      kernel_aarch64 },
 
     { NULL }
 };
-- 
1.8.3.1

  parent reply	other threads:[~2018-02-08 20:10 UTC|newest]

Thread overview: 19+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-02-08 20:09 [Qemu-devel] [PATCH 00/14] qtest patches Thomas Huth
2018-02-08 20:09 ` [Qemu-devel] [PATCH 01/14] tests: Clean up wait for event Thomas Huth
2018-02-08 20:09 ` [Qemu-devel] [PATCH 02/14] libqtest: Use qemu_strtoul() Thomas Huth
2018-02-08 20:09 ` [Qemu-devel] [PATCH 03/14] libqos: Track QTestState with QPCIBus Thomas Huth
2018-02-08 20:09 ` [Qemu-devel] [PATCH 04/14] libqos: Use explicit QTestState for fw_cfg operations Thomas Huth
2018-02-08 20:09 ` [Qemu-devel] [PATCH 05/14] libqos: Use explicit QTestState for rtas operations Thomas Huth
2018-02-08 20:09 ` [Qemu-devel] [PATCH 06/14] libqos: Use explicit QTestState for i2c operations Thomas Huth
2018-02-08 20:09 ` [Qemu-devel] [PATCH 07/14] libqos: Use explicit QTestState for ahci operations Thomas Huth
2018-02-08 20:09 ` [Qemu-devel] [PATCH 08/14] libqos: Use explicit QTestState for remaining libqos operations Thomas Huth
2018-02-08 20:09 ` [Qemu-devel] [PATCH 09/14] qmp-test: Drop dependence on global_qtest Thomas Huth
2018-02-08 20:09 ` [Qemu-devel] [PATCH 10/14] tests/boot-sector: " Thomas Huth
2018-02-08 20:09 ` [Qemu-devel] [PATCH 11/14] wdt_ib700-test: " Thomas Huth
2018-02-08 20:09 ` [Qemu-devel] [PATCH 12/14] tests/boot-serial: Enable the boot-serial test on SPARC machines, too Thomas Huth
2018-02-08 22:40   ` Eric Blake
2018-02-08 20:09 ` [Qemu-devel] [PATCH 13/14] tests/boot-serial: Add tests for PowerPC Mac machines Thomas Huth
2018-02-08 22:41   ` Eric Blake
2018-02-08 20:09 ` Thomas Huth [this message]
2018-02-08 22:44   ` [Qemu-devel] [PATCH 14/14] tests/boot-serial-test: Add support for the aarch64 virt machine Eric Blake
2018-02-08 22:46 ` [Qemu-devel] [PATCH 00/14] qtest patches Eric Blake

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=1518120582-26647-15-git-send-email-thuth@redhat.com \
    --to=thuth@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).