ftrace_func_mapper_add_ip(9)

πŸ“¦ version 7.3.1, in nixpkgs unstable

πŸ’… ftrace_func_mapper_add_ip(9) πŸ’…

okay so bestie, welcome to the Kernel API Manual, section 9 β€” this one lives in ./kernel/trace/ftrace.c and honestly it's giving "tiny function, big responsibilities" ✨


πŸŽ€ NAME πŸŽ€

ftrace_func_mapper_add_ip β€” map some data to an ip πŸ—ΊοΈπŸ’–


✨ SYNOPSIS ✨

int ftrace_func_mapper_add_ip (struct ftrace_func_mapper *mapper ,
unsigned long ip , void *data );

like, three args, one int out, no drama πŸ’…


🌸 ARGUMENTS 🌸

  • mapper β€” the mapper that has the ip maps πŸ—‚οΈ she's the one holding all the mappings, keep her close
  • ip β€” the instruction pointer address you're mapping data to πŸ“ literally the little address key
  • data β€” the data to map to ip 🎁 whatever you're tying to that address, hand it over

πŸ’– RETURN πŸ’–

0 on success, otherwise an error 😭 that's it, that's the whole vibe check β€” zero means slay, anything else means something went sideways


πŸ¦‹ SEE ALSO πŸ¦‹

Kernel file ./kernel/trace/ftrace.c β€” plus the whole friend group, no cap:


iykyk, but if you're adding to a mapper, go peep allocate_ftrace_func_mapper(9) first β€” she's the one who makes the mapper in the first place 🫢

later bestie!! this page came from ./kernel/trace, dated October 2026, and it's part of the Kernel API Manual β€” go forth and map those ips πŸŒˆβ­πŸ’œ

πŸ“¦ where this page comes from