[PATCHv3,1/2] linux-dpdk: configure: move inline files to plat subdirectory

Message ID 1472609329-25784-1-git-send-email-bill.fischofer@linaro.org
State New
Headers show

Commit Message

Bill Fischofer Aug. 31, 2016, 2:08 a.m.
To facilitate integration with odp-linux, move the conditional inline
files associated with ABI support from include/odp/api to
include/odp/api/plat since these are platform-specific optimizations.
Note that this also moves the .gitignore into the platform/linux-dpdk
directory to avoid conflicts with other platforms sharing the main
.gitignore file.

Suggested by: Zoltan Kiss <zoltan.kiss@schaman.hu>

Signed-off-by: Bill Fischofer <bill.fischofer@linaro.org>
---
 .gitignore                                         |  1 -
 platform/linux-dpdk/.gitignore                     |  1 +
 platform/linux-dpdk/Makefile.am                    |  7 +-
 platform/linux-dpdk/include/odp/api/inlines.h.in   | 33 ---------
 platform/linux-dpdk/include/odp/api/packet.h       |  4 +-
 platform/linux-dpdk/include/odp/api/packet_flags.h |  4 +-
 .../include/odp/api/packet_flags_inlines.h         | 44 ------------
 .../linux-dpdk/include/odp/api/packet_inlines.h    | 83 ---------------------
 .../linux-dpdk/include/odp/api/plat/inlines.h.in   | 33 +++++++++
 .../include/odp/api/plat/packet_flags_inlines.h    | 44 ++++++++++++
 .../include/odp/api/plat/packet_inlines.h          | 84 ++++++++++++++++++++++
 platform/linux-dpdk/m4/configure.m4                |  2 +-
 platform/linux-dpdk/odp_packet.c                   |  2 +-
 platform/linux-dpdk/odp_packet_flags.c             |  2 +-
 14 files changed, 172 insertions(+), 172 deletions(-)
 create mode 100644 platform/linux-dpdk/.gitignore
 delete mode 100644 platform/linux-dpdk/include/odp/api/inlines.h.in
 delete mode 100644 platform/linux-dpdk/include/odp/api/packet_flags_inlines.h
 delete mode 100644 platform/linux-dpdk/include/odp/api/packet_inlines.h
 create mode 100644 platform/linux-dpdk/include/odp/api/plat/inlines.h.in
 create mode 100644 platform/linux-dpdk/include/odp/api/plat/packet_flags_inlines.h
 create mode 100644 platform/linux-dpdk/include/odp/api/plat/packet_inlines.h

Comments

Krishna Garapati Sept. 2, 2016, 1:40 p.m. | #1
checkpatch output

WARNING: Possible unwrapped commit description (prefer a maximum 75 chars
per line)
#44:
VG8gZmFjaWxpdGF0ZSBpbnRlZ3JhdGlvbiB3aXRoIG9kcC1saW51eCwgbW92ZSB0aGUgY29uZGl0

ERROR: Does not appear to be a unified-diff format patch

total: 1 errors, 1 warnings, 0 checks, 0 lines checked

/Krishna


On 31 August 2016 at 04:08, Bill Fischofer <bill.fischofer@linaro.org>
wrote:

> To facilitate integration with odp-linux, move the conditional inline
> files associated with ABI support from include/odp/api to
> include/odp/api/plat since these are platform-specific optimizations.
> Note that this also moves the .gitignore into the platform/linux-dpdk
> directory to avoid conflicts with other platforms sharing the main
> .gitignore file.
>
> Suggested by: Zoltan Kiss <zoltan.kiss@schaman.hu>
>
> Signed-off-by: Bill Fischofer <bill.fischofer@linaro.org>
> ---
>  .gitignore                                         |  1 -
>  platform/linux-dpdk/.gitignore                     |  1 +
>  platform/linux-dpdk/Makefile.am                    |  7 +-
>  platform/linux-dpdk/include/odp/api/inlines.h.in   | 33 ---------
>  platform/linux-dpdk/include/odp/api/packet.h       |  4 +-
>  platform/linux-dpdk/include/odp/api/packet_flags.h |  4 +-
>  .../include/odp/api/packet_flags_inlines.h         | 44 ------------
>  .../linux-dpdk/include/odp/api/packet_inlines.h    | 83
> ---------------------
>  .../linux-dpdk/include/odp/api/plat/inlines.h.in   | 33 +++++++++
>  .../include/odp/api/plat/packet_flags_inlines.h    | 44 ++++++++++++
>  .../include/odp/api/plat/packet_inlines.h          | 84
> ++++++++++++++++++++++
>  platform/linux-dpdk/m4/configure.m4                |  2 +-
>  platform/linux-dpdk/odp_packet.c                   |  2 +-
>  platform/linux-dpdk/odp_packet_flags.c             |  2 +-
>  14 files changed, 172 insertions(+), 172 deletions(-)
>  create mode 100644 platform/linux-dpdk/.gitignore
>  delete mode 100644 platform/linux-dpdk/include/odp/api/inlines.h.in
>  delete mode 100644 platform/linux-dpdk/include/
> odp/api/packet_flags_inlines.h
>  delete mode 100644 platform/linux-dpdk/include/odp/api/packet_inlines.h
>  create mode 100644 platform/linux-dpdk/include/odp/api/plat/inlines.h.in
>  create mode 100644 platform/linux-dpdk/include/odp/api/plat/packet_flags_
> inlines.h
>  create mode 100644 platform/linux-dpdk/include/
> odp/api/plat/packet_inlines.h
>
> diff --git a/.gitignore b/.gitignore
> index bcc556c..d4e7d02 100644
> --- a/.gitignore
> +++ b/.gitignore
> @@ -41,6 +41,5 @@ ltmain.sh
>  m4/*.m4
>  missing
>  pkgconfig/libodp*.pc
> -platform/linux-dpdk/include/odp/api/inlines.h
>  tags
>  test-driver
> diff --git a/platform/linux-dpdk/.gitignore b/platform/linux-dpdk/.
> gitignore
> new file mode 100644
> index 0000000..654e50c
> --- /dev/null
> +++ b/platform/linux-dpdk/.gitignore
> @@ -0,0 +1 @@
> +include/odp/api/plat/inlines.h
> \ No newline at end of file
> diff --git a/platform/linux-dpdk/Makefile.am b/platform/linux-dpdk/
> Makefile.am
> index d4e9c79..4d87345 100644
> --- a/platform/linux-dpdk/Makefile.am
> +++ b/platform/linux-dpdk/Makefile.am
> @@ -47,11 +47,8 @@ odpapiinclude_HEADERS = \
>                   $(srcdir)/include/odp/api/hash.h \
>                   $(srcdir)/include/odp/api/hints.h \
>                   $(srcdir)/include/odp/api/init.h \
> -                 $(builddir)/include/odp/api/inlines.h \
>                   $(srcdir)/include/odp/api/packet_flags.h \
> -                 $(srcdir)/include/odp/api/packet_flags_inlines.h \
>                   $(srcdir)/include/odp/api/packet.h \
> -                 $(srcdir)/include/odp/api/packet_inlines.h \
>                   $(srcdir)/include/odp/api/packet_io.h \
>                   $(srcdir)/include/odp/api/packet_io_stats.h \
>                   $(srcdir)/include/odp/api/pool.h \
> @@ -90,8 +87,10 @@ odpapiplatinclude_HEADERS = \
>                   $(srcdir)/include/odp/api/plat/crypto_types.h \
>                   $(srcdir)/include/odp/api/plat/event_types.h \
>                   $(srcdir)/include/odp/api/plat/init_types.h \
> -                 $(srcdir)/include/odp/api/plat/packet_types.h \
> +                 $(srcdir)/include/odp/api/plat/packet_flags_inlines.h \
> +                 $(srcdir)/include/odp/api/plat/packet_inlines.h \
>                   $(srcdir)/include/odp/api/plat/packet_io_types.h \
> +                 $(srcdir)/include/odp/api/plat/packet_types.h \
>                   $(srcdir)/include/odp/api/plat/pool_types.h \
>                   $(srcdir)/include/odp/api/plat/queue_types.h \
>                   $(srcdir)/include/odp/api/plat/rwlock_types.h \
> diff --git a/platform/linux-dpdk/include/odp/api/inlines.h.in
> b/platform/linux-dpdk/include/odp/api/inlines.h.in
> deleted file mode 100644
> index 43e542b..0000000
> --- a/platform/linux-dpdk/include/odp/api/inlines.h.in
> +++ /dev/null
> @@ -1,33 +0,0 @@
> -/* Copyright (c) 2016, Linaro Limited
> - * All rights reserved.
> - *
> - * SPDX-License-Identifier: BSD-3-Clause
> - */
> -
> -/**
> - * @file
> - *
> - * ODP packet inline functions
> - */
> -
> -#ifndef ODP_PLAT_INLINES_H_
> -#define ODP_PLAT_INLINES_H_
> -
> -#ifdef __cplusplus
> -extern "C" {
> -#endif
> -
> -#define @_ODP_INLINES@
> -
> -#ifdef _ODP_INLINES
> -#define _STATIC static inline
> -#else
> -#define _STATIC
> -#endif
> -
> -#ifdef __cplusplus
> -}
> -#endif
> -
> -
> -#endif /* ODP_PLAT_INLINES_H_ */
> diff --git a/platform/linux-dpdk/include/odp/api/packet.h
> b/platform/linux-dpdk/include/odp/api/packet.h
> index 61543fa..f9123d8 100644
> --- a/platform/linux-dpdk/include/odp/api/packet.h
> +++ b/platform/linux-dpdk/include/odp/api/packet.h
> @@ -28,9 +28,9 @@ extern "C" {
>   *  @{
>   */
>
> -#include <odp/api/inlines.h>
> +#include <odp/api/plat/inlines.h>
>  #ifdef _ODP_INLINES
> -#include <odp/api/packet_inlines.h>
> +#include <odp/api/plat/packet_inlines.h>
>  #endif
>
>  /**
> diff --git a/platform/linux-dpdk/include/odp/api/packet_flags.h
> b/platform/linux-dpdk/include/odp/api/packet_flags.h
> index 00dd845..b6ae9f8 100644
> --- a/platform/linux-dpdk/include/odp/api/packet_flags.h
> +++ b/platform/linux-dpdk/include/odp/api/packet_flags.h
> @@ -28,9 +28,9 @@ extern "C" {
>   *  @{
>   */
>
> -#include <odp/api/inlines.h>
> +#include <odp/api/plat/inlines.h>
>  #ifdef _ODP_INLINES
> -#include <odp/api/packet_flags_inlines.h>
> +#include <odp/api/plat/packet_flags_inlines.h>
>  #endif
>
>  /**
> diff --git a/platform/linux-dpdk/include/odp/api/packet_flags_inlines.h
> b/platform/linux-dpdk/include/odp/api/packet_flags_inlines.h
> deleted file mode 100644
> index 7d2464e..0000000
> --- a/platform/linux-dpdk/include/odp/api/packet_flags_inlines.h
> +++ /dev/null
> @@ -1,44 +0,0 @@
> -/* Copyright (c) 2016, Linaro Limited
> - * All rights reserved.
> - *
> - * SPDX-License-Identifier: BSD-3-Clause
> - */
> -
> -/**
> - * @file
> - *
> - * ODP packet flags inline functions
> - */
> -
> -#ifndef ODP_PLAT_PACKET_FLAGS_INLINES_H_
> -#define ODP_PLAT_PACKET_FLAGS_INLINES_H_
> -
> -#ifdef __cplusplus
> -extern "C" {
> -#endif
> -
> -extern const unsigned int ol_flags_offset;
> -extern const uint64_t rss_flag;
> -
> -/*
> - * NOTE: These functions are inlined because they are on a performance
> hot path.
> - * As we can't force the application to directly include DPDK headers we
> have to
> - * export these fields through constants calculated compile time in
> - * odp_packet.c, where we can see the DPDK definitions.
> - *
> - */
> -_STATIC int odp_packet_has_flow_hash(odp_packet_t pkt)
> -{
> -       return *(uint64_t *)((char *)pkt + ol_flags_offset) & rss_flag;
> -}
> -
> -_STATIC void odp_packet_has_flow_hash_clr(odp_packet_t pkt)
> -{
> -       *(uint64_t *)((char *)pkt + ol_flags_offset) &= ~rss_flag;
> -}
> -
> -#ifdef __cplusplus
> -}
> -#endif
> -
> -#endif /* ODP_PLAT_PACKET_FLAGS_INLINES_H_ */
> diff --git a/platform/linux-dpdk/include/odp/api/packet_inlines.h
> b/platform/linux-dpdk/include/odp/api/packet_inlines.h
> deleted file mode 100644
> index 444919d..0000000
> --- a/platform/linux-dpdk/include/odp/api/packet_inlines.h
> +++ /dev/null
> @@ -1,83 +0,0 @@
> -/* Copyright (c) 2016, Linaro Limited
> - * All rights reserved.
> - *
> - * SPDX-License-Identifier: BSD-3-Clause
> - */
> -
> -/**
> - * @file
> - *
> - * ODP packet inline functions
> - */
> -
> -#ifndef ODP_PLAT_PACKET_INLINES_H_
> -#define ODP_PLAT_PACKET_INLINES_H_
> -
> -#ifdef __cplusplus
> -extern "C" {
> -#endif
> -
> -#ifdef _ODP_INLINES
> -
> -extern const unsigned int buf_addr_offset;
> -extern const unsigned int data_off_offset;
> -extern const unsigned int pkt_len_offset;
> -extern const unsigned int seg_len_offset;
> -extern const unsigned int udata_len_offset;
> -extern const unsigned int udata_offset;
> -extern const unsigned int rss_offset;
> -extern const unsigned int ol_flags_offset;
> -extern const uint64_t rss_flag;
> -
> -#endif /* _ODP_INLINES */
> -/*
> - * NOTE: These functions are inlined because they are on a performance
> hot path.
> - * As we can't force the application to directly include DPDK headers we
> have to
> - * export these fields through constants calculated compile time in
> - * odp_packet.c, where we can see the DPDK definitions.
> - *
> - */
> -_STATIC uint32_t odp_packet_len(odp_packet_t pkt)
> -{
> -       return *(uint32_t *)(void *)((char *)pkt + pkt_len_offset);
> -}
> -
> -_STATIC uint32_t odp_packet_seg_len(odp_packet_t pkt)
> -{
> -       return *(uint16_t *)(void *)((char *)pkt + seg_len_offset);
> -}
> -
> -_STATIC void *odp_packet_user_area(odp_packet_t pkt)
> -{
> -       return (void *)((char *)pkt + udata_offset);
> -}
> -
> -_STATIC uint32_t odp_packet_user_area_size(odp_packet_t pkt)
> -{
> -       return *(uint32_t *)(void *)((char *)pkt + udata_len_offset);
> -}
> -
> -_STATIC void *odp_packet_data(odp_packet_t pkt)
> -{
> -       char **buf_addr = (char **)(void *)((char *)pkt + buf_addr_offset);
> -       uint16_t data_off = *(uint16_t *)(void *)((char *)pkt +
> data_off_offset);
> -
> -       return (void *)(*buf_addr + data_off);
> -}
> -
> -_STATIC uint32_t odp_packet_flow_hash(odp_packet_t pkt)
> -{
> -       return *(uint32_t *)(void *)((char *)pkt + rss_offset);
> -}
> -
> -_STATIC void odp_packet_flow_hash_set(odp_packet_t pkt, uint32_t
> flow_hash)
> -{
> -       *(uint32_t *)(void *)((char *)pkt + rss_offset) = flow_hash;
> -       *(uint64_t *)(void *)((char *)pkt + ol_flags_offset) |= rss_flag;
> -}
> -
> -#ifdef __cplusplus
> -}
> -#endif
> -
> -#endif /* ODP_PLAT_PACKET_INLINES_H_ */
> diff --git a/platform/linux-dpdk/include/odp/api/plat/inlines.h.in
> b/platform/linux-dpdk/include/odp/api/plat/inlines.h.in
> new file mode 100644
> index 0000000..43e542b
> --- /dev/null
> +++ b/platform/linux-dpdk/include/odp/api/plat/inlines.h.in
> @@ -0,0 +1,33 @@
> +/* Copyright (c) 2016, Linaro Limited
> + * All rights reserved.
> + *
> + * SPDX-License-Identifier: BSD-3-Clause
> + */
> +
> +/**
> + * @file
> + *
> + * ODP packet inline functions
> + */
> +
> +#ifndef ODP_PLAT_INLINES_H_
> +#define ODP_PLAT_INLINES_H_
> +
> +#ifdef __cplusplus
> +extern "C" {
> +#endif
> +
> +#define @_ODP_INLINES@
> +
> +#ifdef _ODP_INLINES
> +#define _STATIC static inline
> +#else
> +#define _STATIC
> +#endif
> +
> +#ifdef __cplusplus
> +}
> +#endif
> +
> +
> +#endif /* ODP_PLAT_INLINES_H_ */
> diff --git a/platform/linux-dpdk/include/odp/api/plat/packet_flags_inlines.h
> b/platform/linux-dpdk/include/odp/api/plat/packet_flags_inlines.h
> new file mode 100644
> index 0000000..7d2464e
> --- /dev/null
> +++ b/platform/linux-dpdk/include/odp/api/plat/packet_flags_inlines.h
> @@ -0,0 +1,44 @@
> +/* Copyright (c) 2016, Linaro Limited
> + * All rights reserved.
> + *
> + * SPDX-License-Identifier: BSD-3-Clause
> + */
> +
> +/**
> + * @file
> + *
> + * ODP packet flags inline functions
> + */
> +
> +#ifndef ODP_PLAT_PACKET_FLAGS_INLINES_H_
> +#define ODP_PLAT_PACKET_FLAGS_INLINES_H_
> +
> +#ifdef __cplusplus
> +extern "C" {
> +#endif
> +
> +extern const unsigned int ol_flags_offset;
> +extern const uint64_t rss_flag;
> +
> +/*
> + * NOTE: These functions are inlined because they are on a performance
> hot path.
> + * As we can't force the application to directly include DPDK headers we
> have to
> + * export these fields through constants calculated compile time in
> + * odp_packet.c, where we can see the DPDK definitions.
> + *
> + */
> +_STATIC int odp_packet_has_flow_hash(odp_packet_t pkt)
> +{
> +       return *(uint64_t *)((char *)pkt + ol_flags_offset) & rss_flag;
> +}
> +
> +_STATIC void odp_packet_has_flow_hash_clr(odp_packet_t pkt)
> +{
> +       *(uint64_t *)((char *)pkt + ol_flags_offset) &= ~rss_flag;
> +}
> +
> +#ifdef __cplusplus
> +}
> +#endif
> +
> +#endif /* ODP_PLAT_PACKET_FLAGS_INLINES_H_ */
> diff --git a/platform/linux-dpdk/include/odp/api/plat/packet_inlines.h
> b/platform/linux-dpdk/include/odp/api/plat/packet_inlines.h
> new file mode 100644
> index 0000000..cd403bf
> --- /dev/null
> +++ b/platform/linux-dpdk/include/odp/api/plat/packet_inlines.h
> @@ -0,0 +1,84 @@
> +/* Copyright (c) 2016, Linaro Limited
> + * All rights reserved.
> + *
> + * SPDX-License-Identifier: BSD-3-Clause
> + */
> +
> +/**
> + * @file
> + *
> + * ODP packet inline functions
> + */
> +
> +#ifndef ODP_PLAT_PACKET_INLINES_H_
> +#define ODP_PLAT_PACKET_INLINES_H_
> +
> +#ifdef __cplusplus
> +extern "C" {
> +#endif
> +
> +#ifdef _ODP_INLINES
> +
> +extern const unsigned int buf_addr_offset;
> +extern const unsigned int data_off_offset;
> +extern const unsigned int pkt_len_offset;
> +extern const unsigned int seg_len_offset;
> +extern const unsigned int udata_len_offset;
> +extern const unsigned int udata_offset;
> +extern const unsigned int rss_offset;
> +extern const unsigned int ol_flags_offset;
> +extern const uint64_t rss_flag;
> +
> +#endif /* _ODP_INLINES */
> +/*
> + * NOTE: These functions are inlined because they are on a performance
> hot path.
> + * As we can't force the application to directly include DPDK headers we
> have to
> + * export these fields through constants calculated compile time in
> + * odp_packet.c, where we can see the DPDK definitions.
> + *
> + */
> +_STATIC uint32_t odp_packet_len(odp_packet_t pkt)
> +{
> +       return *(uint32_t *)(void *)((char *)pkt + pkt_len_offset);
> +}
> +
> +_STATIC uint32_t odp_packet_seg_len(odp_packet_t pkt)
> +{
> +       return *(uint16_t *)(void *)((char *)pkt + seg_len_offset);
> +}
> +
> +_STATIC void *odp_packet_user_area(odp_packet_t pkt)
> +{
> +       return (void *)((char *)pkt + udata_offset);
> +}
> +
> +_STATIC uint32_t odp_packet_user_area_size(odp_packet_t pkt)
> +{
> +       return *(uint32_t *)(void *)((char *)pkt + udata_len_offset);
> +}
> +
> +_STATIC void *odp_packet_data(odp_packet_t pkt)
> +{
> +       char **buf_addr = (char **)(void *)((char *)pkt + buf_addr_offset);
> +       uint16_t data_off =
> +               *(uint16_t *)(void *)((char *)pkt + data_off_offset);
> +
> +       return (void *)(*buf_addr + data_off);
> +}
> +
> +_STATIC uint32_t odp_packet_flow_hash(odp_packet_t pkt)
> +{
> +       return *(uint32_t *)(void *)((char *)pkt + rss_offset);
> +}
> +
> +_STATIC void odp_packet_flow_hash_set(odp_packet_t pkt, uint32_t
> flow_hash)
> +{
> +       *(uint32_t *)(void *)((char *)pkt + rss_offset) = flow_hash;
> +       *(uint64_t *)(void *)((char *)pkt + ol_flags_offset) |= rss_flag;
> +}
> +
> +#ifdef __cplusplus
> +}
> +#endif
> +
> +#endif /* ODP_PLAT_PACKET_INLINES_H_ */
> diff --git a/platform/linux-dpdk/m4/configure.m4 b/platform/linux-dpdk/m4/
> configure.m4
> index 730b6e8..6807de4 100644
> --- a/platform/linux-dpdk/m4/configure.m4
> +++ b/platform/linux-dpdk/m4/configure.m4
> @@ -75,5 +75,5 @@ LDFLAGS=$OLD_LDFLAGS
>  CPPFLAGS=$OLD_CPPFLAGS
>
>  AC_CONFIG_FILES([platform/linux-dpdk/Makefile
> -                platform/linux-dpdk/include/odp/api/inlines.h])
> +                platform/linux-dpdk/include/odp/api/plat/inlines.h])
>
> diff --git a/platform/linux-dpdk/odp_packet.c b/platform/linux-dpdk/odp_
> packet.c
> index b536281..8bd7379 100644
> --- a/platform/linux-dpdk/odp_packet.c
> +++ b/platform/linux-dpdk/odp_packet.c
> @@ -62,7 +62,7 @@ ODP_STATIC_ASSERT(sizeof(dummy.ol_flags) ==
> sizeof(uint64_t),
>                   "ol_flags should be uint64_t");
>
>  #ifndef _ODP_INLINES
> -#include <odp/api/packet_inlines.h>
> +#include <odp/api/plat/packet_inlines.h>
>  #endif
>
>  /*
> diff --git a/platform/linux-dpdk/odp_packet_flags.c
> b/platform/linux-dpdk/odp_packet_flags.c
> index 1c3b503..10d4097 100644
> --- a/platform/linux-dpdk/odp_packet_flags.c
> +++ b/platform/linux-dpdk/odp_packet_flags.c
> @@ -8,7 +8,7 @@
>  #include <odp_packet_internal.h>
>
>  #ifndef _ODP_INLINES
> -#include <odp/api/packet_flags_inlines.h>
> +#include <odp/api/plat/packet_flags_inlines.h>
>  #endif
>
>  #define retflag(pkt, x) do {                             \
> --
> 2.7.4
>
> _______________________________________________
> lng-odp-dpdk mailing list
> lng-odp-dpdk@lists.linaro.org
> https://lists.linaro.org/mailman/listinfo/lng-odp-dpdk
>
Bill Fischofer Sept. 2, 2016, 3:36 p.m. | #2
I see no such checkpatch warnings. As I've discussed with Mike part 2
generates some spurious warnings relating to the symbolic links, but part 1
is completely clean for me.

Are you applying with git am, or using patch directly?

On Fri, Sep 2, 2016 at 8:40 AM, Krishna Garapati <
balakrishna.garapati@linaro.org> wrote:

> checkpatch output
>
> WARNING: Possible unwrapped commit description (prefer a maximum 75 chars
> per line)
> #44:
> VG8gZmFjaWxpdGF0ZSBpbnRlZ3JhdGlvbiB3aXRoIG9kcC1saW51eCwgbW92
> ZSB0aGUgY29uZGl0
>
> ERROR: Does not appear to be a unified-diff format patch
>
> total: 1 errors, 1 warnings, 0 checks, 0 lines checked
>
> /Krishna
>
>
> On 31 August 2016 at 04:08, Bill Fischofer <bill.fischofer@linaro.org>
> wrote:
>
>> To facilitate integration with odp-linux, move the conditional inline
>> files associated with ABI support from include/odp/api to
>> include/odp/api/plat since these are platform-specific optimizations.
>> Note that this also moves the .gitignore into the platform/linux-dpdk
>> directory to avoid conflicts with other platforms sharing the main
>> .gitignore file.
>>
>> Suggested by: Zoltan Kiss <zoltan.kiss@schaman.hu>
>>
>> Signed-off-by: Bill Fischofer <bill.fischofer@linaro.org>
>> ---
>>  .gitignore                                         |  1 -
>>  platform/linux-dpdk/.gitignore                     |  1 +
>>  platform/linux-dpdk/Makefile.am                    |  7 +-
>>  platform/linux-dpdk/include/odp/api/inlines.h.in   | 33 ---------
>>  platform/linux-dpdk/include/odp/api/packet.h       |  4 +-
>>  platform/linux-dpdk/include/odp/api/packet_flags.h |  4 +-
>>  .../include/odp/api/packet_flags_inlines.h         | 44 ------------
>>  .../linux-dpdk/include/odp/api/packet_inlines.h    | 83
>> ---------------------
>>  .../linux-dpdk/include/odp/api/plat/inlines.h.in   | 33 +++++++++
>>  .../include/odp/api/plat/packet_flags_inlines.h    | 44 ++++++++++++
>>  .../include/odp/api/plat/packet_inlines.h          | 84
>> ++++++++++++++++++++++
>>  platform/linux-dpdk/m4/configure.m4                |  2 +-
>>  platform/linux-dpdk/odp_packet.c                   |  2 +-
>>  platform/linux-dpdk/odp_packet_flags.c             |  2 +-
>>  14 files changed, 172 insertions(+), 172 deletions(-)
>>  create mode 100644 platform/linux-dpdk/.gitignore
>>  delete mode 100644 platform/linux-dpdk/include/odp/api/inlines.h.in
>>  delete mode 100644 platform/linux-dpdk/include/od
>> p/api/packet_flags_inlines.h
>>  delete mode 100644 platform/linux-dpdk/include/odp/api/packet_inlines.h
>>  create mode 100644 platform/linux-dpdk/include/odp/api/plat/inlines.h.in
>>  create mode 100644 platform/linux-dpdk/include/od
>> p/api/plat/packet_flags_inlines.h
>>  create mode 100644 platform/linux-dpdk/include/od
>> p/api/plat/packet_inlines.h
>>
>> diff --git a/.gitignore b/.gitignore
>> index bcc556c..d4e7d02 100644
>> --- a/.gitignore
>> +++ b/.gitignore
>> @@ -41,6 +41,5 @@ ltmain.sh
>>  m4/*.m4
>>  missing
>>  pkgconfig/libodp*.pc
>> -platform/linux-dpdk/include/odp/api/inlines.h
>>  tags
>>  test-driver
>> diff --git a/platform/linux-dpdk/.gitignore
>> b/platform/linux-dpdk/.gitignore
>> new file mode 100644
>> index 0000000..654e50c
>> --- /dev/null
>> +++ b/platform/linux-dpdk/.gitignore
>> @@ -0,0 +1 @@
>> +include/odp/api/plat/inlines.h
>> \ No newline at end of file
>> diff --git a/platform/linux-dpdk/Makefile.am
>> b/platform/linux-dpdk/Makefile.am
>> index d4e9c79..4d87345 100644
>> --- a/platform/linux-dpdk/Makefile.am
>> +++ b/platform/linux-dpdk/Makefile.am
>> @@ -47,11 +47,8 @@ odpapiinclude_HEADERS = \
>>                   $(srcdir)/include/odp/api/hash.h \
>>                   $(srcdir)/include/odp/api/hints.h \
>>                   $(srcdir)/include/odp/api/init.h \
>> -                 $(builddir)/include/odp/api/inlines.h \
>>                   $(srcdir)/include/odp/api/packet_flags.h \
>> -                 $(srcdir)/include/odp/api/packet_flags_inlines.h \
>>                   $(srcdir)/include/odp/api/packet.h \
>> -                 $(srcdir)/include/odp/api/packet_inlines.h \
>>                   $(srcdir)/include/odp/api/packet_io.h \
>>                   $(srcdir)/include/odp/api/packet_io_stats.h \
>>                   $(srcdir)/include/odp/api/pool.h \
>> @@ -90,8 +87,10 @@ odpapiplatinclude_HEADERS = \
>>                   $(srcdir)/include/odp/api/plat/crypto_types.h \
>>                   $(srcdir)/include/odp/api/plat/event_types.h \
>>                   $(srcdir)/include/odp/api/plat/init_types.h \
>> -                 $(srcdir)/include/odp/api/plat/packet_types.h \
>> +                 $(srcdir)/include/odp/api/plat/packet_flags_inlines.h \
>> +                 $(srcdir)/include/odp/api/plat/packet_inlines.h \
>>                   $(srcdir)/include/odp/api/plat/packet_io_types.h \
>> +                 $(srcdir)/include/odp/api/plat/packet_types.h \
>>                   $(srcdir)/include/odp/api/plat/pool_types.h \
>>                   $(srcdir)/include/odp/api/plat/queue_types.h \
>>                   $(srcdir)/include/odp/api/plat/rwlock_types.h \
>> diff --git a/platform/linux-dpdk/include/odp/api/inlines.h.in
>> b/platform/linux-dpdk/include/odp/api/inlines.h.in
>> deleted file mode 100644
>> index 43e542b..0000000
>> --- a/platform/linux-dpdk/include/odp/api/inlines.h.in
>> +++ /dev/null
>> @@ -1,33 +0,0 @@
>> -/* Copyright (c) 2016, Linaro Limited
>> - * All rights reserved.
>> - *
>> - * SPDX-License-Identifier: BSD-3-Clause
>> - */
>> -
>> -/**
>> - * @file
>> - *
>> - * ODP packet inline functions
>> - */
>> -
>> -#ifndef ODP_PLAT_INLINES_H_
>> -#define ODP_PLAT_INLINES_H_
>> -
>> -#ifdef __cplusplus
>> -extern "C" {
>> -#endif
>> -
>> -#define @_ODP_INLINES@
>> -
>> -#ifdef _ODP_INLINES
>> -#define _STATIC static inline
>> -#else
>> -#define _STATIC
>> -#endif
>> -
>> -#ifdef __cplusplus
>> -}
>> -#endif
>> -
>> -
>> -#endif /* ODP_PLAT_INLINES_H_ */
>> diff --git a/platform/linux-dpdk/include/odp/api/packet.h
>> b/platform/linux-dpdk/include/odp/api/packet.h
>> index 61543fa..f9123d8 100644
>> --- a/platform/linux-dpdk/include/odp/api/packet.h
>> +++ b/platform/linux-dpdk/include/odp/api/packet.h
>> @@ -28,9 +28,9 @@ extern "C" {
>>   *  @{
>>   */
>>
>> -#include <odp/api/inlines.h>
>> +#include <odp/api/plat/inlines.h>
>>  #ifdef _ODP_INLINES
>> -#include <odp/api/packet_inlines.h>
>> +#include <odp/api/plat/packet_inlines.h>
>>  #endif
>>
>>  /**
>> diff --git a/platform/linux-dpdk/include/odp/api/packet_flags.h
>> b/platform/linux-dpdk/include/odp/api/packet_flags.h
>> index 00dd845..b6ae9f8 100644
>> --- a/platform/linux-dpdk/include/odp/api/packet_flags.h
>> +++ b/platform/linux-dpdk/include/odp/api/packet_flags.h
>> @@ -28,9 +28,9 @@ extern "C" {
>>   *  @{
>>   */
>>
>> -#include <odp/api/inlines.h>
>> +#include <odp/api/plat/inlines.h>
>>  #ifdef _ODP_INLINES
>> -#include <odp/api/packet_flags_inlines.h>
>> +#include <odp/api/plat/packet_flags_inlines.h>
>>  #endif
>>
>>  /**
>> diff --git a/platform/linux-dpdk/include/odp/api/packet_flags_inlines.h
>> b/platform/linux-dpdk/include/odp/api/packet_flags_inlines.h
>> deleted file mode 100644
>> index 7d2464e..0000000
>> --- a/platform/linux-dpdk/include/odp/api/packet_flags_inlines.h
>> +++ /dev/null
>> @@ -1,44 +0,0 @@
>> -/* Copyright (c) 2016, Linaro Limited
>> - * All rights reserved.
>> - *
>> - * SPDX-License-Identifier: BSD-3-Clause
>> - */
>> -
>> -/**
>> - * @file
>> - *
>> - * ODP packet flags inline functions
>> - */
>> -
>> -#ifndef ODP_PLAT_PACKET_FLAGS_INLINES_H_
>> -#define ODP_PLAT_PACKET_FLAGS_INLINES_H_
>> -
>> -#ifdef __cplusplus
>> -extern "C" {
>> -#endif
>> -
>> -extern const unsigned int ol_flags_offset;
>> -extern const uint64_t rss_flag;
>> -
>> -/*
>> - * NOTE: These functions are inlined because they are on a performance
>> hot path.
>> - * As we can't force the application to directly include DPDK headers we
>> have to
>> - * export these fields through constants calculated compile time in
>> - * odp_packet.c, where we can see the DPDK definitions.
>> - *
>> - */
>> -_STATIC int odp_packet_has_flow_hash(odp_packet_t pkt)
>> -{
>> -       return *(uint64_t *)((char *)pkt + ol_flags_offset) & rss_flag;
>> -}
>> -
>> -_STATIC void odp_packet_has_flow_hash_clr(odp_packet_t pkt)
>> -{
>> -       *(uint64_t *)((char *)pkt + ol_flags_offset) &= ~rss_flag;
>> -}
>> -
>> -#ifdef __cplusplus
>> -}
>> -#endif
>> -
>> -#endif /* ODP_PLAT_PACKET_FLAGS_INLINES_H_ */
>> diff --git a/platform/linux-dpdk/include/odp/api/packet_inlines.h
>> b/platform/linux-dpdk/include/odp/api/packet_inlines.h
>> deleted file mode 100644
>> index 444919d..0000000
>> --- a/platform/linux-dpdk/include/odp/api/packet_inlines.h
>> +++ /dev/null
>> @@ -1,83 +0,0 @@
>> -/* Copyright (c) 2016, Linaro Limited
>> - * All rights reserved.
>> - *
>> - * SPDX-License-Identifier: BSD-3-Clause
>> - */
>> -
>> -/**
>> - * @file
>> - *
>> - * ODP packet inline functions
>> - */
>> -
>> -#ifndef ODP_PLAT_PACKET_INLINES_H_
>> -#define ODP_PLAT_PACKET_INLINES_H_
>> -
>> -#ifdef __cplusplus
>> -extern "C" {
>> -#endif
>> -
>> -#ifdef _ODP_INLINES
>> -
>> -extern const unsigned int buf_addr_offset;
>> -extern const unsigned int data_off_offset;
>> -extern const unsigned int pkt_len_offset;
>> -extern const unsigned int seg_len_offset;
>> -extern const unsigned int udata_len_offset;
>> -extern const unsigned int udata_offset;
>> -extern const unsigned int rss_offset;
>> -extern const unsigned int ol_flags_offset;
>> -extern const uint64_t rss_flag;
>> -
>> -#endif /* _ODP_INLINES */
>> -/*
>> - * NOTE: These functions are inlined because they are on a performance
>> hot path.
>> - * As we can't force the application to directly include DPDK headers we
>> have to
>> - * export these fields through constants calculated compile time in
>> - * odp_packet.c, where we can see the DPDK definitions.
>> - *
>> - */
>> -_STATIC uint32_t odp_packet_len(odp_packet_t pkt)
>> -{
>> -       return *(uint32_t *)(void *)((char *)pkt + pkt_len_offset);
>> -}
>> -
>> -_STATIC uint32_t odp_packet_seg_len(odp_packet_t pkt)
>> -{
>> -       return *(uint16_t *)(void *)((char *)pkt + seg_len_offset);
>> -}
>> -
>> -_STATIC void *odp_packet_user_area(odp_packet_t pkt)
>> -{
>> -       return (void *)((char *)pkt + udata_offset);
>> -}
>> -
>> -_STATIC uint32_t odp_packet_user_area_size(odp_packet_t pkt)
>> -{
>> -       return *(uint32_t *)(void *)((char *)pkt + udata_len_offset);
>> -}
>> -
>> -_STATIC void *odp_packet_data(odp_packet_t pkt)
>> -{
>> -       char **buf_addr = (char **)(void *)((char *)pkt +
>> buf_addr_offset);
>> -       uint16_t data_off = *(uint16_t *)(void *)((char *)pkt +
>> data_off_offset);
>> -
>> -       return (void *)(*buf_addr + data_off);
>> -}
>> -
>> -_STATIC uint32_t odp_packet_flow_hash(odp_packet_t pkt)
>> -{
>> -       return *(uint32_t *)(void *)((char *)pkt + rss_offset);
>> -}
>> -
>> -_STATIC void odp_packet_flow_hash_set(odp_packet_t pkt, uint32_t
>> flow_hash)
>> -{
>> -       *(uint32_t *)(void *)((char *)pkt + rss_offset) = flow_hash;
>> -       *(uint64_t *)(void *)((char *)pkt + ol_flags_offset) |= rss_flag;
>> -}
>> -
>> -#ifdef __cplusplus
>> -}
>> -#endif
>> -
>> -#endif /* ODP_PLAT_PACKET_INLINES_H_ */
>> diff --git a/platform/linux-dpdk/include/odp/api/plat/inlines.h.in
>> b/platform/linux-dpdk/include/odp/api/plat/inlines.h.in
>> new file mode 100644
>> index 0000000..43e542b
>> --- /dev/null
>> +++ b/platform/linux-dpdk/include/odp/api/plat/inlines.h.in
>> @@ -0,0 +1,33 @@
>> +/* Copyright (c) 2016, Linaro Limited
>> + * All rights reserved.
>> + *
>> + * SPDX-License-Identifier: BSD-3-Clause
>> + */
>> +
>> +/**
>> + * @file
>> + *
>> + * ODP packet inline functions
>> + */
>> +
>> +#ifndef ODP_PLAT_INLINES_H_
>> +#define ODP_PLAT_INLINES_H_
>> +
>> +#ifdef __cplusplus
>> +extern "C" {
>> +#endif
>> +
>> +#define @_ODP_INLINES@
>> +
>> +#ifdef _ODP_INLINES
>> +#define _STATIC static inline
>> +#else
>> +#define _STATIC
>> +#endif
>> +
>> +#ifdef __cplusplus
>> +}
>> +#endif
>> +
>> +
>> +#endif /* ODP_PLAT_INLINES_H_ */
>> diff --git a/platform/linux-dpdk/include/odp/api/plat/packet_flags_inlines.h
>> b/platform/linux-dpdk/include/odp/api/plat/packet_flags_inlines.h
>> new file mode 100644
>> index 0000000..7d2464e
>> --- /dev/null
>> +++ b/platform/linux-dpdk/include/odp/api/plat/packet_flags_inlines.h
>> @@ -0,0 +1,44 @@
>> +/* Copyright (c) 2016, Linaro Limited
>> + * All rights reserved.
>> + *
>> + * SPDX-License-Identifier: BSD-3-Clause
>> + */
>> +
>> +/**
>> + * @file
>> + *
>> + * ODP packet flags inline functions
>> + */
>> +
>> +#ifndef ODP_PLAT_PACKET_FLAGS_INLINES_H_
>> +#define ODP_PLAT_PACKET_FLAGS_INLINES_H_
>> +
>> +#ifdef __cplusplus
>> +extern "C" {
>> +#endif
>> +
>> +extern const unsigned int ol_flags_offset;
>> +extern const uint64_t rss_flag;
>> +
>> +/*
>> + * NOTE: These functions are inlined because they are on a performance
>> hot path.
>> + * As we can't force the application to directly include DPDK headers we
>> have to
>> + * export these fields through constants calculated compile time in
>> + * odp_packet.c, where we can see the DPDK definitions.
>> + *
>> + */
>> +_STATIC int odp_packet_has_flow_hash(odp_packet_t pkt)
>> +{
>> +       return *(uint64_t *)((char *)pkt + ol_flags_offset) & rss_flag;
>> +}
>> +
>> +_STATIC void odp_packet_has_flow_hash_clr(odp_packet_t pkt)
>> +{
>> +       *(uint64_t *)((char *)pkt + ol_flags_offset) &= ~rss_flag;
>> +}
>> +
>> +#ifdef __cplusplus
>> +}
>> +#endif
>> +
>> +#endif /* ODP_PLAT_PACKET_FLAGS_INLINES_H_ */
>> diff --git a/platform/linux-dpdk/include/odp/api/plat/packet_inlines.h
>> b/platform/linux-dpdk/include/odp/api/plat/packet_inlines.h
>> new file mode 100644
>> index 0000000..cd403bf
>> --- /dev/null
>> +++ b/platform/linux-dpdk/include/odp/api/plat/packet_inlines.h
>> @@ -0,0 +1,84 @@
>> +/* Copyright (c) 2016, Linaro Limited
>> + * All rights reserved.
>> + *
>> + * SPDX-License-Identifier: BSD-3-Clause
>> + */
>> +
>> +/**
>> + * @file
>> + *
>> + * ODP packet inline functions
>> + */
>> +
>> +#ifndef ODP_PLAT_PACKET_INLINES_H_
>> +#define ODP_PLAT_PACKET_INLINES_H_
>> +
>> +#ifdef __cplusplus
>> +extern "C" {
>> +#endif
>> +
>> +#ifdef _ODP_INLINES
>> +
>> +extern const unsigned int buf_addr_offset;
>> +extern const unsigned int data_off_offset;
>> +extern const unsigned int pkt_len_offset;
>> +extern const unsigned int seg_len_offset;
>> +extern const unsigned int udata_len_offset;
>> +extern const unsigned int udata_offset;
>> +extern const unsigned int rss_offset;
>> +extern const unsigned int ol_flags_offset;
>> +extern const uint64_t rss_flag;
>> +
>> +#endif /* _ODP_INLINES */
>> +/*
>> + * NOTE: These functions are inlined because they are on a performance
>> hot path.
>> + * As we can't force the application to directly include DPDK headers we
>> have to
>> + * export these fields through constants calculated compile time in
>> + * odp_packet.c, where we can see the DPDK definitions.
>> + *
>> + */
>> +_STATIC uint32_t odp_packet_len(odp_packet_t pkt)
>> +{
>> +       return *(uint32_t *)(void *)((char *)pkt + pkt_len_offset);
>> +}
>> +
>> +_STATIC uint32_t odp_packet_seg_len(odp_packet_t pkt)
>> +{
>> +       return *(uint16_t *)(void *)((char *)pkt + seg_len_offset);
>> +}
>> +
>> +_STATIC void *odp_packet_user_area(odp_packet_t pkt)
>> +{
>> +       return (void *)((char *)pkt + udata_offset);
>> +}
>> +
>> +_STATIC uint32_t odp_packet_user_area_size(odp_packet_t pkt)
>> +{
>> +       return *(uint32_t *)(void *)((char *)pkt + udata_len_offset);
>> +}
>> +
>> +_STATIC void *odp_packet_data(odp_packet_t pkt)
>> +{
>> +       char **buf_addr = (char **)(void *)((char *)pkt +
>> buf_addr_offset);
>> +       uint16_t data_off =
>> +               *(uint16_t *)(void *)((char *)pkt + data_off_offset);
>> +
>> +       return (void *)(*buf_addr + data_off);
>> +}
>> +
>> +_STATIC uint32_t odp_packet_flow_hash(odp_packet_t pkt)
>> +{
>> +       return *(uint32_t *)(void *)((char *)pkt + rss_offset);
>> +}
>> +
>> +_STATIC void odp_packet_flow_hash_set(odp_packet_t pkt, uint32_t
>> flow_hash)
>> +{
>> +       *(uint32_t *)(void *)((char *)pkt + rss_offset) = flow_hash;
>> +       *(uint64_t *)(void *)((char *)pkt + ol_flags_offset) |= rss_flag;
>> +}
>> +
>> +#ifdef __cplusplus
>> +}
>> +#endif
>> +
>> +#endif /* ODP_PLAT_PACKET_INLINES_H_ */
>> diff --git a/platform/linux-dpdk/m4/configure.m4
>> b/platform/linux-dpdk/m4/configure.m4
>> index 730b6e8..6807de4 100644
>> --- a/platform/linux-dpdk/m4/configure.m4
>> +++ b/platform/linux-dpdk/m4/configure.m4
>> @@ -75,5 +75,5 @@ LDFLAGS=$OLD_LDFLAGS
>>  CPPFLAGS=$OLD_CPPFLAGS
>>
>>  AC_CONFIG_FILES([platform/linux-dpdk/Makefile
>> -                platform/linux-dpdk/include/odp/api/inlines.h])
>> +                platform/linux-dpdk/include/odp/api/plat/inlines.h])
>>
>> diff --git a/platform/linux-dpdk/odp_packet.c
>> b/platform/linux-dpdk/odp_packet.c
>> index b536281..8bd7379 100644
>> --- a/platform/linux-dpdk/odp_packet.c
>> +++ b/platform/linux-dpdk/odp_packet.c
>> @@ -62,7 +62,7 @@ ODP_STATIC_ASSERT(sizeof(dummy.ol_flags) ==
>> sizeof(uint64_t),
>>                   "ol_flags should be uint64_t");
>>
>>  #ifndef _ODP_INLINES
>> -#include <odp/api/packet_inlines.h>
>> +#include <odp/api/plat/packet_inlines.h>
>>  #endif
>>
>>  /*
>> diff --git a/platform/linux-dpdk/odp_packet_flags.c
>> b/platform/linux-dpdk/odp_packet_flags.c
>> index 1c3b503..10d4097 100644
>> --- a/platform/linux-dpdk/odp_packet_flags.c
>> +++ b/platform/linux-dpdk/odp_packet_flags.c
>> @@ -8,7 +8,7 @@
>>  #include <odp_packet_internal.h>
>>
>>  #ifndef _ODP_INLINES
>> -#include <odp/api/packet_flags_inlines.h>
>> +#include <odp/api/plat/packet_flags_inlines.h>
>>  #endif
>>
>>  #define retflag(pkt, x) do {                             \
>> --
>> 2.7.4
>>
>> _______________________________________________
>> lng-odp-dpdk mailing list
>> lng-odp-dpdk@lists.linaro.org
>> https://lists.linaro.org/mailman/listinfo/lng-odp-dpdk
>>
>
>
Krishna Garapati Sept. 2, 2016, 4:11 p.m. | #3
On 2 September 2016 at 17:36, Bill Fischofer <bill.fischofer@linaro.org>
wrote:

> I see no such checkpatch warnings. As I've discussed with Mike part 2
> generates some spurious warnings relating to the symbolic links, but part 1
> is completely clean for me.
>
> Are you applying with git am, or using patch directly?
>
I use git am and the build is fine. When I do checkpatch directly on the
downloaded patch I see these warning/error messages.

/Krishna

>
> On Fri, Sep 2, 2016 at 8:40 AM, Krishna Garapati <
> balakrishna.garapati@linaro.org> wrote:
>
>> checkpatch output
>>
>> WARNING: Possible unwrapped commit description (prefer a maximum 75 chars
>> per line)
>> #44:
>> VG8gZmFjaWxpdGF0ZSBpbnRlZ3JhdGlvbiB3aXRoIG9kcC1saW51eCwgbW92
>> ZSB0aGUgY29uZGl0
>>
>> ERROR: Does not appear to be a unified-diff format patch
>>
>> total: 1 errors, 1 warnings, 0 checks, 0 lines checked
>>
>> /Krishna
>>
>>
>> On 31 August 2016 at 04:08, Bill Fischofer <bill.fischofer@linaro.org>
>> wrote:
>>
>>> To facilitate integration with odp-linux, move the conditional inline
>>> files associated with ABI support from include/odp/api to
>>> include/odp/api/plat since these are platform-specific optimizations.
>>> Note that this also moves the .gitignore into the platform/linux-dpdk
>>> directory to avoid conflicts with other platforms sharing the main
>>> .gitignore file.
>>>
>>> Suggested by: Zoltan Kiss <zoltan.kiss@schaman.hu>
>>>
>>> Signed-off-by: Bill Fischofer <bill.fischofer@linaro.org>
>>> ---
>>>  .gitignore                                         |  1 -
>>>  platform/linux-dpdk/.gitignore                     |  1 +
>>>  platform/linux-dpdk/Makefile.am                    |  7 +-
>>>  platform/linux-dpdk/include/odp/api/inlines.h.in   | 33 ---------
>>>  platform/linux-dpdk/include/odp/api/packet.h       |  4 +-
>>>  platform/linux-dpdk/include/odp/api/packet_flags.h |  4 +-
>>>  .../include/odp/api/packet_flags_inlines.h         | 44 ------------
>>>  .../linux-dpdk/include/odp/api/packet_inlines.h    | 83
>>> ---------------------
>>>  .../linux-dpdk/include/odp/api/plat/inlines.h.in   | 33 +++++++++
>>>  .../include/odp/api/plat/packet_flags_inlines.h    | 44 ++++++++++++
>>>  .../include/odp/api/plat/packet_inlines.h          | 84
>>> ++++++++++++++++++++++
>>>  platform/linux-dpdk/m4/configure.m4                |  2 +-
>>>  platform/linux-dpdk/odp_packet.c                   |  2 +-
>>>  platform/linux-dpdk/odp_packet_flags.c             |  2 +-
>>>  14 files changed, 172 insertions(+), 172 deletions(-)
>>>  create mode 100644 platform/linux-dpdk/.gitignore
>>>  delete mode 100644 platform/linux-dpdk/include/odp/api/inlines.h.in
>>>  delete mode 100644 platform/linux-dpdk/include/od
>>> p/api/packet_flags_inlines.h
>>>  delete mode 100644 platform/linux-dpdk/include/odp/api/packet_inlines.h
>>>  create mode 100644 platform/linux-dpdk/include/odp/api/plat/
>>> inlines.h.in
>>>  create mode 100644 platform/linux-dpdk/include/od
>>> p/api/plat/packet_flags_inlines.h
>>>  create mode 100644 platform/linux-dpdk/include/od
>>> p/api/plat/packet_inlines.h
>>>
>>> diff --git a/.gitignore b/.gitignore
>>> index bcc556c..d4e7d02 100644
>>> --- a/.gitignore
>>> +++ b/.gitignore
>>> @@ -41,6 +41,5 @@ ltmain.sh
>>>  m4/*.m4
>>>  missing
>>>  pkgconfig/libodp*.pc
>>> -platform/linux-dpdk/include/odp/api/inlines.h
>>>  tags
>>>  test-driver
>>> diff --git a/platform/linux-dpdk/.gitignore
>>> b/platform/linux-dpdk/.gitignore
>>> new file mode 100644
>>> index 0000000..654e50c
>>> --- /dev/null
>>> +++ b/platform/linux-dpdk/.gitignore
>>> @@ -0,0 +1 @@
>>> +include/odp/api/plat/inlines.h
>>> \ No newline at end of file
>>> diff --git a/platform/linux-dpdk/Makefile.am
>>> b/platform/linux-dpdk/Makefile.am
>>> index d4e9c79..4d87345 100644
>>> --- a/platform/linux-dpdk/Makefile.am
>>> +++ b/platform/linux-dpdk/Makefile.am
>>> @@ -47,11 +47,8 @@ odpapiinclude_HEADERS = \
>>>                   $(srcdir)/include/odp/api/hash.h \
>>>                   $(srcdir)/include/odp/api/hints.h \
>>>                   $(srcdir)/include/odp/api/init.h \
>>> -                 $(builddir)/include/odp/api/inlines.h \
>>>                   $(srcdir)/include/odp/api/packet_flags.h \
>>> -                 $(srcdir)/include/odp/api/packet_flags_inlines.h \
>>>                   $(srcdir)/include/odp/api/packet.h \
>>> -                 $(srcdir)/include/odp/api/packet_inlines.h \
>>>                   $(srcdir)/include/odp/api/packet_io.h \
>>>                   $(srcdir)/include/odp/api/packet_io_stats.h \
>>>                   $(srcdir)/include/odp/api/pool.h \
>>> @@ -90,8 +87,10 @@ odpapiplatinclude_HEADERS = \
>>>                   $(srcdir)/include/odp/api/plat/crypto_types.h \
>>>                   $(srcdir)/include/odp/api/plat/event_types.h \
>>>                   $(srcdir)/include/odp/api/plat/init_types.h \
>>> -                 $(srcdir)/include/odp/api/plat/packet_types.h \
>>> +                 $(srcdir)/include/odp/api/plat/packet_flags_inlines.h
>>> \
>>> +                 $(srcdir)/include/odp/api/plat/packet_inlines.h \
>>>                   $(srcdir)/include/odp/api/plat/packet_io_types.h \
>>> +                 $(srcdir)/include/odp/api/plat/packet_types.h \
>>>                   $(srcdir)/include/odp/api/plat/pool_types.h \
>>>                   $(srcdir)/include/odp/api/plat/queue_types.h \
>>>                   $(srcdir)/include/odp/api/plat/rwlock_types.h \
>>> diff --git a/platform/linux-dpdk/include/odp/api/inlines.h.in
>>> b/platform/linux-dpdk/include/odp/api/inlines.h.in
>>> deleted file mode 100644
>>> index 43e542b..0000000
>>> --- a/platform/linux-dpdk/include/odp/api/inlines.h.in
>>> +++ /dev/null
>>> @@ -1,33 +0,0 @@
>>> -/* Copyright (c) 2016, Linaro Limited
>>> - * All rights reserved.
>>> - *
>>> - * SPDX-License-Identifier: BSD-3-Clause
>>> - */
>>> -
>>> -/**
>>> - * @file
>>> - *
>>> - * ODP packet inline functions
>>> - */
>>> -
>>> -#ifndef ODP_PLAT_INLINES_H_
>>> -#define ODP_PLAT_INLINES_H_
>>> -
>>> -#ifdef __cplusplus
>>> -extern "C" {
>>> -#endif
>>> -
>>> -#define @_ODP_INLINES@
>>> -
>>> -#ifdef _ODP_INLINES
>>> -#define _STATIC static inline
>>> -#else
>>> -#define _STATIC
>>> -#endif
>>> -
>>> -#ifdef __cplusplus
>>> -}
>>> -#endif
>>> -
>>> -
>>> -#endif /* ODP_PLAT_INLINES_H_ */
>>> diff --git a/platform/linux-dpdk/include/odp/api/packet.h
>>> b/platform/linux-dpdk/include/odp/api/packet.h
>>> index 61543fa..f9123d8 100644
>>> --- a/platform/linux-dpdk/include/odp/api/packet.h
>>> +++ b/platform/linux-dpdk/include/odp/api/packet.h
>>> @@ -28,9 +28,9 @@ extern "C" {
>>>   *  @{
>>>   */
>>>
>>> -#include <odp/api/inlines.h>
>>> +#include <odp/api/plat/inlines.h>
>>>  #ifdef _ODP_INLINES
>>> -#include <odp/api/packet_inlines.h>
>>> +#include <odp/api/plat/packet_inlines.h>
>>>  #endif
>>>
>>>  /**
>>> diff --git a/platform/linux-dpdk/include/odp/api/packet_flags.h
>>> b/platform/linux-dpdk/include/odp/api/packet_flags.h
>>> index 00dd845..b6ae9f8 100644
>>> --- a/platform/linux-dpdk/include/odp/api/packet_flags.h
>>> +++ b/platform/linux-dpdk/include/odp/api/packet_flags.h
>>> @@ -28,9 +28,9 @@ extern "C" {
>>>   *  @{
>>>   */
>>>
>>> -#include <odp/api/inlines.h>
>>> +#include <odp/api/plat/inlines.h>
>>>  #ifdef _ODP_INLINES
>>> -#include <odp/api/packet_flags_inlines.h>
>>> +#include <odp/api/plat/packet_flags_inlines.h>
>>>  #endif
>>>
>>>  /**
>>> diff --git a/platform/linux-dpdk/include/odp/api/packet_flags_inlines.h
>>> b/platform/linux-dpdk/include/odp/api/packet_flags_inlines.h
>>> deleted file mode 100644
>>> index 7d2464e..0000000
>>> --- a/platform/linux-dpdk/include/odp/api/packet_flags_inlines.h
>>> +++ /dev/null
>>> @@ -1,44 +0,0 @@
>>> -/* Copyright (c) 2016, Linaro Limited
>>> - * All rights reserved.
>>> - *
>>> - * SPDX-License-Identifier: BSD-3-Clause
>>> - */
>>> -
>>> -/**
>>> - * @file
>>> - *
>>> - * ODP packet flags inline functions
>>> - */
>>> -
>>> -#ifndef ODP_PLAT_PACKET_FLAGS_INLINES_H_
>>> -#define ODP_PLAT_PACKET_FLAGS_INLINES_H_
>>> -
>>> -#ifdef __cplusplus
>>> -extern "C" {
>>> -#endif
>>> -
>>> -extern const unsigned int ol_flags_offset;
>>> -extern const uint64_t rss_flag;
>>> -
>>> -/*
>>> - * NOTE: These functions are inlined because they are on a performance
>>> hot path.
>>> - * As we can't force the application to directly include DPDK headers
>>> we have to
>>> - * export these fields through constants calculated compile time in
>>> - * odp_packet.c, where we can see the DPDK definitions.
>>> - *
>>> - */
>>> -_STATIC int odp_packet_has_flow_hash(odp_packet_t pkt)
>>> -{
>>> -       return *(uint64_t *)((char *)pkt + ol_flags_offset) & rss_flag;
>>> -}
>>> -
>>> -_STATIC void odp_packet_has_flow_hash_clr(odp_packet_t pkt)
>>> -{
>>> -       *(uint64_t *)((char *)pkt + ol_flags_offset) &= ~rss_flag;
>>> -}
>>> -
>>> -#ifdef __cplusplus
>>> -}
>>> -#endif
>>> -
>>> -#endif /* ODP_PLAT_PACKET_FLAGS_INLINES_H_ */
>>> diff --git a/platform/linux-dpdk/include/odp/api/packet_inlines.h
>>> b/platform/linux-dpdk/include/odp/api/packet_inlines.h
>>> deleted file mode 100644
>>> index 444919d..0000000
>>> --- a/platform/linux-dpdk/include/odp/api/packet_inlines.h
>>> +++ /dev/null
>>> @@ -1,83 +0,0 @@
>>> -/* Copyright (c) 2016, Linaro Limited
>>> - * All rights reserved.
>>> - *
>>> - * SPDX-License-Identifier: BSD-3-Clause
>>> - */
>>> -
>>> -/**
>>> - * @file
>>> - *
>>> - * ODP packet inline functions
>>> - */
>>> -
>>> -#ifndef ODP_PLAT_PACKET_INLINES_H_
>>> -#define ODP_PLAT_PACKET_INLINES_H_
>>> -
>>> -#ifdef __cplusplus
>>> -extern "C" {
>>> -#endif
>>> -
>>> -#ifdef _ODP_INLINES
>>> -
>>> -extern const unsigned int buf_addr_offset;
>>> -extern const unsigned int data_off_offset;
>>> -extern const unsigned int pkt_len_offset;
>>> -extern const unsigned int seg_len_offset;
>>> -extern const unsigned int udata_len_offset;
>>> -extern const unsigned int udata_offset;
>>> -extern const unsigned int rss_offset;
>>> -extern const unsigned int ol_flags_offset;
>>> -extern const uint64_t rss_flag;
>>> -
>>> -#endif /* _ODP_INLINES */
>>> -/*
>>> - * NOTE: These functions are inlined because they are on a performance
>>> hot path.
>>> - * As we can't force the application to directly include DPDK headers
>>> we have to
>>> - * export these fields through constants calculated compile time in
>>> - * odp_packet.c, where we can see the DPDK definitions.
>>> - *
>>> - */
>>> -_STATIC uint32_t odp_packet_len(odp_packet_t pkt)
>>> -{
>>> -       return *(uint32_t *)(void *)((char *)pkt + pkt_len_offset);
>>> -}
>>> -
>>> -_STATIC uint32_t odp_packet_seg_len(odp_packet_t pkt)
>>> -{
>>> -       return *(uint16_t *)(void *)((char *)pkt + seg_len_offset);
>>> -}
>>> -
>>> -_STATIC void *odp_packet_user_area(odp_packet_t pkt)
>>> -{
>>> -       return (void *)((char *)pkt + udata_offset);
>>> -}
>>> -
>>> -_STATIC uint32_t odp_packet_user_area_size(odp_packet_t pkt)
>>> -{
>>> -       return *(uint32_t *)(void *)((char *)pkt + udata_len_offset);
>>> -}
>>> -
>>> -_STATIC void *odp_packet_data(odp_packet_t pkt)
>>> -{
>>> -       char **buf_addr = (char **)(void *)((char *)pkt +
>>> buf_addr_offset);
>>> -       uint16_t data_off = *(uint16_t *)(void *)((char *)pkt +
>>> data_off_offset);
>>> -
>>> -       return (void *)(*buf_addr + data_off);
>>> -}
>>> -
>>> -_STATIC uint32_t odp_packet_flow_hash(odp_packet_t pkt)
>>> -{
>>> -       return *(uint32_t *)(void *)((char *)pkt + rss_offset);
>>> -}
>>> -
>>> -_STATIC void odp_packet_flow_hash_set(odp_packet_t pkt, uint32_t
>>> flow_hash)
>>> -{
>>> -       *(uint32_t *)(void *)((char *)pkt + rss_offset) = flow_hash;
>>> -       *(uint64_t *)(void *)((char *)pkt + ol_flags_offset) |= rss_flag;
>>> -}
>>> -
>>> -#ifdef __cplusplus
>>> -}
>>> -#endif
>>> -
>>> -#endif /* ODP_PLAT_PACKET_INLINES_H_ */
>>> diff --git a/platform/linux-dpdk/include/odp/api/plat/inlines.h.in
>>> b/platform/linux-dpdk/include/odp/api/plat/inlines.h.in
>>> new file mode 100644
>>> index 0000000..43e542b
>>> --- /dev/null
>>> +++ b/platform/linux-dpdk/include/odp/api/plat/inlines.h.in
>>> @@ -0,0 +1,33 @@
>>> +/* Copyright (c) 2016, Linaro Limited
>>> + * All rights reserved.
>>> + *
>>> + * SPDX-License-Identifier: BSD-3-Clause
>>> + */
>>> +
>>> +/**
>>> + * @file
>>> + *
>>> + * ODP packet inline functions
>>> + */
>>> +
>>> +#ifndef ODP_PLAT_INLINES_H_
>>> +#define ODP_PLAT_INLINES_H_
>>> +
>>> +#ifdef __cplusplus
>>> +extern "C" {
>>> +#endif
>>> +
>>> +#define @_ODP_INLINES@
>>> +
>>> +#ifdef _ODP_INLINES
>>> +#define _STATIC static inline
>>> +#else
>>> +#define _STATIC
>>> +#endif
>>> +
>>> +#ifdef __cplusplus
>>> +}
>>> +#endif
>>> +
>>> +
>>> +#endif /* ODP_PLAT_INLINES_H_ */
>>> diff --git a/platform/linux-dpdk/include/odp/api/plat/packet_flags_inlines.h
>>> b/platform/linux-dpdk/include/odp/api/plat/packet_flags_inlines.h
>>> new file mode 100644
>>> index 0000000..7d2464e
>>> --- /dev/null
>>> +++ b/platform/linux-dpdk/include/odp/api/plat/packet_flags_inlines.h
>>> @@ -0,0 +1,44 @@
>>> +/* Copyright (c) 2016, Linaro Limited
>>> + * All rights reserved.
>>> + *
>>> + * SPDX-License-Identifier: BSD-3-Clause
>>> + */
>>> +
>>> +/**
>>> + * @file
>>> + *
>>> + * ODP packet flags inline functions
>>> + */
>>> +
>>> +#ifndef ODP_PLAT_PACKET_FLAGS_INLINES_H_
>>> +#define ODP_PLAT_PACKET_FLAGS_INLINES_H_
>>> +
>>> +#ifdef __cplusplus
>>> +extern "C" {
>>> +#endif
>>> +
>>> +extern const unsigned int ol_flags_offset;
>>> +extern const uint64_t rss_flag;
>>> +
>>> +/*
>>> + * NOTE: These functions are inlined because they are on a performance
>>> hot path.
>>> + * As we can't force the application to directly include DPDK headers
>>> we have to
>>> + * export these fields through constants calculated compile time in
>>> + * odp_packet.c, where we can see the DPDK definitions.
>>> + *
>>> + */
>>> +_STATIC int odp_packet_has_flow_hash(odp_packet_t pkt)
>>> +{
>>> +       return *(uint64_t *)((char *)pkt + ol_flags_offset) & rss_flag;
>>> +}
>>> +
>>> +_STATIC void odp_packet_has_flow_hash_clr(odp_packet_t pkt)
>>> +{
>>> +       *(uint64_t *)((char *)pkt + ol_flags_offset) &= ~rss_flag;
>>> +}
>>> +
>>> +#ifdef __cplusplus
>>> +}
>>> +#endif
>>> +
>>> +#endif /* ODP_PLAT_PACKET_FLAGS_INLINES_H_ */
>>> diff --git a/platform/linux-dpdk/include/odp/api/plat/packet_inlines.h
>>> b/platform/linux-dpdk/include/odp/api/plat/packet_inlines.h
>>> new file mode 100644
>>> index 0000000..cd403bf
>>> --- /dev/null
>>> +++ b/platform/linux-dpdk/include/odp/api/plat/packet_inlines.h
>>> @@ -0,0 +1,84 @@
>>> +/* Copyright (c) 2016, Linaro Limited
>>> + * All rights reserved.
>>> + *
>>> + * SPDX-License-Identifier: BSD-3-Clause
>>> + */
>>> +
>>> +/**
>>> + * @file
>>> + *
>>> + * ODP packet inline functions
>>> + */
>>> +
>>> +#ifndef ODP_PLAT_PACKET_INLINES_H_
>>> +#define ODP_PLAT_PACKET_INLINES_H_
>>> +
>>> +#ifdef __cplusplus
>>> +extern "C" {
>>> +#endif
>>> +
>>> +#ifdef _ODP_INLINES
>>> +
>>> +extern const unsigned int buf_addr_offset;
>>> +extern const unsigned int data_off_offset;
>>> +extern const unsigned int pkt_len_offset;
>>> +extern const unsigned int seg_len_offset;
>>> +extern const unsigned int udata_len_offset;
>>> +extern const unsigned int udata_offset;
>>> +extern const unsigned int rss_offset;
>>> +extern const unsigned int ol_flags_offset;
>>> +extern const uint64_t rss_flag;
>>> +
>>> +#endif /* _ODP_INLINES */
>>> +/*
>>> + * NOTE: These functions are inlined because they are on a performance
>>> hot path.
>>> + * As we can't force the application to directly include DPDK headers
>>> we have to
>>> + * export these fields through constants calculated compile time in
>>> + * odp_packet.c, where we can see the DPDK definitions.
>>> + *
>>> + */
>>> +_STATIC uint32_t odp_packet_len(odp_packet_t pkt)
>>> +{
>>> +       return *(uint32_t *)(void *)((char *)pkt + pkt_len_offset);
>>> +}
>>> +
>>> +_STATIC uint32_t odp_packet_seg_len(odp_packet_t pkt)
>>> +{
>>> +       return *(uint16_t *)(void *)((char *)pkt + seg_len_offset);
>>> +}
>>> +
>>> +_STATIC void *odp_packet_user_area(odp_packet_t pkt)
>>> +{
>>> +       return (void *)((char *)pkt + udata_offset);
>>> +}
>>> +
>>> +_STATIC uint32_t odp_packet_user_area_size(odp_packet_t pkt)
>>> +{
>>> +       return *(uint32_t *)(void *)((char *)pkt + udata_len_offset);
>>> +}
>>> +
>>> +_STATIC void *odp_packet_data(odp_packet_t pkt)
>>> +{
>>> +       char **buf_addr = (char **)(void *)((char *)pkt +
>>> buf_addr_offset);
>>> +       uint16_t data_off =
>>> +               *(uint16_t *)(void *)((char *)pkt + data_off_offset);
>>> +
>>> +       return (void *)(*buf_addr + data_off);
>>> +}
>>> +
>>> +_STATIC uint32_t odp_packet_flow_hash(odp_packet_t pkt)
>>> +{
>>> +       return *(uint32_t *)(void *)((char *)pkt + rss_offset);
>>> +}
>>> +
>>> +_STATIC void odp_packet_flow_hash_set(odp_packet_t pkt, uint32_t
>>> flow_hash)
>>> +{
>>> +       *(uint32_t *)(void *)((char *)pkt + rss_offset) = flow_hash;
>>> +       *(uint64_t *)(void *)((char *)pkt + ol_flags_offset) |= rss_flag;
>>> +}
>>> +
>>> +#ifdef __cplusplus
>>> +}
>>> +#endif
>>> +
>>> +#endif /* ODP_PLAT_PACKET_INLINES_H_ */
>>> diff --git a/platform/linux-dpdk/m4/configure.m4
>>> b/platform/linux-dpdk/m4/configure.m4
>>> index 730b6e8..6807de4 100644
>>> --- a/platform/linux-dpdk/m4/configure.m4
>>> +++ b/platform/linux-dpdk/m4/configure.m4
>>> @@ -75,5 +75,5 @@ LDFLAGS=$OLD_LDFLAGS
>>>  CPPFLAGS=$OLD_CPPFLAGS
>>>
>>>  AC_CONFIG_FILES([platform/linux-dpdk/Makefile
>>> -                platform/linux-dpdk/include/odp/api/inlines.h])
>>> +                platform/linux-dpdk/include/odp/api/plat/inlines.h])
>>>
>>> diff --git a/platform/linux-dpdk/odp_packet.c
>>> b/platform/linux-dpdk/odp_packet.c
>>> index b536281..8bd7379 100644
>>> --- a/platform/linux-dpdk/odp_packet.c
>>> +++ b/platform/linux-dpdk/odp_packet.c
>>> @@ -62,7 +62,7 @@ ODP_STATIC_ASSERT(sizeof(dummy.ol_flags) ==
>>> sizeof(uint64_t),
>>>                   "ol_flags should be uint64_t");
>>>
>>>  #ifndef _ODP_INLINES
>>> -#include <odp/api/packet_inlines.h>
>>> +#include <odp/api/plat/packet_inlines.h>
>>>  #endif
>>>
>>>  /*
>>> diff --git a/platform/linux-dpdk/odp_packet_flags.c
>>> b/platform/linux-dpdk/odp_packet_flags.c
>>> index 1c3b503..10d4097 100644
>>> --- a/platform/linux-dpdk/odp_packet_flags.c
>>> +++ b/platform/linux-dpdk/odp_packet_flags.c
>>> @@ -8,7 +8,7 @@
>>>  #include <odp_packet_internal.h>
>>>
>>>  #ifndef _ODP_INLINES
>>> -#include <odp/api/packet_flags_inlines.h>
>>> +#include <odp/api/plat/packet_flags_inlines.h>
>>>  #endif
>>>
>>>  #define retflag(pkt, x) do {                             \
>>> --
>>> 2.7.4
>>>
>>> _______________________________________________
>>> lng-odp-dpdk mailing list
>>> lng-odp-dpdk@lists.linaro.org
>>> https://lists.linaro.org/mailman/listinfo/lng-odp-dpdk
>>>
>>
>>
>
Bill Fischofer Sept. 2, 2016, 4:15 p.m. | #4
On Fri, Sep 2, 2016 at 11:11 AM, Krishna Garapati <
balakrishna.garapati@linaro.org> wrote:

>
>
> On 2 September 2016 at 17:36, Bill Fischofer <bill.fischofer@linaro.org>
> wrote:
>
>> I see no such checkpatch warnings. As I've discussed with Mike part 2
>> generates some spurious warnings relating to the symbolic links, but part 1
>> is completely clean for me.
>>
>> Are you applying with git am, or using patch directly?
>>
> I use git am and the build is fine. When I do checkpatch directly on the
> downloaded patch I see these warning/error messages.
>
>
I'm not sure what to say. Do you do this with other patches and see
different behavior? Reason I ask is there haven't been a lot of "external"
patches posted to odp-dpdk of late. Do you see the same difference for the
similar patch series I posted against odp-linux?


> /Krishna
>
>>
>> On Fri, Sep 2, 2016 at 8:40 AM, Krishna Garapati <
>> balakrishna.garapati@linaro.org> wrote:
>>
>>> checkpatch output
>>>
>>> WARNING: Possible unwrapped commit description (prefer a maximum 75
>>> chars per line)
>>> #44:
>>> VG8gZmFjaWxpdGF0ZSBpbnRlZ3JhdGlvbiB3aXRoIG9kcC1saW51eCwgbW92
>>> ZSB0aGUgY29uZGl0
>>>
>>> ERROR: Does not appear to be a unified-diff format patch
>>>
>>> total: 1 errors, 1 warnings, 0 checks, 0 lines checked
>>>
>>> /Krishna
>>>
>>>
>>> On 31 August 2016 at 04:08, Bill Fischofer <bill.fischofer@linaro.org>
>>> wrote:
>>>
>>>> To facilitate integration with odp-linux, move the conditional inline
>>>> files associated with ABI support from include/odp/api to
>>>> include/odp/api/plat since these are platform-specific optimizations.
>>>> Note that this also moves the .gitignore into the platform/linux-dpdk
>>>> directory to avoid conflicts with other platforms sharing the main
>>>> .gitignore file.
>>>>
>>>> Suggested by: Zoltan Kiss <zoltan.kiss@schaman.hu>
>>>>
>>>> Signed-off-by: Bill Fischofer <bill.fischofer@linaro.org>
>>>> ---
>>>>  .gitignore                                         |  1 -
>>>>  platform/linux-dpdk/.gitignore                     |  1 +
>>>>  platform/linux-dpdk/Makefile.am                    |  7 +-
>>>>  platform/linux-dpdk/include/odp/api/inlines.h.in   | 33 ---------
>>>>  platform/linux-dpdk/include/odp/api/packet.h       |  4 +-
>>>>  platform/linux-dpdk/include/odp/api/packet_flags.h |  4 +-
>>>>  .../include/odp/api/packet_flags_inlines.h         | 44 ------------
>>>>  .../linux-dpdk/include/odp/api/packet_inlines.h    | 83
>>>> ---------------------
>>>>  .../linux-dpdk/include/odp/api/plat/inlines.h.in   | 33 +++++++++
>>>>  .../include/odp/api/plat/packet_flags_inlines.h    | 44 ++++++++++++
>>>>  .../include/odp/api/plat/packet_inlines.h          | 84
>>>> ++++++++++++++++++++++
>>>>  platform/linux-dpdk/m4/configure.m4                |  2 +-
>>>>  platform/linux-dpdk/odp_packet.c                   |  2 +-
>>>>  platform/linux-dpdk/odp_packet_flags.c             |  2 +-
>>>>  14 files changed, 172 insertions(+), 172 deletions(-)
>>>>  create mode 100644 platform/linux-dpdk/.gitignore
>>>>  delete mode 100644 platform/linux-dpdk/include/odp/api/inlines.h.in
>>>>  delete mode 100644 platform/linux-dpdk/include/od
>>>> p/api/packet_flags_inlines.h
>>>>  delete mode 100644 platform/linux-dpdk/include/od
>>>> p/api/packet_inlines.h
>>>>  create mode 100644 platform/linux-dpdk/include/odp/api/plat/
>>>> inlines.h.in
>>>>  create mode 100644 platform/linux-dpdk/include/od
>>>> p/api/plat/packet_flags_inlines.h
>>>>  create mode 100644 platform/linux-dpdk/include/od
>>>> p/api/plat/packet_inlines.h
>>>>
>>>> diff --git a/.gitignore b/.gitignore
>>>> index bcc556c..d4e7d02 100644
>>>> --- a/.gitignore
>>>> +++ b/.gitignore
>>>> @@ -41,6 +41,5 @@ ltmain.sh
>>>>  m4/*.m4
>>>>  missing
>>>>  pkgconfig/libodp*.pc
>>>> -platform/linux-dpdk/include/odp/api/inlines.h
>>>>  tags
>>>>  test-driver
>>>> diff --git a/platform/linux-dpdk/.gitignore
>>>> b/platform/linux-dpdk/.gitignore
>>>> new file mode 100644
>>>> index 0000000..654e50c
>>>> --- /dev/null
>>>> +++ b/platform/linux-dpdk/.gitignore
>>>> @@ -0,0 +1 @@
>>>> +include/odp/api/plat/inlines.h
>>>> \ No newline at end of file
>>>> diff --git a/platform/linux-dpdk/Makefile.am
>>>> b/platform/linux-dpdk/Makefile.am
>>>> index d4e9c79..4d87345 100644
>>>> --- a/platform/linux-dpdk/Makefile.am
>>>> +++ b/platform/linux-dpdk/Makefile.am
>>>> @@ -47,11 +47,8 @@ odpapiinclude_HEADERS = \
>>>>                   $(srcdir)/include/odp/api/hash.h \
>>>>                   $(srcdir)/include/odp/api/hints.h \
>>>>                   $(srcdir)/include/odp/api/init.h \
>>>> -                 $(builddir)/include/odp/api/inlines.h \
>>>>                   $(srcdir)/include/odp/api/packet_flags.h \
>>>> -                 $(srcdir)/include/odp/api/packet_flags_inlines.h \
>>>>                   $(srcdir)/include/odp/api/packet.h \
>>>> -                 $(srcdir)/include/odp/api/packet_inlines.h \
>>>>                   $(srcdir)/include/odp/api/packet_io.h \
>>>>                   $(srcdir)/include/odp/api/packet_io_stats.h \
>>>>                   $(srcdir)/include/odp/api/pool.h \
>>>> @@ -90,8 +87,10 @@ odpapiplatinclude_HEADERS = \
>>>>                   $(srcdir)/include/odp/api/plat/crypto_types.h \
>>>>                   $(srcdir)/include/odp/api/plat/event_types.h \
>>>>                   $(srcdir)/include/odp/api/plat/init_types.h \
>>>> -                 $(srcdir)/include/odp/api/plat/packet_types.h \
>>>> +                 $(srcdir)/include/odp/api/plat/packet_flags_inlines.h
>>>> \
>>>> +                 $(srcdir)/include/odp/api/plat/packet_inlines.h \
>>>>                   $(srcdir)/include/odp/api/plat/packet_io_types.h \
>>>> +                 $(srcdir)/include/odp/api/plat/packet_types.h \
>>>>                   $(srcdir)/include/odp/api/plat/pool_types.h \
>>>>                   $(srcdir)/include/odp/api/plat/queue_types.h \
>>>>                   $(srcdir)/include/odp/api/plat/rwlock_types.h \
>>>> diff --git a/platform/linux-dpdk/include/odp/api/inlines.h.in
>>>> b/platform/linux-dpdk/include/odp/api/inlines.h.in
>>>> deleted file mode 100644
>>>> index 43e542b..0000000
>>>> --- a/platform/linux-dpdk/include/odp/api/inlines.h.in
>>>> +++ /dev/null
>>>> @@ -1,33 +0,0 @@
>>>> -/* Copyright (c) 2016, Linaro Limited
>>>> - * All rights reserved.
>>>> - *
>>>> - * SPDX-License-Identifier: BSD-3-Clause
>>>> - */
>>>> -
>>>> -/**
>>>> - * @file
>>>> - *
>>>> - * ODP packet inline functions
>>>> - */
>>>> -
>>>> -#ifndef ODP_PLAT_INLINES_H_
>>>> -#define ODP_PLAT_INLINES_H_
>>>> -
>>>> -#ifdef __cplusplus
>>>> -extern "C" {
>>>> -#endif
>>>> -
>>>> -#define @_ODP_INLINES@
>>>> -
>>>> -#ifdef _ODP_INLINES
>>>> -#define _STATIC static inline
>>>> -#else
>>>> -#define _STATIC
>>>> -#endif
>>>> -
>>>> -#ifdef __cplusplus
>>>> -}
>>>> -#endif
>>>> -
>>>> -
>>>> -#endif /* ODP_PLAT_INLINES_H_ */
>>>> diff --git a/platform/linux-dpdk/include/odp/api/packet.h
>>>> b/platform/linux-dpdk/include/odp/api/packet.h
>>>> index 61543fa..f9123d8 100644
>>>> --- a/platform/linux-dpdk/include/odp/api/packet.h
>>>> +++ b/platform/linux-dpdk/include/odp/api/packet.h
>>>> @@ -28,9 +28,9 @@ extern "C" {
>>>>   *  @{
>>>>   */
>>>>
>>>> -#include <odp/api/inlines.h>
>>>> +#include <odp/api/plat/inlines.h>
>>>>  #ifdef _ODP_INLINES
>>>> -#include <odp/api/packet_inlines.h>
>>>> +#include <odp/api/plat/packet_inlines.h>
>>>>  #endif
>>>>
>>>>  /**
>>>> diff --git a/platform/linux-dpdk/include/odp/api/packet_flags.h
>>>> b/platform/linux-dpdk/include/odp/api/packet_flags.h
>>>> index 00dd845..b6ae9f8 100644
>>>> --- a/platform/linux-dpdk/include/odp/api/packet_flags.h
>>>> +++ b/platform/linux-dpdk/include/odp/api/packet_flags.h
>>>> @@ -28,9 +28,9 @@ extern "C" {
>>>>   *  @{
>>>>   */
>>>>
>>>> -#include <odp/api/inlines.h>
>>>> +#include <odp/api/plat/inlines.h>
>>>>  #ifdef _ODP_INLINES
>>>> -#include <odp/api/packet_flags_inlines.h>
>>>> +#include <odp/api/plat/packet_flags_inlines.h>
>>>>  #endif
>>>>
>>>>  /**
>>>> diff --git a/platform/linux-dpdk/include/odp/api/packet_flags_inlines.h
>>>> b/platform/linux-dpdk/include/odp/api/packet_flags_inlines.h
>>>> deleted file mode 100644
>>>> index 7d2464e..0000000
>>>> --- a/platform/linux-dpdk/include/odp/api/packet_flags_inlines.h
>>>> +++ /dev/null
>>>> @@ -1,44 +0,0 @@
>>>> -/* Copyright (c) 2016, Linaro Limited
>>>> - * All rights reserved.
>>>> - *
>>>> - * SPDX-License-Identifier: BSD-3-Clause
>>>> - */
>>>> -
>>>> -/**
>>>> - * @file
>>>> - *
>>>> - * ODP packet flags inline functions
>>>> - */
>>>> -
>>>> -#ifndef ODP_PLAT_PACKET_FLAGS_INLINES_H_
>>>> -#define ODP_PLAT_PACKET_FLAGS_INLINES_H_
>>>> -
>>>> -#ifdef __cplusplus
>>>> -extern "C" {
>>>> -#endif
>>>> -
>>>> -extern const unsigned int ol_flags_offset;
>>>> -extern const uint64_t rss_flag;
>>>> -
>>>> -/*
>>>> - * NOTE: These functions are inlined because they are on a performance
>>>> hot path.
>>>> - * As we can't force the application to directly include DPDK headers
>>>> we have to
>>>> - * export these fields through constants calculated compile time in
>>>> - * odp_packet.c, where we can see the DPDK definitions.
>>>> - *
>>>> - */
>>>> -_STATIC int odp_packet_has_flow_hash(odp_packet_t pkt)
>>>> -{
>>>> -       return *(uint64_t *)((char *)pkt + ol_flags_offset) & rss_flag;
>>>> -}
>>>> -
>>>> -_STATIC void odp_packet_has_flow_hash_clr(odp_packet_t pkt)
>>>> -{
>>>> -       *(uint64_t *)((char *)pkt + ol_flags_offset) &= ~rss_flag;
>>>> -}
>>>> -
>>>> -#ifdef __cplusplus
>>>> -}
>>>> -#endif
>>>> -
>>>> -#endif /* ODP_PLAT_PACKET_FLAGS_INLINES_H_ */
>>>> diff --git a/platform/linux-dpdk/include/odp/api/packet_inlines.h
>>>> b/platform/linux-dpdk/include/odp/api/packet_inlines.h
>>>> deleted file mode 100644
>>>> index 444919d..0000000
>>>> --- a/platform/linux-dpdk/include/odp/api/packet_inlines.h
>>>> +++ /dev/null
>>>> @@ -1,83 +0,0 @@
>>>> -/* Copyright (c) 2016, Linaro Limited
>>>> - * All rights reserved.
>>>> - *
>>>> - * SPDX-License-Identifier: BSD-3-Clause
>>>> - */
>>>> -
>>>> -/**
>>>> - * @file
>>>> - *
>>>> - * ODP packet inline functions
>>>> - */
>>>> -
>>>> -#ifndef ODP_PLAT_PACKET_INLINES_H_
>>>> -#define ODP_PLAT_PACKET_INLINES_H_
>>>> -
>>>> -#ifdef __cplusplus
>>>> -extern "C" {
>>>> -#endif
>>>> -
>>>> -#ifdef _ODP_INLINES
>>>> -
>>>> -extern const unsigned int buf_addr_offset;
>>>> -extern const unsigned int data_off_offset;
>>>> -extern const unsigned int pkt_len_offset;
>>>> -extern const unsigned int seg_len_offset;
>>>> -extern const unsigned int udata_len_offset;
>>>> -extern const unsigned int udata_offset;
>>>> -extern const unsigned int rss_offset;
>>>> -extern const unsigned int ol_flags_offset;
>>>> -extern const uint64_t rss_flag;
>>>> -
>>>> -#endif /* _ODP_INLINES */
>>>> -/*
>>>> - * NOTE: These functions are inlined because they are on a performance
>>>> hot path.
>>>> - * As we can't force the application to directly include DPDK headers
>>>> we have to
>>>> - * export these fields through constants calculated compile time in
>>>> - * odp_packet.c, where we can see the DPDK definitions.
>>>> - *
>>>> - */
>>>> -_STATIC uint32_t odp_packet_len(odp_packet_t pkt)
>>>> -{
>>>> -       return *(uint32_t *)(void *)((char *)pkt + pkt_len_offset);
>>>> -}
>>>> -
>>>> -_STATIC uint32_t odp_packet_seg_len(odp_packet_t pkt)
>>>> -{
>>>> -       return *(uint16_t *)(void *)((char *)pkt + seg_len_offset);
>>>> -}
>>>> -
>>>> -_STATIC void *odp_packet_user_area(odp_packet_t pkt)
>>>> -{
>>>> -       return (void *)((char *)pkt + udata_offset);
>>>> -}
>>>> -
>>>> -_STATIC uint32_t odp_packet_user_area_size(odp_packet_t pkt)
>>>> -{
>>>> -       return *(uint32_t *)(void *)((char *)pkt + udata_len_offset);
>>>> -}
>>>> -
>>>> -_STATIC void *odp_packet_data(odp_packet_t pkt)
>>>> -{
>>>> -       char **buf_addr = (char **)(void *)((char *)pkt +
>>>> buf_addr_offset);
>>>> -       uint16_t data_off = *(uint16_t *)(void *)((char *)pkt +
>>>> data_off_offset);
>>>> -
>>>> -       return (void *)(*buf_addr + data_off);
>>>> -}
>>>> -
>>>> -_STATIC uint32_t odp_packet_flow_hash(odp_packet_t pkt)
>>>> -{
>>>> -       return *(uint32_t *)(void *)((char *)pkt + rss_offset);
>>>> -}
>>>> -
>>>> -_STATIC void odp_packet_flow_hash_set(odp_packet_t pkt, uint32_t
>>>> flow_hash)
>>>> -{
>>>> -       *(uint32_t *)(void *)((char *)pkt + rss_offset) = flow_hash;
>>>> -       *(uint64_t *)(void *)((char *)pkt + ol_flags_offset) |=
>>>> rss_flag;
>>>> -}
>>>> -
>>>> -#ifdef __cplusplus
>>>> -}
>>>> -#endif
>>>> -
>>>> -#endif /* ODP_PLAT_PACKET_INLINES_H_ */
>>>> diff --git a/platform/linux-dpdk/include/odp/api/plat/inlines.h.in
>>>> b/platform/linux-dpdk/include/odp/api/plat/inlines.h.in
>>>> new file mode 100644
>>>> index 0000000..43e542b
>>>> --- /dev/null
>>>> +++ b/platform/linux-dpdk/include/odp/api/plat/inlines.h.in
>>>> @@ -0,0 +1,33 @@
>>>> +/* Copyright (c) 2016, Linaro Limited
>>>> + * All rights reserved.
>>>> + *
>>>> + * SPDX-License-Identifier: BSD-3-Clause
>>>> + */
>>>> +
>>>> +/**
>>>> + * @file
>>>> + *
>>>> + * ODP packet inline functions
>>>> + */
>>>> +
>>>> +#ifndef ODP_PLAT_INLINES_H_
>>>> +#define ODP_PLAT_INLINES_H_
>>>> +
>>>> +#ifdef __cplusplus
>>>> +extern "C" {
>>>> +#endif
>>>> +
>>>> +#define @_ODP_INLINES@
>>>> +
>>>> +#ifdef _ODP_INLINES
>>>> +#define _STATIC static inline
>>>> +#else
>>>> +#define _STATIC
>>>> +#endif
>>>> +
>>>> +#ifdef __cplusplus
>>>> +}
>>>> +#endif
>>>> +
>>>> +
>>>> +#endif /* ODP_PLAT_INLINES_H_ */
>>>> diff --git a/platform/linux-dpdk/include/odp/api/plat/packet_flags_inlines.h
>>>> b/platform/linux-dpdk/include/odp/api/plat/packet_flags_inlines.h
>>>> new file mode 100644
>>>> index 0000000..7d2464e
>>>> --- /dev/null
>>>> +++ b/platform/linux-dpdk/include/odp/api/plat/packet_flags_inlines.h
>>>> @@ -0,0 +1,44 @@
>>>> +/* Copyright (c) 2016, Linaro Limited
>>>> + * All rights reserved.
>>>> + *
>>>> + * SPDX-License-Identifier: BSD-3-Clause
>>>> + */
>>>> +
>>>> +/**
>>>> + * @file
>>>> + *
>>>> + * ODP packet flags inline functions
>>>> + */
>>>> +
>>>> +#ifndef ODP_PLAT_PACKET_FLAGS_INLINES_H_
>>>> +#define ODP_PLAT_PACKET_FLAGS_INLINES_H_
>>>> +
>>>> +#ifdef __cplusplus
>>>> +extern "C" {
>>>> +#endif
>>>> +
>>>> +extern const unsigned int ol_flags_offset;
>>>> +extern const uint64_t rss_flag;
>>>> +
>>>> +/*
>>>> + * NOTE: These functions are inlined because they are on a performance
>>>> hot path.
>>>> + * As we can't force the application to directly include DPDK headers
>>>> we have to
>>>> + * export these fields through constants calculated compile time in
>>>> + * odp_packet.c, where we can see the DPDK definitions.
>>>> + *
>>>> + */
>>>> +_STATIC int odp_packet_has_flow_hash(odp_packet_t pkt)
>>>> +{
>>>> +       return *(uint64_t *)((char *)pkt + ol_flags_offset) & rss_flag;
>>>> +}
>>>> +
>>>> +_STATIC void odp_packet_has_flow_hash_clr(odp_packet_t pkt)
>>>> +{
>>>> +       *(uint64_t *)((char *)pkt + ol_flags_offset) &= ~rss_flag;
>>>> +}
>>>> +
>>>> +#ifdef __cplusplus
>>>> +}
>>>> +#endif
>>>> +
>>>> +#endif /* ODP_PLAT_PACKET_FLAGS_INLINES_H_ */
>>>> diff --git a/platform/linux-dpdk/include/odp/api/plat/packet_inlines.h
>>>> b/platform/linux-dpdk/include/odp/api/plat/packet_inlines.h
>>>> new file mode 100644
>>>> index 0000000..cd403bf
>>>> --- /dev/null
>>>> +++ b/platform/linux-dpdk/include/odp/api/plat/packet_inlines.h
>>>> @@ -0,0 +1,84 @@
>>>> +/* Copyright (c) 2016, Linaro Limited
>>>> + * All rights reserved.
>>>> + *
>>>> + * SPDX-License-Identifier: BSD-3-Clause
>>>> + */
>>>> +
>>>> +/**
>>>> + * @file
>>>> + *
>>>> + * ODP packet inline functions
>>>> + */
>>>> +
>>>> +#ifndef ODP_PLAT_PACKET_INLINES_H_
>>>> +#define ODP_PLAT_PACKET_INLINES_H_
>>>> +
>>>> +#ifdef __cplusplus
>>>> +extern "C" {
>>>> +#endif
>>>> +
>>>> +#ifdef _ODP_INLINES
>>>> +
>>>> +extern const unsigned int buf_addr_offset;
>>>> +extern const unsigned int data_off_offset;
>>>> +extern const unsigned int pkt_len_offset;
>>>> +extern const unsigned int seg_len_offset;
>>>> +extern const unsigned int udata_len_offset;
>>>> +extern const unsigned int udata_offset;
>>>> +extern const unsigned int rss_offset;
>>>> +extern const unsigned int ol_flags_offset;
>>>> +extern const uint64_t rss_flag;
>>>> +
>>>> +#endif /* _ODP_INLINES */
>>>> +/*
>>>> + * NOTE: These functions are inlined because they are on a performance
>>>> hot path.
>>>> + * As we can't force the application to directly include DPDK headers
>>>> we have to
>>>> + * export these fields through constants calculated compile time in
>>>> + * odp_packet.c, where we can see the DPDK definitions.
>>>> + *
>>>> + */
>>>> +_STATIC uint32_t odp_packet_len(odp_packet_t pkt)
>>>> +{
>>>> +       return *(uint32_t *)(void *)((char *)pkt + pkt_len_offset);
>>>> +}
>>>> +
>>>> +_STATIC uint32_t odp_packet_seg_len(odp_packet_t pkt)
>>>> +{
>>>> +       return *(uint16_t *)(void *)((char *)pkt + seg_len_offset);
>>>> +}
>>>> +
>>>> +_STATIC void *odp_packet_user_area(odp_packet_t pkt)
>>>> +{
>>>> +       return (void *)((char *)pkt + udata_offset);
>>>> +}
>>>> +
>>>> +_STATIC uint32_t odp_packet_user_area_size(odp_packet_t pkt)
>>>> +{
>>>> +       return *(uint32_t *)(void *)((char *)pkt + udata_len_offset);
>>>> +}
>>>> +
>>>> +_STATIC void *odp_packet_data(odp_packet_t pkt)
>>>> +{
>>>> +       char **buf_addr = (char **)(void *)((char *)pkt +
>>>> buf_addr_offset);
>>>> +       uint16_t data_off =
>>>> +               *(uint16_t *)(void *)((char *)pkt + data_off_offset);
>>>> +
>>>> +       return (void *)(*buf_addr + data_off);
>>>> +}
>>>> +
>>>> +_STATIC uint32_t odp_packet_flow_hash(odp_packet_t pkt)
>>>> +{
>>>> +       return *(uint32_t *)(void *)((char *)pkt + rss_offset);
>>>> +}
>>>> +
>>>> +_STATIC void odp_packet_flow_hash_set(odp_packet_t pkt, uint32_t
>>>> flow_hash)
>>>> +{
>>>> +       *(uint32_t *)(void *)((char *)pkt + rss_offset) = flow_hash;
>>>> +       *(uint64_t *)(void *)((char *)pkt + ol_flags_offset) |=
>>>> rss_flag;
>>>> +}
>>>> +
>>>> +#ifdef __cplusplus
>>>> +}
>>>> +#endif
>>>> +
>>>> +#endif /* ODP_PLAT_PACKET_INLINES_H_ */
>>>> diff --git a/platform/linux-dpdk/m4/configure.m4
>>>> b/platform/linux-dpdk/m4/configure.m4
>>>> index 730b6e8..6807de4 100644
>>>> --- a/platform/linux-dpdk/m4/configure.m4
>>>> +++ b/platform/linux-dpdk/m4/configure.m4
>>>> @@ -75,5 +75,5 @@ LDFLAGS=$OLD_LDFLAGS
>>>>  CPPFLAGS=$OLD_CPPFLAGS
>>>>
>>>>  AC_CONFIG_FILES([platform/linux-dpdk/Makefile
>>>> -                platform/linux-dpdk/include/odp/api/inlines.h])
>>>> +                platform/linux-dpdk/include/odp/api/plat/inlines.h])
>>>>
>>>> diff --git a/platform/linux-dpdk/odp_packet.c
>>>> b/platform/linux-dpdk/odp_packet.c
>>>> index b536281..8bd7379 100644
>>>> --- a/platform/linux-dpdk/odp_packet.c
>>>> +++ b/platform/linux-dpdk/odp_packet.c
>>>> @@ -62,7 +62,7 @@ ODP_STATIC_ASSERT(sizeof(dummy.ol_flags) ==
>>>> sizeof(uint64_t),
>>>>                   "ol_flags should be uint64_t");
>>>>
>>>>  #ifndef _ODP_INLINES
>>>> -#include <odp/api/packet_inlines.h>
>>>> +#include <odp/api/plat/packet_inlines.h>
>>>>  #endif
>>>>
>>>>  /*
>>>> diff --git a/platform/linux-dpdk/odp_packet_flags.c
>>>> b/platform/linux-dpdk/odp_packet_flags.c
>>>> index 1c3b503..10d4097 100644
>>>> --- a/platform/linux-dpdk/odp_packet_flags.c
>>>> +++ b/platform/linux-dpdk/odp_packet_flags.c
>>>> @@ -8,7 +8,7 @@
>>>>  #include <odp_packet_internal.h>
>>>>
>>>>  #ifndef _ODP_INLINES
>>>> -#include <odp/api/packet_flags_inlines.h>
>>>> +#include <odp/api/plat/packet_flags_inlines.h>
>>>>  #endif
>>>>
>>>>  #define retflag(pkt, x) do {                             \
>>>> --
>>>> 2.7.4
>>>>
>>>> _______________________________________________
>>>> lng-odp-dpdk mailing list
>>>> lng-odp-dpdk@lists.linaro.org
>>>> https://lists.linaro.org/mailman/listinfo/lng-odp-dpdk
>>>>
>>>
>>>
>>
>
Mike Holmes Sept. 2, 2016, 4:26 p.m. | #5
On 2 September 2016 at 12:15, Bill Fischofer <bill.fischofer@linaro.org>
wrote:

> On Fri, Sep 2, 2016 at 11:11 AM, Krishna Garapati <
> balakrishna.garapati@linaro.org> wrote:
>
> >
> >
> > On 2 September 2016 at 17:36, Bill Fischofer <bill.fischofer@linaro.org>
> > wrote:
> >
> >> I see no such checkpatch warnings. As I've discussed with Mike part 2
> >> generates some spurious warnings relating to the symbolic links, but
> part 1
> >> is completely clean for me.
> >>
> >> Are you applying with git am, or using patch directly?
> >>
> > I use git am and the build is fine. When I do checkpatch directly on the
> > downloaded patch I see these warning/error messages.
>

The downloaded "patch" is an mbox file with email headers etc not a patch
isn't it ?
It does depend how you extract the patches, but git am applies patches form
a mailbox, not patches


> >
> >
> I'm not sure what to say. Do you do this with other patches and see
> different behavior? Reason I ask is there haven't been a lot of "external"
> patches posted to odp-dpdk of late. Do you see the same difference for the
> similar patch series I posted against odp-linux?
>
>
> > /Krishna
> >
> >>
> >> On Fri, Sep 2, 2016 at 8:40 AM, Krishna Garapati <
> >> balakrishna.garapati@linaro.org> wrote:
> >>
> >>> checkpatch output
> >>>
> >>> WARNING: Possible unwrapped commit description (prefer a maximum 75
> >>> chars per line)
> >>> #44:
> >>> VG8gZmFjaWxpdGF0ZSBpbnRlZ3JhdGlvbiB3aXRoIG9kcC1saW51eCwgbW92
> >>> ZSB0aGUgY29uZGl0
> >>>
> >>> ERROR: Does not appear to be a unified-diff format patch
> >>>
> >>> total: 1 errors, 1 warnings, 0 checks, 0 lines checked
> >>>
> >>> /Krishna
> >>>
> >>>
> >>> On 31 August 2016 at 04:08, Bill Fischofer <bill.fischofer@linaro.org>
> >>> wrote:
> >>>
> >>>> To facilitate integration with odp-linux, move the conditional inline
> >>>> files associated with ABI support from include/odp/api to
> >>>> include/odp/api/plat since these are platform-specific optimizations.
> >>>> Note that this also moves the .gitignore into the platform/linux-dpdk
> >>>> directory to avoid conflicts with other platforms sharing the main
> >>>> .gitignore file.
> >>>>
> >>>> Suggested by: Zoltan Kiss <zoltan.kiss@schaman.hu>
> >>>>
> >>>> Signed-off-by: Bill Fischofer <bill.fischofer@linaro.org>
> >>>> ---
> >>>>  .gitignore                                         |  1 -
> >>>>  platform/linux-dpdk/.gitignore                     |  1 +
> >>>>  platform/linux-dpdk/Makefile.am                    |  7 +-
> >>>>  platform/linux-dpdk/include/odp/api/inlines.h.in   | 33 ---------
> >>>>  platform/linux-dpdk/include/odp/api/packet.h       |  4 +-
> >>>>  platform/linux-dpdk/include/odp/api/packet_flags.h |  4 +-
> >>>>  .../include/odp/api/packet_flags_inlines.h         | 44 ------------
> >>>>  .../linux-dpdk/include/odp/api/packet_inlines.h    | 83
> >>>> ---------------------
> >>>>  .../linux-dpdk/include/odp/api/plat/inlines.h.in   | 33 +++++++++
> >>>>  .../include/odp/api/plat/packet_flags_inlines.h    | 44 ++++++++++++
> >>>>  .../include/odp/api/plat/packet_inlines.h          | 84
> >>>> ++++++++++++++++++++++
> >>>>  platform/linux-dpdk/m4/configure.m4                |  2 +-
> >>>>  platform/linux-dpdk/odp_packet.c                   |  2 +-
> >>>>  platform/linux-dpdk/odp_packet_flags.c             |  2 +-
> >>>>  14 files changed, 172 insertions(+), 172 deletions(-)
> >>>>  create mode 100644 platform/linux-dpdk/.gitignore
> >>>>  delete mode 100644 platform/linux-dpdk/include/odp/api/inlines.h.in
> >>>>  delete mode 100644 platform/linux-dpdk/include/od
> >>>> p/api/packet_flags_inlines.h
> >>>>  delete mode 100644 platform/linux-dpdk/include/od
> >>>> p/api/packet_inlines.h
> >>>>  create mode 100644 platform/linux-dpdk/include/odp/api/plat/
> >>>> inlines.h.in
> >>>>  create mode 100644 platform/linux-dpdk/include/od
> >>>> p/api/plat/packet_flags_inlines.h
> >>>>  create mode 100644 platform/linux-dpdk/include/od
> >>>> p/api/plat/packet_inlines.h
> >>>>
> >>>> diff --git a/.gitignore b/.gitignore
> >>>> index bcc556c..d4e7d02 100644
> >>>> --- a/.gitignore
> >>>> +++ b/.gitignore
> >>>> @@ -41,6 +41,5 @@ ltmain.sh
> >>>>  m4/*.m4
> >>>>  missing
> >>>>  pkgconfig/libodp*.pc
> >>>> -platform/linux-dpdk/include/odp/api/inlines.h
> >>>>  tags
> >>>>  test-driver
> >>>> diff --git a/platform/linux-dpdk/.gitignore
> >>>> b/platform/linux-dpdk/.gitignore
> >>>> new file mode 100644
> >>>> index 0000000..654e50c
> >>>> --- /dev/null
> >>>> +++ b/platform/linux-dpdk/.gitignore
> >>>> @@ -0,0 +1 @@
> >>>> +include/odp/api/plat/inlines.h
> >>>> \ No newline at end of file
> >>>> diff --git a/platform/linux-dpdk/Makefile.am
> >>>> b/platform/linux-dpdk/Makefile.am
> >>>> index d4e9c79..4d87345 100644
> >>>> --- a/platform/linux-dpdk/Makefile.am
> >>>> +++ b/platform/linux-dpdk/Makefile.am
> >>>> @@ -47,11 +47,8 @@ odpapiinclude_HEADERS = \
> >>>>                   $(srcdir)/include/odp/api/hash.h \
> >>>>                   $(srcdir)/include/odp/api/hints.h \
> >>>>                   $(srcdir)/include/odp/api/init.h \
> >>>> -                 $(builddir)/include/odp/api/inlines.h \
> >>>>                   $(srcdir)/include/odp/api/packet_flags.h \
> >>>> -                 $(srcdir)/include/odp/api/packet_flags_inlines.h \
> >>>>                   $(srcdir)/include/odp/api/packet.h \
> >>>> -                 $(srcdir)/include/odp/api/packet_inlines.h \
> >>>>                   $(srcdir)/include/odp/api/packet_io.h \
> >>>>                   $(srcdir)/include/odp/api/packet_io_stats.h \
> >>>>                   $(srcdir)/include/odp/api/pool.h \
> >>>> @@ -90,8 +87,10 @@ odpapiplatinclude_HEADERS = \
> >>>>                   $(srcdir)/include/odp/api/plat/crypto_types.h \
> >>>>                   $(srcdir)/include/odp/api/plat/event_types.h \
> >>>>                   $(srcdir)/include/odp/api/plat/init_types.h \
> >>>> -                 $(srcdir)/include/odp/api/plat/packet_types.h \
> >>>> +                 $(srcdir)/include/odp/api/
> plat/packet_flags_inlines.h
> >>>> \
> >>>> +                 $(srcdir)/include/odp/api/plat/packet_inlines.h \
> >>>>                   $(srcdir)/include/odp/api/plat/packet_io_types.h \
> >>>> +                 $(srcdir)/include/odp/api/plat/packet_types.h \
> >>>>                   $(srcdir)/include/odp/api/plat/pool_types.h \
> >>>>                   $(srcdir)/include/odp/api/plat/queue_types.h \
> >>>>                   $(srcdir)/include/odp/api/plat/rwlock_types.h \
> >>>> diff --git a/platform/linux-dpdk/include/odp/api/inlines.h.in
> >>>> b/platform/linux-dpdk/include/odp/api/inlines.h.in
> >>>> deleted file mode 100644
> >>>> index 43e542b..0000000
> >>>> --- a/platform/linux-dpdk/include/odp/api/inlines.h.in
> >>>> +++ /dev/null
> >>>> @@ -1,33 +0,0 @@
> >>>> -/* Copyright (c) 2016, Linaro Limited
> >>>> - * All rights reserved.
> >>>> - *
> >>>> - * SPDX-License-Identifier: BSD-3-Clause
> >>>> - */
> >>>> -
> >>>> -/**
> >>>> - * @file
> >>>> - *
> >>>> - * ODP packet inline functions
> >>>> - */
> >>>> -
> >>>> -#ifndef ODP_PLAT_INLINES_H_
> >>>> -#define ODP_PLAT_INLINES_H_
> >>>> -
> >>>> -#ifdef __cplusplus
> >>>> -extern "C" {
> >>>> -#endif
> >>>> -
> >>>> -#define @_ODP_INLINES@
> >>>> -
> >>>> -#ifdef _ODP_INLINES
> >>>> -#define _STATIC static inline
> >>>> -#else
> >>>> -#define _STATIC
> >>>> -#endif
> >>>> -
> >>>> -#ifdef __cplusplus
> >>>> -}
> >>>> -#endif
> >>>> -
> >>>> -
> >>>> -#endif /* ODP_PLAT_INLINES_H_ */
> >>>> diff --git a/platform/linux-dpdk/include/odp/api/packet.h
> >>>> b/platform/linux-dpdk/include/odp/api/packet.h
> >>>> index 61543fa..f9123d8 100644
> >>>> --- a/platform/linux-dpdk/include/odp/api/packet.h
> >>>> +++ b/platform/linux-dpdk/include/odp/api/packet.h
> >>>> @@ -28,9 +28,9 @@ extern "C" {
> >>>>   *  @{
> >>>>   */
> >>>>
> >>>> -#include <odp/api/inlines.h>
> >>>> +#include <odp/api/plat/inlines.h>
> >>>>  #ifdef _ODP_INLINES
> >>>> -#include <odp/api/packet_inlines.h>
> >>>> +#include <odp/api/plat/packet_inlines.h>
> >>>>  #endif
> >>>>
> >>>>  /**
> >>>> diff --git a/platform/linux-dpdk/include/odp/api/packet_flags.h
> >>>> b/platform/linux-dpdk/include/odp/api/packet_flags.h
> >>>> index 00dd845..b6ae9f8 100644
> >>>> --- a/platform/linux-dpdk/include/odp/api/packet_flags.h
> >>>> +++ b/platform/linux-dpdk/include/odp/api/packet_flags.h
> >>>> @@ -28,9 +28,9 @@ extern "C" {
> >>>>   *  @{
> >>>>   */
> >>>>
> >>>> -#include <odp/api/inlines.h>
> >>>> +#include <odp/api/plat/inlines.h>
> >>>>  #ifdef _ODP_INLINES
> >>>> -#include <odp/api/packet_flags_inlines.h>
> >>>> +#include <odp/api/plat/packet_flags_inlines.h>
> >>>>  #endif
> >>>>
> >>>>  /**
> >>>> diff --git a/platform/linux-dpdk/include/
> odp/api/packet_flags_inlines.h
> >>>> b/platform/linux-dpdk/include/odp/api/packet_flags_inlines.h
> >>>> deleted file mode 100644
> >>>> index 7d2464e..0000000
> >>>> --- a/platform/linux-dpdk/include/odp/api/packet_flags_inlines.h
> >>>> +++ /dev/null
> >>>> @@ -1,44 +0,0 @@
> >>>> -/* Copyright (c) 2016, Linaro Limited
> >>>> - * All rights reserved.
> >>>> - *
> >>>> - * SPDX-License-Identifier: BSD-3-Clause
> >>>> - */
> >>>> -
> >>>> -/**
> >>>> - * @file
> >>>> - *
> >>>> - * ODP packet flags inline functions
> >>>> - */
> >>>> -
> >>>> -#ifndef ODP_PLAT_PACKET_FLAGS_INLINES_H_
> >>>> -#define ODP_PLAT_PACKET_FLAGS_INLINES_H_
> >>>> -
> >>>> -#ifdef __cplusplus
> >>>> -extern "C" {
> >>>> -#endif
> >>>> -
> >>>> -extern const unsigned int ol_flags_offset;
> >>>> -extern const uint64_t rss_flag;
> >>>> -
> >>>> -/*
> >>>> - * NOTE: These functions are inlined because they are on a
> performance
> >>>> hot path.
> >>>> - * As we can't force the application to directly include DPDK headers
> >>>> we have to
> >>>> - * export these fields through constants calculated compile time in
> >>>> - * odp_packet.c, where we can see the DPDK definitions.
> >>>> - *
> >>>> - */
> >>>> -_STATIC int odp_packet_has_flow_hash(odp_packet_t pkt)
> >>>> -{
> >>>> -       return *(uint64_t *)((char *)pkt + ol_flags_offset) &
> rss_flag;
> >>>> -}
> >>>> -
> >>>> -_STATIC void odp_packet_has_flow_hash_clr(odp_packet_t pkt)
> >>>> -{
> >>>> -       *(uint64_t *)((char *)pkt + ol_flags_offset) &= ~rss_flag;
> >>>> -}
> >>>> -
> >>>> -#ifdef __cplusplus
> >>>> -}
> >>>> -#endif
> >>>> -
> >>>> -#endif /* ODP_PLAT_PACKET_FLAGS_INLINES_H_ */
> >>>> diff --git a/platform/linux-dpdk/include/odp/api/packet_inlines.h
> >>>> b/platform/linux-dpdk/include/odp/api/packet_inlines.h
> >>>> deleted file mode 100644
> >>>> index 444919d..0000000
> >>>> --- a/platform/linux-dpdk/include/odp/api/packet_inlines.h
> >>>> +++ /dev/null
> >>>> @@ -1,83 +0,0 @@
> >>>> -/* Copyright (c) 2016, Linaro Limited
> >>>> - * All rights reserved.
> >>>> - *
> >>>> - * SPDX-License-Identifier: BSD-3-Clause
> >>>> - */
> >>>> -
> >>>> -/**
> >>>> - * @file
> >>>> - *
> >>>> - * ODP packet inline functions
> >>>> - */
> >>>> -
> >>>> -#ifndef ODP_PLAT_PACKET_INLINES_H_
> >>>> -#define ODP_PLAT_PACKET_INLINES_H_
> >>>> -
> >>>> -#ifdef __cplusplus
> >>>> -extern "C" {
> >>>> -#endif
> >>>> -
> >>>> -#ifdef _ODP_INLINES
> >>>> -
> >>>> -extern const unsigned int buf_addr_offset;
> >>>> -extern const unsigned int data_off_offset;
> >>>> -extern const unsigned int pkt_len_offset;
> >>>> -extern const unsigned int seg_len_offset;
> >>>> -extern const unsigned int udata_len_offset;
> >>>> -extern const unsigned int udata_offset;
> >>>> -extern const unsigned int rss_offset;
> >>>> -extern const unsigned int ol_flags_offset;
> >>>> -extern const uint64_t rss_flag;
> >>>> -
> >>>> -#endif /* _ODP_INLINES */
> >>>> -/*
> >>>> - * NOTE: These functions are inlined because they are on a
> performance
> >>>> hot path.
> >>>> - * As we can't force the application to directly include DPDK headers
> >>>> we have to
> >>>> - * export these fields through constants calculated compile time in
> >>>> - * odp_packet.c, where we can see the DPDK definitions.
> >>>> - *
> >>>> - */
> >>>> -_STATIC uint32_t odp_packet_len(odp_packet_t pkt)
> >>>> -{
> >>>> -       return *(uint32_t *)(void *)((char *)pkt + pkt_len_offset);
> >>>> -}
> >>>> -
> >>>> -_STATIC uint32_t odp_packet_seg_len(odp_packet_t pkt)
> >>>> -{
> >>>> -       return *(uint16_t *)(void *)((char *)pkt + seg_len_offset);
> >>>> -}
> >>>> -
> >>>> -_STATIC void *odp_packet_user_area(odp_packet_t pkt)
> >>>> -{
> >>>> -       return (void *)((char *)pkt + udata_offset);
> >>>> -}
> >>>> -
> >>>> -_STATIC uint32_t odp_packet_user_area_size(odp_packet_t pkt)
> >>>> -{
> >>>> -       return *(uint32_t *)(void *)((char *)pkt + udata_len_offset);
> >>>> -}
> >>>> -
> >>>> -_STATIC void *odp_packet_data(odp_packet_t pkt)
> >>>> -{
> >>>> -       char **buf_addr = (char **)(void *)((char *)pkt +
> >>>> buf_addr_offset);
> >>>> -       uint16_t data_off = *(uint16_t *)(void *)((char *)pkt +
> >>>> data_off_offset);
> >>>> -
> >>>> -       return (void *)(*buf_addr + data_off);
> >>>> -}
> >>>> -
> >>>> -_STATIC uint32_t odp_packet_flow_hash(odp_packet_t pkt)
> >>>> -{
> >>>> -       return *(uint32_t *)(void *)((char *)pkt + rss_offset);
> >>>> -}
> >>>> -
> >>>> -_STATIC void odp_packet_flow_hash_set(odp_packet_t pkt, uint32_t
> >>>> flow_hash)
> >>>> -{
> >>>> -       *(uint32_t *)(void *)((char *)pkt + rss_offset) = flow_hash;
> >>>> -       *(uint64_t *)(void *)((char *)pkt + ol_flags_offset) |=
> >>>> rss_flag;
> >>>> -}
> >>>> -
> >>>> -#ifdef __cplusplus
> >>>> -}
> >>>> -#endif
> >>>> -
> >>>> -#endif /* ODP_PLAT_PACKET_INLINES_H_ */
> >>>> diff --git a/platform/linux-dpdk/include/odp/api/plat/inlines.h.in
> >>>> b/platform/linux-dpdk/include/odp/api/plat/inlines.h.in
> >>>> new file mode 100644
> >>>> index 0000000..43e542b
> >>>> --- /dev/null
> >>>> +++ b/platform/linux-dpdk/include/odp/api/plat/inlines.h.in
> >>>> @@ -0,0 +1,33 @@
> >>>> +/* Copyright (c) 2016, Linaro Limited
> >>>> + * All rights reserved.
> >>>> + *
> >>>> + * SPDX-License-Identifier: BSD-3-Clause
> >>>> + */
> >>>> +
> >>>> +/**
> >>>> + * @file
> >>>> + *
> >>>> + * ODP packet inline functions
> >>>> + */
> >>>> +
> >>>> +#ifndef ODP_PLAT_INLINES_H_
> >>>> +#define ODP_PLAT_INLINES_H_
> >>>> +
> >>>> +#ifdef __cplusplus
> >>>> +extern "C" {
> >>>> +#endif
> >>>> +
> >>>> +#define @_ODP_INLINES@
> >>>> +
> >>>> +#ifdef _ODP_INLINES
> >>>> +#define _STATIC static inline
> >>>> +#else
> >>>> +#define _STATIC
> >>>> +#endif
> >>>> +
> >>>> +#ifdef __cplusplus
> >>>> +}
> >>>> +#endif
> >>>> +
> >>>> +
> >>>> +#endif /* ODP_PLAT_INLINES_H_ */
> >>>> diff --git a/platform/linux-dpdk/include/odp/api/plat/packet_flags_
> inlines.h
> >>>> b/platform/linux-dpdk/include/odp/api/plat/packet_flags_inlines.h
> >>>> new file mode 100644
> >>>> index 0000000..7d2464e
> >>>> --- /dev/null
> >>>> +++ b/platform/linux-dpdk/include/odp/api/plat/packet_flags_inlines.h
> >>>> @@ -0,0 +1,44 @@
> >>>> +/* Copyright (c) 2016, Linaro Limited
> >>>> + * All rights reserved.
> >>>> + *
> >>>> + * SPDX-License-Identifier: BSD-3-Clause
> >>>> + */
> >>>> +
> >>>> +/**
> >>>> + * @file
> >>>> + *
> >>>> + * ODP packet flags inline functions
> >>>> + */
> >>>> +
> >>>> +#ifndef ODP_PLAT_PACKET_FLAGS_INLINES_H_
> >>>> +#define ODP_PLAT_PACKET_FLAGS_INLINES_H_
> >>>> +
> >>>> +#ifdef __cplusplus
> >>>> +extern "C" {
> >>>> +#endif
> >>>> +
> >>>> +extern const unsigned int ol_flags_offset;
> >>>> +extern const uint64_t rss_flag;
> >>>> +
> >>>> +/*
> >>>> + * NOTE: These functions are inlined because they are on a
> performance
> >>>> hot path.
> >>>> + * As we can't force the application to directly include DPDK headers
> >>>> we have to
> >>>> + * export these fields through constants calculated compile time in
> >>>> + * odp_packet.c, where we can see the DPDK definitions.
> >>>> + *
> >>>> + */
> >>>> +_STATIC int odp_packet_has_flow_hash(odp_packet_t pkt)
> >>>> +{
> >>>> +       return *(uint64_t *)((char *)pkt + ol_flags_offset) &
> rss_flag;
> >>>> +}
> >>>> +
> >>>> +_STATIC void odp_packet_has_flow_hash_clr(odp_packet_t pkt)
> >>>> +{
> >>>> +       *(uint64_t *)((char *)pkt + ol_flags_offset) &= ~rss_flag;
> >>>> +}
> >>>> +
> >>>> +#ifdef __cplusplus
> >>>> +}
> >>>> +#endif
> >>>> +
> >>>> +#endif /* ODP_PLAT_PACKET_FLAGS_INLINES_H_ */
> >>>> diff --git a/platform/linux-dpdk/include/
> odp/api/plat/packet_inlines.h
> >>>> b/platform/linux-dpdk/include/odp/api/plat/packet_inlines.h
> >>>> new file mode 100644
> >>>> index 0000000..cd403bf
> >>>> --- /dev/null
> >>>> +++ b/platform/linux-dpdk/include/odp/api/plat/packet_inlines.h
> >>>> @@ -0,0 +1,84 @@
> >>>> +/* Copyright (c) 2016, Linaro Limited
> >>>> + * All rights reserved.
> >>>> + *
> >>>> + * SPDX-License-Identifier: BSD-3-Clause
> >>>> + */
> >>>> +
> >>>> +/**
> >>>> + * @file
> >>>> + *
> >>>> + * ODP packet inline functions
> >>>> + */
> >>>> +
> >>>> +#ifndef ODP_PLAT_PACKET_INLINES_H_
> >>>> +#define ODP_PLAT_PACKET_INLINES_H_
> >>>> +
> >>>> +#ifdef __cplusplus
> >>>> +extern "C" {
> >>>> +#endif
> >>>> +
> >>>> +#ifdef _ODP_INLINES
> >>>> +
> >>>> +extern const unsigned int buf_addr_offset;
> >>>> +extern const unsigned int data_off_offset;
> >>>> +extern const unsigned int pkt_len_offset;
> >>>> +extern const unsigned int seg_len_offset;
> >>>> +extern const unsigned int udata_len_offset;
> >>>> +extern const unsigned int udata_offset;
> >>>> +extern const unsigned int rss_offset;
> >>>> +extern const unsigned int ol_flags_offset;
> >>>> +extern const uint64_t rss_flag;
> >>>> +
> >>>> +#endif /* _ODP_INLINES */
> >>>> +/*
> >>>> + * NOTE: These functions are inlined because they are on a
> performance
> >>>> hot path.
> >>>> + * As we can't force the application to directly include DPDK headers
> >>>> we have to
> >>>> + * export these fields through constants calculated compile time in
> >>>> + * odp_packet.c, where we can see the DPDK definitions.
> >>>> + *
> >>>> + */
> >>>> +_STATIC uint32_t odp_packet_len(odp_packet_t pkt)
> >>>> +{
> >>>> +       return *(uint32_t *)(void *)((char *)pkt + pkt_len_offset);
> >>>> +}
> >>>> +
> >>>> +_STATIC uint32_t odp_packet_seg_len(odp_packet_t pkt)
> >>>> +{
> >>>> +       return *(uint16_t *)(void *)((char *)pkt + seg_len_offset);
> >>>> +}
> >>>> +
> >>>> +_STATIC void *odp_packet_user_area(odp_packet_t pkt)
> >>>> +{
> >>>> +       return (void *)((char *)pkt + udata_offset);
> >>>> +}
> >>>> +
> >>>> +_STATIC uint32_t odp_packet_user_area_size(odp_packet_t pkt)
> >>>> +{
> >>>> +       return *(uint32_t *)(void *)((char *)pkt + udata_len_offset);
> >>>> +}
> >>>> +
> >>>> +_STATIC void *odp_packet_data(odp_packet_t pkt)
> >>>> +{
> >>>> +       char **buf_addr = (char **)(void *)((char *)pkt +
> >>>> buf_addr_offset);
> >>>> +       uint16_t data_off =
> >>>> +               *(uint16_t *)(void *)((char *)pkt + data_off_offset);
> >>>> +
> >>>> +       return (void *)(*buf_addr + data_off);
> >>>> +}
> >>>> +
> >>>> +_STATIC uint32_t odp_packet_flow_hash(odp_packet_t pkt)
> >>>> +{
> >>>> +       return *(uint32_t *)(void *)((char *)pkt + rss_offset);
> >>>> +}
> >>>> +
> >>>> +_STATIC void odp_packet_flow_hash_set(odp_packet_t pkt, uint32_t
> >>>> flow_hash)
> >>>> +{
> >>>> +       *(uint32_t *)(void *)((char *)pkt + rss_offset) = flow_hash;
> >>>> +       *(uint64_t *)(void *)((char *)pkt + ol_flags_offset) |=
> >>>> rss_flag;
> >>>> +}
> >>>> +
> >>>> +#ifdef __cplusplus
> >>>> +}
> >>>> +#endif
> >>>> +
> >>>> +#endif /* ODP_PLAT_PACKET_INLINES_H_ */
> >>>> diff --git a/platform/linux-dpdk/m4/configure.m4
> >>>> b/platform/linux-dpdk/m4/configure.m4
> >>>> index 730b6e8..6807de4 100644
> >>>> --- a/platform/linux-dpdk/m4/configure.m4
> >>>> +++ b/platform/linux-dpdk/m4/configure.m4
> >>>> @@ -75,5 +75,5 @@ LDFLAGS=$OLD_LDFLAGS
> >>>>  CPPFLAGS=$OLD_CPPFLAGS
> >>>>
> >>>>  AC_CONFIG_FILES([platform/linux-dpdk/Makefile
> >>>> -                platform/linux-dpdk/include/odp/api/inlines.h])
> >>>> +                platform/linux-dpdk/include/odp/api/plat/inlines.h])
> >>>>
> >>>> diff --git a/platform/linux-dpdk/odp_packet.c
> >>>> b/platform/linux-dpdk/odp_packet.c
> >>>> index b536281..8bd7379 100644
> >>>> --- a/platform/linux-dpdk/odp_packet.c
> >>>> +++ b/platform/linux-dpdk/odp_packet.c
> >>>> @@ -62,7 +62,7 @@ ODP_STATIC_ASSERT(sizeof(dummy.ol_flags) ==
> >>>> sizeof(uint64_t),
> >>>>                   "ol_flags should be uint64_t");
> >>>>
> >>>>  #ifndef _ODP_INLINES
> >>>> -#include <odp/api/packet_inlines.h>
> >>>> +#include <odp/api/plat/packet_inlines.h>
> >>>>  #endif
> >>>>
> >>>>  /*
> >>>> diff --git a/platform/linux-dpdk/odp_packet_flags.c
> >>>> b/platform/linux-dpdk/odp_packet_flags.c
> >>>> index 1c3b503..10d4097 100644
> >>>> --- a/platform/linux-dpdk/odp_packet_flags.c
> >>>> +++ b/platform/linux-dpdk/odp_packet_flags.c
> >>>> @@ -8,7 +8,7 @@
> >>>>  #include <odp_packet_internal.h>
> >>>>
> >>>>  #ifndef _ODP_INLINES
> >>>> -#include <odp/api/packet_flags_inlines.h>
> >>>> +#include <odp/api/plat/packet_flags_inlines.h>
> >>>>  #endif
> >>>>
> >>>>  #define retflag(pkt, x) do {                             \
> >>>> --
> >>>> 2.7.4
> >>>>
> >>>> _______________________________________________
> >>>> lng-odp-dpdk mailing list
> >>>> lng-odp-dpdk@lists.linaro.org
> >>>> https://lists.linaro.org/mailman/listinfo/lng-odp-dpdk
> >>>>
> >>>
> >>>
> >>
> >
> _______________________________________________
> lng-odp-dpdk mailing list
> lng-odp-dpdk@lists.linaro.org
> https://lists.linaro.org/mailman/listinfo/lng-odp-dpdk
>
Krishna Garapati Sept. 2, 2016, 4:43 p.m. | #6
On 2 September 2016 at 18:26, Mike Holmes <mike.holmes@linaro.org> wrote:

>
>
> On 2 September 2016 at 12:15, Bill Fischofer <bill.fischofer@linaro.org>
> wrote:
>
>> On Fri, Sep 2, 2016 at 11:11 AM, Krishna Garapati <
>> balakrishna.garapati@linaro.org> wrote:
>>
>> >
>> >
>> > On 2 September 2016 at 17:36, Bill Fischofer <bill.fischofer@linaro.org
>> >
>> > wrote:
>> >
>> >> I see no such checkpatch warnings. As I've discussed with Mike part 2
>> >> generates some spurious warnings relating to the symbolic links, but
>> part 1
>> >> is completely clean for me.
>> >>
>> >> Are you applying with git am, or using patch directly?
>> >>
>> > I use git am and the build is fine. When I do checkpatch directly on the
>> > downloaded patch I see these warning/error messages.
>>
>
> The downloaded "patch" is an mbox file with email headers etc not a patch
> isn't it ?
> It does depend how you extract the patches, but git am applies patches
> form a mailbox, not patches
>
Yes, you are right. It's my mistake.

/Krishna

>
>
>> >
>> >
>> I'm not sure what to say. Do you do this with other patches and see
>> different behavior? Reason I ask is there haven't been a lot of "external"
>> patches posted to odp-dpdk of late. Do you see the same difference for the
>> similar patch series I posted against odp-linux?
>>
>>
>> > /Krishna
>> >
>> >>
>> >> On Fri, Sep 2, 2016 at 8:40 AM, Krishna Garapati <
>> >> balakrishna.garapati@linaro.org> wrote:
>> >>
>> >>> checkpatch output
>> >>>
>> >>> WARNING: Possible unwrapped commit description (prefer a maximum 75
>> >>> chars per line)
>> >>> #44:
>> >>> VG8gZmFjaWxpdGF0ZSBpbnRlZ3JhdGlvbiB3aXRoIG9kcC1saW51eCwgbW92
>> >>> ZSB0aGUgY29uZGl0
>> >>>
>> >>> ERROR: Does not appear to be a unified-diff format patch
>> >>>
>> >>> total: 1 errors, 1 warnings, 0 checks, 0 lines checked
>> >>>
>> >>> /Krishna
>> >>>
>> >>>
>> >>> On 31 August 2016 at 04:08, Bill Fischofer <bill.fischofer@linaro.org
>> >
>> >>> wrote:
>> >>>
>> >>>> To facilitate integration with odp-linux, move the conditional inline
>> >>>> files associated with ABI support from include/odp/api to
>> >>>> include/odp/api/plat since these are platform-specific optimizations.
>> >>>> Note that this also moves the .gitignore into the platform/linux-dpdk
>> >>>> directory to avoid conflicts with other platforms sharing the main
>> >>>> .gitignore file.
>> >>>>
>> >>>> Suggested by: Zoltan Kiss <zoltan.kiss@schaman.hu>
>> >>>>
>> >>>> Signed-off-by: Bill Fischofer <bill.fischofer@linaro.org>
>> >>>> ---
>> >>>>  .gitignore                                         |  1 -
>> >>>>  platform/linux-dpdk/.gitignore                     |  1 +
>> >>>>  platform/linux-dpdk/Makefile.am                    |  7 +-
>> >>>>  platform/linux-dpdk/include/odp/api/inlines.h.in   | 33 ---------
>> >>>>  platform/linux-dpdk/include/odp/api/packet.h       |  4 +-
>> >>>>  platform/linux-dpdk/include/odp/api/packet_flags.h |  4 +-
>> >>>>  .../include/odp/api/packet_flags_inlines.h         | 44
>> ------------
>> >>>>  .../linux-dpdk/include/odp/api/packet_inlines.h    | 83
>> >>>> ---------------------
>> >>>>  .../linux-dpdk/include/odp/api/plat/inlines.h.in   | 33 +++++++++
>> >>>>  .../include/odp/api/plat/packet_flags_inlines.h    | 44
>> ++++++++++++
>> >>>>  .../include/odp/api/plat/packet_inlines.h          | 84
>> >>>> ++++++++++++++++++++++
>> >>>>  platform/linux-dpdk/m4/configure.m4                |  2 +-
>> >>>>  platform/linux-dpdk/odp_packet.c                   |  2 +-
>> >>>>  platform/linux-dpdk/odp_packet_flags.c             |  2 +-
>> >>>>  14 files changed, 172 insertions(+), 172 deletions(-)
>> >>>>  create mode 100644 platform/linux-dpdk/.gitignore
>> >>>>  delete mode 100644 platform/linux-dpdk/include/odp/api/inlines.h.in
>> >>>>  delete mode 100644 platform/linux-dpdk/include/od
>> >>>> p/api/packet_flags_inlines.h
>> >>>>  delete mode 100644 platform/linux-dpdk/include/od
>> >>>> p/api/packet_inlines.h
>> >>>>  create mode 100644 platform/linux-dpdk/include/odp/api/plat/
>> >>>> inlines.h.in
>> >>>>  create mode 100644 platform/linux-dpdk/include/od
>> >>>> p/api/plat/packet_flags_inlines.h
>> >>>>  create mode 100644 platform/linux-dpdk/include/od
>> >>>> p/api/plat/packet_inlines.h
>> >>>>
>> >>>> diff --git a/.gitignore b/.gitignore
>> >>>> index bcc556c..d4e7d02 100644
>> >>>> --- a/.gitignore
>> >>>> +++ b/.gitignore
>> >>>> @@ -41,6 +41,5 @@ ltmain.sh
>> >>>>  m4/*.m4
>> >>>>  missing
>> >>>>  pkgconfig/libodp*.pc
>> >>>> -platform/linux-dpdk/include/odp/api/inlines.h
>> >>>>  tags
>> >>>>  test-driver
>> >>>> diff --git a/platform/linux-dpdk/.gitignore
>> >>>> b/platform/linux-dpdk/.gitignore
>> >>>> new file mode 100644
>> >>>> index 0000000..654e50c
>> >>>> --- /dev/null
>> >>>> +++ b/platform/linux-dpdk/.gitignore
>> >>>> @@ -0,0 +1 @@
>> >>>> +include/odp/api/plat/inlines.h
>> >>>> \ No newline at end of file
>> >>>> diff --git a/platform/linux-dpdk/Makefile.am
>> >>>> b/platform/linux-dpdk/Makefile.am
>> >>>> index d4e9c79..4d87345 100644
>> >>>> --- a/platform/linux-dpdk/Makefile.am
>> >>>> +++ b/platform/linux-dpdk/Makefile.am
>> >>>> @@ -47,11 +47,8 @@ odpapiinclude_HEADERS = \
>> >>>>                   $(srcdir)/include/odp/api/hash.h \
>> >>>>                   $(srcdir)/include/odp/api/hints.h \
>> >>>>                   $(srcdir)/include/odp/api/init.h \
>> >>>> -                 $(builddir)/include/odp/api/inlines.h \
>> >>>>                   $(srcdir)/include/odp/api/packet_flags.h \
>> >>>> -                 $(srcdir)/include/odp/api/packet_flags_inlines.h \
>> >>>>                   $(srcdir)/include/odp/api/packet.h \
>> >>>> -                 $(srcdir)/include/odp/api/packet_inlines.h \
>> >>>>                   $(srcdir)/include/odp/api/packet_io.h \
>> >>>>                   $(srcdir)/include/odp/api/packet_io_stats.h \
>> >>>>                   $(srcdir)/include/odp/api/pool.h \
>> >>>> @@ -90,8 +87,10 @@ odpapiplatinclude_HEADERS = \
>> >>>>                   $(srcdir)/include/odp/api/plat/crypto_types.h \
>> >>>>                   $(srcdir)/include/odp/api/plat/event_types.h \
>> >>>>                   $(srcdir)/include/odp/api/plat/init_types.h \
>> >>>> -                 $(srcdir)/include/odp/api/plat/packet_types.h \
>> >>>> +                 $(srcdir)/include/odp/api/pla
>> t/packet_flags_inlines.h
>> >>>> \
>> >>>> +                 $(srcdir)/include/odp/api/plat/packet_inlines.h \
>> >>>>                   $(srcdir)/include/odp/api/plat/packet_io_types.h \
>> >>>> +                 $(srcdir)/include/odp/api/plat/packet_types.h \
>> >>>>                   $(srcdir)/include/odp/api/plat/pool_types.h \
>> >>>>                   $(srcdir)/include/odp/api/plat/queue_types.h \
>> >>>>                   $(srcdir)/include/odp/api/plat/rwlock_types.h \
>> >>>> diff --git a/platform/linux-dpdk/include/odp/api/inlines.h.in
>> >>>> b/platform/linux-dpdk/include/odp/api/inlines.h.in
>> >>>> deleted file mode 100644
>> >>>> index 43e542b..0000000
>> >>>> --- a/platform/linux-dpdk/include/odp/api/inlines.h.in
>> >>>> +++ /dev/null
>> >>>> @@ -1,33 +0,0 @@
>> >>>> -/* Copyright (c) 2016, Linaro Limited
>> >>>> - * All rights reserved.
>> >>>> - *
>> >>>> - * SPDX-License-Identifier: BSD-3-Clause
>> >>>> - */
>> >>>> -
>> >>>> -/**
>> >>>> - * @file
>> >>>> - *
>> >>>> - * ODP packet inline functions
>> >>>> - */
>> >>>> -
>> >>>> -#ifndef ODP_PLAT_INLINES_H_
>> >>>> -#define ODP_PLAT_INLINES_H_
>> >>>> -
>> >>>> -#ifdef __cplusplus
>> >>>> -extern "C" {
>> >>>> -#endif
>> >>>> -
>> >>>> -#define @_ODP_INLINES@
>> >>>> -
>> >>>> -#ifdef _ODP_INLINES
>> >>>> -#define _STATIC static inline
>> >>>> -#else
>> >>>> -#define _STATIC
>> >>>> -#endif
>> >>>> -
>> >>>> -#ifdef __cplusplus
>> >>>> -}
>> >>>> -#endif
>> >>>> -
>> >>>> -
>> >>>> -#endif /* ODP_PLAT_INLINES_H_ */
>> >>>> diff --git a/platform/linux-dpdk/include/odp/api/packet.h
>> >>>> b/platform/linux-dpdk/include/odp/api/packet.h
>> >>>> index 61543fa..f9123d8 100644
>> >>>> --- a/platform/linux-dpdk/include/odp/api/packet.h
>> >>>> +++ b/platform/linux-dpdk/include/odp/api/packet.h
>> >>>> @@ -28,9 +28,9 @@ extern "C" {
>> >>>>   *  @{
>> >>>>   */
>> >>>>
>> >>>> -#include <odp/api/inlines.h>
>> >>>> +#include <odp/api/plat/inlines.h>
>> >>>>  #ifdef _ODP_INLINES
>> >>>> -#include <odp/api/packet_inlines.h>
>> >>>> +#include <odp/api/plat/packet_inlines.h>
>> >>>>  #endif
>> >>>>
>> >>>>  /**
>> >>>> diff --git a/platform/linux-dpdk/include/odp/api/packet_flags.h
>> >>>> b/platform/linux-dpdk/include/odp/api/packet_flags.h
>> >>>> index 00dd845..b6ae9f8 100644
>> >>>> --- a/platform/linux-dpdk/include/odp/api/packet_flags.h
>> >>>> +++ b/platform/linux-dpdk/include/odp/api/packet_flags.h
>> >>>> @@ -28,9 +28,9 @@ extern "C" {
>> >>>>   *  @{
>> >>>>   */
>> >>>>
>> >>>> -#include <odp/api/inlines.h>
>> >>>> +#include <odp/api/plat/inlines.h>
>> >>>>  #ifdef _ODP_INLINES
>> >>>> -#include <odp/api/packet_flags_inlines.h>
>> >>>> +#include <odp/api/plat/packet_flags_inlines.h>
>> >>>>  #endif
>> >>>>
>> >>>>  /**
>> >>>> diff --git a/platform/linux-dpdk/include/
>> odp/api/packet_flags_inlines.h
>> >>>> b/platform/linux-dpdk/include/odp/api/packet_flags_inlines.h
>> >>>> deleted file mode 100644
>> >>>> index 7d2464e..0000000
>> >>>> --- a/platform/linux-dpdk/include/odp/api/packet_flags_inlines.h
>> >>>> +++ /dev/null
>> >>>> @@ -1,44 +0,0 @@
>> >>>> -/* Copyright (c) 2016, Linaro Limited
>> >>>> - * All rights reserved.
>> >>>> - *
>> >>>> - * SPDX-License-Identifier: BSD-3-Clause
>> >>>> - */
>> >>>> -
>> >>>> -/**
>> >>>> - * @file
>> >>>> - *
>> >>>> - * ODP packet flags inline functions
>> >>>> - */
>> >>>> -
>> >>>> -#ifndef ODP_PLAT_PACKET_FLAGS_INLINES_H_
>> >>>> -#define ODP_PLAT_PACKET_FLAGS_INLINES_H_
>> >>>> -
>> >>>> -#ifdef __cplusplus
>> >>>> -extern "C" {
>> >>>> -#endif
>> >>>> -
>> >>>> -extern const unsigned int ol_flags_offset;
>> >>>> -extern const uint64_t rss_flag;
>> >>>> -
>> >>>> -/*
>> >>>> - * NOTE: These functions are inlined because they are on a
>> performance
>> >>>> hot path.
>> >>>> - * As we can't force the application to directly include DPDK
>> headers
>> >>>> we have to
>> >>>> - * export these fields through constants calculated compile time in
>> >>>> - * odp_packet.c, where we can see the DPDK definitions.
>> >>>> - *
>> >>>> - */
>> >>>> -_STATIC int odp_packet_has_flow_hash(odp_packet_t pkt)
>> >>>> -{
>> >>>> -       return *(uint64_t *)((char *)pkt + ol_flags_offset) &
>> rss_flag;
>> >>>> -}
>> >>>> -
>> >>>> -_STATIC void odp_packet_has_flow_hash_clr(odp_packet_t pkt)
>> >>>> -{
>> >>>> -       *(uint64_t *)((char *)pkt + ol_flags_offset) &= ~rss_flag;
>> >>>> -}
>> >>>> -
>> >>>> -#ifdef __cplusplus
>> >>>> -}
>> >>>> -#endif
>> >>>> -
>> >>>> -#endif /* ODP_PLAT_PACKET_FLAGS_INLINES_H_ */
>> >>>> diff --git a/platform/linux-dpdk/include/odp/api/packet_inlines.h
>> >>>> b/platform/linux-dpdk/include/odp/api/packet_inlines.h
>> >>>> deleted file mode 100644
>> >>>> index 444919d..0000000
>> >>>> --- a/platform/linux-dpdk/include/odp/api/packet_inlines.h
>> >>>> +++ /dev/null
>> >>>> @@ -1,83 +0,0 @@
>> >>>> -/* Copyright (c) 2016, Linaro Limited
>> >>>> - * All rights reserved.
>> >>>> - *
>> >>>> - * SPDX-License-Identifier: BSD-3-Clause
>> >>>> - */
>> >>>> -
>> >>>> -/**
>> >>>> - * @file
>> >>>> - *
>> >>>> - * ODP packet inline functions
>> >>>> - */
>> >>>> -
>> >>>> -#ifndef ODP_PLAT_PACKET_INLINES_H_
>> >>>> -#define ODP_PLAT_PACKET_INLINES_H_
>> >>>> -
>> >>>> -#ifdef __cplusplus
>> >>>> -extern "C" {
>> >>>> -#endif
>> >>>> -
>> >>>> -#ifdef _ODP_INLINES
>> >>>> -
>> >>>> -extern const unsigned int buf_addr_offset;
>> >>>> -extern const unsigned int data_off_offset;
>> >>>> -extern const unsigned int pkt_len_offset;
>> >>>> -extern const unsigned int seg_len_offset;
>> >>>> -extern const unsigned int udata_len_offset;
>> >>>> -extern const unsigned int udata_offset;
>> >>>> -extern const unsigned int rss_offset;
>> >>>> -extern const unsigned int ol_flags_offset;
>> >>>> -extern const uint64_t rss_flag;
>> >>>> -
>> >>>> -#endif /* _ODP_INLINES */
>> >>>> -/*
>> >>>> - * NOTE: These functions are inlined because they are on a
>> performance
>> >>>> hot path.
>> >>>> - * As we can't force the application to directly include DPDK
>> headers
>> >>>> we have to
>> >>>> - * export these fields through constants calculated compile time in
>> >>>> - * odp_packet.c, where we can see the DPDK definitions.
>> >>>> - *
>> >>>> - */
>> >>>> -_STATIC uint32_t odp_packet_len(odp_packet_t pkt)
>> >>>> -{
>> >>>> -       return *(uint32_t *)(void *)((char *)pkt + pkt_len_offset);
>> >>>> -}
>> >>>> -
>> >>>> -_STATIC uint32_t odp_packet_seg_len(odp_packet_t pkt)
>> >>>> -{
>> >>>> -       return *(uint16_t *)(void *)((char *)pkt + seg_len_offset);
>> >>>> -}
>> >>>> -
>> >>>> -_STATIC void *odp_packet_user_area(odp_packet_t pkt)
>> >>>> -{
>> >>>> -       return (void *)((char *)pkt + udata_offset);
>> >>>> -}
>> >>>> -
>> >>>> -_STATIC uint32_t odp_packet_user_area_size(odp_packet_t pkt)
>> >>>> -{
>> >>>> -       return *(uint32_t *)(void *)((char *)pkt + udata_len_offset);
>> >>>> -}
>> >>>> -
>> >>>> -_STATIC void *odp_packet_data(odp_packet_t pkt)
>> >>>> -{
>> >>>> -       char **buf_addr = (char **)(void *)((char *)pkt +
>> >>>> buf_addr_offset);
>> >>>> -       uint16_t data_off = *(uint16_t *)(void *)((char *)pkt +
>> >>>> data_off_offset);
>> >>>> -
>> >>>> -       return (void *)(*buf_addr + data_off);
>> >>>> -}
>> >>>> -
>> >>>> -_STATIC uint32_t odp_packet_flow_hash(odp_packet_t pkt)
>> >>>> -{
>> >>>> -       return *(uint32_t *)(void *)((char *)pkt + rss_offset);
>> >>>> -}
>> >>>> -
>> >>>> -_STATIC void odp_packet_flow_hash_set(odp_packet_t pkt, uint32_t
>> >>>> flow_hash)
>> >>>> -{
>> >>>> -       *(uint32_t *)(void *)((char *)pkt + rss_offset) = flow_hash;
>> >>>> -       *(uint64_t *)(void *)((char *)pkt + ol_flags_offset) |=
>> >>>> rss_flag;
>> >>>> -}
>> >>>> -
>> >>>> -#ifdef __cplusplus
>> >>>> -}
>> >>>> -#endif
>> >>>> -
>> >>>> -#endif /* ODP_PLAT_PACKET_INLINES_H_ */
>> >>>> diff --git a/platform/linux-dpdk/include/odp/api/plat/inlines.h.in
>> >>>> b/platform/linux-dpdk/include/odp/api/plat/inlines.h.in
>> >>>> new file mode 100644
>> >>>> index 0000000..43e542b
>> >>>> --- /dev/null
>> >>>> +++ b/platform/linux-dpdk/include/odp/api/plat/inlines.h.in
>> >>>> @@ -0,0 +1,33 @@
>> >>>> +/* Copyright (c) 2016, Linaro Limited
>> >>>> + * All rights reserved.
>> >>>> + *
>> >>>> + * SPDX-License-Identifier: BSD-3-Clause
>> >>>> + */
>> >>>> +
>> >>>> +/**
>> >>>> + * @file
>> >>>> + *
>> >>>> + * ODP packet inline functions
>> >>>> + */
>> >>>> +
>> >>>> +#ifndef ODP_PLAT_INLINES_H_
>> >>>> +#define ODP_PLAT_INLINES_H_
>> >>>> +
>> >>>> +#ifdef __cplusplus
>> >>>> +extern "C" {
>> >>>> +#endif
>> >>>> +
>> >>>> +#define @_ODP_INLINES@
>> >>>> +
>> >>>> +#ifdef _ODP_INLINES
>> >>>> +#define _STATIC static inline
>> >>>> +#else
>> >>>> +#define _STATIC
>> >>>> +#endif
>> >>>> +
>> >>>> +#ifdef __cplusplus
>> >>>> +}
>> >>>> +#endif
>> >>>> +
>> >>>> +
>> >>>> +#endif /* ODP_PLAT_INLINES_H_ */
>> >>>> diff --git a/platform/linux-dpdk/include/
>> odp/api/plat/packet_flags_inlines.h
>> >>>> b/platform/linux-dpdk/include/odp/api/plat/packet_flags_inlines.h
>> >>>> new file mode 100644
>> >>>> index 0000000..7d2464e
>> >>>> --- /dev/null
>> >>>> +++ b/platform/linux-dpdk/include/odp/api/plat/packet_flags_inli
>> nes.h
>> >>>> @@ -0,0 +1,44 @@
>> >>>> +/* Copyright (c) 2016, Linaro Limited
>> >>>> + * All rights reserved.
>> >>>> + *
>> >>>> + * SPDX-License-Identifier: BSD-3-Clause
>> >>>> + */
>> >>>> +
>> >>>> +/**
>> >>>> + * @file
>> >>>> + *
>> >>>> + * ODP packet flags inline functions
>> >>>> + */
>> >>>> +
>> >>>> +#ifndef ODP_PLAT_PACKET_FLAGS_INLINES_H_
>> >>>> +#define ODP_PLAT_PACKET_FLAGS_INLINES_H_
>> >>>> +
>> >>>> +#ifdef __cplusplus
>> >>>> +extern "C" {
>> >>>> +#endif
>> >>>> +
>> >>>> +extern const unsigned int ol_flags_offset;
>> >>>> +extern const uint64_t rss_flag;
>> >>>> +
>> >>>> +/*
>> >>>> + * NOTE: These functions are inlined because they are on a
>> performance
>> >>>> hot path.
>> >>>> + * As we can't force the application to directly include DPDK
>> headers
>> >>>> we have to
>> >>>> + * export these fields through constants calculated compile time in
>> >>>> + * odp_packet.c, where we can see the DPDK definitions.
>> >>>> + *
>> >>>> + */
>> >>>> +_STATIC int odp_packet_has_flow_hash(odp_packet_t pkt)
>> >>>> +{
>> >>>> +       return *(uint64_t *)((char *)pkt + ol_flags_offset) &
>> rss_flag;
>> >>>> +}
>> >>>> +
>> >>>> +_STATIC void odp_packet_has_flow_hash_clr(odp_packet_t pkt)
>> >>>> +{
>> >>>> +       *(uint64_t *)((char *)pkt + ol_flags_offset) &= ~rss_flag;
>> >>>> +}
>> >>>> +
>> >>>> +#ifdef __cplusplus
>> >>>> +}
>> >>>> +#endif
>> >>>> +
>> >>>> +#endif /* ODP_PLAT_PACKET_FLAGS_INLINES_H_ */
>> >>>> diff --git a/platform/linux-dpdk/include/
>> odp/api/plat/packet_inlines.h
>> >>>> b/platform/linux-dpdk/include/odp/api/plat/packet_inlines.h
>> >>>> new file mode 100644
>> >>>> index 0000000..cd403bf
>> >>>> --- /dev/null
>> >>>> +++ b/platform/linux-dpdk/include/odp/api/plat/packet_inlines.h
>> >>>> @@ -0,0 +1,84 @@
>> >>>> +/* Copyright (c) 2016, Linaro Limited
>> >>>> + * All rights reserved.
>> >>>> + *
>> >>>> + * SPDX-License-Identifier: BSD-3-Clause
>> >>>> + */
>> >>>> +
>> >>>> +/**
>> >>>> + * @file
>> >>>> + *
>> >>>> + * ODP packet inline functions
>> >>>> + */
>> >>>> +
>> >>>> +#ifndef ODP_PLAT_PACKET_INLINES_H_
>> >>>> +#define ODP_PLAT_PACKET_INLINES_H_
>> >>>> +
>> >>>> +#ifdef __cplusplus
>> >>>> +extern "C" {
>> >>>> +#endif
>> >>>> +
>> >>>> +#ifdef _ODP_INLINES
>> >>>> +
>> >>>> +extern const unsigned int buf_addr_offset;
>> >>>> +extern const unsigned int data_off_offset;
>> >>>> +extern const unsigned int pkt_len_offset;
>> >>>> +extern const unsigned int seg_len_offset;
>> >>>> +extern const unsigned int udata_len_offset;
>> >>>> +extern const unsigned int udata_offset;
>> >>>> +extern const unsigned int rss_offset;
>> >>>> +extern const unsigned int ol_flags_offset;
>> >>>> +extern const uint64_t rss_flag;
>> >>>> +
>> >>>> +#endif /* _ODP_INLINES */
>> >>>> +/*
>> >>>> + * NOTE: These functions are inlined because they are on a
>> performance
>> >>>> hot path.
>> >>>> + * As we can't force the application to directly include DPDK
>> headers
>> >>>> we have to
>> >>>> + * export these fields through constants calculated compile time in
>> >>>> + * odp_packet.c, where we can see the DPDK definitions.
>> >>>> + *
>> >>>> + */
>> >>>> +_STATIC uint32_t odp_packet_len(odp_packet_t pkt)
>> >>>> +{
>> >>>> +       return *(uint32_t *)(void *)((char *)pkt + pkt_len_offset);
>> >>>> +}
>> >>>> +
>> >>>> +_STATIC uint32_t odp_packet_seg_len(odp_packet_t pkt)
>> >>>> +{
>> >>>> +       return *(uint16_t *)(void *)((char *)pkt + seg_len_offset);
>> >>>> +}
>> >>>> +
>> >>>> +_STATIC void *odp_packet_user_area(odp_packet_t pkt)
>> >>>> +{
>> >>>> +       return (void *)((char *)pkt + udata_offset);
>> >>>> +}
>> >>>> +
>> >>>> +_STATIC uint32_t odp_packet_user_area_size(odp_packet_t pkt)
>> >>>> +{
>> >>>> +       return *(uint32_t *)(void *)((char *)pkt + udata_len_offset);
>> >>>> +}
>> >>>> +
>> >>>> +_STATIC void *odp_packet_data(odp_packet_t pkt)
>> >>>> +{
>> >>>> +       char **buf_addr = (char **)(void *)((char *)pkt +
>> >>>> buf_addr_offset);
>> >>>> +       uint16_t data_off =
>> >>>> +               *(uint16_t *)(void *)((char *)pkt + data_off_offset);
>> >>>> +
>> >>>> +       return (void *)(*buf_addr + data_off);
>> >>>> +}
>> >>>> +
>> >>>> +_STATIC uint32_t odp_packet_flow_hash(odp_packet_t pkt)
>> >>>> +{
>> >>>> +       return *(uint32_t *)(void *)((char *)pkt + rss_offset);
>> >>>> +}
>> >>>> +
>> >>>> +_STATIC void odp_packet_flow_hash_set(odp_packet_t pkt, uint32_t
>> >>>> flow_hash)
>> >>>> +{
>> >>>> +       *(uint32_t *)(void *)((char *)pkt + rss_offset) = flow_hash;
>> >>>> +       *(uint64_t *)(void *)((char *)pkt + ol_flags_offset) |=
>> >>>> rss_flag;
>> >>>> +}
>> >>>> +
>> >>>> +#ifdef __cplusplus
>> >>>> +}
>> >>>> +#endif
>> >>>> +
>> >>>> +#endif /* ODP_PLAT_PACKET_INLINES_H_ */
>> >>>> diff --git a/platform/linux-dpdk/m4/configure.m4
>> >>>> b/platform/linux-dpdk/m4/configure.m4
>> >>>> index 730b6e8..6807de4 100644
>> >>>> --- a/platform/linux-dpdk/m4/configure.m4
>> >>>> +++ b/platform/linux-dpdk/m4/configure.m4
>> >>>> @@ -75,5 +75,5 @@ LDFLAGS=$OLD_LDFLAGS
>> >>>>  CPPFLAGS=$OLD_CPPFLAGS
>> >>>>
>> >>>>  AC_CONFIG_FILES([platform/linux-dpdk/Makefile
>> >>>> -                platform/linux-dpdk/include/odp/api/inlines.h])
>> >>>> +                platform/linux-dpdk/include/od
>> p/api/plat/inlines.h])
>> >>>>
>> >>>> diff --git a/platform/linux-dpdk/odp_packet.c
>> >>>> b/platform/linux-dpdk/odp_packet.c
>> >>>> index b536281..8bd7379 100644
>> >>>> --- a/platform/linux-dpdk/odp_packet.c
>> >>>> +++ b/platform/linux-dpdk/odp_packet.c
>> >>>> @@ -62,7 +62,7 @@ ODP_STATIC_ASSERT(sizeof(dummy.ol_flags) ==
>> >>>> sizeof(uint64_t),
>> >>>>                   "ol_flags should be uint64_t");
>> >>>>
>> >>>>  #ifndef _ODP_INLINES
>> >>>> -#include <odp/api/packet_inlines.h>
>> >>>> +#include <odp/api/plat/packet_inlines.h>
>> >>>>  #endif
>> >>>>
>> >>>>  /*
>> >>>> diff --git a/platform/linux-dpdk/odp_packet_flags.c
>> >>>> b/platform/linux-dpdk/odp_packet_flags.c
>> >>>> index 1c3b503..10d4097 100644
>> >>>> --- a/platform/linux-dpdk/odp_packet_flags.c
>> >>>> +++ b/platform/linux-dpdk/odp_packet_flags.c
>> >>>> @@ -8,7 +8,7 @@
>> >>>>  #include <odp_packet_internal.h>
>> >>>>
>> >>>>  #ifndef _ODP_INLINES
>> >>>> -#include <odp/api/packet_flags_inlines.h>
>> >>>> +#include <odp/api/plat/packet_flags_inlines.h>
>> >>>>  #endif
>> >>>>
>> >>>>  #define retflag(pkt, x) do {                             \
>> >>>> --
>> >>>> 2.7.4
>> >>>>
>> >>>> _______________________________________________
>> >>>> lng-odp-dpdk mailing list
>> >>>> lng-odp-dpdk@lists.linaro.org
>> >>>> https://lists.linaro.org/mailman/listinfo/lng-odp-dpdk
>> >>>>
>> >>>
>> >>>
>> >>
>> >
>> _______________________________________________
>> lng-odp-dpdk mailing list
>> lng-odp-dpdk@lists.linaro.org
>> https://lists.linaro.org/mailman/listinfo/lng-odp-dpdk
>>
>
>
>
> --
> Mike Holmes
> Program Manager - Linaro Networking Group
> Linaro.org <http://www.linaro.org/> *│ *Open source software for ARM SoCs
> "Work should be fun and collaborative, the rest follows"
>
>
>
Krishna Garapati Sept. 6, 2016, 8:15 a.m. | #7
Reviewed-and-tested-by: Balakrishna Garapati <
balakrishna.garapati@linaro.org>

/Krishna

On 2 September 2016 at 18:43, Krishna Garapati <
balakrishna.garapati@linaro.org> wrote:

>
>
> On 2 September 2016 at 18:26, Mike Holmes <mike.holmes@linaro.org> wrote:
>
>>
>>
>> On 2 September 2016 at 12:15, Bill Fischofer <bill.fischofer@linaro.org>
>> wrote:
>>
>>> On Fri, Sep 2, 2016 at 11:11 AM, Krishna Garapati <
>>> balakrishna.garapati@linaro.org> wrote:
>>>
>>> >
>>> >
>>> > On 2 September 2016 at 17:36, Bill Fischofer <
>>> bill.fischofer@linaro.org>
>>> > wrote:
>>> >
>>> >> I see no such checkpatch warnings. As I've discussed with Mike part 2
>>> >> generates some spurious warnings relating to the symbolic links, but
>>> part 1
>>> >> is completely clean for me.
>>> >>
>>> >> Are you applying with git am, or using patch directly?
>>> >>
>>> > I use git am and the build is fine. When I do checkpatch directly on
>>> the
>>> > downloaded patch I see these warning/error messages.
>>>
>>
>> The downloaded "patch" is an mbox file with email headers etc not a patch
>> isn't it ?
>> It does depend how you extract the patches, but git am applies patches
>> form a mailbox, not patches
>>
> Yes, you are right. It's my mistake.
>
> /Krishna
>
>>
>>
>>> >
>>> >
>>> I'm not sure what to say. Do you do this with other patches and see
>>> different behavior? Reason I ask is there haven't been a lot of
>>> "external"
>>> patches posted to odp-dpdk of late. Do you see the same difference for
>>> the
>>> similar patch series I posted against odp-linux?
>>>
>>>
>>> > /Krishna
>>> >
>>> >>
>>> >> On Fri, Sep 2, 2016 at 8:40 AM, Krishna Garapati <
>>> >> balakrishna.garapati@linaro.org> wrote:
>>> >>
>>> >>> checkpatch output
>>> >>>
>>> >>> WARNING: Possible unwrapped commit description (prefer a maximum 75
>>> >>> chars per line)
>>> >>> #44:
>>> >>> VG8gZmFjaWxpdGF0ZSBpbnRlZ3JhdGlvbiB3aXRoIG9kcC1saW51eCwgbW92
>>> >>> ZSB0aGUgY29uZGl0
>>> >>>
>>> >>> ERROR: Does not appear to be a unified-diff format patch
>>> >>>
>>> >>> total: 1 errors, 1 warnings, 0 checks, 0 lines checked
>>> >>>
>>> >>> /Krishna
>>> >>>
>>> >>>
>>> >>> On 31 August 2016 at 04:08, Bill Fischofer <
>>> bill.fischofer@linaro.org>
>>> >>> wrote:
>>> >>>
>>> >>>> To facilitate integration with odp-linux, move the conditional
>>> inline
>>> >>>> files associated with ABI support from include/odp/api to
>>> >>>> include/odp/api/plat since these are platform-specific
>>> optimizations.
>>> >>>> Note that this also moves the .gitignore into the
>>> platform/linux-dpdk
>>> >>>> directory to avoid conflicts with other platforms sharing the main
>>> >>>> .gitignore file.
>>> >>>>
>>> >>>> Suggested by: Zoltan Kiss <zoltan.kiss@schaman.hu>
>>> >>>>
>>> >>>> Signed-off-by: Bill Fischofer <bill.fischofer@linaro.org>
>>> >>>> ---
>>> >>>>  .gitignore                                         |  1 -
>>> >>>>  platform/linux-dpdk/.gitignore                     |  1 +
>>> >>>>  platform/linux-dpdk/Makefile.am                    |  7 +-
>>> >>>>  platform/linux-dpdk/include/odp/api/inlines.h.in   | 33 ---------
>>> >>>>  platform/linux-dpdk/include/odp/api/packet.h       |  4 +-
>>> >>>>  platform/linux-dpdk/include/odp/api/packet_flags.h |  4 +-
>>> >>>>  .../include/odp/api/packet_flags_inlines.h         | 44
>>> ------------
>>> >>>>  .../linux-dpdk/include/odp/api/packet_inlines.h    | 83
>>> >>>> ---------------------
>>> >>>>  .../linux-dpdk/include/odp/api/plat/inlines.h.in   | 33 +++++++++
>>> >>>>  .../include/odp/api/plat/packet_flags_inlines.h    | 44
>>> ++++++++++++
>>> >>>>  .../include/odp/api/plat/packet_inlines.h          | 84
>>> >>>> ++++++++++++++++++++++
>>> >>>>  platform/linux-dpdk/m4/configure.m4                |  2 +-
>>> >>>>  platform/linux-dpdk/odp_packet.c                   |  2 +-
>>> >>>>  platform/linux-dpdk/odp_packet_flags.c             |  2 +-
>>> >>>>  14 files changed, 172 insertions(+), 172 deletions(-)
>>> >>>>  create mode 100644 platform/linux-dpdk/.gitignore
>>> >>>>  delete mode 100644 platform/linux-dpdk/include/odp/api/
>>> inlines.h.in
>>> >>>>  delete mode 100644 platform/linux-dpdk/include/od
>>> >>>> p/api/packet_flags_inlines.h
>>> >>>>  delete mode 100644 platform/linux-dpdk/include/od
>>> >>>> p/api/packet_inlines.h
>>> >>>>  create mode 100644 platform/linux-dpdk/include/odp/api/plat/
>>> >>>> inlines.h.in
>>> >>>>  create mode 100644 platform/linux-dpdk/include/od
>>> >>>> p/api/plat/packet_flags_inlines.h
>>> >>>>  create mode 100644 platform/linux-dpdk/include/od
>>> >>>> p/api/plat/packet_inlines.h
>>> >>>>
>>> >>>> diff --git a/.gitignore b/.gitignore
>>> >>>> index bcc556c..d4e7d02 100644
>>> >>>> --- a/.gitignore
>>> >>>> +++ b/.gitignore
>>> >>>> @@ -41,6 +41,5 @@ ltmain.sh
>>> >>>>  m4/*.m4
>>> >>>>  missing
>>> >>>>  pkgconfig/libodp*.pc
>>> >>>> -platform/linux-dpdk/include/odp/api/inlines.h
>>> >>>>  tags
>>> >>>>  test-driver
>>> >>>> diff --git a/platform/linux-dpdk/.gitignore
>>> >>>> b/platform/linux-dpdk/.gitignore
>>> >>>> new file mode 100644
>>> >>>> index 0000000..654e50c
>>> >>>> --- /dev/null
>>> >>>> +++ b/platform/linux-dpdk/.gitignore
>>> >>>> @@ -0,0 +1 @@
>>> >>>> +include/odp/api/plat/inlines.h
>>> >>>> \ No newline at end of file
>>> >>>> diff --git a/platform/linux-dpdk/Makefile.am
>>> >>>> b/platform/linux-dpdk/Makefile.am
>>> >>>> index d4e9c79..4d87345 100644
>>> >>>> --- a/platform/linux-dpdk/Makefile.am
>>> >>>> +++ b/platform/linux-dpdk/Makefile.am
>>> >>>> @@ -47,11 +47,8 @@ odpapiinclude_HEADERS = \
>>> >>>>                   $(srcdir)/include/odp/api/hash.h \
>>> >>>>                   $(srcdir)/include/odp/api/hints.h \
>>> >>>>                   $(srcdir)/include/odp/api/init.h \
>>> >>>> -                 $(builddir)/include/odp/api/inlines.h \
>>> >>>>                   $(srcdir)/include/odp/api/packet_flags.h \
>>> >>>> -                 $(srcdir)/include/odp/api/packet_flags_inlines.h
>>> \
>>> >>>>                   $(srcdir)/include/odp/api/packet.h \
>>> >>>> -                 $(srcdir)/include/odp/api/packet_inlines.h \
>>> >>>>                   $(srcdir)/include/odp/api/packet_io.h \
>>> >>>>                   $(srcdir)/include/odp/api/packet_io_stats.h \
>>> >>>>                   $(srcdir)/include/odp/api/pool.h \
>>> >>>> @@ -90,8 +87,10 @@ odpapiplatinclude_HEADERS = \
>>> >>>>                   $(srcdir)/include/odp/api/plat/crypto_types.h \
>>> >>>>                   $(srcdir)/include/odp/api/plat/event_types.h \
>>> >>>>                   $(srcdir)/include/odp/api/plat/init_types.h \
>>> >>>> -                 $(srcdir)/include/odp/api/plat/packet_types.h \
>>> >>>> +                 $(srcdir)/include/odp/api/pla
>>> t/packet_flags_inlines.h
>>> >>>> \
>>> >>>> +                 $(srcdir)/include/odp/api/plat/packet_inlines.h \
>>> >>>>                   $(srcdir)/include/odp/api/plat/packet_io_types.h
>>> \
>>> >>>> +                 $(srcdir)/include/odp/api/plat/packet_types.h \
>>> >>>>                   $(srcdir)/include/odp/api/plat/pool_types.h \
>>> >>>>                   $(srcdir)/include/odp/api/plat/queue_types.h \
>>> >>>>                   $(srcdir)/include/odp/api/plat/rwlock_types.h \
>>> >>>> diff --git a/platform/linux-dpdk/include/odp/api/inlines.h.in
>>> >>>> b/platform/linux-dpdk/include/odp/api/inlines.h.in
>>> >>>> deleted file mode 100644
>>> >>>> index 43e542b..0000000
>>> >>>> --- a/platform/linux-dpdk/include/odp/api/inlines.h.in
>>> >>>> +++ /dev/null
>>> >>>> @@ -1,33 +0,0 @@
>>> >>>> -/* Copyright (c) 2016, Linaro Limited
>>> >>>> - * All rights reserved.
>>> >>>> - *
>>> >>>> - * SPDX-License-Identifier: BSD-3-Clause
>>> >>>> - */
>>> >>>> -
>>> >>>> -/**
>>> >>>> - * @file
>>> >>>> - *
>>> >>>> - * ODP packet inline functions
>>> >>>> - */
>>> >>>> -
>>> >>>> -#ifndef ODP_PLAT_INLINES_H_
>>> >>>> -#define ODP_PLAT_INLINES_H_
>>> >>>> -
>>> >>>> -#ifdef __cplusplus
>>> >>>> -extern "C" {
>>> >>>> -#endif
>>> >>>> -
>>> >>>> -#define @_ODP_INLINES@
>>> >>>> -
>>> >>>> -#ifdef _ODP_INLINES
>>> >>>> -#define _STATIC static inline
>>> >>>> -#else
>>> >>>> -#define _STATIC
>>> >>>> -#endif
>>> >>>> -
>>> >>>> -#ifdef __cplusplus
>>> >>>> -}
>>> >>>> -#endif
>>> >>>> -
>>> >>>> -
>>> >>>> -#endif /* ODP_PLAT_INLINES_H_ */
>>> >>>> diff --git a/platform/linux-dpdk/include/odp/api/packet.h
>>> >>>> b/platform/linux-dpdk/include/odp/api/packet.h
>>> >>>> index 61543fa..f9123d8 100644
>>> >>>> --- a/platform/linux-dpdk/include/odp/api/packet.h
>>> >>>> +++ b/platform/linux-dpdk/include/odp/api/packet.h
>>> >>>> @@ -28,9 +28,9 @@ extern "C" {
>>> >>>>   *  @{
>>> >>>>   */
>>> >>>>
>>> >>>> -#include <odp/api/inlines.h>
>>> >>>> +#include <odp/api/plat/inlines.h>
>>> >>>>  #ifdef _ODP_INLINES
>>> >>>> -#include <odp/api/packet_inlines.h>
>>> >>>> +#include <odp/api/plat/packet_inlines.h>
>>> >>>>  #endif
>>> >>>>
>>> >>>>  /**
>>> >>>> diff --git a/platform/linux-dpdk/include/odp/api/packet_flags.h
>>> >>>> b/platform/linux-dpdk/include/odp/api/packet_flags.h
>>> >>>> index 00dd845..b6ae9f8 100644
>>> >>>> --- a/platform/linux-dpdk/include/odp/api/packet_flags.h
>>> >>>> +++ b/platform/linux-dpdk/include/odp/api/packet_flags.h
>>> >>>> @@ -28,9 +28,9 @@ extern "C" {
>>> >>>>   *  @{
>>> >>>>   */
>>> >>>>
>>> >>>> -#include <odp/api/inlines.h>
>>> >>>> +#include <odp/api/plat/inlines.h>
>>> >>>>  #ifdef _ODP_INLINES
>>> >>>> -#include <odp/api/packet_flags_inlines.h>
>>> >>>> +#include <odp/api/plat/packet_flags_inlines.h>
>>> >>>>  #endif
>>> >>>>
>>> >>>>  /**
>>> >>>> diff --git a/platform/linux-dpdk/include/
>>> odp/api/packet_flags_inlines.h
>>> >>>> b/platform/linux-dpdk/include/odp/api/packet_flags_inlines.h
>>> >>>> deleted file mode 100644
>>> >>>> index 7d2464e..0000000
>>> >>>> --- a/platform/linux-dpdk/include/odp/api/packet_flags_inlines.h
>>> >>>> +++ /dev/null
>>> >>>> @@ -1,44 +0,0 @@
>>> >>>> -/* Copyright (c) 2016, Linaro Limited
>>> >>>> - * All rights reserved.
>>> >>>> - *
>>> >>>> - * SPDX-License-Identifier: BSD-3-Clause
>>> >>>> - */
>>> >>>> -
>>> >>>> -/**
>>> >>>> - * @file
>>> >>>> - *
>>> >>>> - * ODP packet flags inline functions
>>> >>>> - */
>>> >>>> -
>>> >>>> -#ifndef ODP_PLAT_PACKET_FLAGS_INLINES_H_
>>> >>>> -#define ODP_PLAT_PACKET_FLAGS_INLINES_H_
>>> >>>> -
>>> >>>> -#ifdef __cplusplus
>>> >>>> -extern "C" {
>>> >>>> -#endif
>>> >>>> -
>>> >>>> -extern const unsigned int ol_flags_offset;
>>> >>>> -extern const uint64_t rss_flag;
>>> >>>> -
>>> >>>> -/*
>>> >>>> - * NOTE: These functions are inlined because they are on a
>>> performance
>>> >>>> hot path.
>>> >>>> - * As we can't force the application to directly include DPDK
>>> headers
>>> >>>> we have to
>>> >>>> - * export these fields through constants calculated compile time in
>>> >>>> - * odp_packet.c, where we can see the DPDK definitions.
>>> >>>> - *
>>> >>>> - */
>>> >>>> -_STATIC int odp_packet_has_flow_hash(odp_packet_t pkt)
>>> >>>> -{
>>> >>>> -       return *(uint64_t *)((char *)pkt + ol_flags_offset) &
>>> rss_flag;
>>> >>>> -}
>>> >>>> -
>>> >>>> -_STATIC void odp_packet_has_flow_hash_clr(odp_packet_t pkt)
>>> >>>> -{
>>> >>>> -       *(uint64_t *)((char *)pkt + ol_flags_offset) &= ~rss_flag;
>>> >>>> -}
>>> >>>> -
>>> >>>> -#ifdef __cplusplus
>>> >>>> -}
>>> >>>> -#endif
>>> >>>> -
>>> >>>> -#endif /* ODP_PLAT_PACKET_FLAGS_INLINES_H_ */
>>> >>>> diff --git a/platform/linux-dpdk/include/odp/api/packet_inlines.h
>>> >>>> b/platform/linux-dpdk/include/odp/api/packet_inlines.h
>>> >>>> deleted file mode 100644
>>> >>>> index 444919d..0000000
>>> >>>> --- a/platform/linux-dpdk/include/odp/api/packet_inlines.h
>>> >>>> +++ /dev/null
>>> >>>> @@ -1,83 +0,0 @@
>>> >>>> -/* Copyright (c) 2016, Linaro Limited
>>> >>>> - * All rights reserved.
>>> >>>> - *
>>> >>>> - * SPDX-License-Identifier: BSD-3-Clause
>>> >>>> - */
>>> >>>> -
>>> >>>> -/**
>>> >>>> - * @file
>>> >>>> - *
>>> >>>> - * ODP packet inline functions
>>> >>>> - */
>>> >>>> -
>>> >>>> -#ifndef ODP_PLAT_PACKET_INLINES_H_
>>> >>>> -#define ODP_PLAT_PACKET_INLINES_H_
>>> >>>> -
>>> >>>> -#ifdef __cplusplus
>>> >>>> -extern "C" {
>>> >>>> -#endif
>>> >>>> -
>>> >>>> -#ifdef _ODP_INLINES
>>> >>>> -
>>> >>>> -extern const unsigned int buf_addr_offset;
>>> >>>> -extern const unsigned int data_off_offset;
>>> >>>> -extern const unsigned int pkt_len_offset;
>>> >>>> -extern const unsigned int seg_len_offset;
>>> >>>> -extern const unsigned int udata_len_offset;
>>> >>>> -extern const unsigned int udata_offset;
>>> >>>> -extern const unsigned int rss_offset;
>>> >>>> -extern const unsigned int ol_flags_offset;
>>> >>>> -extern const uint64_t rss_flag;
>>> >>>> -
>>> >>>> -#endif /* _ODP_INLINES */
>>> >>>> -/*
>>> >>>> - * NOTE: These functions are inlined because they are on a
>>> performance
>>> >>>> hot path.
>>> >>>> - * As we can't force the application to directly include DPDK
>>> headers
>>> >>>> we have to
>>> >>>> - * export these fields through constants calculated compile time in
>>> >>>> - * odp_packet.c, where we can see the DPDK definitions.
>>> >>>> - *
>>> >>>> - */
>>> >>>> -_STATIC uint32_t odp_packet_len(odp_packet_t pkt)
>>> >>>> -{
>>> >>>> -       return *(uint32_t *)(void *)((char *)pkt + pkt_len_offset);
>>> >>>> -}
>>> >>>> -
>>> >>>> -_STATIC uint32_t odp_packet_seg_len(odp_packet_t pkt)
>>> >>>> -{
>>> >>>> -       return *(uint16_t *)(void *)((char *)pkt + seg_len_offset);
>>> >>>> -}
>>> >>>> -
>>> >>>> -_STATIC void *odp_packet_user_area(odp_packet_t pkt)
>>> >>>> -{
>>> >>>> -       return (void *)((char *)pkt + udata_offset);
>>> >>>> -}
>>> >>>> -
>>> >>>> -_STATIC uint32_t odp_packet_user_area_size(odp_packet_t pkt)
>>> >>>> -{
>>> >>>> -       return *(uint32_t *)(void *)((char *)pkt +
>>> udata_len_offset);
>>> >>>> -}
>>> >>>> -
>>> >>>> -_STATIC void *odp_packet_data(odp_packet_t pkt)
>>> >>>> -{
>>> >>>> -       char **buf_addr = (char **)(void *)((char *)pkt +
>>> >>>> buf_addr_offset);
>>> >>>> -       uint16_t data_off = *(uint16_t *)(void *)((char *)pkt +
>>> >>>> data_off_offset);
>>> >>>> -
>>> >>>> -       return (void *)(*buf_addr + data_off);
>>> >>>> -}
>>> >>>> -
>>> >>>> -_STATIC uint32_t odp_packet_flow_hash(odp_packet_t pkt)
>>> >>>> -{
>>> >>>> -       return *(uint32_t *)(void *)((char *)pkt + rss_offset);
>>> >>>> -}
>>> >>>> -
>>> >>>> -_STATIC void odp_packet_flow_hash_set(odp_packet_t pkt, uint32_t
>>> >>>> flow_hash)
>>> >>>> -{
>>> >>>> -       *(uint32_t *)(void *)((char *)pkt + rss_offset) = flow_hash;
>>> >>>> -       *(uint64_t *)(void *)((char *)pkt + ol_flags_offset) |=
>>> >>>> rss_flag;
>>> >>>> -}
>>> >>>> -
>>> >>>> -#ifdef __cplusplus
>>> >>>> -}
>>> >>>> -#endif
>>> >>>> -
>>> >>>> -#endif /* ODP_PLAT_PACKET_INLINES_H_ */
>>> >>>> diff --git a/platform/linux-dpdk/include/odp/api/plat/inlines.h.in
>>> >>>> b/platform/linux-dpdk/include/odp/api/plat/inlines.h.in
>>> >>>> new file mode 100644
>>> >>>> index 0000000..43e542b
>>> >>>> --- /dev/null
>>> >>>> +++ b/platform/linux-dpdk/include/odp/api/plat/inlines.h.in
>>> >>>> @@ -0,0 +1,33 @@
>>> >>>> +/* Copyright (c) 2016, Linaro Limited
>>> >>>> + * All rights reserved.
>>> >>>> + *
>>> >>>> + * SPDX-License-Identifier: BSD-3-Clause
>>> >>>> + */
>>> >>>> +
>>> >>>> +/**
>>> >>>> + * @file
>>> >>>> + *
>>> >>>> + * ODP packet inline functions
>>> >>>> + */
>>> >>>> +
>>> >>>> +#ifndef ODP_PLAT_INLINES_H_
>>> >>>> +#define ODP_PLAT_INLINES_H_
>>> >>>> +
>>> >>>> +#ifdef __cplusplus
>>> >>>> +extern "C" {
>>> >>>> +#endif
>>> >>>> +
>>> >>>> +#define @_ODP_INLINES@
>>> >>>> +
>>> >>>> +#ifdef _ODP_INLINES
>>> >>>> +#define _STATIC static inline
>>> >>>> +#else
>>> >>>> +#define _STATIC
>>> >>>> +#endif
>>> >>>> +
>>> >>>> +#ifdef __cplusplus
>>> >>>> +}
>>> >>>> +#endif
>>> >>>> +
>>> >>>> +
>>> >>>> +#endif /* ODP_PLAT_INLINES_H_ */
>>> >>>> diff --git a/platform/linux-dpdk/include/
>>> odp/api/plat/packet_flags_inlines.h
>>> >>>> b/platform/linux-dpdk/include/odp/api/plat/packet_flags_inlines.h
>>> >>>> new file mode 100644
>>> >>>> index 0000000..7d2464e
>>> >>>> --- /dev/null
>>> >>>> +++ b/platform/linux-dpdk/include/odp/api/plat/packet_flags_inli
>>> nes.h
>>> >>>> @@ -0,0 +1,44 @@
>>> >>>> +/* Copyright (c) 2016, Linaro Limited
>>> >>>> + * All rights reserved.
>>> >>>> + *
>>> >>>> + * SPDX-License-Identifier: BSD-3-Clause
>>> >>>> + */
>>> >>>> +
>>> >>>> +/**
>>> >>>> + * @file
>>> >>>> + *
>>> >>>> + * ODP packet flags inline functions
>>> >>>> + */
>>> >>>> +
>>> >>>> +#ifndef ODP_PLAT_PACKET_FLAGS_INLINES_H_
>>> >>>> +#define ODP_PLAT_PACKET_FLAGS_INLINES_H_
>>> >>>> +
>>> >>>> +#ifdef __cplusplus
>>> >>>> +extern "C" {
>>> >>>> +#endif
>>> >>>> +
>>> >>>> +extern const unsigned int ol_flags_offset;
>>> >>>> +extern const uint64_t rss_flag;
>>> >>>> +
>>> >>>> +/*
>>> >>>> + * NOTE: These functions are inlined because they are on a
>>> performance
>>> >>>> hot path.
>>> >>>> + * As we can't force the application to directly include DPDK
>>> headers
>>> >>>> we have to
>>> >>>> + * export these fields through constants calculated compile time in
>>> >>>> + * odp_packet.c, where we can see the DPDK definitions.
>>> >>>> + *
>>> >>>> + */
>>> >>>> +_STATIC int odp_packet_has_flow_hash(odp_packet_t pkt)
>>> >>>> +{
>>> >>>> +       return *(uint64_t *)((char *)pkt + ol_flags_offset) &
>>> rss_flag;
>>> >>>> +}
>>> >>>> +
>>> >>>> +_STATIC void odp_packet_has_flow_hash_clr(odp_packet_t pkt)
>>> >>>> +{
>>> >>>> +       *(uint64_t *)((char *)pkt + ol_flags_offset) &= ~rss_flag;
>>> >>>> +}
>>> >>>> +
>>> >>>> +#ifdef __cplusplus
>>> >>>> +}
>>> >>>> +#endif
>>> >>>> +
>>> >>>> +#endif /* ODP_PLAT_PACKET_FLAGS_INLINES_H_ */
>>> >>>> diff --git a/platform/linux-dpdk/include/
>>> odp/api/plat/packet_inlines.h
>>> >>>> b/platform/linux-dpdk/include/odp/api/plat/packet_inlines.h
>>> >>>> new file mode 100644
>>> >>>> index 0000000..cd403bf
>>> >>>> --- /dev/null
>>> >>>> +++ b/platform/linux-dpdk/include/odp/api/plat/packet_inlines.h
>>> >>>> @@ -0,0 +1,84 @@
>>> >>>> +/* Copyright (c) 2016, Linaro Limited
>>> >>>> + * All rights reserved.
>>> >>>> + *
>>> >>>> + * SPDX-License-Identifier: BSD-3-Clause
>>> >>>> + */
>>> >>>> +
>>> >>>> +/**
>>> >>>> + * @file
>>> >>>> + *
>>> >>>> + * ODP packet inline functions
>>> >>>> + */
>>> >>>> +
>>> >>>> +#ifndef ODP_PLAT_PACKET_INLINES_H_
>>> >>>> +#define ODP_PLAT_PACKET_INLINES_H_
>>> >>>> +
>>> >>>> +#ifdef __cplusplus
>>> >>>> +extern "C" {
>>> >>>> +#endif
>>> >>>> +
>>> >>>> +#ifdef _ODP_INLINES
>>> >>>> +
>>> >>>> +extern const unsigned int buf_addr_offset;
>>> >>>> +extern const unsigned int data_off_offset;
>>> >>>> +extern const unsigned int pkt_len_offset;
>>> >>>> +extern const unsigned int seg_len_offset;
>>> >>>> +extern const unsigned int udata_len_offset;
>>> >>>> +extern const unsigned int udata_offset;
>>> >>>> +extern const unsigned int rss_offset;
>>> >>>> +extern const unsigned int ol_flags_offset;
>>> >>>> +extern const uint64_t rss_flag;
>>> >>>> +
>>> >>>> +#endif /* _ODP_INLINES */
>>> >>>> +/*
>>> >>>> + * NOTE: These functions are inlined because they are on a
>>> performance
>>> >>>> hot path.
>>> >>>> + * As we can't force the application to directly include DPDK
>>> headers
>>> >>>> we have to
>>> >>>> + * export these fields through constants calculated compile time in
>>> >>>> + * odp_packet.c, where we can see the DPDK definitions.
>>> >>>> + *
>>> >>>> + */
>>> >>>> +_STATIC uint32_t odp_packet_len(odp_packet_t pkt)
>>> >>>> +{
>>> >>>> +       return *(uint32_t *)(void *)((char *)pkt + pkt_len_offset);
>>> >>>> +}
>>> >>>> +
>>> >>>> +_STATIC uint32_t odp_packet_seg_len(odp_packet_t pkt)
>>> >>>> +{
>>> >>>> +       return *(uint16_t *)(void *)((char *)pkt + seg_len_offset);
>>> >>>> +}
>>> >>>> +
>>> >>>> +_STATIC void *odp_packet_user_area(odp_packet_t pkt)
>>> >>>> +{
>>> >>>> +       return (void *)((char *)pkt + udata_offset);
>>> >>>> +}
>>> >>>> +
>>> >>>> +_STATIC uint32_t odp_packet_user_area_size(odp_packet_t pkt)
>>> >>>> +{
>>> >>>> +       return *(uint32_t *)(void *)((char *)pkt +
>>> udata_len_offset);
>>> >>>> +}
>>> >>>> +
>>> >>>> +_STATIC void *odp_packet_data(odp_packet_t pkt)
>>> >>>> +{
>>> >>>> +       char **buf_addr = (char **)(void *)((char *)pkt +
>>> >>>> buf_addr_offset);
>>> >>>> +       uint16_t data_off =
>>> >>>> +               *(uint16_t *)(void *)((char *)pkt +
>>> data_off_offset);
>>> >>>> +
>>> >>>> +       return (void *)(*buf_addr + data_off);
>>> >>>> +}
>>> >>>> +
>>> >>>> +_STATIC uint32_t odp_packet_flow_hash(odp_packet_t pkt)
>>> >>>> +{
>>> >>>> +       return *(uint32_t *)(void *)((char *)pkt + rss_offset);
>>> >>>> +}
>>> >>>> +
>>> >>>> +_STATIC void odp_packet_flow_hash_set(odp_packet_t pkt, uint32_t
>>> >>>> flow_hash)
>>> >>>> +{
>>> >>>> +       *(uint32_t *)(void *)((char *)pkt + rss_offset) = flow_hash;
>>> >>>> +       *(uint64_t *)(void *)((char *)pkt + ol_flags_offset) |=
>>> >>>> rss_flag;
>>> >>>> +}
>>> >>>> +
>>> >>>> +#ifdef __cplusplus
>>> >>>> +}
>>> >>>> +#endif
>>> >>>> +
>>> >>>> +#endif /* ODP_PLAT_PACKET_INLINES_H_ */
>>> >>>> diff --git a/platform/linux-dpdk/m4/configure.m4
>>> >>>> b/platform/linux-dpdk/m4/configure.m4
>>> >>>> index 730b6e8..6807de4 100644
>>> >>>> --- a/platform/linux-dpdk/m4/configure.m4
>>> >>>> +++ b/platform/linux-dpdk/m4/configure.m4
>>> >>>> @@ -75,5 +75,5 @@ LDFLAGS=$OLD_LDFLAGS
>>> >>>>  CPPFLAGS=$OLD_CPPFLAGS
>>> >>>>
>>> >>>>  AC_CONFIG_FILES([platform/linux-dpdk/Makefile
>>> >>>> -                platform/linux-dpdk/include/odp/api/inlines.h])
>>> >>>> +                platform/linux-dpdk/include/od
>>> p/api/plat/inlines.h])
>>> >>>>
>>> >>>> diff --git a/platform/linux-dpdk/odp_packet.c
>>> >>>> b/platform/linux-dpdk/odp_packet.c
>>> >>>> index b536281..8bd7379 100644
>>> >>>> --- a/platform/linux-dpdk/odp_packet.c
>>> >>>> +++ b/platform/linux-dpdk/odp_packet.c
>>> >>>> @@ -62,7 +62,7 @@ ODP_STATIC_ASSERT(sizeof(dummy.ol_flags) ==
>>> >>>> sizeof(uint64_t),
>>> >>>>                   "ol_flags should be uint64_t");
>>> >>>>
>>> >>>>  #ifndef _ODP_INLINES
>>> >>>> -#include <odp/api/packet_inlines.h>
>>> >>>> +#include <odp/api/plat/packet_inlines.h>
>>> >>>>  #endif
>>> >>>>
>>> >>>>  /*
>>> >>>> diff --git a/platform/linux-dpdk/odp_packet_flags.c
>>> >>>> b/platform/linux-dpdk/odp_packet_flags.c
>>> >>>> index 1c3b503..10d4097 100644
>>> >>>> --- a/platform/linux-dpdk/odp_packet_flags.c
>>> >>>> +++ b/platform/linux-dpdk/odp_packet_flags.c
>>> >>>> @@ -8,7 +8,7 @@
>>> >>>>  #include <odp_packet_internal.h>
>>> >>>>
>>> >>>>  #ifndef _ODP_INLINES
>>> >>>> -#include <odp/api/packet_flags_inlines.h>
>>> >>>> +#include <odp/api/plat/packet_flags_inlines.h>
>>> >>>>  #endif
>>> >>>>
>>> >>>>  #define retflag(pkt, x) do {                             \
>>> >>>> --
>>> >>>> 2.7.4
>>> >>>>
>>> >>>> _______________________________________________
>>> >>>> lng-odp-dpdk mailing list
>>> >>>> lng-odp-dpdk@lists.linaro.org
>>> >>>> https://lists.linaro.org/mailman/listinfo/lng-odp-dpdk
>>> >>>>
>>> >>>
>>> >>>
>>> >>
>>> >
>>> _______________________________________________
>>> lng-odp-dpdk mailing list
>>> lng-odp-dpdk@lists.linaro.org
>>> https://lists.linaro.org/mailman/listinfo/lng-odp-dpdk
>>>
>>
>>
>>
>> --
>> Mike Holmes
>> Program Manager - Linaro Networking Group
>> Linaro.org <http://www.linaro.org/> *│ *Open source software for ARM SoCs
>> "Work should be fun and collaborative, the rest follows"
>>
>>
>>
>

Patch

diff --git a/.gitignore b/.gitignore
index bcc556c..d4e7d02 100644
--- a/.gitignore
+++ b/.gitignore
@@ -41,6 +41,5 @@  ltmain.sh
 m4/*.m4
 missing
 pkgconfig/libodp*.pc
-platform/linux-dpdk/include/odp/api/inlines.h
 tags
 test-driver
diff --git a/platform/linux-dpdk/.gitignore b/platform/linux-dpdk/.gitignore
new file mode 100644
index 0000000..654e50c
--- /dev/null
+++ b/platform/linux-dpdk/.gitignore
@@ -0,0 +1 @@ 
+include/odp/api/plat/inlines.h
\ No newline at end of file
diff --git a/platform/linux-dpdk/Makefile.am b/platform/linux-dpdk/Makefile.am
index d4e9c79..4d87345 100644
--- a/platform/linux-dpdk/Makefile.am
+++ b/platform/linux-dpdk/Makefile.am
@@ -47,11 +47,8 @@  odpapiinclude_HEADERS = \
 		  $(srcdir)/include/odp/api/hash.h \
 		  $(srcdir)/include/odp/api/hints.h \
 		  $(srcdir)/include/odp/api/init.h \
-		  $(builddir)/include/odp/api/inlines.h \
 		  $(srcdir)/include/odp/api/packet_flags.h \
-		  $(srcdir)/include/odp/api/packet_flags_inlines.h \
 		  $(srcdir)/include/odp/api/packet.h \
-		  $(srcdir)/include/odp/api/packet_inlines.h \
 		  $(srcdir)/include/odp/api/packet_io.h \
 		  $(srcdir)/include/odp/api/packet_io_stats.h \
 		  $(srcdir)/include/odp/api/pool.h \
@@ -90,8 +87,10 @@  odpapiplatinclude_HEADERS = \
 		  $(srcdir)/include/odp/api/plat/crypto_types.h \
 		  $(srcdir)/include/odp/api/plat/event_types.h \
 		  $(srcdir)/include/odp/api/plat/init_types.h \
-		  $(srcdir)/include/odp/api/plat/packet_types.h \
+		  $(srcdir)/include/odp/api/plat/packet_flags_inlines.h \
+		  $(srcdir)/include/odp/api/plat/packet_inlines.h \
 		  $(srcdir)/include/odp/api/plat/packet_io_types.h \
+		  $(srcdir)/include/odp/api/plat/packet_types.h \
 		  $(srcdir)/include/odp/api/plat/pool_types.h \
 		  $(srcdir)/include/odp/api/plat/queue_types.h \
 		  $(srcdir)/include/odp/api/plat/rwlock_types.h \
diff --git a/platform/linux-dpdk/include/odp/api/inlines.h.in b/platform/linux-dpdk/include/odp/api/inlines.h.in
deleted file mode 100644
index 43e542b..0000000
--- a/platform/linux-dpdk/include/odp/api/inlines.h.in
+++ /dev/null
@@ -1,33 +0,0 @@ 
-/* Copyright (c) 2016, Linaro Limited
- * All rights reserved.
- *
- * SPDX-License-Identifier: BSD-3-Clause
- */
-
-/**
- * @file
- *
- * ODP packet inline functions
- */
-
-#ifndef ODP_PLAT_INLINES_H_
-#define ODP_PLAT_INLINES_H_
-
-#ifdef __cplusplus
-extern "C" {
-#endif
-
-#define @_ODP_INLINES@
-
-#ifdef _ODP_INLINES
-#define _STATIC static inline
-#else
-#define _STATIC
-#endif
-
-#ifdef __cplusplus
-}
-#endif
-
-
-#endif /* ODP_PLAT_INLINES_H_ */
diff --git a/platform/linux-dpdk/include/odp/api/packet.h b/platform/linux-dpdk/include/odp/api/packet.h
index 61543fa..f9123d8 100644
--- a/platform/linux-dpdk/include/odp/api/packet.h
+++ b/platform/linux-dpdk/include/odp/api/packet.h
@@ -28,9 +28,9 @@  extern "C" {
  *  @{
  */
 
-#include <odp/api/inlines.h>
+#include <odp/api/plat/inlines.h>
 #ifdef _ODP_INLINES
-#include <odp/api/packet_inlines.h>
+#include <odp/api/plat/packet_inlines.h>
 #endif
 
 /**
diff --git a/platform/linux-dpdk/include/odp/api/packet_flags.h b/platform/linux-dpdk/include/odp/api/packet_flags.h
index 00dd845..b6ae9f8 100644
--- a/platform/linux-dpdk/include/odp/api/packet_flags.h
+++ b/platform/linux-dpdk/include/odp/api/packet_flags.h
@@ -28,9 +28,9 @@  extern "C" {
  *  @{
  */
 
-#include <odp/api/inlines.h>
+#include <odp/api/plat/inlines.h>
 #ifdef _ODP_INLINES
-#include <odp/api/packet_flags_inlines.h>
+#include <odp/api/plat/packet_flags_inlines.h>
 #endif
 
 /**
diff --git a/platform/linux-dpdk/include/odp/api/packet_flags_inlines.h b/platform/linux-dpdk/include/odp/api/packet_flags_inlines.h
deleted file mode 100644
index 7d2464e..0000000
--- a/platform/linux-dpdk/include/odp/api/packet_flags_inlines.h
+++ /dev/null
@@ -1,44 +0,0 @@ 
-/* Copyright (c) 2016, Linaro Limited
- * All rights reserved.
- *
- * SPDX-License-Identifier: BSD-3-Clause
- */
-
-/**
- * @file
- *
- * ODP packet flags inline functions
- */
-
-#ifndef ODP_PLAT_PACKET_FLAGS_INLINES_H_
-#define ODP_PLAT_PACKET_FLAGS_INLINES_H_
-
-#ifdef __cplusplus
-extern "C" {
-#endif
-
-extern const unsigned int ol_flags_offset;
-extern const uint64_t rss_flag;
-
-/*
- * NOTE: These functions are inlined because they are on a performance hot path.
- * As we can't force the application to directly include DPDK headers we have to
- * export these fields through constants calculated compile time in
- * odp_packet.c, where we can see the DPDK definitions.
- *
- */
-_STATIC int odp_packet_has_flow_hash(odp_packet_t pkt)
-{
-	return *(uint64_t *)((char *)pkt + ol_flags_offset) & rss_flag;
-}
-
-_STATIC void odp_packet_has_flow_hash_clr(odp_packet_t pkt)
-{
-	*(uint64_t *)((char *)pkt + ol_flags_offset) &= ~rss_flag;
-}
-
-#ifdef __cplusplus
-}
-#endif
-
-#endif /* ODP_PLAT_PACKET_FLAGS_INLINES_H_ */
diff --git a/platform/linux-dpdk/include/odp/api/packet_inlines.h b/platform/linux-dpdk/include/odp/api/packet_inlines.h
deleted file mode 100644
index 444919d..0000000
--- a/platform/linux-dpdk/include/odp/api/packet_inlines.h
+++ /dev/null
@@ -1,83 +0,0 @@ 
-/* Copyright (c) 2016, Linaro Limited
- * All rights reserved.
- *
- * SPDX-License-Identifier: BSD-3-Clause
- */
-
-/**
- * @file
- *
- * ODP packet inline functions
- */
-
-#ifndef ODP_PLAT_PACKET_INLINES_H_
-#define ODP_PLAT_PACKET_INLINES_H_
-
-#ifdef __cplusplus
-extern "C" {
-#endif
-
-#ifdef _ODP_INLINES
-
-extern const unsigned int buf_addr_offset;
-extern const unsigned int data_off_offset;
-extern const unsigned int pkt_len_offset;
-extern const unsigned int seg_len_offset;
-extern const unsigned int udata_len_offset;
-extern const unsigned int udata_offset;
-extern const unsigned int rss_offset;
-extern const unsigned int ol_flags_offset;
-extern const uint64_t rss_flag;
-
-#endif /* _ODP_INLINES */
-/*
- * NOTE: These functions are inlined because they are on a performance hot path.
- * As we can't force the application to directly include DPDK headers we have to
- * export these fields through constants calculated compile time in
- * odp_packet.c, where we can see the DPDK definitions.
- *
- */
-_STATIC uint32_t odp_packet_len(odp_packet_t pkt)
-{
-	return *(uint32_t *)(void *)((char *)pkt + pkt_len_offset);
-}
-
-_STATIC uint32_t odp_packet_seg_len(odp_packet_t pkt)
-{
-	return *(uint16_t *)(void *)((char *)pkt + seg_len_offset);
-}
-
-_STATIC void *odp_packet_user_area(odp_packet_t pkt)
-{
-	return (void *)((char *)pkt + udata_offset);
-}
-
-_STATIC uint32_t odp_packet_user_area_size(odp_packet_t pkt)
-{
-	return *(uint32_t *)(void *)((char *)pkt + udata_len_offset);
-}
-
-_STATIC void *odp_packet_data(odp_packet_t pkt)
-{
-	char **buf_addr = (char **)(void *)((char *)pkt + buf_addr_offset);
-	uint16_t data_off = *(uint16_t *)(void *)((char *)pkt + data_off_offset);
-
-	return (void *)(*buf_addr + data_off);
-}
-
-_STATIC uint32_t odp_packet_flow_hash(odp_packet_t pkt)
-{
-	return *(uint32_t *)(void *)((char *)pkt + rss_offset);
-}
-
-_STATIC void odp_packet_flow_hash_set(odp_packet_t pkt, uint32_t flow_hash)
-{
-	*(uint32_t *)(void *)((char *)pkt + rss_offset) = flow_hash;
-	*(uint64_t *)(void *)((char *)pkt + ol_flags_offset) |= rss_flag;
-}
-
-#ifdef __cplusplus
-}
-#endif
-
-#endif /* ODP_PLAT_PACKET_INLINES_H_ */
diff --git a/platform/linux-dpdk/include/odp/api/plat/inlines.h.in b/platform/linux-dpdk/include/odp/api/plat/inlines.h.in
new file mode 100644
index 0000000..43e542b
--- /dev/null
+++ b/platform/linux-dpdk/include/odp/api/plat/inlines.h.in
@@ -0,0 +1,33 @@ 
+/* Copyright (c) 2016, Linaro Limited
+ * All rights reserved.
+ *
+ * SPDX-License-Identifier: BSD-3-Clause
+ */
+
+/**
+ * @file
+ *
+ * ODP packet inline functions
+ */
+
+#ifndef ODP_PLAT_INLINES_H_
+#define ODP_PLAT_INLINES_H_
+
+#ifdef __cplusplus
+extern "C" {
+#endif
+
+#define @_ODP_INLINES@
+
+#ifdef _ODP_INLINES
+#define _STATIC static inline
+#else
+#define _STATIC
+#endif
+
+#ifdef __cplusplus
+}
+#endif
+
+
+#endif /* ODP_PLAT_INLINES_H_ */
diff --git a/platform/linux-dpdk/include/odp/api/plat/packet_flags_inlines.h b/platform/linux-dpdk/include/odp/api/plat/packet_flags_inlines.h
new file mode 100644
index 0000000..7d2464e
--- /dev/null
+++ b/platform/linux-dpdk/include/odp/api/plat/packet_flags_inlines.h
@@ -0,0 +1,44 @@ 
+/* Copyright (c) 2016, Linaro Limited
+ * All rights reserved.
+ *
+ * SPDX-License-Identifier: BSD-3-Clause
+ */
+
+/**
+ * @file
+ *
+ * ODP packet flags inline functions
+ */
+
+#ifndef ODP_PLAT_PACKET_FLAGS_INLINES_H_
+#define ODP_PLAT_PACKET_FLAGS_INLINES_H_
+
+#ifdef __cplusplus
+extern "C" {
+#endif
+
+extern const unsigned int ol_flags_offset;
+extern const uint64_t rss_flag;
+
+/*
+ * NOTE: These functions are inlined because they are on a performance hot path.
+ * As we can't force the application to directly include DPDK headers we have to
+ * export these fields through constants calculated compile time in
+ * odp_packet.c, where we can see the DPDK definitions.
+ *
+ */
+_STATIC int odp_packet_has_flow_hash(odp_packet_t pkt)
+{
+	return *(uint64_t *)((char *)pkt + ol_flags_offset) & rss_flag;
+}
+
+_STATIC void odp_packet_has_flow_hash_clr(odp_packet_t pkt)
+{
+	*(uint64_t *)((char *)pkt + ol_flags_offset) &= ~rss_flag;
+}
+
+#ifdef __cplusplus
+}
+#endif
+
+#endif /* ODP_PLAT_PACKET_FLAGS_INLINES_H_ */
diff --git a/platform/linux-dpdk/include/odp/api/plat/packet_inlines.h b/platform/linux-dpdk/include/odp/api/plat/packet_inlines.h
new file mode 100644
index 0000000..cd403bf
--- /dev/null
+++ b/platform/linux-dpdk/include/odp/api/plat/packet_inlines.h
@@ -0,0 +1,84 @@ 
+/* Copyright (c) 2016, Linaro Limited
+ * All rights reserved.
+ *
+ * SPDX-License-Identifier: BSD-3-Clause
+ */
+
+/**
+ * @file
+ *
+ * ODP packet inline functions
+ */
+
+#ifndef ODP_PLAT_PACKET_INLINES_H_
+#define ODP_PLAT_PACKET_INLINES_H_
+
+#ifdef __cplusplus
+extern "C" {
+#endif
+
+#ifdef _ODP_INLINES
+
+extern const unsigned int buf_addr_offset;
+extern const unsigned int data_off_offset;
+extern const unsigned int pkt_len_offset;
+extern const unsigned int seg_len_offset;
+extern const unsigned int udata_len_offset;
+extern const unsigned int udata_offset;
+extern const unsigned int rss_offset;
+extern const unsigned int ol_flags_offset;
+extern const uint64_t rss_flag;
+
+#endif /* _ODP_INLINES */
+/*
+ * NOTE: These functions are inlined because they are on a performance hot path.
+ * As we can't force the application to directly include DPDK headers we have to
+ * export these fields through constants calculated compile time in
+ * odp_packet.c, where we can see the DPDK definitions.
+ *
+ */
+_STATIC uint32_t odp_packet_len(odp_packet_t pkt)
+{
+	return *(uint32_t *)(void *)((char *)pkt + pkt_len_offset);
+}
+
+_STATIC uint32_t odp_packet_seg_len(odp_packet_t pkt)
+{
+	return *(uint16_t *)(void *)((char *)pkt + seg_len_offset);
+}
+
+_STATIC void *odp_packet_user_area(odp_packet_t pkt)
+{
+	return (void *)((char *)pkt + udata_offset);
+}
+
+_STATIC uint32_t odp_packet_user_area_size(odp_packet_t pkt)
+{
+	return *(uint32_t *)(void *)((char *)pkt + udata_len_offset);
+}
+
+_STATIC void *odp_packet_data(odp_packet_t pkt)
+{
+	char **buf_addr = (char **)(void *)((char *)pkt + buf_addr_offset);
+	uint16_t data_off =
+		*(uint16_t *)(void *)((char *)pkt + data_off_offset);
+
+	return (void *)(*buf_addr + data_off);
+}
+
+_STATIC uint32_t odp_packet_flow_hash(odp_packet_t pkt)
+{
+	return *(uint32_t *)(void *)((char *)pkt + rss_offset);
+}
+
+_STATIC void odp_packet_flow_hash_set(odp_packet_t pkt, uint32_t flow_hash)
+{
+	*(uint32_t *)(void *)((char *)pkt + rss_offset) = flow_hash;
+	*(uint64_t *)(void *)((char *)pkt + ol_flags_offset) |= rss_flag;
+}
+
+#ifdef __cplusplus
+}
+#endif
+
+#endif /* ODP_PLAT_PACKET_INLINES_H_ */
diff --git a/platform/linux-dpdk/m4/configure.m4 b/platform/linux-dpdk/m4/configure.m4
index 730b6e8..6807de4 100644
--- a/platform/linux-dpdk/m4/configure.m4
+++ b/platform/linux-dpdk/m4/configure.m4
@@ -75,5 +75,5 @@  LDFLAGS=$OLD_LDFLAGS
 CPPFLAGS=$OLD_CPPFLAGS
 
 AC_CONFIG_FILES([platform/linux-dpdk/Makefile
-		 platform/linux-dpdk/include/odp/api/inlines.h])
+		 platform/linux-dpdk/include/odp/api/plat/inlines.h])
 
diff --git a/platform/linux-dpdk/odp_packet.c b/platform/linux-dpdk/odp_packet.c
index b536281..8bd7379 100644
--- a/platform/linux-dpdk/odp_packet.c
+++ b/platform/linux-dpdk/odp_packet.c
@@ -62,7 +62,7 @@  ODP_STATIC_ASSERT(sizeof(dummy.ol_flags) == sizeof(uint64_t),
 		  "ol_flags should be uint64_t");
 
 #ifndef _ODP_INLINES
-#include <odp/api/packet_inlines.h>
+#include <odp/api/plat/packet_inlines.h>
 #endif
 
 /*
diff --git a/platform/linux-dpdk/odp_packet_flags.c b/platform/linux-dpdk/odp_packet_flags.c
index 1c3b503..10d4097 100644
--- a/platform/linux-dpdk/odp_packet_flags.c
+++ b/platform/linux-dpdk/odp_packet_flags.c
@@ -8,7 +8,7 @@ 
 #include <odp_packet_internal.h>
 
 #ifndef _ODP_INLINES
-#include <odp/api/packet_flags_inlines.h>
+#include <odp/api/plat/packet_flags_inlines.h>
 #endif
 
 #define retflag(pkt, x) do {                             \