dev_pm_opp_f...loor_indexed(9)

πŸ“¦ version 7.3.1, in nixpkgs unstable

🌸 dev_pm_opp_find_freq_floor_indexed πŸ’…

okay so bestie, welcome to the Kernel API Manual β€” yes this is that dev_pm_opp_f...loor_indexed(9) page, the one with the truncated name that looks like it fell asleep mid-word 😭 don't worry, we're getting into it together 🫢


✨ NAME ✨

dev_pm_opp_find_freq_floor_indexed β€” bestie, this one searches for a rounded floor frequency for the clock that corresponds to the index πŸ‘‘


πŸ¦‹ SYNOPSIS πŸ¦‹

struct dev_pm_opp * dev_pm_opp_find_freq_floor_indexed (struct device
*dev , unsigned long *freq , u32 index );

like, that's the whole vibe right there ✨


πŸŽ€ ARGUMENTS πŸŽ€

  • dev β€” the Device we're doing this whole operation for 🫢
  • freq β€” the start frequency, that's where the search kicks off πŸ“
  • index β€” the clock index πŸ•

πŸ’– DESCRIPTION πŸ’–

So the way this works: it searches for the matching floor available OPP for the clock corresponding to the specified index β€” starting from a start freq, for a device ✨ ngl, "floor" here is doing a lot of work and it's kind of iconic for it.

Caller obligations, no cap: you literally have to call dev_pm_opp_put for the returned OPP after you use it πŸ”₯ don't just vibe with it forever, that's a leak bestie 😭


🌈 RETURN 🌈

  • On a win: the matching *opp, and it refreshes *freq accordingly πŸ’…βœ¨
  • Otherwise: it returns ERR_PTR in case of error β€” and you should be handling that with IS_ERR πŸ™ˆ

the possible error return values, laid out cute:

  • EINVAL β€” for bad pointer 🚫
  • ERANGE β€” no match found for search 😭
  • ENODEV β€” if the device is not found in the list of registered devices πŸ’€

🧚 SEE ALSO 🧚

Kernel file ./drivers/opp/core.c, plus this whole friend group of manpages β€” every single one, we're not skipping anybody, everybody's invited to the group chat πŸ‘‘


and that's the page bestie πŸ’œ this one lives over in ./drivers/opp and it's dated October 2026 β€” yeah, from the future, main character energy fr fr πŸŽ€ go call dev_pm_opp_put when you're done, ily, bye πŸ’…βœ¨

πŸ“¦ where this page comes from