[v4,4/4] net/ixgbe: build on Windows
Checks
Commit Message
This patch enables building the ixgbe driver for Windows.
It also enables its dependencies on security and cryptodev.
I tested on AWS using ixgbe VF device, using dpdk-testpmd.
Signed-off-by: William Tu <u9012063@gmail.com>
---
drivers/net/ixgbe/base/ixgbe_hv_vf.c | 1 +
drivers/net/ixgbe/base/ixgbe_osdep.h | 9 +++++++++
drivers/net/ixgbe/base/meson.build | 2 +-
drivers/net/ixgbe/ixgbe_ethdev.c | 2 +-
drivers/net/ixgbe/ixgbe_ethdev.h | 1 +
drivers/net/ixgbe/ixgbe_flow.c | 2 +-
drivers/net/ixgbe/ixgbe_tm.c | 2 +-
drivers/net/ixgbe/meson.build | 6 ------
8 files changed, 15 insertions(+), 10 deletions(-)
Comments
2021-10-05 17:02 (UTC+0000), William Tu:
> This patch enables building the ixgbe driver for Windows.
> It also enables its dependencies on security and cryptodev.
> I tested on AWS using ixgbe VF device, using dpdk-testpmd.
>
> Signed-off-by: William Tu <u9012063@gmail.com>
Acked-by: Dmitry Kozlyuk <dmitry.kozliuk@gmail.com>
On 10/5/2021 10:02 AM, William Tu wrote:
> This patch enables building the ixgbe driver for Windows.
> It also enables its dependencies on security and cryptodev.
> I tested on AWS using ixgbe VF device, using dpdk-testpmd.
>
> Signed-off-by: William Tu <u9012063@gmail.com>
> ---
should we mention the added support in the release notes?
Otherwise,
Acked-by: Pallavi Kadam <pallavi.kadam@intel.com>
>
On Tue, Oct 5, 2021 at 10:33 PM Kadam, Pallavi <pallavi.kadam@intel.com> wrote:
>
>
> On 10/5/2021 10:02 AM, William Tu wrote:
> > This patch enables building the ixgbe driver for Windows.
> > It also enables its dependencies on security and cryptodev.
> > I tested on AWS using ixgbe VF device, using dpdk-testpmd.
> >
> > Signed-off-by: William Tu <u9012063@gmail.com>
> > ---
>
> should we mention the added support in the release notes?
Hi Pallavi,
Thanks! I will add it to my next version.
William
>
> Otherwise,
>
> Acked-by: Pallavi Kadam <pallavi.kadam@intel.com>
>
> >
@@ -4,6 +4,7 @@
#include "ixgbe_vf.h"
#include "ixgbe_hv_vf.h"
+#include "ixgbe_osdep.h"
/**
* Hyper-V variant - just a stub.
@@ -16,10 +16,15 @@
#include <rte_log.h>
#include <rte_byteorder.h>
#include <rte_io.h>
+#include <rte_ip.h>
#include "../ixgbe_logs.h"
#include "../ixgbe_bypass_defines.h"
+#ifndef IPPROTO_SCTP
+#define IPPROTO_SCTP 132
+#endif
+
#define ASSERT(x) if(!(x)) rte_panic("IXGBE: x")
#define DELAY(x) rte_delay_us_sleep(x)
@@ -43,12 +48,16 @@
#define false 0
#define true 1
+#ifndef RTE_EXEC_ENV_WINDOWS
#define min(a,b) RTE_MIN(a,b)
+#endif
#define EWARN(hw, S, args...) DEBUGOUT1(S, ##args)
/* Bunch of defines for shared code bogosity */
+#ifndef UNREFERENCED_PARAMETER
#define UNREFERENCED_PARAMETER(_p)
+#endif
#define UNREFERENCED_1PARAMETER(_p)
#define UNREFERENCED_2PARAMETER(_p, _q)
#define UNREFERENCED_3PARAMETER(_p, _q, _r)
@@ -29,6 +29,6 @@ foreach flag: error_cflags
endforeach
base_lib = static_library('ixgbe_base', sources,
- dependencies: static_rte_eal,
+ dependencies: [static_rte_eal, static_rte_net],
c_args: c_args)
base_objs = base_lib.extract_all_objects(recursive: true)
@@ -10,7 +10,6 @@
#include <unistd.h>
#include <stdarg.h>
#include <inttypes.h>
-#include <netinet/in.h>
#include <rte_string_fns.h>
#include <rte_byteorder.h>
#include <rte_common.h>
@@ -46,6 +45,7 @@
#include "ixgbe_rxtx.h"
#include "base/ixgbe_type.h"
#include "base/ixgbe_phy.h"
+#include "base/ixgbe_osdep.h"
#include "ixgbe_regs.h"
/*
@@ -6,6 +6,7 @@
#define _IXGBE_ETHDEV_H_
#include <stdint.h>
+#include <sys/queue.h>
#include "base/ixgbe_type.h"
#include "base/ixgbe_dcb.h"
@@ -10,7 +10,6 @@
#include <unistd.h>
#include <stdarg.h>
#include <inttypes.h>
-#include <netinet/in.h>
#include <rte_byteorder.h>
#include <rte_common.h>
#include <rte_cycles.h>
@@ -37,6 +36,7 @@
#include "base/ixgbe_api.h"
#include "base/ixgbe_vf.h"
#include "base/ixgbe_common.h"
+#include "base/ixgbe_osdep.h"
#include "ixgbe_ethdev.h"
#include "ixgbe_bypass.h"
#include "ixgbe_rxtx.h"
@@ -665,7 +665,7 @@ ixgbe_node_add(struct rte_eth_dev *dev, uint32_t node_id,
}
/* check level */
if (level_id != RTE_TM_NODE_LEVEL_ID_ANY &&
- level_id != parent_node_type + 1) {
+ level_id != (uint32_t)parent_node_type + 1) {
error->type = RTE_TM_ERROR_TYPE_NODE_PARAMS;
error->message = "Wrong level";
return -EINVAL;
@@ -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
-
cflags += ['-DRTE_LIBRTE_IXGBE_BYPASS']
subdir('base')