From nobody Wed Apr 16 16:47:02 2025 Delivered-To: importer@patchew.org Received-SPF: pass (zoho.com: domain of gnu.org designates 208.118.235.17 as permitted sender) client-ip=208.118.235.17; envelope-from=qemu-devel-bounces+importer=patchew.org@nongnu.org; helo=lists.gnu.org; Authentication-Results: mx.zohomail.com; spf=pass (zoho.com: domain of gnu.org designates 208.118.235.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; dmarc=fail(p=none dis=none) header.from=linaro.org Return-Path: Received: from lists.gnu.org (lists.gnu.org [208.118.235.17]) by mx.zohomail.com with SMTPS id 15411799530202.929828859483223; Fri, 2 Nov 2018 10:32:33 -0700 (PDT) Received: from localhost ([::1]:52857 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1gIdJ9-0006Pn-Kg for importer@patchew.org; Fri, 02 Nov 2018 13:32:31 -0400 Received: from eggs.gnu.org ([2001:4830:134:3::10]:50946) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1gId67-0002Bs-TT for qemu-devel@nongnu.org; Fri, 02 Nov 2018 13:19:05 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1gId66-0004K8-CO for qemu-devel@nongnu.org; Fri, 02 Nov 2018 13:19:03 -0400 Received: from orth.archaic.org.uk ([2001:8b0:1d0::2]:52250) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_256_CBC_SHA1:32) (Exim 4.71) (envelope-from ) id 1gId65-0002Zn-Nt for qemu-devel@nongnu.org; Fri, 02 Nov 2018 13:19:02 -0400 Received: from pm215 by orth.archaic.org.uk with local (Exim 4.89) (envelope-from ) id 1gId3t-0003a4-90 for qemu-devel@nongnu.org; Fri, 02 Nov 2018 17:16:45 +0000 From: Peter Maydell To: qemu-devel@nongnu.org Date: Fri, 2 Nov 2018 17:16:32 +0000 Message-Id: <20181102171638.24069-5-peter.maydell@linaro.org> X-Mailer: git-send-email 2.19.1 In-Reply-To: <20181102171638.24069-1-peter.maydell@linaro.org> References: <20181102171638.24069-1-peter.maydell@linaro.org> MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable X-detected-operating-system: by eggs.gnu.org: Genre and OS details not recognized. X-Received-From: 2001:8b0:1d0::2 Subject: [Qemu-devel] [PULL 04/10] tests/boot-serial-test: Add microbit board testcase X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+importer=patchew.org@nongnu.org Sender: "Qemu-devel" Content-Type: text/plain; charset="utf-8" From: Julia Suvorova New mini-kernel test for nRF51 SoC UART. Signed-off-by: Julia Suvorova Acked-by: Thomas Huth Reviewed-by: Stefan Hajnoczi Signed-off-by: Peter Maydell --- tests/boot-serial-test.c | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) diff --git a/tests/boot-serial-test.c b/tests/boot-serial-test.c index f865822e32f..8ec6aed35d2 100644 --- a/tests/boot-serial-test.c +++ b/tests/boot-serial-test.c @@ -62,6 +62,24 @@ static const uint8_t kernel_aarch64[] =3D { 0xfd, 0xff, 0xff, 0x17, /* b -12 (loop) */ }; =20 +static const uint8_t kernel_nrf51[] =3D { + 0x00, 0x00, 0x00, 0x00, /* Stack top address */ + 0x09, 0x00, 0x00, 0x00, /* Reset handler address */ + 0x04, 0x4a, /* ldr r2, [pc, #16] Get ENAB= LE */ + 0x04, 0x21, /* movs r1, #4 */ + 0x11, 0x60, /* str r1, [r2] */ + 0x04, 0x4a, /* ldr r2, [pc, #16] Get STAR= TTX */ + 0x01, 0x21, /* movs r1, #1 */ + 0x11, 0x60, /* str r1, [r2] */ + 0x03, 0x4a, /* ldr r2, [pc, #12] Get TXD = */ + 0x54, 0x21, /* movs r1, 'T' */ + 0x11, 0x60, /* str r1, [r2] */ + 0xfe, 0xe7, /* b . */ + 0x00, 0x25, 0x00, 0x40, /* 0x40002500 =3D UART ENABLE = */ + 0x08, 0x20, 0x00, 0x40, /* 0x40002008 =3D UART STARTTX= */ + 0x1c, 0x25, 0x00, 0x40 /* 0x4000251c =3D UART TXD */ +}; + typedef struct testdef { const char *arch; /* Target architecture */ const char *machine; /* Name of the machine */ @@ -105,6 +123,7 @@ static testdef_t tests[] =3D { { "hppa", "hppa", "", "SeaBIOS wants SYSTEM HALT" }, { "aarch64", "virt", "-cpu cortex-a57", "TT", sizeof(kernel_aarch64), kernel_aarch64 }, + { "arm", "microbit", "", "T", sizeof(kernel_nrf51), kernel_nrf51 }, =20 { NULL } }; --=20 2.19.1