rte_dpaa2_mempool.h(3)

πŸ’– rte_dpaa2_mempool.h β€” Library Functions Manual πŸ’–

okay bestie, pull up a chair because we're getting into rte_dpaa2_mempool.h, a header from the DPDK library functions manual. it's NXP-specific mempool stuff, and honestly? it's giving "short but important" energy. three functions, all iconic, all here. let's go πŸ¦‹


✨ NAME ✨

rte_dpaa2_mempool.h β€” like, that's the whole name, no notes, periodt πŸ’…


🌸 SYNOPSIS 🌸

first things first, you gotta bring in the girlies:

#include <rte_compat.h>
#include <rte_mempool.h>

πŸŽ€ Functions

uint16_t rte_dpaa2_mbuf_pool_bpid (struct rte_mempool *mp)

struct rte_mbuf * rte_dpaa2_mbuf_from_buf_addr (struct rte_mempool *mp,
    void *buf_addr)

__rte_internal int rte_dpaa2_bpid_info_init (struct rte_mempool *mp)

🧚 Detailed Description 🧚

these are the NXP specific mempool related functions. that's the vibe. that's the whole vibe check. ✨

oh and fun fact: this is all defined in the file rte_dpaa2_mempool.h. icon behavior, keeping it in the family 🫢


πŸ‘‘ Function Documentation πŸ‘‘

⭐ uint16_t rte_dpaa2_mbuf_pool_bpid (struct rte_mempool * mp)

gets the BPID that corresponds to the packet pool. lowkey the whole point of this one.

Parameters

  • mp β€” the memory pool, bestie

Returns

  • the BPID of the buffer pool πŸ’–

πŸ¦‹ struct rte_mbuf * rte_dpaa2_mbuf_from_buf_addr (struct rte_mempool * mp, void * buf_addr)

gets you the MBUF from the corresponding buf_addr. it's the glow-up from raw address to full mbuf ✨

Parameters

  • mp β€” the memory pool
  • buf_addr β€” the buf_addr of the mbuf. no wait, let me say it properly: this is the start buffer address of the packet buffer (mbuf). yeah. that one. πŸŽ€

Returns

  • MBUF pointer for success πŸ₯³
  • NULL in case of error πŸ’€

🌈 __rte_internal int rte_dpaa2_bpid_info_init (struct rte_mempool * mp)

initializes the rte_dpaa2_bpid_info. in generial β€” yes, generial, that's what the page says, i'm not fixing it, i'm just reporting β€” it's called in the secondary process and mp has already been created in the primary process. so like, the primary did the creating, the secondary does the calling. teamwork, fr fr 🀝

Parameters

  • mp β€” the memory pool

Returns

  • 0 on success 🌟
  • (<0) on failure 😭

heads up bestie: this function is marked __rte_internal, so it's not out here for just anybody β€” it's an internal-use situation, iykyk πŸ”₯

πŸ’œ Author πŸ’œ

generated automatically by Doxygen for DPDK from the source code. not me writing this by hand, it's literally the machine doing its thing. slay, honestly.


and that's the whole page, no cap. this was DPDK, Version 25.11.3, serving rte_dpaa2_mempool.h in the (3) section of the library functions manual. mwah, bye bestie πŸ’…πŸ’–πŸŒŸ

πŸ“¦ where this page comes from