DPDK patches and discussions
 help / color / mirror / Atom feed
* [dpdk-dev] [PATCH] net/e1000: build on Windows
@ 2021-10-07 20:24 William Tu
  2021-10-08  6:54 ` David Marchand
  2021-10-08 13:53 ` [dpdk-dev] [PATCH v2] " William Tu
  0 siblings, 2 replies; 21+ messages in thread
From: William Tu @ 2021-10-07 20:24 UTC (permalink / raw)
  To: dev; +Cc: Dmitry.Kozliuk, pallavi.kadam

This patch enables building the e1000 driver for Windows.
I tested using two Windows VM on top of VMware Fusion,
creating two e1000 devices with device ID 0x10D3,
verifying rx/tx works correctly using dpdk-testpmd.exe
rxonly and txonly mode.

Signed-off-by: William Tu <u9012063@gmail.com>
---
Example when running:
PS C:\dpdk> .\build\app\dpdk-testpmd.exe
EAL: Detected CPU lcores: 4
EAL: Detected NUMA nodes: 1
EAL: Multi-process support is requested, but not available.
EAL: WARNING: TSC frequency estimated roughly - clock timings may be less accurate.
EAL: Probe PCI driver: net_e1000_em (8086:10d3) device: 0000:03:00.0 (socket 0)
EAL: Requested device 0000:1b:00.0 cannot be used
testpmd: create a new mbuf pool <mb_pool_0>: n=171456, size=2176, socket=0
testpmd: preferred mempool ops selected: ring_mp_mc

Warning! port-topology=paired and odd forward ports number, the last port will p
air with itself.
Configuring Port 0 (socket 0)
Port 0: 00:50:56:3A:4D:A6
Checking link statuses...
Done
No commandline core given, start packet forwarding
allocation mode: native
Logical Core 1 (socket 0) forwards packets on 1 streams:
  RX P=0/Q=0 (socket 0) -> TX P=0/Q=0 (socket 0) peer=02:00:00:00:00:00

  io packet forwarding packets/burst=32
  nb forwarding cores=1 - nb forwarding ports=1
  port 0: RX queue number: 1 Tx queue number: 1
    Rx offloads=0x0 Tx offloads=0x0
    RX queue: 0
      RX desc=256 - RX free threshold=0
      TX desc=256 - TX free threshold=32
      TX offloads=0x0 - TX RS bit threshold=32
Press enter to exit

Telling cores to stop...
Waiting for lcores to finish...

  ---------------------- Forward statistics for port 0  ------------------
  RX-packets: 40361          RX-dropped: 0             RX-total: 40361
  TX-packets: 40616          TX-dropped: 0             TX-total: 40616
  ------------------------------------------------------------------------

  +++++++++++++++ Accumulated forward statistics for all ports+++++++++++
  RX-packets: 40361          RX-dropped: 0             RX-total: 40361
  TX-packets: 40616          TX-dropped: 0             TX-total: 40616
  ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

--
---
 drivers/net/e1000/base/e1000_osdep.h | 2 ++
 drivers/net/e1000/e1000_ethdev.h     | 1 +
 drivers/net/e1000/meson.build        | 6 ------
 3 files changed, 3 insertions(+), 6 deletions(-)

diff --git a/drivers/net/e1000/base/e1000_osdep.h b/drivers/net/e1000/base/e1000_osdep.h
index 94a49f3404..cd90228cef 100644
--- a/drivers/net/e1000/base/e1000_osdep.h
+++ b/drivers/net/e1000/base/e1000_osdep.h
@@ -34,7 +34,9 @@
 #define DEBUGOUT6(S, args...)   DEBUGOUT(S, ##args)
 #define DEBUGOUT7(S, args...)   DEBUGOUT(S, ##args)
 
+#ifndef UNREFERENCED_PARAMETER
 #define UNREFERENCED_PARAMETER(_p)
+#endif
 #define UNREFERENCED_1PARAMETER(_p)
 #define UNREFERENCED_2PARAMETER(_p, _q)
 #define UNREFERENCED_3PARAMETER(_p, _q, _r)
diff --git a/drivers/net/e1000/e1000_ethdev.h b/drivers/net/e1000/e1000_ethdev.h
index 3b4d9c3ee6..613b81f030 100644
--- a/drivers/net/e1000/e1000_ethdev.h
+++ b/drivers/net/e1000/e1000_ethdev.h
@@ -6,6 +6,7 @@
 #define _E1000_ETHDEV_H_
 
 #include <stdint.h>
+#include <sys/queue.h>
 
 #include <rte_flow.h>
 #include <rte_time.h>
diff --git a/drivers/net/e1000/meson.build b/drivers/net/e1000/meson.build
index c5e48c6bc7..296ec25f2c 100644
--- a/drivers/net/e1000/meson.build
+++ b/drivers/net/e1000/meson.build
@@ -1,12 +1,6 @@
 # SPDX-License-Identifier: BSD-3-Clause
 # Copyright(c) 2017 Intel Corporation
 
-if is_windows
-    build = false
-    reason = 'not supported on Windows'
-    subdir_done()
-endif
-
 subdir('base')
 objs = [base_objs]
 
-- 
2.30.2


^ permalink raw reply	[flat|nested] 21+ messages in thread

* Re: [dpdk-dev] [PATCH] net/e1000: build on Windows
  2021-10-07 20:24 [dpdk-dev] [PATCH] net/e1000: build on Windows William Tu
@ 2021-10-08  6:54 ` David Marchand
  2021-10-08  6:55   ` David Marchand
  2021-10-08 12:20   ` William Tu
  2021-10-08 13:53 ` [dpdk-dev] [PATCH v2] " William Tu
  1 sibling, 2 replies; 21+ messages in thread
From: David Marchand @ 2021-10-08  6:54 UTC (permalink / raw)
  To: William Tu; +Cc: dev, Dmitry Kozlyuk, Pallavi Kadam

On Thu, Oct 7, 2021 at 10:25 PM William Tu <u9012063@gmail.com> wrote:
>
> This patch enables building the e1000 driver for Windows.
> I tested using two Windows VM on top of VMware Fusion,
> creating two e1000 devices with device ID 0x10D3,
> verifying rx/tx works correctly using dpdk-testpmd.exe
> rxonly and txonly mode.
>
> Signed-off-by: William Tu <u9012063@gmail.com>

Please, Cc: driver maintainers when touching one.
You can pass --to-cmd or --cc-cmd ./devtools/get-maintainer.sh when
calling git send-email as suggested in the contributing howto.
https://doc.dpdk.org/guides/contributing/patches.html#sending-patches


> ---
> Example when running:
> PS C:\dpdk> .\build\app\dpdk-testpmd.exe
> EAL: Detected CPU lcores: 4
> EAL: Detected NUMA nodes: 1
> EAL: Multi-process support is requested, but not available.
> EAL: WARNING: TSC frequency estimated roughly - clock timings may be less accurate.
> EAL: Probe PCI driver: net_e1000_em (8086:10d3) device: 0000:03:00.0 (socket 0)
> EAL: Requested device 0000:1b:00.0 cannot be used

Odd to read this, and still see testpmd getting one port afterwards.

Could you enable debug logs?
It will be verbose but let's try with --log-level=*:debug.


> testpmd: create a new mbuf pool <mb_pool_0>: n=171456, size=2176, socket=0
> testpmd: preferred mempool ops selected: ring_mp_mc
>
> Warning! port-topology=paired and odd forward ports number, the last port will p
> air with itself.
> Configuring Port 0 (socket 0)
> Port 0: 00:50:56:3A:4D:A6
> Checking link statuses...
> Done
> No commandline core given, start packet forwarding
> allocation mode: native
> Logical Core 1 (socket 0) forwards packets on 1 streams:
>   RX P=0/Q=0 (socket 0) -> TX P=0/Q=0 (socket 0) peer=02:00:00:00:00:00
>
>   io packet forwarding packets/burst=32
>   nb forwarding cores=1 - nb forwarding ports=1
>   port 0: RX queue number: 1 Tx queue number: 1
>     Rx offloads=0x0 Tx offloads=0x0
>     RX queue: 0
>       RX desc=256 - RX free threshold=0
>       TX desc=256 - TX free threshold=32
>       TX offloads=0x0 - TX RS bit threshold=32


-- 
David Marchand


^ permalink raw reply	[flat|nested] 21+ messages in thread

* Re: [dpdk-dev] [PATCH] net/e1000: build on Windows
  2021-10-08  6:54 ` David Marchand
@ 2021-10-08  6:55   ` David Marchand
  2021-10-08 12:20   ` William Tu
  1 sibling, 0 replies; 21+ messages in thread
From: David Marchand @ 2021-10-08  6:55 UTC (permalink / raw)
  To: William Tu; +Cc: dev, Dmitry Kozlyuk, Pallavi Kadam, Wang, Haiyue

On Fri, Oct 8, 2021 at 8:54 AM David Marchand <david.marchand@redhat.com> wrote:
>
> On Thu, Oct 7, 2021 at 10:25 PM William Tu <u9012063@gmail.com> wrote:
> >
> > This patch enables building the e1000 driver for Windows.
> > I tested using two Windows VM on top of VMware Fusion,
> > creating two e1000 devices with device ID 0x10D3,
> > verifying rx/tx works correctly using dpdk-testpmd.exe
> > rxonly and txonly mode.
> >
> > Signed-off-by: William Tu <u9012063@gmail.com>
>
> Please, Cc: driver maintainers when touching one.

And I pressed Send before adding Haiyue... fixed.


-- 
David Marchand


^ permalink raw reply	[flat|nested] 21+ messages in thread

* Re: [dpdk-dev] [PATCH] net/e1000: build on Windows
  2021-10-08  6:54 ` David Marchand
  2021-10-08  6:55   ` David Marchand
@ 2021-10-08 12:20   ` William Tu
  2021-10-08 12:24     ` David Marchand
  1 sibling, 1 reply; 21+ messages in thread
From: William Tu @ 2021-10-08 12:20 UTC (permalink / raw)
  To: David Marchand; +Cc: dev, Dmitry Kozlyuk, Pallavi Kadam, haiyue.wang

On Thu, Oct 7, 2021 at 11:54 PM David Marchand
<david.marchand@redhat.com> wrote:
>
> On Thu, Oct 7, 2021 at 10:25 PM William Tu <u9012063@gmail.com> wrote:
> >
> > This patch enables building the e1000 driver for Windows.
> > I tested using two Windows VM on top of VMware Fusion,
> > creating two e1000 devices with device ID 0x10D3,
> > verifying rx/tx works correctly using dpdk-testpmd.exe
> > rxonly and txonly mode.
> >
> > Signed-off-by: William Tu <u9012063@gmail.com>
>
> Please, Cc: driver maintainers when touching one.
> You can pass --to-cmd or --cc-cmd ./devtools/get-maintainer.sh when
> calling git send-email as suggested in the contributing howto.
> https://doc.dpdk.org/guides/contributing/patches.html#sending-patches

Got it, thanks.

>
>
> > ---
> > Example when running:
> > PS C:\dpdk> .\build\app\dpdk-testpmd.exe
> > EAL: Detected CPU lcores: 4
> > EAL: Detected NUMA nodes: 1
> > EAL: Multi-process support is requested, but not available.
> > EAL: WARNING: TSC frequency estimated roughly - clock timings may be less accurate.
> > EAL: Probe PCI driver: net_e1000_em (8086:10d3) device: 0000:03:00.0 (socket 0)
> > EAL: Requested device 0000:1b:00.0 cannot be used
>
> Odd to read this, and still see testpmd getting one port afterwards.
This is expected. Because I only enable 1 dpdk port (0000:03:00.0)
The 0000:1b:00.0 is still running kernel driver. I will mention it in next
version.

Thanks
William

^ permalink raw reply	[flat|nested] 21+ messages in thread

* Re: [dpdk-dev] [PATCH] net/e1000: build on Windows
  2021-10-08 12:20   ` William Tu
@ 2021-10-08 12:24     ` David Marchand
  0 siblings, 0 replies; 21+ messages in thread
From: David Marchand @ 2021-10-08 12:24 UTC (permalink / raw)
  To: William Tu; +Cc: dev, Dmitry Kozlyuk, Pallavi Kadam, Wang, Haiyue

On Fri, Oct 8, 2021 at 2:21 PM William Tu <u9012063@gmail.com> wrote:
> > > Example when running:
> > > PS C:\dpdk> .\build\app\dpdk-testpmd.exe
> > > EAL: Detected CPU lcores: 4
> > > EAL: Detected NUMA nodes: 1
> > > EAL: Multi-process support is requested, but not available.
> > > EAL: WARNING: TSC frequency estimated roughly - clock timings may be less accurate.
> > > EAL: Probe PCI driver: net_e1000_em (8086:10d3) device: 0000:03:00.0 (socket 0)
> > > EAL: Requested device 0000:1b:00.0 cannot be used
> >
> > Odd to read this, and still see testpmd getting one port afterwards.
> This is expected. Because I only enable 1 dpdk port (0000:03:00.0)
> The 0000:1b:00.0 is still running kernel driver. I will mention it in next
> version.

Ok sorry, I did not notice.
No need to mention, simply start testpmd with -a 0000:03:00.0.


-- 
David Marchand


^ permalink raw reply	[flat|nested] 21+ messages in thread

* [dpdk-dev] [PATCH v2] net/e1000: build on Windows
  2021-10-07 20:24 [dpdk-dev] [PATCH] net/e1000: build on Windows William Tu
  2021-10-08  6:54 ` David Marchand
@ 2021-10-08 13:53 ` William Tu
  2021-10-08 16:08   ` Wang, Haiyue
                     ` (3 more replies)
  1 sibling, 4 replies; 21+ messages in thread
From: William Tu @ 2021-10-08 13:53 UTC (permalink / raw)
  To: dev; +Cc: pallavi.kadam, david.marchand, Haiyue Wang

This patch enables building the e1000 driver for Windows.
I tested using two Windows VM on top of VMware Fusion,
creating two e1000 devices with device ID 0x10D3,
verifying rx/tx works correctly using dpdk-testpmd.exe
rxonly and txonly mode.

Signed-off-by: William Tu <u9012063@gmail.com>
Cc: Haiyue Wang <haiyue.wang@intel.com>
---
A short demo:
https://youtu.be/UZ9hm2jQa2Y

Example when running:
PS C:\dpdk> .\build\app\dpdk-testpmd.exe
EAL: Detected CPU lcores: 4
EAL: Detected NUMA nodes: 1
EAL: Multi-process support is requested, but not available.
EAL: WARNING: TSC frequency estimated roughly - clock timings may be less accurate.
EAL: Probe PCI driver: net_e1000_em (8086:10d3) device: 0000:03:00.0 (socket 0)
EAL: Requested device 0000:1b:00.0 cannot be used
testpmd: create a new mbuf pool <mb_pool_0>: n=171456, size=2176, socket=0
testpmd: preferred mempool ops selected: ring_mp_mc

Warning! port-topology=paired and odd forward ports number, the last port will p
air with itself.
Configuring Port 0 (socket 0)
Port 0: 00:50:56:3A:4D:A6
Checking link statuses...
Done
No commandline core given, start packet forwarding
allocation mode: native
Logical Core 1 (socket 0) forwards packets on 1 streams:
  RX P=0/Q=0 (socket 0) -> TX P=0/Q=0 (socket 0) peer=02:00:00:00:00:00

  io packet forwarding packets/burst=32
  nb forwarding cores=1 - nb forwarding ports=1
  port 0: RX queue number: 1 Tx queue number: 1
    Rx offloads=0x0 Tx offloads=0x0
    RX queue: 0
      RX desc=256 - RX free threshold=0
      TX desc=256 - TX free threshold=32
      TX offloads=0x0 - TX RS bit threshold=32
Press enter to exit

Telling cores to stop...
Waiting for lcores to finish...

  ---------------------- Forward statistics for port 0  ------------------
  RX-packets: 40361          RX-dropped: 0             RX-total: 40361
  TX-packets: 40616          TX-dropped: 0             TX-total: 40616
  ------------------------------------------------------------------------

  +++++++++++++++ Accumulated forward statistics for all ports+++++++++++
  RX-packets: 40361          RX-dropped: 0             RX-total: 40361
  TX-packets: 40616          TX-dropped: 0             TX-total: 40616
  ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

---
 doc/guides/nics/e1000em.rst            | 13 +++++++++++++
 doc/guides/nics/features/e1000.ini     |  1 +
 doc/guides/rel_notes/release_21_11.rst |  4 ++++
 drivers/net/e1000/base/e1000_osdep.h   |  2 ++
 drivers/net/e1000/e1000_ethdev.h       |  1 +
 drivers/net/e1000/meson.build          |  6 ------
 6 files changed, 21 insertions(+), 6 deletions(-)

diff --git a/doc/guides/nics/e1000em.rst b/doc/guides/nics/e1000em.rst
index 041c9a09a3a5..03ae23838bfa 100644
--- a/doc/guides/nics/e1000em.rst
+++ b/doc/guides/nics/e1000em.rst
@@ -1,6 +1,8 @@
 ..  SPDX-License-Identifier: BSD-3-Clause
     Copyright(c) 2010-2014 Intel Corporation.
 
+.. include:: <isonum.txt>
+
 Driver for VM Emulated Devices
 ==============================
 
@@ -153,3 +155,14 @@ The following are known limitations:
 #.  Qemu e1000 only supports one interrupt source, so link and Rx interrupt should be exclusive.
 
 #.  Qemu e1000 does not support interrupt auto-clear, application should disable interrupt immediately when woken up.
+
+Windows Configuration
+---------------------
+
+- Follow the :doc:`guide for Windows <../windows_gsg/run_apps>`
+  to setup the basic DPDK environment.
+
+- Identify the Intel\ |reg| Ethernet adapter.
+
+- To load NetUIO driver, follow the steps mentioned in `dpdk-kmods repository
+  <https://git.dpdk.org/dpdk-kmods/tree/windows/netuio/README.rst>`_.
diff --git a/doc/guides/nics/features/e1000.ini b/doc/guides/nics/features/e1000.ini
index 5af6040e375b..b33f5a86e2e9 100644
--- a/doc/guides/nics/features/e1000.ini
+++ b/doc/guides/nics/features/e1000.ini
@@ -27,6 +27,7 @@ Tx descriptor status = Y
 Basic stats          = Y
 FreeBSD              = Y
 Linux                = Y
+Windows              = Y
 x86-32               = Y
 x86-64               = Y
 
diff --git a/doc/guides/rel_notes/release_21_11.rst b/doc/guides/rel_notes/release_21_11.rst
index efeffe37a0e2..e4a092e562e3 100644
--- a/doc/guides/rel_notes/release_21_11.rst
+++ b/doc/guides/rel_notes/release_21_11.rst
@@ -73,6 +73,10 @@ New Features
   * Implement support for tunnel offload.
   * Updated HWRM API to version 1.10.2.44
 
+* **Updated Intel e1000 emulated driver.**
+
+  * Added Intel e1000 support on Windows.
+
 * **Updated Intel iavf driver.**
 
   * Added Intel iavf support on Windows.
diff --git a/drivers/net/e1000/base/e1000_osdep.h b/drivers/net/e1000/base/e1000_osdep.h
index 94a49f340446..cd90228cef59 100644
--- a/drivers/net/e1000/base/e1000_osdep.h
+++ b/drivers/net/e1000/base/e1000_osdep.h
@@ -34,7 +34,9 @@
 #define DEBUGOUT6(S, args...)   DEBUGOUT(S, ##args)
 #define DEBUGOUT7(S, args...)   DEBUGOUT(S, ##args)
 
+#ifndef UNREFERENCED_PARAMETER
 #define UNREFERENCED_PARAMETER(_p)
+#endif
 #define UNREFERENCED_1PARAMETER(_p)
 #define UNREFERENCED_2PARAMETER(_p, _q)
 #define UNREFERENCED_3PARAMETER(_p, _q, _r)
diff --git a/drivers/net/e1000/e1000_ethdev.h b/drivers/net/e1000/e1000_ethdev.h
index 3b4d9c3ee6f4..613b81f03092 100644
--- a/drivers/net/e1000/e1000_ethdev.h
+++ b/drivers/net/e1000/e1000_ethdev.h
@@ -6,6 +6,7 @@
 #define _E1000_ETHDEV_H_
 
 #include <stdint.h>
+#include <sys/queue.h>
 
 #include <rte_flow.h>
 #include <rte_time.h>
diff --git a/drivers/net/e1000/meson.build b/drivers/net/e1000/meson.build
index c5e48c6bc7fc..296ec25f2ce7 100644
--- a/drivers/net/e1000/meson.build
+++ b/drivers/net/e1000/meson.build
@@ -1,12 +1,6 @@
 # SPDX-License-Identifier: BSD-3-Clause
 # Copyright(c) 2017 Intel Corporation
 
-if is_windows
-    build = false
-    reason = 'not supported on Windows'
-    subdir_done()
-endif
-
 subdir('base')
 objs = [base_objs]
 
-- 
2.33.0.windows.2


^ permalink raw reply	[flat|nested] 21+ messages in thread

* Re: [dpdk-dev] [PATCH v2] net/e1000: build on Windows
  2021-10-08 13:53 ` [dpdk-dev] [PATCH v2] " William Tu
@ 2021-10-08 16:08   ` Wang, Haiyue
  2021-10-08 21:12     ` Kadam, Pallavi
  2021-10-08 20:35   ` Dmitry Kozlyuk
                     ` (2 subsequent siblings)
  3 siblings, 1 reply; 21+ messages in thread
From: Wang, Haiyue @ 2021-10-08 16:08 UTC (permalink / raw)
  To: William Tu, dev, Kadam, Pallavi; +Cc: david.marchand

> -----Original Message-----
> From: William Tu <u9012063@gmail.com>
> Sent: Friday, October 8, 2021 21:54
> To: dev@dpdk.org
> Cc: Kadam, Pallavi <pallavi.kadam@intel.com>; david.marchand@redhat.com; Wang, Haiyue
> <haiyue.wang@intel.com>
> Subject: [PATCH v2] net/e1000: build on Windows
> 
> This patch enables building the e1000 driver for Windows.
> I tested using two Windows VM on top of VMware Fusion,
> creating two e1000 devices with device ID 0x10D3,
> verifying rx/tx works correctly using dpdk-testpmd.exe
> rxonly and txonly mode.
> 
> Signed-off-by: William Tu <u9012063@gmail.com>
> Cc: Haiyue Wang <haiyue.wang@intel.com>
> ---
> A short demo:
> https://youtu.be/UZ9hm2jQa2Y
> 
> Example when running:
> PS C:\dpdk> .\build\app\dpdk-testpmd.exe
> EAL: Detected CPU lcores: 4
> EAL: Detected NUMA nodes: 1
> EAL: Multi-process support is requested, but not available.
> EAL: WARNING: TSC frequency estimated roughly - clock timings may be less accurate.
> EAL: Probe PCI driver: net_e1000_em (8086:10d3) device: 0000:03:00.0 (socket 0)
> EAL: Requested device 0000:1b:00.0 cannot be used
> testpmd: create a new mbuf pool <mb_pool_0>: n=171456, size=2176, socket=0
> testpmd: preferred mempool ops selected: ring_mp_mc
> 
> Warning! port-topology=paired and odd forward ports number, the last port will p
> air with itself.
> Configuring Port 0 (socket 0)
> Port 0: 00:50:56:3A:4D:A6
> Checking link statuses...
> Done
> No commandline core given, start packet forwarding
> allocation mode: native
> Logical Core 1 (socket 0) forwards packets on 1 streams:
>   RX P=0/Q=0 (socket 0) -> TX P=0/Q=0 (socket 0) peer=02:00:00:00:00:00
> 
>   io packet forwarding packets/burst=32
>   nb forwarding cores=1 - nb forwarding ports=1
>   port 0: RX queue number: 1 Tx queue number: 1
>     Rx offloads=0x0 Tx offloads=0x0
>     RX queue: 0
>       RX desc=256 - RX free threshold=0
>       TX desc=256 - TX free threshold=32
>       TX offloads=0x0 - TX RS bit threshold=32
> Press enter to exit
> 
> Telling cores to stop...
> Waiting for lcores to finish...
> 
>   ---------------------- Forward statistics for port 0  ------------------
>   RX-packets: 40361          RX-dropped: 0             RX-total: 40361
>   TX-packets: 40616          TX-dropped: 0             TX-total: 40616
>   ------------------------------------------------------------------------
> 
>   +++++++++++++++ Accumulated forward statistics for all ports+++++++++++
>   RX-packets: 40361          RX-dropped: 0             RX-total: 40361
>   TX-packets: 40616          TX-dropped: 0             TX-total: 40616
>   ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
> 
> ---
>  doc/guides/nics/e1000em.rst            | 13 +++++++++++++
>  doc/guides/nics/features/e1000.ini     |  1 +
>  doc/guides/rel_notes/release_21_11.rst |  4 ++++
>  drivers/net/e1000/base/e1000_osdep.h   |  2 ++
>  drivers/net/e1000/e1000_ethdev.h       |  1 +
>  drivers/net/e1000/meson.build          |  6 ------
>  6 files changed, 21 insertions(+), 6 deletions(-)
> 

LGTM, thanks!

Acked-by: Haiyue Wang <haiyue.wang@intel.com>

Hi @ Pallavi, What do you think about the patch ?
Your one more ACK will be nice. ;-)

> 
> --
> 2.33.0.windows.2


^ permalink raw reply	[flat|nested] 21+ messages in thread

* Re: [dpdk-dev] [PATCH v2] net/e1000: build on Windows
  2021-10-08 13:53 ` [dpdk-dev] [PATCH v2] " William Tu
  2021-10-08 16:08   ` Wang, Haiyue
@ 2021-10-08 20:35   ` Dmitry Kozlyuk
  2021-10-08 21:41     ` William Tu
  2021-10-09 16:37     ` William Tu
  2021-10-09  0:02   ` Kadam, Pallavi
  2021-10-09 16:31   ` [dpdk-dev] [PATCH v3] " William Tu
  3 siblings, 2 replies; 21+ messages in thread
From: Dmitry Kozlyuk @ 2021-10-08 20:35 UTC (permalink / raw)
  To: William Tu; +Cc: dev, pallavi.kadam, david.marchand, Haiyue Wang

2021-10-08 06:53 (UTC-0700), William Tu:
> This patch enables building the e1000 driver for Windows.
> I tested using two Windows VM on top of VMware Fusion,
> creating two e1000 devices with device ID 0x10D3,
> verifying rx/tx works correctly using dpdk-testpmd.exe
> rxonly and txonly mode.
> 
> Signed-off-by: William Tu <u9012063@gmail.com>
> Cc: Haiyue Wang <haiyue.wang@intel.com>

Will there be an accompanying kmods patch to add the device ID to .inf?

With device ID added to netuio, in QEMU with -device e1000e,
Tested-by: Dmitry Kozlyuk <dmitry.kozliuk@gmail.com>

> diff --git a/doc/guides/nics/e1000em.rst b/doc/guides/nics/e1000em.rst
> index 041c9a09a3a5..03ae23838bfa 100644
> --- a/doc/guides/nics/e1000em.rst
> +++ b/doc/guides/nics/e1000em.rst
> @@ -1,6 +1,8 @@
>  ..  SPDX-License-Identifier: BSD-3-Clause
>      Copyright(c) 2010-2014 Intel Corporation.
>  
> +.. include:: <isonum.txt>
> +
>  Driver for VM Emulated Devices
>  ==============================
>  
> @@ -153,3 +155,14 @@ The following are known limitations:
>  #.  Qemu e1000 only supports one interrupt source, so link and Rx interrupt should be exclusive.
>  
>  #.  Qemu e1000 does not support interrupt auto-clear, application should disable interrupt immediately when woken up.
> +
> +Windows Configuration
> +---------------------
> +
> +- Follow the :doc:`guide for Windows <../windows_gsg/run_apps>`
> +  to setup the basic DPDK environment.
> +
> +- Identify the Intel\ |reg| Ethernet adapter.
> +
> +- To load NetUIO driver, follow the steps mentioned in `dpdk-kmods repository
> +  <https://git.dpdk.org/dpdk-kmods/tree/windows/netuio/README.rst>`_.

There is nothing special about setting up this device on Windows.
I think we don't need this part.

^ permalink raw reply	[flat|nested] 21+ messages in thread

* Re: [dpdk-dev] [PATCH v2] net/e1000: build on Windows
  2021-10-08 16:08   ` Wang, Haiyue
@ 2021-10-08 21:12     ` Kadam, Pallavi
  0 siblings, 0 replies; 21+ messages in thread
From: Kadam, Pallavi @ 2021-10-08 21:12 UTC (permalink / raw)
  To: Wang, Haiyue, William Tu, dev; +Cc: david.marchand


On 10/8/2021 9:08 AM, Wang, Haiyue wrote:
>> -----Original Message-----
>> From: William Tu <u9012063@gmail.com>
>> Sent: Friday, October 8, 2021 21:54
>> To: dev@dpdk.org
>> Cc: Kadam, Pallavi <pallavi.kadam@intel.com>; david.marchand@redhat.com; Wang, Haiyue
>> <haiyue.wang@intel.com>
>> Subject: [PATCH v2] net/e1000: build on Windows
>>
>> This patch enables building the e1000 driver for Windows.
>> I tested using two Windows VM on top of VMware Fusion,
>> creating two e1000 devices with device ID 0x10D3,
>> verifying rx/tx works correctly using dpdk-testpmd.exe
>> rxonly and txonly mode.
>>
>> Signed-off-by: William Tu <u9012063@gmail.com>
>> Cc: Haiyue Wang <haiyue.wang@intel.com>
>> ---
>> A short demo:
>> https://youtu.be/UZ9hm2jQa2Y
>>
>> Example when running:
>> PS C:\dpdk> .\build\app\dpdk-testpmd.exe
>> EAL: Detected CPU lcores: 4
>> EAL: Detected NUMA nodes: 1
>> EAL: Multi-process support is requested, but not available.
>> EAL: WARNING: TSC frequency estimated roughly - clock timings may be less accurate.
>> EAL: Probe PCI driver: net_e1000_em (8086:10d3) device: 0000:03:00.0 (socket 0)
>> EAL: Requested device 0000:1b:00.0 cannot be used
>> testpmd: create a new mbuf pool <mb_pool_0>: n=171456, size=2176, socket=0
>> testpmd: preferred mempool ops selected: ring_mp_mc
>>
>> Warning! port-topology=paired and odd forward ports number, the last port will p
>> air with itself.
>> Configuring Port 0 (socket 0)
>> Port 0: 00:50:56:3A:4D:A6
>> Checking link statuses...
>> Done
>> No commandline core given, start packet forwarding
>> allocation mode: native
>> Logical Core 1 (socket 0) forwards packets on 1 streams:
>>    RX P=0/Q=0 (socket 0) -> TX P=0/Q=0 (socket 0) peer=02:00:00:00:00:00
>>
>>    io packet forwarding packets/burst=32
>>    nb forwarding cores=1 - nb forwarding ports=1
>>    port 0: RX queue number: 1 Tx queue number: 1
>>      Rx offloads=0x0 Tx offloads=0x0
>>      RX queue: 0
>>        RX desc=256 - RX free threshold=0
>>        TX desc=256 - TX free threshold=32
>>        TX offloads=0x0 - TX RS bit threshold=32
>> Press enter to exit
>>
>> Telling cores to stop...
>> Waiting for lcores to finish...
>>
>>    ---------------------- Forward statistics for port 0  ------------------
>>    RX-packets: 40361          RX-dropped: 0             RX-total: 40361
>>    TX-packets: 40616          TX-dropped: 0             TX-total: 40616
>>    ------------------------------------------------------------------------
>>
>>    +++++++++++++++ Accumulated forward statistics for all ports+++++++++++
>>    RX-packets: 40361          RX-dropped: 0             RX-total: 40361
>>    TX-packets: 40616          TX-dropped: 0             TX-total: 40616
>>    ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
>>
>> ---
>>   doc/guides/nics/e1000em.rst            | 13 +++++++++++++
>>   doc/guides/nics/features/e1000.ini     |  1 +
>>   doc/guides/rel_notes/release_21_11.rst |  4 ++++
>>   drivers/net/e1000/base/e1000_osdep.h   |  2 ++
>>   drivers/net/e1000/e1000_ethdev.h       |  1 +
>>   drivers/net/e1000/meson.build          |  6 ------
>>   6 files changed, 21 insertions(+), 6 deletions(-)
>>
> LGTM, thanks!
>
> Acked-by: Haiyue Wang <haiyue.wang@intel.com>
>
> Hi @ Pallavi, What do you think about the patch ?
> Your one more ACK will be nice. ;-)

Yes, code looks good to me. I actually don't have the exact same 1GbE 
device William is using.

We are trying to figure out some issues with the current 1GbE device 
that is installed.

So, will acknowledge as soon as we test it on Windows. Thanks,

>
>> --
>> 2.33.0.windows.2

^ permalink raw reply	[flat|nested] 21+ messages in thread

* Re: [dpdk-dev] [PATCH v2] net/e1000: build on Windows
  2021-10-08 20:35   ` Dmitry Kozlyuk
@ 2021-10-08 21:41     ` William Tu
  2021-10-09 16:37     ` William Tu
  1 sibling, 0 replies; 21+ messages in thread
From: William Tu @ 2021-10-08 21:41 UTC (permalink / raw)
  To: Dmitry Kozlyuk; +Cc: dpdk-dev, Pallavi Kadam, David Marchand, Haiyue Wang

On Fri, Oct 8, 2021 at 1:35 PM Dmitry Kozlyuk <dmitry.kozliuk@gmail.com> wrote:
>
> 2021-10-08 06:53 (UTC-0700), William Tu:
> > This patch enables building the e1000 driver for Windows.
> > I tested using two Windows VM on top of VMware Fusion,
> > creating two e1000 devices with device ID 0x10D3,
> > verifying rx/tx works correctly using dpdk-testpmd.exe
> > rxonly and txonly mode.
> >
> > Signed-off-by: William Tu <u9012063@gmail.com>
> > Cc: Haiyue Wang <haiyue.wang@intel.com>
>
> Will there be an accompanying kmods patch to add the device ID to .inf?
>
> With device ID added to netuio, in QEMU with -device e1000e,
> Tested-by: Dmitry Kozlyuk <dmitry.kozliuk@gmail.com>
>
> > diff --git a/doc/guides/nics/e1000em.rst b/doc/guides/nics/e1000em.rst
> > index 041c9a09a3a5..03ae23838bfa 100644
> > --- a/doc/guides/nics/e1000em.rst
> > +++ b/doc/guides/nics/e1000em.rst
> > @@ -1,6 +1,8 @@
> >  ..  SPDX-License-Identifier: BSD-3-Clause
> >      Copyright(c) 2010-2014 Intel Corporation.
> >
> > +.. include:: <isonum.txt>
> > +
> >  Driver for VM Emulated Devices
> >  ==============================
> >
> > @@ -153,3 +155,14 @@ The following are known limitations:
> >  #.  Qemu e1000 only supports one interrupt source, so link and Rx interrupt should be exclusive.
> >
> >  #.  Qemu e1000 does not support interrupt auto-clear, application should disable interrupt immediately when woken up.
> > +
> > +Windows Configuration
> > +---------------------
> > +
> > +- Follow the :doc:`guide for Windows <../windows_gsg/run_apps>`
> > +  to setup the basic DPDK environment.
> > +
> > +- Identify the Intel\ |reg| Ethernet adapter.
> > +
> > +- To load NetUIO driver, follow the steps mentioned in `dpdk-kmods repository
> > +  <https://git.dpdk.org/dpdk-kmods/tree/windows/netuio/README.rst>`_.
>
> There is nothing special about setting up this device on Windows.
> I think we don't need this part.

Thank you. I will add the Device ID to netuio.inf file
and remove the above part.
Will wait for Pallavi's test and resend the patch.

Thanks
William

^ permalink raw reply	[flat|nested] 21+ messages in thread

* Re: [dpdk-dev] [PATCH v2] net/e1000: build on Windows
  2021-10-08 13:53 ` [dpdk-dev] [PATCH v2] " William Tu
  2021-10-08 16:08   ` Wang, Haiyue
  2021-10-08 20:35   ` Dmitry Kozlyuk
@ 2021-10-09  0:02   ` Kadam, Pallavi
  2021-10-09  0:14     ` William Tu
  2021-10-09 16:31   ` [dpdk-dev] [PATCH v3] " William Tu
  3 siblings, 1 reply; 21+ messages in thread
From: Kadam, Pallavi @ 2021-10-09  0:02 UTC (permalink / raw)
  To: William Tu, dev; +Cc: david.marchand, Haiyue Wang


On 10/8/2021 6:53 AM, William Tu wrote:
> This patch enables building the e1000 driver for Windows.
> I tested using two Windows VM on top of VMware Fusion,
> creating two e1000 devices with device ID 0x10D3,
> verifying rx/tx works correctly using dpdk-testpmd.exe
> rxonly and txonly mode.
>
> Signed-off-by: William Tu <u9012063@gmail.com>
> Cc: Haiyue Wang <haiyue.wang@intel.com>
> ---

Tested-by: Pallavi Kadam <pallavi.kadam@intel.com>

Acked-by: Pallavi Kadam <pallavi.kadam@intel.com>


^ permalink raw reply	[flat|nested] 21+ messages in thread

* Re: [dpdk-dev] [PATCH v2] net/e1000: build on Windows
  2021-10-09  0:02   ` Kadam, Pallavi
@ 2021-10-09  0:14     ` William Tu
  2021-10-09 18:40       ` Kadam, Pallavi
  0 siblings, 1 reply; 21+ messages in thread
From: William Tu @ 2021-10-09  0:14 UTC (permalink / raw)
  To: Kadam, Pallavi; +Cc: dpdk-dev, David Marchand, Haiyue Wang

On Fri, Oct 8, 2021 at 5:02 PM Kadam, Pallavi <pallavi.kadam@intel.com> wrote:
>
>
> On 10/8/2021 6:53 AM, William Tu wrote:
> > This patch enables building the e1000 driver for Windows.
> > I tested using two Windows VM on top of VMware Fusion,
> > creating two e1000 devices with device ID 0x10D3,
> > verifying rx/tx works correctly using dpdk-testpmd.exe
> > rxonly and txonly mode.
> >
> > Signed-off-by: William Tu <u9012063@gmail.com>
> > Cc: Haiyue Wang <haiyue.wang@intel.com>
> > ---
>
> Tested-by: Pallavi Kadam <pallavi.kadam@intel.com>
>
> Acked-by: Pallavi Kadam <pallavi.kadam@intel.com>
Thanks!
I'm curious, what device ID are you testing so I can also add it to
the netuio.inf.
William

^ permalink raw reply	[flat|nested] 21+ messages in thread

* [dpdk-dev] [PATCH v3] net/e1000: build on Windows
  2021-10-08 13:53 ` [dpdk-dev] [PATCH v2] " William Tu
                     ` (2 preceding siblings ...)
  2021-10-09  0:02   ` Kadam, Pallavi
@ 2021-10-09 16:31   ` William Tu
  2021-10-09 17:28     ` Dmitry Kozlyuk
                       ` (2 more replies)
  3 siblings, 3 replies; 21+ messages in thread
From: William Tu @ 2021-10-09 16:31 UTC (permalink / raw)
  To: dev; +Cc: Haiyue Wang, Pallavi Kadam, Dmitry Kozlyuk

This patch enables building the e1000 driver for Windows.
I tested using two Windows VM on top of VMware Fusion,
creating two e1000 devices with device ID 0x10D3 (8274L),
verifying rx/tx works correctly using dpdk-testpmd.exe
rxonly and txonly mode.

Signed-off-by: William Tu <u9012063@gmail.com>
Acked-by: Haiyue Wang <haiyue.wang@intel.com>
Acked-by: Pallavi Kadam <pallavi.kadam@intel.com>
Tested-by: Dmitry Kozlyuk <dmitry.kozliuk@gmail.com>
Tested-by: Pallavi Kadam <pallavi.kadam@intel.com>
---
v3:
* Add acked and tested by tags
* @Dmitry: I think it's better keep the doc for
  people to reference NetUIO setup.
* I will send corresponding netuio device id patch
  to dpdk-kmods

A short demo:
https://youtu.be/UZ9hm2jQa2Y
Example when running:
PS C:\dpdk> .\build\app\dpdk-testpmd.exe
EAL: Detected CPU lcores: 4
EAL: Detected NUMA nodes: 1
EAL: Multi-process support is requested, but not available.
EAL: WARNING: TSC frequency estimated roughly - clock timings may be less accurate.
EAL: Probe PCI driver: net_e1000_em (8086:10d3) device: 0000:03:00.0 (socket 0)
EAL: Requested device 0000:1b:00.0 cannot be used
testpmd: create a new mbuf pool <mb_pool_0>: n=171456, size=2176, socket=0
testpmd: preferred mempool ops selected: ring_mp_mc

Warning! port-topology=paired and odd forward ports number, the last port will p
air with itself.
Configuring Port 0 (socket 0)
Port 0: 00:50:56:3A:4D:A6
Checking link statuses...
Done
No commandline core given, start packet forwarding
allocation mode: native
Logical Core 1 (socket 0) forwards packets on 1 streams:
  RX P=0/Q=0 (socket 0) -> TX P=0/Q=0 (socket 0) peer=02:00:00:00:00:00

  io packet forwarding packets/burst=32
  nb forwarding cores=1 - nb forwarding ports=1
  port 0: RX queue number: 1 Tx queue number: 1
    Rx offloads=0x0 Tx offloads=0x0
    RX queue: 0
      RX desc=256 - RX free threshold=0
      TX desc=256 - TX free threshold=32
      TX offloads=0x0 - TX RS bit threshold=32
Press enter to exit

Telling cores to stop...
Waiting for lcores to finish...

  ---------------------- Forward statistics for port 0  ------------------
  RX-packets: 40361          RX-dropped: 0             RX-total: 40361
  TX-packets: 40616          TX-dropped: 0             TX-total: 40616
  ------------------------------------------------------------------------

  +++++++++++++++ Accumulated forward statistics for all ports+++++++++++
  RX-packets: 40361          RX-dropped: 0             RX-total: 40361
  TX-packets: 40616          TX-dropped: 0             TX-total: 40616
  ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

--
---
 doc/guides/nics/e1000em.rst            | 13 +++++++++++++
 doc/guides/nics/features/e1000.ini     |  1 +
 doc/guides/rel_notes/release_21_11.rst |  4 ++++
 drivers/net/e1000/base/e1000_osdep.h   |  2 ++
 drivers/net/e1000/e1000_ethdev.h       |  1 +
 drivers/net/e1000/meson.build          |  6 ------
 6 files changed, 21 insertions(+), 6 deletions(-)

diff --git a/doc/guides/nics/e1000em.rst b/doc/guides/nics/e1000em.rst
index 041c9a09a3a5..03ae23838bfa 100644
--- a/doc/guides/nics/e1000em.rst
+++ b/doc/guides/nics/e1000em.rst
@@ -1,6 +1,8 @@
 ..  SPDX-License-Identifier: BSD-3-Clause
     Copyright(c) 2010-2014 Intel Corporation.
 
+.. include:: <isonum.txt>
+
 Driver for VM Emulated Devices
 ==============================
 
@@ -153,3 +155,14 @@ The following are known limitations:
 #.  Qemu e1000 only supports one interrupt source, so link and Rx interrupt should be exclusive.
 
 #.  Qemu e1000 does not support interrupt auto-clear, application should disable interrupt immediately when woken up.
+
+Windows Configuration
+---------------------
+
+- Follow the :doc:`guide for Windows <../windows_gsg/run_apps>`
+  to setup the basic DPDK environment.
+
+- Identify the Intel\ |reg| Ethernet adapter.
+
+- To load NetUIO driver, follow the steps mentioned in `dpdk-kmods repository
+  <https://git.dpdk.org/dpdk-kmods/tree/windows/netuio/README.rst>`_.
diff --git a/doc/guides/nics/features/e1000.ini b/doc/guides/nics/features/e1000.ini
index 5af6040e375b..b33f5a86e2e9 100644
--- a/doc/guides/nics/features/e1000.ini
+++ b/doc/guides/nics/features/e1000.ini
@@ -27,6 +27,7 @@ Tx descriptor status = Y
 Basic stats          = Y
 FreeBSD              = Y
 Linux                = Y
+Windows              = Y
 x86-32               = Y
 x86-64               = Y
 
diff --git a/doc/guides/rel_notes/release_21_11.rst b/doc/guides/rel_notes/release_21_11.rst
index efeffe37a0e2..e4a092e562e3 100644
--- a/doc/guides/rel_notes/release_21_11.rst
+++ b/doc/guides/rel_notes/release_21_11.rst
@@ -73,6 +73,10 @@ New Features
   * Implement support for tunnel offload.
   * Updated HWRM API to version 1.10.2.44
 
+* **Updated Intel e1000 emulated driver.**
+
+  * Added Intel e1000 support on Windows.
+
 * **Updated Intel iavf driver.**
 
   * Added Intel iavf support on Windows.
diff --git a/drivers/net/e1000/base/e1000_osdep.h b/drivers/net/e1000/base/e1000_osdep.h
index 94a49f340446..cd90228cef59 100644
--- a/drivers/net/e1000/base/e1000_osdep.h
+++ b/drivers/net/e1000/base/e1000_osdep.h
@@ -34,7 +34,9 @@
 #define DEBUGOUT6(S, args...)   DEBUGOUT(S, ##args)
 #define DEBUGOUT7(S, args...)   DEBUGOUT(S, ##args)
 
+#ifndef UNREFERENCED_PARAMETER
 #define UNREFERENCED_PARAMETER(_p)
+#endif
 #define UNREFERENCED_1PARAMETER(_p)
 #define UNREFERENCED_2PARAMETER(_p, _q)
 #define UNREFERENCED_3PARAMETER(_p, _q, _r)
diff --git a/drivers/net/e1000/e1000_ethdev.h b/drivers/net/e1000/e1000_ethdev.h
index 3b4d9c3ee6f4..613b81f03092 100644
--- a/drivers/net/e1000/e1000_ethdev.h
+++ b/drivers/net/e1000/e1000_ethdev.h
@@ -6,6 +6,7 @@
 #define _E1000_ETHDEV_H_
 
 #include <stdint.h>
+#include <sys/queue.h>
 
 #include <rte_flow.h>
 #include <rte_time.h>
diff --git a/drivers/net/e1000/meson.build b/drivers/net/e1000/meson.build
index c5e48c6bc7fc..296ec25f2ce7 100644
--- a/drivers/net/e1000/meson.build
+++ b/drivers/net/e1000/meson.build
@@ -1,12 +1,6 @@
 # SPDX-License-Identifier: BSD-3-Clause
 # Copyright(c) 2017 Intel Corporation
 
-if is_windows
-    build = false
-    reason = 'not supported on Windows'
-    subdir_done()
-endif
-
 subdir('base')
 objs = [base_objs]
 
-- 
2.33.0.windows.2


^ permalink raw reply	[flat|nested] 21+ messages in thread

* Re: [dpdk-dev] [PATCH v2] net/e1000: build on Windows
  2021-10-08 20:35   ` Dmitry Kozlyuk
  2021-10-08 21:41     ` William Tu
@ 2021-10-09 16:37     ` William Tu
  1 sibling, 0 replies; 21+ messages in thread
From: William Tu @ 2021-10-09 16:37 UTC (permalink / raw)
  To: Dmitry Kozlyuk; +Cc: dpdk-dev, Pallavi Kadam, David Marchand, Haiyue Wang

> > +Windows Configuration
> > +---------------------
> > +
> > +- Follow the :doc:`guide for Windows <../windows_gsg/run_apps>`
> > +  to setup the basic DPDK environment.
> > +
> > +- Identify the Intel\ |reg| Ethernet adapter.
> > +
> > +- To load NetUIO driver, follow the steps mentioned in `dpdk-kmods repository
> > +  <https://git.dpdk.org/dpdk-kmods/tree/windows/netuio/README.rst>`_.
>
> There is nothing special about setting up this device on Windows.
> I think we don't need this part.

Hi Dmitry,

I keep this part in my v3 patch.
However, I think we should move or copy the netuio configuration
guide to DPDK repo
https://doc.dpdk.org/guides/windows_gsg/run_apps.html
maybe
4.2: Load the virt2phys driver
4.3: Load the NetUIO driver
4.4: Run helloworld example

Thanks
William

^ permalink raw reply	[flat|nested] 21+ messages in thread

* Re: [dpdk-dev] [PATCH v3] net/e1000: build on Windows
  2021-10-09 16:31   ` [dpdk-dev] [PATCH v3] " William Tu
@ 2021-10-09 17:28     ` Dmitry Kozlyuk
  2021-10-10 10:56       ` Wang, Haiyue
  2021-10-19 19:05     ` William Tu
  2021-10-20  3:47     ` [dpdk-dev] [PATCH v4] " William Tu
  2 siblings, 1 reply; 21+ messages in thread
From: Dmitry Kozlyuk @ 2021-10-09 17:28 UTC (permalink / raw)
  To: William Tu; +Cc: dev, Haiyue Wang, Pallavi Kadam

2021-10-09 09:31 (UTC-0700), William Tu:
> [...]
> * @Dmitry: I think it's better keep the doc for
>   people to reference NetUIO setup.

I won't insist, especially since Intel is OK with this.
I've sent a patch to put the link in Windows GSG
so that we won't need to repeat it for each PMD:
http://inbox.dpdk.org/dev/20211008211154.349793-1-dmitry.kozliuk@gmail.com/T/#u


^ permalink raw reply	[flat|nested] 21+ messages in thread

* Re: [dpdk-dev] [PATCH v2] net/e1000: build on Windows
  2021-10-09  0:14     ` William Tu
@ 2021-10-09 18:40       ` Kadam, Pallavi
  0 siblings, 0 replies; 21+ messages in thread
From: Kadam, Pallavi @ 2021-10-09 18:40 UTC (permalink / raw)
  To: William Tu; +Cc: dpdk-dev, David Marchand, Haiyue Wang


On 10/8/2021 5:14 PM, William Tu wrote:
> On Fri, Oct 8, 2021 at 5:02 PM Kadam, Pallavi <pallavi.kadam@intel.com> wrote:
>>
>> On 10/8/2021 6:53 AM, William Tu wrote:
>>> This patch enables building the e1000 driver for Windows.
>>> I tested using two Windows VM on top of VMware Fusion,
>>> creating two e1000 devices with device ID 0x10D3,
>>> verifying rx/tx works correctly using dpdk-testpmd.exe
>>> rxonly and txonly mode.
>>>
>>> Signed-off-by: William Tu <u9012063@gmail.com>
>>> Cc: Haiyue Wang <haiyue.wang@intel.com>
>>> ---
>> Tested-by: Pallavi Kadam <pallavi.kadam@intel.com>
>>
>> Acked-by: Pallavi Kadam <pallavi.kadam@intel.com>
> Thanks!
> I'm curious, what device ID are you testing so I can also add it to
> the netuio.inf.
> William

The Device ID is: 1521

Used the following string:

Intel.E1521NC.Description = "Intel(R) I350 Gigabit Network Connection"

Thanks,

Pallavi



^ permalink raw reply	[flat|nested] 21+ messages in thread

* Re: [dpdk-dev] [PATCH v3] net/e1000: build on Windows
  2021-10-09 17:28     ` Dmitry Kozlyuk
@ 2021-10-10 10:56       ` Wang, Haiyue
  0 siblings, 0 replies; 21+ messages in thread
From: Wang, Haiyue @ 2021-10-10 10:56 UTC (permalink / raw)
  To: Dmitry Kozlyuk, William Tu; +Cc: dev, Kadam, Pallavi

> -----Original Message-----
> From: Dmitry Kozlyuk <dmitry.kozliuk@gmail.com>
> Sent: Sunday, October 10, 2021 01:28
> To: William Tu <u9012063@gmail.com>
> Cc: dev@dpdk.org; Wang, Haiyue <haiyue.wang@intel.com>; Kadam, Pallavi <pallavi.kadam@intel.com>
> Subject: Re: [PATCH v3] net/e1000: build on Windows
> 
> 2021-10-09 09:31 (UTC-0700), William Tu:
> > [...]
> > * @Dmitry: I think it's better keep the doc for
> >   people to reference NetUIO setup.
> 
> I won't insist, especially since Intel is OK with this.
> I've sent a patch to put the link in Windows GSG
> so that we won't need to repeat it for each PMD:
> http://inbox.dpdk.org/dev/20211008211154.349793-1-dmitry.kozliuk@gmail.com/T/#u

+1, This is better.

For PMD itself, it just need to set 'Windows = Y' in *ini if it supports Windows.

^ permalink raw reply	[flat|nested] 21+ messages in thread

* Re: [dpdk-dev] [PATCH v3] net/e1000: build on Windows
  2021-10-09 16:31   ` [dpdk-dev] [PATCH v3] " William Tu
  2021-10-09 17:28     ` Dmitry Kozlyuk
@ 2021-10-19 19:05     ` William Tu
  2021-10-19 19:12       ` Thomas Monjalon
  2021-10-20  3:47     ` [dpdk-dev] [PATCH v4] " William Tu
  2 siblings, 1 reply; 21+ messages in thread
From: William Tu @ 2021-10-19 19:05 UTC (permalink / raw)
  To: dpdk-dev, Thomas Monjalon; +Cc: Haiyue Wang, Pallavi Kadam, Dmitry Kozlyuk

Hi Thomas,
Can we apply this patch?
Thanks
William

On Sat, Oct 9, 2021 at 9:32 AM William Tu <u9012063@gmail.com> wrote:
>
> This patch enables building the e1000 driver for Windows.
> I tested using two Windows VM on top of VMware Fusion,
> creating two e1000 devices with device ID 0x10D3 (8274L),
> verifying rx/tx works correctly using dpdk-testpmd.exe
> rxonly and txonly mode.
>
> Signed-off-by: William Tu <u9012063@gmail.com>
> Acked-by: Haiyue Wang <haiyue.wang@intel.com>
> Acked-by: Pallavi Kadam <pallavi.kadam@intel.com>
> Tested-by: Dmitry Kozlyuk <dmitry.kozliuk@gmail.com>
> Tested-by: Pallavi Kadam <pallavi.kadam@intel.com>
> ---
> v3:
> * Add acked and tested by tags
> * @Dmitry: I think it's better keep the doc for
>   people to reference NetUIO setup.
> * I will send corresponding netuio device id patch
>   to dpdk-kmods
>
> A short demo:
> https://youtu.be/UZ9hm2jQa2Y
> Example when running:
> PS C:\dpdk> .\build\app\dpdk-testpmd.exe
> EAL: Detected CPU lcores: 4
> EAL: Detected NUMA nodes: 1
> EAL: Multi-process support is requested, but not available.
> EAL: WARNING: TSC frequency estimated roughly - clock timings may be less accurate.
> EAL: Probe PCI driver: net_e1000_em (8086:10d3) device: 0000:03:00.0 (socket 0)
> EAL: Requested device 0000:1b:00.0 cannot be used
> testpmd: create a new mbuf pool <mb_pool_0>: n=171456, size=2176, socket=0
> testpmd: preferred mempool ops selected: ring_mp_mc
>
> Warning! port-topology=paired and odd forward ports number, the last port will p
> air with itself.
> Configuring Port 0 (socket 0)
> Port 0: 00:50:56:3A:4D:A6
> Checking link statuses...
> Done
> No commandline core given, start packet forwarding
> allocation mode: native
> Logical Core 1 (socket 0) forwards packets on 1 streams:
>   RX P=0/Q=0 (socket 0) -> TX P=0/Q=0 (socket 0) peer=02:00:00:00:00:00
>
>   io packet forwarding packets/burst=32
>   nb forwarding cores=1 - nb forwarding ports=1
>   port 0: RX queue number: 1 Tx queue number: 1
>     Rx offloads=0x0 Tx offloads=0x0
>     RX queue: 0
>       RX desc=256 - RX free threshold=0
>       TX desc=256 - TX free threshold=32
>       TX offloads=0x0 - TX RS bit threshold=32
> Press enter to exit
>
> Telling cores to stop...
> Waiting for lcores to finish...
>
>   ---------------------- Forward statistics for port 0  ------------------
>   RX-packets: 40361          RX-dropped: 0             RX-total: 40361
>   TX-packets: 40616          TX-dropped: 0             TX-total: 40616
>   ------------------------------------------------------------------------
>
>   +++++++++++++++ Accumulated forward statistics for all ports+++++++++++
>   RX-packets: 40361          RX-dropped: 0             RX-total: 40361
>   TX-packets: 40616          TX-dropped: 0             TX-total: 40616
>   ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
>
> --
> ---
>  doc/guides/nics/e1000em.rst            | 13 +++++++++++++
>  doc/guides/nics/features/e1000.ini     |  1 +
>  doc/guides/rel_notes/release_21_11.rst |  4 ++++
>  drivers/net/e1000/base/e1000_osdep.h   |  2 ++
>  drivers/net/e1000/e1000_ethdev.h       |  1 +
>  drivers/net/e1000/meson.build          |  6 ------
>  6 files changed, 21 insertions(+), 6 deletions(-)
>
> diff --git a/doc/guides/nics/e1000em.rst b/doc/guides/nics/e1000em.rst
> index 041c9a09a3a5..03ae23838bfa 100644
> --- a/doc/guides/nics/e1000em.rst
> +++ b/doc/guides/nics/e1000em.rst
> @@ -1,6 +1,8 @@
>  ..  SPDX-License-Identifier: BSD-3-Clause
>      Copyright(c) 2010-2014 Intel Corporation.
>
> +.. include:: <isonum.txt>
> +
>  Driver for VM Emulated Devices
>  ==============================
>
> @@ -153,3 +155,14 @@ The following are known limitations:
>  #.  Qemu e1000 only supports one interrupt source, so link and Rx interrupt should be exclusive.
>
>  #.  Qemu e1000 does not support interrupt auto-clear, application should disable interrupt immediately when woken up.
> +
> +Windows Configuration
> +---------------------
> +
> +- Follow the :doc:`guide for Windows <../windows_gsg/run_apps>`
> +  to setup the basic DPDK environment.
> +
> +- Identify the Intel\ |reg| Ethernet adapter.
> +
> +- To load NetUIO driver, follow the steps mentioned in `dpdk-kmods repository
> +  <https://git.dpdk.org/dpdk-kmods/tree/windows/netuio/README.rst>`_.
> diff --git a/doc/guides/nics/features/e1000.ini b/doc/guides/nics/features/e1000.ini
> index 5af6040e375b..b33f5a86e2e9 100644
> --- a/doc/guides/nics/features/e1000.ini
> +++ b/doc/guides/nics/features/e1000.ini
> @@ -27,6 +27,7 @@ Tx descriptor status = Y
>  Basic stats          = Y
>  FreeBSD              = Y
>  Linux                = Y
> +Windows              = Y
>  x86-32               = Y
>  x86-64               = Y
>
> diff --git a/doc/guides/rel_notes/release_21_11.rst b/doc/guides/rel_notes/release_21_11.rst
> index efeffe37a0e2..e4a092e562e3 100644
> --- a/doc/guides/rel_notes/release_21_11.rst
> +++ b/doc/guides/rel_notes/release_21_11.rst
> @@ -73,6 +73,10 @@ New Features
>    * Implement support for tunnel offload.
>    * Updated HWRM API to version 1.10.2.44
>
> +* **Updated Intel e1000 emulated driver.**
> +
> +  * Added Intel e1000 support on Windows.
> +
>  * **Updated Intel iavf driver.**
>
>    * Added Intel iavf support on Windows.
> diff --git a/drivers/net/e1000/base/e1000_osdep.h b/drivers/net/e1000/base/e1000_osdep.h
> index 94a49f340446..cd90228cef59 100644
> --- a/drivers/net/e1000/base/e1000_osdep.h
> +++ b/drivers/net/e1000/base/e1000_osdep.h
> @@ -34,7 +34,9 @@
>  #define DEBUGOUT6(S, args...)   DEBUGOUT(S, ##args)
>  #define DEBUGOUT7(S, args...)   DEBUGOUT(S, ##args)
>
> +#ifndef UNREFERENCED_PARAMETER
>  #define UNREFERENCED_PARAMETER(_p)
> +#endif
>  #define UNREFERENCED_1PARAMETER(_p)
>  #define UNREFERENCED_2PARAMETER(_p, _q)
>  #define UNREFERENCED_3PARAMETER(_p, _q, _r)
> diff --git a/drivers/net/e1000/e1000_ethdev.h b/drivers/net/e1000/e1000_ethdev.h
> index 3b4d9c3ee6f4..613b81f03092 100644
> --- a/drivers/net/e1000/e1000_ethdev.h
> +++ b/drivers/net/e1000/e1000_ethdev.h
> @@ -6,6 +6,7 @@
>  #define _E1000_ETHDEV_H_
>
>  #include <stdint.h>
> +#include <sys/queue.h>
>
>  #include <rte_flow.h>
>  #include <rte_time.h>
> diff --git a/drivers/net/e1000/meson.build b/drivers/net/e1000/meson.build
> index c5e48c6bc7fc..296ec25f2ce7 100644
> --- a/drivers/net/e1000/meson.build
> +++ b/drivers/net/e1000/meson.build
> @@ -1,12 +1,6 @@
>  # SPDX-License-Identifier: BSD-3-Clause
>  # Copyright(c) 2017 Intel Corporation
>
> -if is_windows
> -    build = false
> -    reason = 'not supported on Windows'
> -    subdir_done()
> -endif
> -
>  subdir('base')
>  objs = [base_objs]
>
> --
> 2.33.0.windows.2
>

^ permalink raw reply	[flat|nested] 21+ messages in thread

* Re: [dpdk-dev] [PATCH v3] net/e1000: build on Windows
  2021-10-19 19:05     ` William Tu
@ 2021-10-19 19:12       ` Thomas Monjalon
  0 siblings, 0 replies; 21+ messages in thread
From: Thomas Monjalon @ 2021-10-19 19:12 UTC (permalink / raw)
  To: William Tu
  Cc: dpdk-dev, Haiyue Wang, Pallavi Kadam, Dmitry Kozlyuk, ferruh.yigit

19/10/2021 21:05, William Tu:
> Hi Thomas,
> Can we apply this patch?

The net driver patches are managed in next-net by Ferruh.


> On Sat, Oct 9, 2021 at 9:32 AM William Tu <u9012063@gmail.com> wrote:
> > This patch enables building the e1000 driver for Windows.
> > I tested using two Windows VM on top of VMware Fusion,
> > creating two e1000 devices with device ID 0x10D3 (8274L),
> > verifying rx/tx works correctly using dpdk-testpmd.exe
> > rxonly and txonly mode.
> >
> > Signed-off-by: William Tu <u9012063@gmail.com>
> > Acked-by: Haiyue Wang <haiyue.wang@intel.com>
> > Acked-by: Pallavi Kadam <pallavi.kadam@intel.com>
> > Tested-by: Dmitry Kozlyuk <dmitry.kozliuk@gmail.com>
> > Tested-by: Pallavi Kadam <pallavi.kadam@intel.com>





^ permalink raw reply	[flat|nested] 21+ messages in thread

* [dpdk-dev] [PATCH v4] net/e1000: build on Windows
  2021-10-09 16:31   ` [dpdk-dev] [PATCH v3] " William Tu
  2021-10-09 17:28     ` Dmitry Kozlyuk
  2021-10-19 19:05     ` William Tu
@ 2021-10-20  3:47     ` William Tu
  2021-10-21  2:56       ` Zhang, Qi Z
  2 siblings, 1 reply; 21+ messages in thread
From: William Tu @ 2021-10-20  3:47 UTC (permalink / raw)
  To: dev; +Cc: Haiyue Wang, Pallavi Kadam, Dmitry Kozlyuk

This patch enables building the e1000 driver for Windows.
I tested using two Windows VM on top of VMware Fusion,
creating two e1000 devices with device ID 0x10D3 (8274L),
verifying rx/tx works correctly using dpdk-testpmd.exe
rxonly and txonly mode.

Signed-off-by: William Tu <u9012063@gmail.com>
Acked-by: Haiyue Wang <haiyue.wang@intel.com>
Acked-by: Pallavi Kadam <pallavi.kadam@intel.com>
Tested-by: Dmitry Kozlyuk <dmitry.kozliuk@gmail.com>
Tested-by: Pallavi Kadam <pallavi.kadam@intel.com>
---
v4:
* remove the documentation about Windows setup.
  this is already mention in doc/windows_gsg
v3:
* Add acked and tested by tags
* @Dmitry: I think it's better keep the doc for
  people to reference NetUIO setup.
* I will send corresponding netuio device id patch
  to dpdk-kmods
* A short demo:
  https://youtu.be/UZ9hm2jQa2Y

---
 doc/guides/nics/features/e1000.ini     | 1 +
 doc/guides/rel_notes/release_21_11.rst | 4 ++++
 drivers/net/e1000/base/e1000_osdep.h   | 2 ++
 drivers/net/e1000/e1000_ethdev.h       | 1 +
 drivers/net/e1000/meson.build          | 6 ------
 5 files changed, 8 insertions(+), 6 deletions(-)

diff --git a/doc/guides/nics/features/e1000.ini b/doc/guides/nics/features/e1000.ini
index 5af6040e375b..b33f5a86e2e9 100644
--- a/doc/guides/nics/features/e1000.ini
+++ b/doc/guides/nics/features/e1000.ini
@@ -27,6 +27,7 @@ Tx descriptor status = Y
 Basic stats          = Y
 FreeBSD              = Y
 Linux                = Y
+Windows              = Y
 x86-32               = Y
 x86-64               = Y
 
diff --git a/doc/guides/rel_notes/release_21_11.rst b/doc/guides/rel_notes/release_21_11.rst
index 3362c52a738c..876b5f1886bb 100644
--- a/doc/guides/rel_notes/release_21_11.rst
+++ b/doc/guides/rel_notes/release_21_11.rst
@@ -91,6 +91,10 @@ New Features
   * Implement support for tunnel offload.
   * Updated HWRM API to version 1.10.2.44
 
+* **Updated Intel e1000 emulated driver.**
+
+  * Added Intel e1000 support on Windows.
+
 * **Updated Intel iavf driver.**
 
   * Added Intel iavf support on Windows.
diff --git a/drivers/net/e1000/base/e1000_osdep.h b/drivers/net/e1000/base/e1000_osdep.h
index 94a49f340446..cd90228cef59 100644
--- a/drivers/net/e1000/base/e1000_osdep.h
+++ b/drivers/net/e1000/base/e1000_osdep.h
@@ -34,7 +34,9 @@
 #define DEBUGOUT6(S, args...)   DEBUGOUT(S, ##args)
 #define DEBUGOUT7(S, args...)   DEBUGOUT(S, ##args)
 
+#ifndef UNREFERENCED_PARAMETER
 #define UNREFERENCED_PARAMETER(_p)
+#endif
 #define UNREFERENCED_1PARAMETER(_p)
 #define UNREFERENCED_2PARAMETER(_p, _q)
 #define UNREFERENCED_3PARAMETER(_p, _q, _r)
diff --git a/drivers/net/e1000/e1000_ethdev.h b/drivers/net/e1000/e1000_ethdev.h
index 8e10e2777e64..bf0e902991a7 100644
--- a/drivers/net/e1000/e1000_ethdev.h
+++ b/drivers/net/e1000/e1000_ethdev.h
@@ -6,6 +6,7 @@
 #define _E1000_ETHDEV_H_
 
 #include <stdint.h>
+#include <sys/queue.h>
 
 #include <rte_flow.h>
 #include <rte_time.h>
diff --git a/drivers/net/e1000/meson.build b/drivers/net/e1000/meson.build
index c5e48c6bc7fc..296ec25f2ce7 100644
--- a/drivers/net/e1000/meson.build
+++ b/drivers/net/e1000/meson.build
@@ -1,12 +1,6 @@
 # SPDX-License-Identifier: BSD-3-Clause
 # Copyright(c) 2017 Intel Corporation
 
-if is_windows
-    build = false
-    reason = 'not supported on Windows'
-    subdir_done()
-endif
-
 subdir('base')
 objs = [base_objs]
 
-- 
2.33.0.windows.2


^ permalink raw reply	[flat|nested] 21+ messages in thread

* Re: [dpdk-dev] [PATCH v4] net/e1000: build on Windows
  2021-10-20  3:47     ` [dpdk-dev] [PATCH v4] " William Tu
@ 2021-10-21  2:56       ` Zhang, Qi Z
  0 siblings, 0 replies; 21+ messages in thread
From: Zhang, Qi Z @ 2021-10-21  2:56 UTC (permalink / raw)
  To: William Tu, dev; +Cc: Wang, Haiyue, Kadam, Pallavi, Dmitry Kozlyuk



> -----Original Message-----
> From: dev <dev-bounces@dpdk.org> On Behalf Of William Tu
> Sent: Wednesday, October 20, 2021 11:48 AM
> To: dev@dpdk.org
> Cc: Wang, Haiyue <haiyue.wang@intel.com>; Kadam, Pallavi
> <pallavi.kadam@intel.com>; Dmitry Kozlyuk <dmitry.kozliuk@gmail.com>
> Subject: [dpdk-dev] [PATCH v4] net/e1000: build on Windows
> 
> This patch enables building the e1000 driver for Windows.
> I tested using two Windows VM on top of VMware Fusion, creating two e1000
> devices with device ID 0x10D3 (8274L), verifying rx/tx works correctly using
> dpdk-testpmd.exe rxonly and txonly mode.
> 
> Signed-off-by: William Tu <u9012063@gmail.com>
> Acked-by: Haiyue Wang <haiyue.wang@intel.com>
> Acked-by: Pallavi Kadam <pallavi.kadam@intel.com>
> Tested-by: Dmitry Kozlyuk <dmitry.kozliuk@gmail.com>
> Tested-by: Pallavi Kadam <pallavi.kadam@intel.com>

Applied to dpdk-next-net-intel.

Thanks
Qi


^ permalink raw reply	[flat|nested] 21+ messages in thread

end of thread, other threads:[~2021-10-21  2:57 UTC | newest]

Thread overview: 21+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-10-07 20:24 [dpdk-dev] [PATCH] net/e1000: build on Windows William Tu
2021-10-08  6:54 ` David Marchand
2021-10-08  6:55   ` David Marchand
2021-10-08 12:20   ` William Tu
2021-10-08 12:24     ` David Marchand
2021-10-08 13:53 ` [dpdk-dev] [PATCH v2] " William Tu
2021-10-08 16:08   ` Wang, Haiyue
2021-10-08 21:12     ` Kadam, Pallavi
2021-10-08 20:35   ` Dmitry Kozlyuk
2021-10-08 21:41     ` William Tu
2021-10-09 16:37     ` William Tu
2021-10-09  0:02   ` Kadam, Pallavi
2021-10-09  0:14     ` William Tu
2021-10-09 18:40       ` Kadam, Pallavi
2021-10-09 16:31   ` [dpdk-dev] [PATCH v3] " William Tu
2021-10-09 17:28     ` Dmitry Kozlyuk
2021-10-10 10:56       ` Wang, Haiyue
2021-10-19 19:05     ` William Tu
2021-10-19 19:12       ` Thomas Monjalon
2021-10-20  3:47     ` [dpdk-dev] [PATCH v4] " William Tu
2021-10-21  2:56       ` Zhang, Qi Z

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).