rte_hash_parameters(3)

πŸ’– rte_hash_parameters πŸ’–

okay so bestie, we're digging into rte_hash_parameters β€” it's a page from the Library Functions Manual, and it's basically the ✨blueprint✨ for making a hash table in DPDK. no cap, this one's a struct, so it's giving "fill out the form before we let you in" energy.


✨ SYNOPSIS ✨

plot twist: it's a struct, so you just include the header and start filling in fields. first tho:

#include <rte_hash.h>

πŸ¦‹ Data Fields

  • const char * name
  • uint32_t entries
  • uint32_t reserved
  • uint32_t key_len
  • rte_hash_function hash_func
  • uint32_t hash_func_init_val
  • int socket_id
  • uint8_t extra_flag

🌸 Detailed Description 🌸

these are the parameters used when creating the hash table. that's the whole vibe. that's the job. 🧚

Definition at line 82 of file rte_hash.h.


πŸ’… Field Documentation πŸ’…

const char* name

Name of the hash. label your baby, bestie β€” you're gonna want to know which one's which later. 🏷️

Definition at line 83 of file rte_hash.h.

uint32_t entries

Total hash table entries. like, how many slots do you want in this thing. pick a number, any number (well, a uint32_t number). πŸ”’

Definition at line 84 of file rte_hash.h.

uint32_t reserved

Unused field. Should be set to 0. okay this one is literally just vibes β€” it does nothing, so set it to 0 and move on, don't be weird about it. 🚫

Definition at line 85 of file rte_hash.h.

uint32_t key_len

Length of hash key. how big is each key, in bytes. measure twice, hash once. πŸ“

Definition at line 86 of file rte_hash.h.

rte_hash_function hash_func

Primary Hash function used to calculate hash. the main character of this struct fr fr β€” this is the function doing the actual hashing. πŸ‘‘

Definition at line 87 of file rte_hash.h.

uint32_t hash_func_init_val

Init value used by hash_func. the little starter value your hash function gets handed before it starts cooking. πŸ“

Definition at line 88 of file rte_hash.h.

int socket_id

NUMA Socket ID for memory. where in the NUMA party the memory lives. pick your socket wisely, iykyk. πŸŽ€

Definition at line 89 of file rte_hash.h.

uint8_t extra_flag

Indicate if additional parameters are present. literally just a "hey, is there more stuff coming?" flag. set it, and the extra params slide in. 🌈

Definition at line 90 of file rte_hash.h.


🫢 Author 🫢

Generated automatically by Doxygen for DPDK from the source code. so no human wrote this by hand β€” the docs machine did it and honestly it ate. πŸ€–βœ¨


aaaand that's the whole page, bestie! πŸ’œ this one came from DPDK, Version 25.11.3 β€” rte_hash_parameters(3), slay, that's a wrap, periodt. πŸ’…πŸ’–

πŸ“¦ where this page comes from