aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMatias Elo <matias.elo@nokia.com>2024-02-29 15:34:43 +0200
committerMatias Elo <matias.elo@nokia.com>2024-03-11 15:03:00 +0200
commitd3d7a49a448e1f7ab284237cb8a82201be903362 (patch)
treed7d6a64b3b45acb0cedeac4ba5a3ea375fefd675
parent889080035df939b09c447bb296af49baead168e7 (diff)
Port 10753512c "linux-gen: pool: add buffer_subtype_set()"
Port original commit from linux-generic. Signed-off-by: Matias Elo <matias.elo@nokia.com> Reviewed-by: Tuomas Taipale <tuomas.taipale@nokia.com>
-rw-r--r--platform/linux-dpdk/include/odp_buffer_internal.h7
1 files changed, 7 insertions, 0 deletions
diff --git a/platform/linux-dpdk/include/odp_buffer_internal.h b/platform/linux-dpdk/include/odp_buffer_internal.h
index dc65fd17d..cb7f50073 100644
--- a/platform/linux-dpdk/include/odp_buffer_internal.h
+++ b/platform/linux-dpdk/include/odp_buffer_internal.h
@@ -73,6 +73,13 @@ static inline odp_buffer_hdr_t *_odp_buf_hdr(odp_buffer_t buf)
return (odp_buffer_hdr_t *)(uintptr_t)buf;
}
+static inline void _odp_buffer_subtype_set(odp_buffer_t buf, int subtype)
+{
+ odp_buffer_hdr_t *buf_hdr = _odp_buf_hdr(buf);
+
+ buf_hdr->event_hdr.subtype = subtype;
+}
+
#ifdef __cplusplus
}
#endif