fgraph_retrieve_parent_data(9)

πŸ“¦ version 7.3.1, in nixpkgs unstable

πŸ’… fgraph_retrieve_parent_data(9) β€” bestie's guide to grabbing parent data

okay so this is a page straight out of the Kernel API Manual, and honestly? it's a little icon. it's the function that lets you peek at data that belongs to the caller above you instead of the function you're standing in. the way that's so useful for tracing πŸ˜­πŸ’–


✨ NAME ✨

fgraph_retrieve_parent_data β€” get data from a parent function 🫢

so like, the whole vibe of this function is "hey what's going on one (or more) frames up?"


🌸 SYNOPSIS 🌸

void * fgraph_retrieve_parent_data (int idx , int *size_bytes , int depth );

no cap, that's the whole signature. returns a void *, takes three args. slay.


πŸŽ€ ARGUMENTS πŸŽ€

  • idx β€” the index into the fgraph_array (that's fgraph_ops::idx btw, exact field name, iykyk). it's how you tell the kernel which fgraph_ops entry you're talking about πŸ’…
  • size_bytes β€” a pointer to the retrieved data size. so you pass in an int * and it gets filled with how many bytes you scored ✨
  • depth β€” the depth to find the parent, and bestie listen: 0 is the current function. so depth 1 is your caller, depth 2 is their caller, and so on up the chain πŸ¦‹

πŸ’– DESCRIPTION πŸ’–

this one is literally the sibling of fgraph_retrieve_data β€” same energy, different address. it's similar to fgraph_retrieve_data, except instead of grabbing your own data, it can be used to retrieve data from a parent caller function. so you're reaching up the call stack like "excuse me, can I borrow that?" πŸ™ˆβœ¨

lowkey important: depth of 0 means the current function, not the parent. so if you want an actual parent you gotta go 1 or higher πŸ‘‘

⭐ RETURN ⭐

it returns a pointer to the specified parent data πŸ’« β€” or NULL if it's not found. that's it. that's the deal. no data, no pointer, NULL, bye 😭


🌈 SEE ALSO 🌈

go read those next, they're all part of the same friend group fr fr 🫢


and that's the whole page gorgeous πŸ’œ β€” brought to you by the ./kernel/trace crew, dated October 2026, filed under fgraph_retrieve_parent_data(9). go get that parent data, main character βœ¨πŸŽ€πŸ‘‘

πŸ“¦ where this page comes from