ida_find_first_range(9)

πŸ“¦ version 7.3.1, in nixpkgs unstable

πŸ’œ ida_find_first_range(9) πŸ’œ

ok so this is a page from the Kernel API Manual bestie, and it's all about ida_find_first_range β€” the little function that goes "hey, what's the lowest ID somebody's actually using in here?" πŸŽ€


✨ NAME ✨

ida_find_first_range β€” get the lowest used ID. literally that's the whole job, and she does it slayfully πŸ’…


✨ SYNOPSIS ✨

int ida_find_first_range (struct ida *ida , unsigned int min , unsigned
int max );

πŸ¦‹ ARGUMENTS πŸ¦‹

  • ida β€” your IDA handle πŸ’– this is the lil container we're snooping around in.
  • min β€” the lowest ID you want to get. the floor of the search, basically.
  • max β€” the highest ID you want to get. the ceiling. the vibes boundary. ⭐

🌸 DESCRIPTION 🌸

ok so real talk: this gets the lowest used ID between min and max, and yes bestie, that range is inclusive on both ends πŸ’―

and here's the tea β€” the returned ID will not exceed INT_MAX, even if max is larger. like, max can be out here living its best enormous life and the return value is still gonna respect that INT_MAX ceiling. no cap. πŸ‘‘


🌈 CONTEXT 🌈

any context. takes and releases the xa_lock. so she's polite about it β€” grabs the lock, does her thing, puts it right back 🫢


⭐ RETURN ⭐

the lowest used ID. and if there's no used ID to be found? you get an errno instead 😭 that's it, that's the deal.


πŸ’€ SEE ALSO πŸ’€

kernel file ./lib/idr.c, plus the whole friend group:


and that's the whole page bestie!! 🧚 this icon lives in ./lib, it's dated October 2026, and it's literally called ida_find_first_range(9) β€” go find some ranges, you got this πŸ’œπŸ’–βœ¨

πŸ“¦ where this page comes from