From nobody Sat Jul 12 06:17:20 2025 Delivered-To: importer2@patchew.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+importer2=patchew.org@nongnu.org ARC-Seal: i=1; a=rsa-sha256; t=1677149584; cv=none; d=zohomail.com; s=zohoarc; b=HYTHmi2BEHzOiT/05B4DkMdKwrILgMuZvH3+1CkAMSK6ijKKoDcTj2b8c7sfWTc+/ioIije39Qpm4j6x5f6J+TkZaBIGpuHzkSFOv9XioDPQoaj9DXXafYyiJnUKS3QGCU26m7fgkYvyeus6zST0ReTeXAZA3JrDGbKbFmnREzs= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1677149584; h=Content-Type:Content-Transfer-Encoding:Cc:Date:From:In-Reply-To:List-Subscribe:List-Post:List-Id:List-Archive:List-Help:List-Unsubscribe:MIME-Version:Message-ID:References:Sender:Subject; bh=RUAHGzsOHqjWLqPro0gyFdLt1A2lRTHbQY6qX0Cbr6c=; b=YzCdMSnZC+DUJuUJrNvqHNjzMvDDrTrUUqxvA6s2KmLopHXK4TBP+a+y0+wXGapeOeXIUVD4ac8r8+hDsqqGhU9GO+0CZtDF+i4Sqfr0i+Xa7x1Wiciup8ViDvf8gV0fRrYeApfle4IeuqKB0UckSLcbfk2lcdAxz4Q5qT8xeUQ= 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+importer2=patchew.org@nongnu.org Return-Path: Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mx.zohomail.com with SMTPS id 16771495841061018.9846867450282; Thu, 23 Feb 2023 02:53:04 -0800 (PST) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1pV9Ci-0007kh-5Q; Thu, 23 Feb 2023 05:52:00 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1pV9Ce-0007de-Ri for qemu-devel@nongnu.org; Thu, 23 Feb 2023 05:51:56 -0500 Received: from mail-pl1-x630.google.com ([2607:f8b0:4864:20::630]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1pV9Cc-0003kk-I6 for qemu-devel@nongnu.org; Thu, 23 Feb 2023 05:51:56 -0500 Received: by mail-pl1-x630.google.com with SMTP id q11so12636542plx.5 for ; Thu, 23 Feb 2023 02:51:54 -0800 (PST) Received: from alarm.flets-east.jp ([2400:4050:a840:1e00:4457:c267:5e09:481b]) by smtp.gmail.com with ESMTPSA id k184-20020a6384c1000000b004fb26a80875sm4477692pgd.22.2023.02.23.02.51.47 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 23 Feb 2023 02:51:52 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=daynix-com.20210112.gappssmtp.com; s=20210112; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=RUAHGzsOHqjWLqPro0gyFdLt1A2lRTHbQY6qX0Cbr6c=; b=2i+ebXf/3RcHuSpljG/Tl3t2+LtIwtqV04VGf5t14SAJ2UL8mM+blecG/sfxXtt49f D56Ea8eI28uC5qZramKURhFEbsjENnvBlXrgu6l7JLDJwqRfrGg/Bn6m//1KorVywFxo 51u8e7V3BIhIM8NugCCRmDXQIj3/r1Mx3GLpnzZMJfSxsQYTh0tFKXjRLi529xZTEFxR feRBk1yAo9bJQBx83skPpXsXZZhfpg1YQDR8/8WbN1RmGdDHTWCgqPDQes2WgRJvAq+r DpDRF/UTpj88PeCljpEnbPewm3L+5lau0fMer5Wk+nIg/rQ7Zla0+gknBVgKjBZIyyBp mhIQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=RUAHGzsOHqjWLqPro0gyFdLt1A2lRTHbQY6qX0Cbr6c=; b=QWKgi49qYucW7qjD9G2hs7qLOwjhE3Inh0kOLzfj7d1T5hEjG8VE2N23o+lbFpQIhM kPRV/ue8nfkBKqOExhiROF4QhmZCM2bLklWIHNlJa7qyNAZR+Wlhhs3rXAhRNFKwzdP5 1OtCHMJMmpno/zl6bBLCIEpKgCtVwhy6euYM/XqLuuRhwUumIxZHUVQncGeOpO7jU/EB 6NsN5WGlBZQYJHeJGftTG+GCDfHd3OPB6daMU1Cs+080hQnh5frwTiH8vyNpP4b/J8qO wFHJEz5Pb8YsS0wAC/sELMcDgUO1Zfxyw5vM46jDGUZGa1QNCs1rxcm550USLIFsVJMm NzFQ== X-Gm-Message-State: AO0yUKURzKFwr25M+7+SoqhcLdJa8SEnf+XNiID5NsATMpNA12JBzDQL o9IL2ffbm3+76TywRlfX7bcEYw== X-Google-Smtp-Source: AK7set/ATF6Ak52RGoy/nWDTPzn8Rbpk3QyzbD+gC4zEEi1UXwgdW7puCpn+tA6PMYkfKmLSqx57LA== X-Received: by 2002:a05:6a20:8f1f:b0:bf:1e6b:663d with SMTP id b31-20020a056a208f1f00b000bf1e6b663dmr13311839pzk.44.1677149513324; Thu, 23 Feb 2023 02:51:53 -0800 (PST) From: Akihiko Odaki To: Cc: Jason Wang , Dmitry Fleytman , "Michael S . Tsirkin" , Marcel Apfelbaum , =?UTF-8?q?Alex=20Benn=C3=A9e?= , =?UTF-8?q?Philippe=20Mathieu-Daud=C3=A9?= , Thomas Huth , Wainer dos Santos Moschetta , Beraldo Leal , Cleber Rosa , Laurent Vivier , Paolo Bonzini , Alexander Bulekov , Bandan Das , Stefan Hajnoczi , Darren Kenny , Qiuhao Li , qemu-devel@nongnu.org, qemu-ppc@nongnu.org, devel@daynix.com, Yan Vugenfirer , Yuri Benditovich , Sriram Yagnaraman , Gal Hammer , Akihiko Odaki , =?UTF-8?q?C=C3=A9dric=20Le=20Goater?= Subject: [PATCH v9 8/9] tests/avocado: Add igb test Date: Thu, 23 Feb 2023 19:50:56 +0900 Message-Id: <20230223105057.144309-9-akihiko.odaki@daynix.com> X-Mailer: git-send-email 2.39.1 In-Reply-To: <20230223105057.144309-1-akihiko.odaki@daynix.com> References: <20230223105057.144309-1-akihiko.odaki@daynix.com> MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable 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+importer2=patchew.org@nongnu.org; helo=lists.gnu.org; Received-SPF: none client-ip=2607:f8b0:4864:20::630; envelope-from=akihiko.odaki@daynix.com; helo=mail-pl1-x630.google.com X-Spam_score_int: -18 X-Spam_score: -1.9 X-Spam_bar: - X-Spam_report: (-1.9 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_NONE=0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+importer2=patchew.org@nongnu.org Sender: qemu-devel-bounces+importer2=patchew.org@nongnu.org X-ZohoMail-DKIM: pass (identity @daynix-com.20210112.gappssmtp.com) X-ZM-MESSAGEID: 1677149585086100001 This automates ethtool tests for igb registers, interrupts, etc. Signed-off-by: Akihiko Odaki Reviewed-by: C=C3=A9dric Le Goater --- MAINTAINERS | 1 + .../org.centos/stream/8/x86_64/test-avocado | 1 + tests/avocado/igb.py | 38 +++++++++++++++++++ 3 files changed, 40 insertions(+) create mode 100644 tests/avocado/igb.py diff --git a/MAINTAINERS b/MAINTAINERS index 446283d5bc..410c871cf1 100644 --- a/MAINTAINERS +++ b/MAINTAINERS @@ -2229,6 +2229,7 @@ igb M: Akihiko Odaki S: Maintained F: hw/net/igb* +F: tests/avocado/igb.py F: tests/qtest/igb-test.c F: tests/qtest/libqos/igb.c =20 diff --git a/scripts/ci/org.centos/stream/8/x86_64/test-avocado b/scripts/c= i/org.centos/stream/8/x86_64/test-avocado index f403e4e7ec..d2c0e5fb4c 100755 --- a/scripts/ci/org.centos/stream/8/x86_64/test-avocado +++ b/scripts/ci/org.centos/stream/8/x86_64/test-avocado @@ -30,6 +30,7 @@ make get-vm-images tests/avocado/cpu_queries.py:QueryCPUModelExpansion.test \ tests/avocado/empty_cpu_model.py:EmptyCPUModel.test \ tests/avocado/hotplug_cpu.py:HotPlugCPU.test \ + tests/avocado/igb.py:IGB.test \ tests/avocado/info_usernet.py:InfoUsernet.test_hostfwd \ tests/avocado/intel_iommu.py:IntelIOMMU.test_intel_iommu \ tests/avocado/intel_iommu.py:IntelIOMMU.test_intel_iommu_pt \ diff --git a/tests/avocado/igb.py b/tests/avocado/igb.py new file mode 100644 index 0000000000..abf5dfa07f --- /dev/null +++ b/tests/avocado/igb.py @@ -0,0 +1,38 @@ +# SPDX-License-Identifier: GPL-2.0-or-later +# ethtool tests for igb registers, interrupts, etc + +from avocado_qemu import LinuxTest + +class IGB(LinuxTest): + """ + :avocado: tags=3Daccel:kvm + :avocado: tags=3Darch:x86_64 + :avocado: tags=3Ddistro:fedora + :avocado: tags=3Ddistro_version:31 + :avocado: tags=3Dmachine:q35 + """ + + timeout =3D 180 + + def test(self): + self.require_accelerator('kvm') + kernel_url =3D self.distro.pxeboot_url + 'vmlinuz' + kernel_hash =3D '5b6f6876e1b5bda314f93893271da0d5777b1f3c' + kernel_path =3D self.fetch_asset(kernel_url, asset_hash=3Dkernel_h= ash) + initrd_url =3D self.distro.pxeboot_url + 'initrd.img' + initrd_hash =3D 'dd0340a1b39bd28f88532babd4581c67649ec5b1' + initrd_path =3D self.fetch_asset(initrd_url, asset_hash=3Dinitrd_h= ash) + + # Ideally we want to test MSI as well, but it is blocked by a bug + # fixed with: + # https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.g= it/commit/?id=3D28e96556baca7056d11d9fb3cdd0aba4483e00d8 + kernel_params =3D self.distro.default_kernel_params + ' pci=3Dnoms= i' + + self.vm.add_args('-kernel', kernel_path, + '-initrd', initrd_path, + '-append', kernel_params, + '-accel', 'kvm', + '-device', 'igb') + self.launch_and_wait() + self.ssh_command('dnf -y install ethtool') + self.ssh_command('ethtool -t eth1 offline') --=20 2.39.1