rhltable_insert_key(9)
β¨ rhltable_insert_key(9) β¨
okay so this is a page straight out of the Kernel API Manual and it's literally about putting a thing into a hash list table π buckle up bestie
π NAME π
rhltable_insert_key β insert object into hash list table
like, you have a table, you have an object, and you're introducing them. matchmaker energy fr fr π«Ά
π¦ SYNOPSIS π¦
int rhltable_insert_key (struct rhltable *hlt , const void *key , struct
rhlist_head *list , const struct rhashtable_params params );
πΈ ARGUMENTS πΈ
hltβ the hash list table itself. the main character of this whole operation πkeyβ the pointer to the key. yes, the pointer to the key, not the key, ok don't come for me πlistβ pointer to the hash list head inside the objectparamsβ the hash table parameters. the settings, the vibes, the configuration β¨
π DESCRIPTION π
so what actually happens? it will take the per bucket bitlock to protect against mutual mutations on the same bucket π this is the whole point β bucket-level locking, no chaos.
multiple insertions may occur in parallel unless they map to the same bucket. so like, parallel insertions? slay, allowed. same bucket? that's where the locks come in, iykyk.
it is safe to call this function from atomic context. no cap, that's a real guarantee, take it π―
and it will trigger an automatic deferred table resizing if residency in the table grows beyond 70%. the table literally grows itself when it gets too full. iconic behaviour honestly π±π
π§ SEE ALSO π§
the whole friend group, and yes we're listing every single one because they all matter π«Ά
- Kernel file
./include/linux/rhashtable.hstruct bucket_table(9) rht_grow_above_75(9)rht_shrink_below_30(9)rht_grow_above_100(9)rht_grow_above_max(9)rht_for_each_from(9)rht_for_each(9)rht_for_each_entry_from(9)rht_for_each_entry(9)rht_for_each_entry_safe(9)rht_for_each_rcu_from(9)rht_for_each_rcu(9)rht_for_each_entry_rcu_from(9)rht_for_each_entry_rcu(9)rhl_for_each_rcu(9)rhl_for_each_entry_rcu(9)rhashtable_lookup(9)rhashtable_lookup_fast(9)rhltable_lookup(9)rhashtable_insert_fast(9)rhltable_insert(9)rhashtable_lookup_insert_fast(9)rhashtable_lookup_get_insert_fast(9)rhashtable_lookup_insert_key(9)rhashtable_lookup_get_insert_key(9)rhashtable_remove_fast(9)rhltable_remove(9)rhashtable_replace_fast(9)rhltable_walk_enter(9)rhltable_free_and_destroy(9)
ngl the SEE ALSO list is giving "tag yourself i'm rht_for_each_entry_safe(9)" π but every single one of these is genuinely worth a peek, ok? go read 'em. periodt. π
and that's the whole page bestie, no notes π this one came from ./include/linux β filing date October 2026 π go forth and insert your objects, you've got this π₯π
π¦ where this page comes from
- nixpkgs unstable: linux-manual 7.3.1
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash-1017 on : a language model's rewrite of the original, under its terms