dev_pm_opp_find_freq_exact(9)

πŸ“¦ version 7.3.1, in nixpkgs unstable

✨ NAME ✨

okay bestie, welcome to the Kernel API Manual πŸ’– this page is dev_pm_opp_find_freq_exact(9) β€” the function that searches for an exact frequency. that's the whole vibe 🎯

🌸 SYNOPSIS 🌸

struct dev_pm_opp * dev_pm_opp_find_freq_exact (struct device *dev ,
       unsigned long freq , bool available );

πŸŽ€ ARGUMENTS πŸŽ€

  • dev β€” the device we're doing this little operation for 🫢
  • freq β€” the frequency to search for, literally the target 🎯
  • available β€” true/false; match for available opp βœ…

πŸ’– RETURN πŸ’–

It searches for an exact match in the opp table and returns a pointer to the matching opp if it finds one. If not, it returns ERR_PTR in case of error, and bestie you must handle that using IS_ERR 😭

Error return values can be:

  • EINVAL β€” for bad pointer
  • ERANGE β€” no match found for search
  • ENODEV β€” if device not found in list of registered devices

πŸ¦‹ NOTE πŸ¦‹

available is a modifier for the search, no cap. if available=true, then the match is for exact matching frequency and is available in the stored OPP table. if false, the match is for exact frequency which is not available ✨

This provides a mechanism to enable an opp which is not available currently or the opposite as well πŸ”

The callers are required to call dev_pm_opp_put for the returned OPP after use. don't forget, bestie β€” that part matters πŸ’…

πŸ‘‘ SEE ALSO πŸ‘‘

Kernel file ./drivers/opp/core.c and the whole sibling squad:


that's the whole page, bestie πŸ’…βœ¨ xoxo β€” source ./drivers/opp, manual Kernel API Manual, dated October 2026, page dev_pm_opp_find_freq_exact(9) πŸŽ€

πŸ“¦ where this page comes from