dso__data_get_fd(9)
π dso__data_get_fd β like, the Kernel API Manual page, but make it make sense π
okay bestie, welcome to the Kernel API Manual entry for dso__data_get_fd β it's giving "tiny function, big responsibility" energy, and honestly? we're obsessed. let's get into it β¨
πΈ NAME πΈ
dso__data_get_fd β get the dso's data file descriptor π
π¦ SYNOPSIS π¦
bool dso__data_get_fd (struct dso *dso , struct machine *machine , int
*fd );
that's the whole signature, no cap β copy it exactly, spaces and all, she's particular π
π ARGUMENTS π
dsoβ the dso object. like, the actual star of the show πmachineβ the machine object. yes she's here too, she matters π«Άfdβ um. the manpage literally says-- undescribed --and honestly? π iconic of the original authors to leave us hanging like that. that's the whole description. no notes.
π₯ DESCRIPTION π₯
so dso__data_get_fd is the external interface you use to find the dso's file, open it, and get the file descriptor back. literally that's the job β find, open, hand over the fd. main character behavior fr fr β¨
β οΈ okay this part is important, don't scroll past it: if it returns a non-negative value, you must pair the call with dso__data_put_fd. like, always. it's a two-part harmony, you can't just take the fd and ghost it π
π SEE ALSO π
- the kernel file
./tools/perf/util/dso.cπ dso__data_close(9)dso__data_size(9)dso__data_read_offset(9)dso__data_read_addr(9)dso__data_write_cache_offs(9)dso__data_write_cache_addr(9)
go read all of them, iykyk π
and that's the page!! π§ sourced from ./tools/perf/util, dated October 2026 β big slay, go pair your dso__data_put_fd calls and stay hydrated bestie ππ¦
π¦ 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