Skip to content

eal/windows: do not expose POSIX symbols

Dmitry Kozlyuk dpdk-dev 10 versions – Applied

Status from this message: Applied, thanks

Get series with b4
b4 am [email protected]

Versions newest first · linked by author and title

  1. v10 Latest4 patches 2 repliesApplied
  2. v94 patches 9 repliesSuperseded
  3. v84 patches 5 repliesSuperseded
Earlier versions · 7
VersionPostedPatchesRepliesStatus
v75 patches5 repliesSuperseded
v65 patches11 repliesSuperseded
v55 patches1 replySuperseded
v44 patches3 repliesSuperseded
v37 patches12 repliesSuperseded
v27 patches21 repliesSuperseded
v17 patches1 replySuperseded

Changes in v10 from the cover letter

* Fix examples that build on Windows.

Patches in v10 Applied

#Subject and filesSizeRepliesApplied
1/4eal/windows: hide asprintf() shimlib/librte_eal/common/eal_private.h lib/librte_eal/windows/eal.c lib/librte_eal/windows/include/rte_os.h+41 -300 replies
2/4eal: make OS shims internaldrivers/bus/pci/private.h drivers/bus/vdev/vdev_private.h drivers/common/mlx5/mlx5_common.h +21 more+82 -780 replies
3/4net: work around s_addr macro on Windowslib/librte_net/rte_ether.h+20 -60 replies
4/4net: provide IP-related API on any OSdrivers/net/i40e/i40e_fdir.c drivers/net/mlx5/mlx5.h drivers/net/mlx5/mlx5_flow.c +21 more+24 -1440 replies

Reviews trailers per patch

3 of 4 patches have a Reviewed-by or Acked-by of their own; the series has one for all of them.

PatchKhoa ToThomas MonjalonRanjit Menon
SeriesA-b
1/4A-b
2/4A-b
3/4A-b
4/4

Trailers given in replies are filled; those carried in the patches from earlier versions are outlined with dashes. Scroll the table sideways for all 3 reviewers.

Read the v10 thread

Cover letter [dpdk-dev] [PATCH v10 0/4] eal/windows: do not expose POSIX symbols

On Windows, EAL contains two sets of functions and macros for POSIX
compatibility: <rte_os.h> and a networking shim (socket headers). The latter conflicts with system headers and should not exist. Exposing the former from EAL can break consumer own POSIX compatibility layer and is against standards in general. Hide these symbols from external consumers, while keeping them available for DPDK code.

v10:
* Fix examples that build on Windows.
v9:
* Fix missing <rte_os_shim.h> include in rte_common_log.c. (This will happen again. Going to add a checkpatch test after this series is merged.)

Dmitry Kozlyuk (4):
eal/windows: hide asprintf() shim
eal: make OS shims internal
net: work around s_addr macro on Windows
net: provide IP-related API on any OS

 drivers/bus/pci/private.h                    |  4 +-
 drivers/bus/vdev/vdev_private.h              |  2 +
 drivers/common/mlx5/mlx5_common.h            |  1 +
 drivers/net/i40e/i40e_ethdev.c               |  1 +
 drivers/net/i40e/i40e_fdir.c                 |  1 +
 drivers/net/mlx5/mlx5.h                      |  1 -
 drivers/net/mlx5/mlx5_flow.c                 |  4 +-
 drivers/net/mlx5/mlx5_flow.h                 |  3 +-
 drivers/net/mlx5/mlx5_mac.c                  |  1 -
 examples/cmdline/commands.c                  |  5 --
 examples/cmdline/parse_obj_list.c            |  2 -
 examples/flow_filtering/main.c               |  1 -
 examples/l2fwd/main.c                        |  1 -
 examples/link_status_interrupt/main.c        |  1 -
 examples/service_cores/main.c                |  4 +-
 lib/librte_cmdline/cmdline.c                 |  5 --
 lib/librte_cmdline/cmdline_os_windows.c      |  2 -
 lib/librte_cmdline/cmdline_parse.c           |  2 -
 lib/librte_cmdline/cmdline_parse_etheraddr.c |  6 --
 lib/librte_cmdline/cmdline_parse_ipaddr.c    |  6 --
 lib/librte_cmdline/cmdline_parse_ipaddr.h    |  2 +-
 lib/librte_cmdline/cmdline_private.h         |  1 +
 lib/librte_cmdline/cmdline_socket.c          |  4 -
 lib/librte_eal/common/eal_common_config.c    |  1 -
 lib/librte_eal/common/eal_common_errno.c     |  4 +
 lib/librte_eal/common/eal_common_log.c       |  1 +
 lib/librte_eal/common/eal_common_options.c   |  2 +-
 lib/librte_eal/common/eal_common_timer.c     |  4 +-
 lib/librte_eal/common/eal_internal_cfg.h     |  1 +
 lib/librte_eal/common/eal_private.h          | 11 +++
 lib/librte_eal/freebsd/include/rte_os_shim.h | 14 +++
 lib/librte_eal/linux/include/rte_os_shim.h   | 14 +++
 lib/librte_eal/windows/eal.c                 | 30 +++++++
 lib/librte_eal/windows/eal_hugepages.c       |  1 -
 lib/librte_eal/windows/eal_lcore.c           |  1 -
 lib/librte_eal/windows/eal_memalloc.c        |  1 -
 lib/librte_eal/windows/include/arpa/inet.h   | 30 -------
 lib/librte_eal/windows/include/netinet/in.h  | 38 --------
 lib/librte_eal/windows/include/netinet/ip.h  | 10 ---
 lib/librte_eal/windows/include/rte_os.h      | 92 +-------------------
 lib/librte_eal/windows/include/rte_os_shim.h | 36 ++++++++
 lib/librte_eal/windows/include/sys/socket.h  | 24 -----
 lib/librte_ethdev/ethdev_private.h           |  2 +
 lib/librte_ethdev/rte_ethdev.c               | 12 +--
 lib/librte_ethdev/rte_ethdev_core.h          |  1 -
 lib/librte_kvargs/rte_kvargs.c               |  1 +
 lib/librte_net/rte_ether.h                   | 26 ++++--
 lib/librte_net/rte_ip.h                      |  7 ++
 lib/librte_net/rte_net.c                     |  1 +
 49 files changed, 167 insertions(+), 258 deletions(-)
 create mode 100644 lib/librte_eal/freebsd/include/rte_os_shim.h
 create mode 100644 lib/librte_eal/linux/include/rte_os_shim.h
 delete mode 100644 lib/librte_eal/windows/include/arpa/inet.h
 delete mode 100644 lib/librte_eal/windows/include/netinet/in.h
 delete mode 100644 lib/librte_eal/windows/include/netinet/ip.h
 create mode 100644 lib/librte_eal/windows/include/rte_os_shim.h
 delete mode 100644 lib/librte_eal/windows/include/sys/socket.h
Signature · 1 line
2.29.3