<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: rte_eth_rx_burst -&amp;gt; returning same mbuff pointer twice consecutively in Layerscape</title>
    <link>https://community.nxp.com/t5/Layerscape/rte-eth-rx-burst-gt-returning-same-mbuff-pointer-twice/m-p/2380197#M16731</link>
    <description>&lt;P&gt;Thanks&amp;nbsp;&lt;a href="https://community.nxp.com/t5/user/viewprofilepage/user-id/52411"&gt;@yipingwang&lt;/a&gt;&amp;nbsp; for Quick reply . I will try and update you .&lt;/P&gt;&lt;P&gt;One observation every time multiple mbuf ( same address coming ) getting below prints in screen&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;fslmc: dpaa2_get_qbman_swp(): New Portal 0x17ffd61c0 (5) affined thread - 1953&lt;BR /&gt;fslmc: dpaa2_configure_stashing(): Portal= 5 CPU= 10 SDEST= 5&lt;BR /&gt;fslmc: DPAA Portal=0x17ffd61c0 (5) is affined to thread 1953&lt;/P&gt;</description>
    <pubDate>Thu, 11 Jun 2026 11:38:54 GMT</pubDate>
    <dc:creator>Chidananda22</dc:creator>
    <dc:date>2026-06-11T11:38:54Z</dc:date>
    <item>
      <title>rte_eth_rx_burst -&gt; returning same mbuff pointer twice consecutively</title>
      <link>https://community.nxp.com/t5/Layerscape/rte-eth-rx-burst-gt-returning-same-mbuff-pointer-twice/m-p/2379408#M16726</link>
      <description>&lt;P&gt;From my application calling rte_eth_rx_burst&amp;nbsp;&lt;/P&gt;&lt;P&gt;checking sometimes same mbuff coming twice . Checked code buffer not freeing . With out mbuff free what could be the scenario that same mbuff pointer received twice .&lt;/P&gt;</description>
      <pubDate>Wed, 10 Jun 2026 09:00:27 GMT</pubDate>
      <guid>https://community.nxp.com/t5/Layerscape/rte-eth-rx-burst-gt-returning-same-mbuff-pointer-twice/m-p/2379408#M16726</guid>
      <dc:creator>Chidananda22</dc:creator>
      <dc:date>2026-06-10T09:00:27Z</dc:date>
    </item>
    <item>
      <title>Re: rte_eth_rx_burst -&gt; returning same mbuff pointer twice consecutively</title>
      <link>https://community.nxp.com/t5/Layerscape/rte-eth-rx-burst-gt-returning-same-mbuff-pointer-twice/m-p/2379422#M16727</link>
      <description>&lt;P&gt;Without an explicit mbuf free in your code, the most likely scenarios are that the mbuf is still being effectively returned/reused through another path in the application or shared unsafely across threads/cores, or that a special driver/path-specific buffer handling issue is corrupting lifecycle state.&lt;/P&gt;
&lt;UL class=""&gt;
&lt;LI class=""&gt;&lt;STRONG class=""&gt;Cross-core/shared mbuf ownership issue.&lt;/STRONG&gt;&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;One documented case used one CPU for RX and many worker CPUs consuming mbufs from a ring; the mbuf address was then seen reused/overwritten while still referenced elsewhere. NXP specifically asked whether&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;&lt;CODE class=""&gt;RTE_MBUF_REFCNT_ATOMIC&lt;/CODE&gt;&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;was enabled for multicore access, and the customer said yes, but the issue was still treated as application-level ownership/lifetime handling.,&lt;/LI&gt;
&lt;LI class=""&gt;&lt;STRONG class=""&gt;Duplicate release or hidden return path in the application pipeline.&lt;/STRONG&gt;&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;NXP’s guidance in that case was to instrument buffer allocate/release/packet-send actions to see whether the same address was being released back to the buffer pool more than once.&lt;/LI&gt;
&lt;LI class=""&gt;&lt;STRONG class=""&gt;PMD/driver returning malformed mbufs to pool in special paths.&lt;/STRONG&gt;&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;There is a separate DPAA2 PMD case involving chained mbufs where mbufs returned to the mempool appeared corrupted (&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;&lt;CODE class=""&gt;next&lt;/CODE&gt;&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;not cleared), causing sanity-check failures on later allocation. That is not the same symptom as your report, but it does show that special buffer handling paths can lead to later reuse/corruption symptoms.&lt;/LI&gt;
&lt;LI class=""&gt;&lt;STRONG class=""&gt;Same source and destination mbuf in crypto path.&lt;/STRONG&gt;&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;In a DPAA security/IPsec case, NXP noted that if&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;&lt;CODE class=""&gt;sym-&amp;gt;m_dst&lt;/CODE&gt;&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;is&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;&lt;CODE class=""&gt;NULL&lt;/CODE&gt;&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;, then&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;&lt;CODE class=""&gt;m_src&lt;/CODE&gt;&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;and&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;&lt;CODE class=""&gt;m_dst&lt;/CODE&gt;&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;use the same mbuf. That can make packet contents appear rewritten “in place” under load, even though the pointer identity did not change.&lt;/LI&gt;
&lt;/UL&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Wed, 10 Jun 2026 09:16:26 GMT</pubDate>
      <guid>https://community.nxp.com/t5/Layerscape/rte-eth-rx-burst-gt-returning-same-mbuff-pointer-twice/m-p/2379422#M16727</guid>
      <dc:creator>yipingwang</dc:creator>
      <dc:date>2026-06-10T09:16:26Z</dc:date>
    </item>
    <item>
      <title>Re: rte_eth_rx_burst -&gt; returning same mbuff pointer twice consecutively</title>
      <link>https://community.nxp.com/t5/Layerscape/rte-eth-rx-burst-gt-returning-same-mbuff-pointer-twice/m-p/2379465#M16728</link>
      <description>&lt;P&gt;thanks&amp;nbsp;&lt;a href="https://community.nxp.com/t5/user/viewprofilepage/user-id/52411"&gt;@yipingwang&lt;/a&gt;&amp;nbsp; for your quick reply and suggestions. from code i am not to figure out more . Any DPDK debug flag can help ?&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Wed, 10 Jun 2026 10:16:43 GMT</pubDate>
      <guid>https://community.nxp.com/t5/Layerscape/rte-eth-rx-burst-gt-returning-same-mbuff-pointer-twice/m-p/2379465#M16728</guid>
      <dc:creator>Chidananda22</dc:creator>
      <dc:date>2026-06-10T10:16:43Z</dc:date>
    </item>
    <item>
      <title>Re: rte_eth_rx_burst -&gt; returning same mbuff pointer twice consecutively</title>
      <link>https://community.nxp.com/t5/Layerscape/rte-eth-rx-burst-gt-returning-same-mbuff-pointer-twice/m-p/2379796#M16729</link>
      <description>&lt;OL&gt;
&lt;LI&gt;&lt;STRONG&gt;Enable DPDK log levels (first thing to try)&lt;/STRONG&gt;&lt;/LI&gt;
&lt;/OL&gt;
&lt;P&gt;Run your app with:&lt;/P&gt;
&lt;P&gt;--log-level=8&lt;/P&gt;
&lt;P&gt;What you’ll see:&lt;/P&gt;
&lt;UL&gt;
&lt;LI&gt;RX descriptor handling&lt;/LI&gt;
&lt;LI&gt;buffer allocation/recycling&lt;/LI&gt;
&lt;LI&gt;PMD behavior&lt;/LI&gt;
&lt;/UL&gt;
&lt;OL start="2"&gt;
&lt;LI&gt;&lt;STRONG&gt;Enable mbuf debug checking (very useful)&lt;/STRONG&gt;&lt;/LI&gt;
&lt;/OL&gt;
&lt;P&gt;Rebuild DPDK with:&lt;/P&gt;
&lt;P&gt;CONFIG_RTE_LIBRTE_MBUF_DEBUG=y&lt;/P&gt;
&lt;P&gt;This will:&lt;/P&gt;
&lt;UL&gt;
&lt;LI&gt;Validate mbuf consistency&lt;/LI&gt;
&lt;LI&gt;Catch:
&lt;UL&gt;
&lt;LI&gt;corrupted metadata&lt;/LI&gt;
&lt;LI&gt;reused mbuf incorrectly&lt;/LI&gt;
&lt;LI&gt;invalid refcnt&lt;/LI&gt;
&lt;/UL&gt;
&lt;/LI&gt;
&lt;/UL&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;OL start="3"&gt;
&lt;LI&gt;&lt;STRONG&gt;Enable mempool debug&lt;/STRONG&gt;&lt;/LI&gt;
&lt;/OL&gt;
&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; CONFIG_RTE_LIBRTE_MEMPOOL_DEBUG=y&lt;/P&gt;
&lt;P&gt;Helps detect:&lt;/P&gt;
&lt;UL&gt;
&lt;LI&gt;double allocation&lt;/LI&gt;
&lt;LI&gt;cache corruption&lt;/LI&gt;
&lt;LI&gt;same buffer returned twice from mempool&lt;/LI&gt;
&lt;/UL&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;OL start="4"&gt;
&lt;LI&gt;&lt;STRONG&gt;Poison/free tracking (EXTREMELY useful)&lt;/STRONG&gt;&lt;/LI&gt;
&lt;/OL&gt;
&lt;P&gt;You can enable memory overwrite checking:&lt;/P&gt;
&lt;P&gt;CONFIG_RTE_MALLOC_DEBUG=y&lt;/P&gt;
&lt;P&gt;and&lt;/P&gt;
&lt;P&gt;--mp-alloc=debug&lt;/P&gt;
&lt;P&gt;This helps detect:&lt;/P&gt;
&lt;UL&gt;
&lt;LI&gt;overwrite before/after mbuf&lt;/LI&gt;
&lt;LI&gt;hidden memory corruption&lt;/LI&gt;
&lt;/UL&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;OL start="5"&gt;
&lt;LI&gt;&lt;STRONG&gt;Quick isolation trick (VERY effective)&lt;/STRONG&gt;&lt;/LI&gt;
&lt;/OL&gt;
&lt;P&gt;Run&lt;/P&gt;
&lt;P&gt;testpmd -- -i&lt;/P&gt;
&lt;P&gt;Then:&lt;/P&gt;
&lt;P&gt;set fwd rxonly&lt;/P&gt;
&lt;P&gt;start&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;If duplication disappears:&lt;/P&gt;
&lt;UL&gt;
&lt;LI&gt;your application bug&lt;/LI&gt;
&lt;/UL&gt;
&lt;P&gt;If still happens:&lt;/P&gt;
&lt;UL&gt;
&lt;LI&gt;PMD / HW / queue config issue&lt;/LI&gt;
&lt;/UL&gt;</description>
      <pubDate>Thu, 11 Jun 2026 02:25:14 GMT</pubDate>
      <guid>https://community.nxp.com/t5/Layerscape/rte-eth-rx-burst-gt-returning-same-mbuff-pointer-twice/m-p/2379796#M16729</guid>
      <dc:creator>yipingwang</dc:creator>
      <dc:date>2026-06-11T02:25:14Z</dc:date>
    </item>
    <item>
      <title>Re: rte_eth_rx_burst -&gt; returning same mbuff pointer twice consecutively</title>
      <link>https://community.nxp.com/t5/Layerscape/rte-eth-rx-burst-gt-returning-same-mbuff-pointer-twice/m-p/2380197#M16731</link>
      <description>&lt;P&gt;Thanks&amp;nbsp;&lt;a href="https://community.nxp.com/t5/user/viewprofilepage/user-id/52411"&gt;@yipingwang&lt;/a&gt;&amp;nbsp; for Quick reply . I will try and update you .&lt;/P&gt;&lt;P&gt;One observation every time multiple mbuf ( same address coming ) getting below prints in screen&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;fslmc: dpaa2_get_qbman_swp(): New Portal 0x17ffd61c0 (5) affined thread - 1953&lt;BR /&gt;fslmc: dpaa2_configure_stashing(): Portal= 5 CPU= 10 SDEST= 5&lt;BR /&gt;fslmc: DPAA Portal=0x17ffd61c0 (5) is affined to thread 1953&lt;/P&gt;</description>
      <pubDate>Thu, 11 Jun 2026 11:38:54 GMT</pubDate>
      <guid>https://community.nxp.com/t5/Layerscape/rte-eth-rx-burst-gt-returning-same-mbuff-pointer-twice/m-p/2380197#M16731</guid>
      <dc:creator>Chidananda22</dc:creator>
      <dc:date>2026-06-11T11:38:54Z</dc:date>
    </item>
  </channel>
</rss>

