rte_eal_memconfig.h(3)

πŸŽ€ rte_eal_memconfig.h πŸŽ€

okay bestie, so this is the library functions manual for rte_eal_memconfig.h β€” yes that's the man page name, section 3, and it's literally just vibing here so you can peek at EAL shared memory config through a lil API. no cap. it's short, it's cute, it's giving "exactly three header files and a whole row of lock helpers". πŸ’…


✨ SYNOPSIS ✨

like, include these first or nothing works, fr fr:

#include <stdbool.h>
#include <rte_rwlock.h>
#include <rte_spinlock.h>

🌸 Functions 🌸

here's the whole roster, every single one, no skipping:

  • __rte_internal rte_rwlock_t * rte_mcfg_mem_get_lock (void)
  • void rte_mcfg_mem_read_lock (void)
  • void rte_mcfg_mem_read_unlock (void)
  • void rte_mcfg_mem_write_lock (void)
  • void rte_mcfg_mem_write_unlock (void)
  • void rte_mcfg_tailq_read_lock (void)
  • void rte_mcfg_tailq_read_unlock (void)
  • void rte_mcfg_tailq_write_lock (void)
  • void rte_mcfg_tailq_write_unlock (void)
  • void rte_mcfg_mempool_read_lock (void)
  • void rte_mcfg_mempool_read_unlock (void)
  • void rte_mcfg_mempool_write_lock (void)
  • void rte_mcfg_mempool_write_unlock (void)
  • void rte_mcfg_timer_lock (void)
  • void rte_mcfg_timer_unlock (void)
  • bool rte_mcfg_get_single_file_segments (void)

πŸ’– Detailed Description πŸ’–

so what this API actually does: it lets you access the EAL shared memory configuration through an API. that's it, that's the whole thing. iconic behaviour honestly. πŸ‘‘

oh and btw β€” it's defined in the file rte_eal_memconfig.h. definition location noted, bestie. πŸ“


πŸ”₯ Function Documentation πŸ”₯

πŸ’œ __rte_internal rte_rwlock_t * rte_mcfg_mem_get_lock (void )

internal helpers used for lock annotations. that's the description verbatim energy β€” this one is an internal lil guy, so it's here for the annotation machinery, not for you to grab snacks out of. πŸ™ˆ

πŸ’œ void rte_mcfg_mem_read_lock (void )

locks the internal EAL shared memory configuration for shared access. multiple readers? sure babe, come on in. 🫢

πŸ’œ void rte_mcfg_mem_read_unlock (void )

unlocks the internal EAL shared memory configuration for shared access. close the door behind you please. πŸšͺ

πŸ’œ void rte_mcfg_mem_write_lock (void )

locks the internal EAL shared memory configuration for exclusive access. nobody else in the room while you're doing this, periodt. ⚠️

πŸ’œ void rte_mcfg_mem_write_unlock (void )

unlocks the internal EAL shared memory configuration for exclusive access. you may now let the girlies back in. ✨

πŸ’œ void rte_mcfg_tailq_read_lock (void )

locks the internal EAL TAILQ list for shared access.

πŸ’œ void rte_mcfg_tailq_read_unlock (void )

unlocks the internal EAL TAILQ list for shared access.

πŸ’œ void rte_mcfg_tailq_write_lock (void )

locks the internal EAL TAILQ list for exclusive access.

πŸ’œ void rte_mcfg_tailq_write_unlock (void )

unlocks the internal EAL TAILQ list for exclusive access.

πŸ’œ void rte_mcfg_mempool_read_lock (void )

locks the internal EAL Mempool list for shared access.

πŸ’œ void rte_mcfg_mempool_read_unlock (void )

unlocks the internal EAL Mempool list for shared access.

πŸ’œ void rte_mcfg_mempool_write_lock (void )

locks the internal EAL Mempool list for exclusive access.

πŸ’œ void rte_mcfg_mempool_write_unlock (void )

unlocks the internal EAL Mempool list for exclusive access.

πŸ’œ void rte_mcfg_timer_lock (void )

locks the internal EAL Timer Library lock for exclusive access. ⏰

πŸ’œ void rte_mcfg_timer_unlock (void )

unlocks the internal EAL Timer Library lock for exclusive access.

πŸ’œ bool rte_mcfg_get_single_file_segments (void )

the vibe check function right here: if it returns true, pages are put in single files β€” one per memseg list β€” as opposed to creating a file per page. so like, true = bundled, false-ish world = one file per page. you get it. πŸ“


ngl, this whole page was generated automatically by Doxygen for DPDK, straight from the source code. so if you came here for author tea, there is none β€” the robots did it. πŸ€–πŸ’…

and that's the page bestie!! DPDK, Version 25.11.3, rte_eal_memconfig.h(3) β€” mwah, go lock something responsibly. πŸ¦‹πŸ’–πŸŽ€

πŸ“¦ where this page comes from