From patchwork Thu Jun 27 11:53:30 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?Philippe_Mathieu-Daud=C3=A9?= X-Patchwork-Id: 1123317 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Authentication-Results: ozlabs.org; spf=pass (mailfrom) smtp.mailfrom=nongnu.org (client-ip=209.51.188.17; helo=lists.gnu.org; envelope-from=qemu-devel-bounces+incoming=patchwork.ozlabs.org@nongnu.org; receiver=) Authentication-Results: ozlabs.org; dmarc=none (p=none dis=none) header.from=amsat.org Authentication-Results: ozlabs.org; dkim=fail reason="signature verification failed" (2048-bit key; unprotected) header.d=gmail.com header.i=@gmail.com header.b="gvjC/PjX"; dkim-atps=neutral Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id 45ZJGg1MDtz9s4Y for ; Thu, 27 Jun 2019 21:54:35 +1000 (AEST) Received: from localhost ([::1]:49166 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.86_2) (envelope-from ) id 1hgSz3-0007R9-92 for incoming@patchwork.ozlabs.org; Thu, 27 Jun 2019 07:54:33 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:38708) by lists.gnu.org with esmtp (Exim 4.86_2) (envelope-from ) id 1hgSyB-0007CJ-Ah for qemu-devel@nongnu.org; Thu, 27 Jun 2019 07:53:40 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1hgSy9-000145-Ln for qemu-devel@nongnu.org; Thu, 27 Jun 2019 07:53:39 -0400 Received: from mail-wm1-x344.google.com ([2a00:1450:4864:20::344]:50559) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1hgSy9-000130-F4 for qemu-devel@nongnu.org; Thu, 27 Jun 2019 07:53:37 -0400 Received: by mail-wm1-x344.google.com with SMTP id c66so5441977wmf.0 for ; Thu, 27 Jun 2019 04:53:37 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=sender:from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=7Kaojq+JVYsXMPIVtQoIpSEKIUgt3q0HMeJqgC9HTsI=; b=gvjC/PjXran5Lc6W1YhS2STDcvjGC9M6M7vdGtzdzeT7I7/rAXXnwW8xx54gor/dRs KQlh0P4rBK1iLb2iQoahmA2le6rwlsucyqNBESfIuZGJlvrw+8FsRb4Q5io6Pw70RGsN DgqfNDVIzm4WyURTyRowf0b+7wp/cZ4Qk1WkIf2625e82Ai+jhEMndkuNhatuHNt5hBz IC1cUEbF9o+ZwsUdNWGVRXuwd6V+bjx20zJ1KSHnsLCmUK6ycUv5Iw/xwgY2ZU/EXUW0 KXleepvh1nwdMhNxPHvUbmePHTFDprOi9qQbsXS6yZ2tN/fdfW96Stai0InzCWja/7EQ i5Rw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:sender:from:to:cc:subject:date:message-id :in-reply-to:references:mime-version:content-transfer-encoding; bh=7Kaojq+JVYsXMPIVtQoIpSEKIUgt3q0HMeJqgC9HTsI=; b=lEeV/5ZYxVgqJDiQuduiGgbQn7pdZenjnZyzp1h+wy8yB00v6rOmVpriXy5i7Aen9p zkpE2EyAjpyyj1iu+TM7cco3LCV6k8r68fQ0hnd22mQUsBrkT4KMFKs0OzTdvmSgAnju tukqZEiEx7XCbzr1sW4vC0SfGu6Jg1BSnCpiVpkSu/UyfLOeP84Yip2aTfxxiZ4clmJ8 XDDMCA6oeL41UpQcUxCDrIWQ44wSzJcEuP4RKtROfVy0PX4kV7PB5EEWpjTIfEjSpd4a wSVQc6RBiFHC8rZiPAi+cuFxYY4qq1FRaOdmAeLajuufnQ0m4NxvR4Tb7oB5mV5lLNh/ roMg== X-Gm-Message-State: APjAAAVkJytJ+epQc/lEHHTz99rXDlg0jaIo68B18uGhL3G5qK/56mXi qnUk8wk/mGAE7TmBWZ4qJDAe2BuN X-Google-Smtp-Source: APXvYqyF3GA5C5LZakVVi5cf7TS5DBmzSWiSNjQL5lHwDl8fjibYqM5GcnyM0q/qp4GSAftalacaOQ== X-Received: by 2002:a1c:6585:: with SMTP id z127mr3184776wmb.25.1561636416139; Thu, 27 Jun 2019 04:53:36 -0700 (PDT) Received: from x1.local (183.red-88-21-202.staticip.rima-tde.net. [88.21.202.183]) by smtp.gmail.com with ESMTPSA id o126sm6196408wmo.1.2019.06.27.04.53.34 (version=TLS1_3 cipher=AEAD-AES256-GCM-SHA384 bits=256/256); Thu, 27 Jun 2019 04:53:35 -0700 (PDT) From: =?utf-8?q?Philippe_Mathieu-Daud=C3=A9?= To: qemu-devel@nongnu.org Date: Thu, 27 Jun 2019 13:53:30 +0200 Message-Id: <20190627115331.2373-3-f4bug@amsat.org> X-Mailer: git-send-email 2.19.1 In-Reply-To: <20190627115331.2373-1-f4bug@amsat.org> References: <20190627115331.2373-1-f4bug@amsat.org> MIME-Version: 1.0 X-detected-operating-system: by eggs.gnu.org: Genre and OS details not recognized. X-Received-From: 2a00:1450:4864:20::344 Subject: [Qemu-devel] [PATCH 2/3] tests/acceptance: Add test that boots Linux up to BusyBox on Leon3 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: , Cc: Fam Zheng , Eduardo Habkost , =?utf-8?q?Alex_Benn=C3=A9e?= , Mark Cave-Ayland , =?utf-8?q?Philippe_Mathieu-Daud?= =?utf-8?b?w6k=?= , Fabien Chouteau , KONRAD Frederic , Cleber Rosa , =?utf-8?q?Philippe_Mathieu-Daud=C3=A9?= Errors-To: qemu-devel-bounces+incoming=patchwork.ozlabs.org@nongnu.org Sender: "Qemu-devel" Gaisler provides convenient images: https://www.gaisler.com/index.php/downloads/linux HOWTO build: https://www.gaisler.com/index.php/products/operating-systems/linux Signed-off-by: Philippe Mathieu-Daudé --- tests/acceptance/machine_sparc_leon3.py | 31 +++++++++++++++++++++++++ 1 file changed, 31 insertions(+) diff --git a/tests/acceptance/machine_sparc_leon3.py b/tests/acceptance/machine_sparc_leon3.py index 0bbae44f85..b3039b5d30 100644 --- a/tests/acceptance/machine_sparc_leon3.py +++ b/tests/acceptance/machine_sparc_leon3.py @@ -37,6 +37,11 @@ class Leon3Machine(Test): fail = 'Failure message found in console: %s' % failure_message self.fail(fail) + def exec_command_and_wait_for_pattern(self, command, success_message): + command += '\n' + self.vm.console_socket.sendall(command.encode()) + self.wait_for_console_pattern(success_message) + def test_leon3_helenos_uimage(self): """ :avocado: tags=arch:sparc @@ -56,3 +61,29 @@ class Leon3Machine(Test): self.wait_for_console_pattern('Copyright (c) 2001-2014 HelenOS project') self.wait_for_console_pattern('Booting the kernel ...') + + def test_leon3_linux_kernel_4_9_busybox(self): + """ + :avocado: tags=arch:sparc + :avocado: tags=machine:leon3 + """ + kernel_url = ('https://www.gaisler.com/anonftp/linux/linux-4/images/' + 'leon-linux-4.9/leon-linux-4.9-1.0/up/image.ram') + kernel_hash = '289bd1bcca10cda76d0ef2264a8657adc251f5f5' + kernel_path = self.fetch_asset(kernel_url, asset_hash=kernel_hash) + + self.vm.set_machine('leon3_generic') + self.vm.set_console() + self.vm.add_args('-kernel', kernel_path) + + self.vm.launch() + + self.wait_for_console_pattern('TYPE: Leon3 System-on-a-Chip') + + self.wait_for_console_pattern('Welcome to Buildroot') + + self.wait_for_console_pattern('buildroot login:') + self.exec_command_and_wait_for_pattern('root', '#') + uname = 'Linux buildroot 4.9.54-00018-g62dab2c #2 ' \ + 'Wed Oct 18 09:45:51 CEST 2017 sparc GNU/Linux' + self.exec_command_and_wait_for_pattern('uname -a', uname)