[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[PATCH 27/31] tests/qtest/libqos/e1000e: Export macreg functions
From: |
Akihiko Odaki |
Subject: |
[PATCH 27/31] tests/qtest/libqos/e1000e: Export macreg functions |
Date: |
Thu, 12 Jan 2023 18:57:39 +0900 |
They will be useful for igb testing.
Signed-off-by: Akihiko Odaki <akihiko.odaki@daynix.com>
---
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 @@
#define E1000E_RING_LEN (0x1000)
-static void e1000e_macreg_write(QE1000E *d, uint32_t reg, uint32_t val)
-{
- QE1000E_PCI *d_pci = 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 = 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 = 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;
};
+static inline void e1000e_macreg_write(QE1000E *d, uint32_t reg, uint32_t val)
+{
+ QE1000E_PCI *d_pci = 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 = 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);
--
2.39.0
- [PATCH 09/31] e1000: Use memcpy to intialize registers, (continued)
- [PATCH 09/31] e1000: Use memcpy to intialize registers, Akihiko Odaki, 2023/01/12
- [PATCH 10/31] e1000e: Use memcpy to intialize registers, Akihiko Odaki, 2023/01/12
- [PATCH 13/31] e1000: Configure ResettableClass, Akihiko Odaki, 2023/01/12
- [PATCH 15/31] e1000e: Introduce e1000_rx_desc_union, Akihiko Odaki, 2023/01/12
- [PATCH 16/31] e1000e: Set MII_ANER_NWAY, Akihiko Odaki, 2023/01/12
- [PATCH 23/31] igb: Rename identifiers, Akihiko Odaki, 2023/01/12
- [PATCH 26/31] tests/qtest/e1000e-test: Fabricate ethernet header, Akihiko Odaki, 2023/01/12
- [PATCH 30/31] tests/avocado: Add igb test, Akihiko Odaki, 2023/01/12
- [PATCH 27/31] tests/qtest/libqos/e1000e: Export macreg functions,
Akihiko Odaki <=
- [PATCH 28/31] tests/qtest/libqos/igb: Copy e1000e code, Akihiko Odaki, 2023/01/12
- [PATCH 29/31] tests/qtest/libqos/igb: Transform to igb tests, Akihiko Odaki, 2023/01/12
- [PATCH 20/31] pcie: Introduce pcie_sriov_num_vfs, Akihiko Odaki, 2023/01/12
- [PATCH 14/31] e1000e: Configure ResettableClass, Akihiko Odaki, 2023/01/12
- Re: [PATCH 00/31] Introduce igb, Philippe Mathieu-Daudé, 2023/01/12