From nobody Sat Jul 12 06:16:16 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=1677149606; cv=none; d=zohomail.com; s=zohoarc; b=CDYC7gzHsGp1cFGQRBBPZLEqH/s1wY9xl1M3nYlkhF4WXe8vmdpYp0T1RV8SDaYlhpjm+Rpl44jWfro9cmwxtN5NPuKCMEQlTMp3j1hlAepmO454dKJgdoR2JUHD1G65SAR40QyRKfH1+Y2h8pxPVQqnIQZY3DEo23hlSKyWY5o= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1677149606; h=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=s/bxjHFIsiAL+63eNAGcS2MggSsbsWq0QCFg0Dd0/BY=; b=aHuLse3inEfxcIRxtNJAzK1rRhPLFDLGS0iARIx8KoFBQqN1I9F3NiQwdsxeCRzSLe3V+zKxLOZp/KfFhIscOI/sH17yzt29q+Gaa3+Y5YprsH9sUUVEFJlxwKZUdl9Sl/USggDmErngw8LUqA8Q9P3u0EoFYPuxU6Rr9mNeYXQ= 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 1677149606784882.2277942654722; Thu, 23 Feb 2023 02:53:26 -0800 (PST) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1pV9Cc-0007W2-03; Thu, 23 Feb 2023 05:51:54 -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 1pV9CT-0007KU-PZ for qemu-devel@nongnu.org; Thu, 23 Feb 2023 05:51:46 -0500 Received: from mail-pl1-x62e.google.com ([2607:f8b0:4864:20::62e]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1pV9CS-0003j5-6B for qemu-devel@nongnu.org; Thu, 23 Feb 2023 05:51:45 -0500 Received: by mail-pl1-x62e.google.com with SMTP id u14so8387255ple.7 for ; Thu, 23 Feb 2023 02:51:41 -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.35 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 23 Feb 2023 02:51:40 -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=s/bxjHFIsiAL+63eNAGcS2MggSsbsWq0QCFg0Dd0/BY=; b=vKALSwgAN+n2icZXXQLqebb/Y8rZEwDUdfzrc8eUjzhywoL4YD7FA2wCwFEX71P3hU qJC7lFETiMCs/NNmzHkVCo+M13Jj+oghFQG+/lobIYEEa1Oj2am1xyaQqLBFVgbiIhKa r9uJgfZiAyHRNM0a1T1acjZFbxHn94paaZMJ+UPBK9tMl+b2bEVj51MiQhkWJruhK//t xp/fowBxNRu8W9tU5cv2UBFd8NdpQuW9xB18RC7qPW1zbgqe1JwG9gzjj4wiptx3tvS/ +ZVJBhUdFYug6IRwSAhxoUMCMghF/IzljqH6X+rOxRZuhvlPg1ZT200QH8ltdGKSZxiq 8jfQ== 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=s/bxjHFIsiAL+63eNAGcS2MggSsbsWq0QCFg0Dd0/BY=; b=PSSd+F5Fln+ChMPibWBrqf0l0bdavtiWuf7vNeTmJBsUL6W/Eq7NDj/R2F1l9gbn/M 8rhJfYzS/NUimTBn2E27Bs8TAAj91CMIbyBb19CeFkext7/Uzhd4x3icIu3JQb1OZ1Ez Pe73+/c9mAZiULoqjdTUJ4KgATO1nuZAwyz9tr+jDtHt+J6tOOdeRo0YOfm5nvrDcrJJ R84MZGJyI/f/pXroAcDqC3dqgaWrlXKaeTGkHpa33rNSZC/DT8haxZAUO/QNwqlcnl+p aZkeSe2zA3kzBhqPuRyQ5wK1H/gydR46uPkjd7epOR8TvT0HWl9aRPm2r71b/B+HUTZ7 K29w== X-Gm-Message-State: AO0yUKVivOk6UGwBGSvzAmB1NLw4idtfEj6CZLCWvhjeJQoAeqUwaeua xJvLKXm7hgYTJdhZXHsIDHrvZw== X-Google-Smtp-Source: AK7set/pTJWwED5+GzIDrjD74Ho747yi24fSfY3KiSdSrGV4G8TimpByiOp1ABCI1JsZCp+dPz6mWQ== X-Received: by 2002:a05:6a20:69a3:b0:cb:af96:ace7 with SMTP id t35-20020a056a2069a300b000cbaf96ace7mr11565214pzk.46.1677149501011; Thu, 23 Feb 2023 02:51:41 -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 Subject: [PATCH v9 6/9] tests/qtest/libqos/e1000e: Export macreg functions Date: Thu, 23 Feb 2023 19:50:54 +0900 Message-Id: <20230223105057.144309-7-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-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::62e; envelope-from=akihiko.odaki@daynix.com; helo=mail-pl1-x62e.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: 1677149607230100001 Content-Type: text/plain; charset="utf-8" They will be useful for igb testing. Signed-off-by: Akihiko Odaki Reviewed-by: Thomas Huth --- tests/qtest/libqos/e1000e.c | 12 ------------ tests/qtest/libqos/e1000e.h | 12 ++++++++++++ 2 files changed, 12 insertions(+), 12 deletions(-) diff --git a/tests/qtest/libqos/e1000e.c b/tests/qtest/libqos/e1000e.c index 28fb3052aa..925654c7fd 100644 --- a/tests/qtest/libqos/e1000e.c +++ b/tests/qtest/libqos/e1000e.c @@ -36,18 +36,6 @@ =20 #define E1000E_RING_LEN (0x1000) =20 -static void e1000e_macreg_write(QE1000E *d, uint32_t reg, uint32_t val) -{ - QE1000E_PCI *d_pci =3D container_of(d, QE1000E_PCI, e1000e); - qpci_io_writel(&d_pci->pci_dev, d_pci->mac_regs, reg, val); -} - -static uint32_t e1000e_macreg_read(QE1000E *d, uint32_t reg) -{ - QE1000E_PCI *d_pci =3D container_of(d, QE1000E_PCI, e1000e); - return qpci_io_readl(&d_pci->pci_dev, d_pci->mac_regs, reg); -} - void e1000e_tx_ring_push(QE1000E *d, void *descr) { QE1000E_PCI *d_pci =3D container_of(d, QE1000E_PCI, e1000e); diff --git a/tests/qtest/libqos/e1000e.h b/tests/qtest/libqos/e1000e.h index 5e2b201aa7..30643c8094 100644 --- a/tests/qtest/libqos/e1000e.h +++ b/tests/qtest/libqos/e1000e.h @@ -42,6 +42,18 @@ struct QE1000E_PCI { QE1000E e1000e; }; =20 +static inline void e1000e_macreg_write(QE1000E *d, uint32_t reg, uint32_t = val) +{ + QE1000E_PCI *d_pci =3D container_of(d, QE1000E_PCI, e1000e); + qpci_io_writel(&d_pci->pci_dev, d_pci->mac_regs, reg, val); +} + +static inline uint32_t e1000e_macreg_read(QE1000E *d, uint32_t reg) +{ + QE1000E_PCI *d_pci =3D container_of(d, QE1000E_PCI, e1000e); + return qpci_io_readl(&d_pci->pci_dev, d_pci->mac_regs, reg); +} + void e1000e_wait_isr(QE1000E *d, uint16_t msg_id); void e1000e_tx_ring_push(QE1000E *d, void *descr); void e1000e_rx_ring_push(QE1000E *d, void *descr); --=20 2.39.1