From nobody Thu Dec 18 22:24:19 2025 Delivered-To: importer@patchew.org Received-SPF: pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; envelope-from=qemu-devel-bounces+importer=patchew.org@nongnu.org; helo=lists.gnu.org; Authentication-Results: mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; dmarc=pass(p=none dis=none) header.from=linaro.org ARC-Seal: i=1; a=rsa-sha256; t=1582908605; cv=none; d=zohomail.com; s=zohoarc; b=Lou+dpq4n1VS7e7ZzuTi9qdH1xSWJ30PPmv2YOuQovXroTF5G429CQbRoZ6BSoWELup0Ecm8QVHikVLUKUnalYoOe8kyZ5aVl9YPYWWENrmnj/Io5g1cq1LfCZtaEESsheKbAamjeDkbL4/Fg9ZJtEtZKc1dxl1CGB0Cqj0eQD8= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1582908605; h=Content-Type:Content-Transfer-Encoding:Date:From:In-Reply-To:List-Subscribe:List-Post:List-Id:List-Archive:List-Help:List-Unsubscribe:MIME-Version:Message-ID:References:Sender:Subject:To; bh=MzcpXPRjhRqp+Fy3j7b0AOUvrSs6C4ggJpK7+di/i9I=; b=LcSqHfj3LManBTjwT5zEaGuyGO4BJwpwQGR6J2M8uPP7NjwLMKpdnMSZQo9uFuQSkgcnnS2LOJAv0qbzgmnRf1waPb7+hkxOVJps8+QepyYoN8JlQC8dGZ8sWaX2werBNoEgkgBeeRTu9WM5JNnc0EJQ9RBosHSh54qBgz5qCrY= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; dmarc=pass header.from= (p=none dis=none) header.from= Return-Path: Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mx.zohomail.com with SMTPS id 1582908605123321.7698707223336; Fri, 28 Feb 2020 08:50:05 -0800 (PST) Received: from localhost ([::1]:50580 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1j7ipu-0002FP-U4 for importer@patchew.org; Fri, 28 Feb 2020 11:50:02 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]:56711) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1j7ifT-00087h-Es for qemu-devel@nongnu.org; Fri, 28 Feb 2020 11:39:16 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1j7ifS-000242-1u for qemu-devel@nongnu.org; Fri, 28 Feb 2020 11:39:15 -0500 Received: from mail-wm1-x342.google.com ([2a00:1450:4864:20::342]:55833) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1j7ifR-00023P-Qr for qemu-devel@nongnu.org; Fri, 28 Feb 2020 11:39:13 -0500 Received: by mail-wm1-x342.google.com with SMTP id q9so3813325wmj.5 for ; Fri, 28 Feb 2020 08:39:13 -0800 (PST) Received: from orth.archaic.org.uk (orth.archaic.org.uk. [81.2.115.148]) by smtp.gmail.com with ESMTPSA id c9sm13335214wrq.44.2020.02.28.08.39.11 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 28 Feb 2020 08:39:12 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:subject:date:message-id:in-reply-to:references:mime-version :content-transfer-encoding; bh=MzcpXPRjhRqp+Fy3j7b0AOUvrSs6C4ggJpK7+di/i9I=; b=YHTEuaiywv6TwkaEpQ6y0Pr/eYo/MuLd+bW/CxXYFyS6XLWRgpJalfRmsEv33czlkp CqCSUX+5Z7hZ/8oYAf2G8WE2CIhmigaeQW9BURErQCN3FwoSLjQ12sQwyPGUn7fUnEt4 nUlbcTPXSA5R/eabQ5y9Oz1s4IExO/BELOocxKtzhgzVmU9N/jICp/lTSeRQxRKZGech WYKYumSxWRX6fbOnOiryoFmvFqPcGJ8om6ZcKcAC8Awj/pl5iauel4NedTOv15Eucu9K OHGW1Jf3iYJogkSZvhKjdIEl/Ofsf6TaaG3hqXSH7Sk2YC02TiuM9g8C6h24P1MxRYbN rzng== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=MzcpXPRjhRqp+Fy3j7b0AOUvrSs6C4ggJpK7+di/i9I=; b=b0JbWh8vlZH4uvpynV1gEEhI5MWpofN4wkg15DpaqJCg2mdZDn0/Moue0gYVienWd+ SzShAnr/L3rgZKVrzcaM2G95tuX/3PUpxIrWiwZSS8rE2IAn2Yr3ZGd/jQ4kN3RCiz3W L2DyVge6jFHbsAtG3r/yBG/M/5en9QqN/ueKxxYHP51Z8960WWi5+qGJmYN5oVpifICq uYSHuwuqQvwS2rH9s5uCSY2EbWPLqaPqqS9J5bm86A25BxnOEhAqujqzp2wNZ1tB7tl/ UvTMMoYvzhDsv1Xcft/i9Txwu14/xAR6bQDxMsRiB/FzLzkjoRgSN8olIQmD10fVxgk/ luMw== X-Gm-Message-State: APjAAAWPnAxQNvzHKv4aL3cGdDhf60fsYSjwF+ImhEb9Al0SwNhDVYUk 8LcQXQWrC+k/JsTtpe2yLKyAwnMuE+tVLA== X-Google-Smtp-Source: APXvYqweZBabnXeP+wV5O8uhPd4pdXk68ewudzcBz+O6ExOQJezLLbXdz/4m5kUMfvBq/PKV8r82Og== X-Received: by 2002:a1c:9c87:: with SMTP id f129mr5856634wme.26.1582907952559; Fri, 28 Feb 2020 08:39:12 -0800 (PST) From: Peter Maydell To: qemu-devel@nongnu.org Subject: [PULL 26/33] tests/acceptance: Add a test for the integratorcp arm machine Date: Fri, 28 Feb 2020 16:38:33 +0000 Message-Id: <20200228163840.23585-27-peter.maydell@linaro.org> X-Mailer: git-send-email 2.20.1 In-Reply-To: <20200228163840.23585-1-peter.maydell@linaro.org> References: <20200228163840.23585-1-peter.maydell@linaro.org> MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable X-detected-operating-system: by eggs.gnu.org: Genre and OS details not recognized. X-Received-From: 2a00:1450:4864:20::342 X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.23 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" X-ZohoMail-DKIM: pass (identity @linaro.org) From: Thomas Huth There is a kernel and initrd available on github which we can use for testing this machine. Signed-off-by: Thomas Huth Reviewed-by: Philippe Mathieu-Daud=C3=A9 Tested-by: Philippe Mathieu-Daud=C3=A9 Reviewed-by: Wainer dos Santos Moschetta Signed-off-by: Philippe Mathieu-Daud=C3=A9 Message-id: 20200225172501.29609-3-philmd@redhat.com Message-Id: <20200131170233.14584-1-thuth@redhat.com> [PMD: Renamed test method, moved description from class to method] Signed-off-by: Philippe Mathieu-Daud=C3=A9 Signed-off-by: Peter Maydell --- MAINTAINERS | 1 + tests/acceptance/machine_arm_integratorcp.py | 43 ++++++++++++++++++++ 2 files changed, 44 insertions(+) create mode 100644 tests/acceptance/machine_arm_integratorcp.py diff --git a/MAINTAINERS b/MAINTAINERS index 264374adbe8..c258391cad8 100644 --- a/MAINTAINERS +++ b/MAINTAINERS @@ -613,6 +613,7 @@ S: Maintained F: hw/arm/integratorcp.c F: hw/misc/arm_integrator_debug.c F: include/hw/misc/arm_integrator_debug.h +F: tests/acceptance/machine_arm_integratorcp.py =20 MCIMX6UL EVK / i.MX6ul M: Peter Maydell diff --git a/tests/acceptance/machine_arm_integratorcp.py b/tests/acceptanc= e/machine_arm_integratorcp.py new file mode 100644 index 00000000000..d928ed79b4c --- /dev/null +++ b/tests/acceptance/machine_arm_integratorcp.py @@ -0,0 +1,43 @@ +# Functional test that boots a Linux kernel and checks the console +# +# Copyright (c) 2020 Red Hat, Inc. +# +# Author: +# Thomas Huth +# +# This work is licensed under the terms of the GNU GPL, version 2 or +# later. See the COPYING file in the top-level directory. + +import os + +from avocado import skipUnless +from avocado_qemu import Test +from avocado_qemu import wait_for_console_pattern + +class IntegratorMachine(Test): + + timeout =3D 90 + + @skipUnless(os.getenv('AVOCADO_ALLOW_UNTRUSTED_CODE'), 'untrusted code= ') + def test_integratorcp_console(self): + """ + Boots the Linux kernel and checks that the console is operational + :avocado: tags=3Darch:arm + :avocado: tags=3Dmachine:integratorcp + """ + kernel_url =3D ('https://github.com/zayac/qemu-arm/raw/master/' + 'arm-test/kernel/zImage.integrator') + kernel_hash =3D '0d7adba893c503267c946a3cbdc63b4b54f25468' + kernel_path =3D self.fetch_asset(kernel_url, asset_hash=3Dkernel_h= ash) + + initrd_url =3D ('https://github.com/zayac/qemu-arm/raw/master/' + 'arm-test/kernel/arm_root.img') + initrd_hash =3D 'b51e4154285bf784e017a37586428332d8c7bd8b' + initrd_path =3D self.fetch_asset(initrd_url, asset_hash=3Dinitrd_h= ash) + + self.vm.set_console() + self.vm.add_args('-kernel', kernel_path, + '-initrd', initrd_path, + '-append', 'printk.time=3D0 console=3DttyAMA0') + self.vm.launch() + wait_for_console_pattern(self, 'Log in as root') --=20 2.20.1