[dpdk-stable] patch 'mbuf: fix debug checks for headroom and tailroom' has been queued to LTS release 16.11.3
Yuanhan Liu
yliu at fridaylinux.org
Fri Jul 14 12:33:48 CEST 2017
Hi,
FYI, your patch has been queued to LTS release 16.11.3
Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 07/19/17. So please
shout if anyone has objections.
Thanks.
--yliu
---
>From e496325ee597bf8c478aacaae02c464d6a113d8e Mon Sep 17 00:00:00 2001
From: Vasily Philipov <vasilyf at mellanox.com>
Date: Wed, 28 Jun 2017 15:25:12 +0300
Subject: [PATCH] mbuf: fix debug checks for headroom and tailroom
[ upstream commit 814baffdb6910c1a949bd7c5ce3c6807f703c799 ]
rte_pktmbuf_headroom() and rte_pktmbuf_tailroom() should be usable
with any segment, not only with headered ones, so is_header should be 0
when we call for sanity check inside them.
Fixes: af75078fece3 ("first public release")
Signed-off-by: Vasily Philipov <vasilyf at mellanox.com>
Acked-by: Olivier Matz <olivier.matz at 6wind.com>
---
lib/librte_mbuf/rte_mbuf.h | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/lib/librte_mbuf/rte_mbuf.h b/lib/librte_mbuf/rte_mbuf.h
index ead7c6e..00b8495 100644
--- a/lib/librte_mbuf/rte_mbuf.h
+++ b/lib/librte_mbuf/rte_mbuf.h
@@ -1331,7 +1331,7 @@ static inline void rte_pktmbuf_refcnt_update(struct rte_mbuf *m, int16_t v)
*/
static inline uint16_t rte_pktmbuf_headroom(const struct rte_mbuf *m)
{
- __rte_mbuf_sanity_check(m, 1);
+ __rte_mbuf_sanity_check(m, 0);
return m->data_off;
}
@@ -1345,7 +1345,7 @@ static inline uint16_t rte_pktmbuf_headroom(const struct rte_mbuf *m)
*/
static inline uint16_t rte_pktmbuf_tailroom(const struct rte_mbuf *m)
{
- __rte_mbuf_sanity_check(m, 1);
+ __rte_mbuf_sanity_check(m, 0);
return (uint16_t)(m->buf_len - rte_pktmbuf_headroom(m) -
m->data_len);
}
--
2.7.4
More information about the stable
mailing list