drm_of_component_probe(9)

πŸ“¦ version 7.3.1, in nixpkgs unstable

πŸ’… drm_of_component_probe β€” a Kernel API Manual moment

okay bestie, so this page is from the Kernel API Manual (yes, that manual), and today's main character is drm_of_component_probe(9). buckle up, she's a probe function and she's iconic ✨


🌸 NAME 🌸

drm_of_component_probe β€” the generic probe function for a component based master, fr fr 🫢


✨ SYNOPSIS ✨

int drm_of_component_probe (struct device *dev , int
(*compare_of)(struct device *, void *) , const struct
component_master_ops *m_ops );

like, that's the whole vibe right there πŸ’…


πŸŽ€ ARGUMENTS πŸŽ€

  • dev β€” the master device containing the OF node. she's the one holding the node, okay πŸ‘‘
  • compare_of β€” the compare function used for matching components. lowkey the matchmaker of the whole operation 🧚
  • m_ops β€” the component master ops to be used. these are the ops she's gonna run with πŸ’–

πŸ¦‹ DESCRIPTION πŸ¦‹

so what she actually does: she parses the platform device OF node and binds all the components associated with the master. no cap, all of them.

the important little detail bestie β€” interface ports are added before the encoders, and that's specifically in order to satisfy their .bind requirements. it's giving "order matters, do not come for me" energy 😭πŸ”₯

the bindings live here, go read them iykyk:

https://github.com/devicetree-org/dt-
schema/blob/main/dtschema/schemas/graph.yaml

and the return value? she returns zero if successful, or one of the standard error codes if it fails. that's it, that's the whole tea β˜•

ngl the "standard error codes" part means you should actually check the return, bestie. don't just ignore her πŸ™ˆ

πŸ’œ SEE ALSO πŸ’œ

literally the whole drm_of.c friend group, periodt:


🌈 sign-off 🌈

and that's the page!! she lives in ./drivers/gpu/drm, she's dated October 2026, and she answers to the name drm_of_component_probe(9). go forth and probe responsibly, bestie πŸ’–πŸ¦‹πŸ“β­πŸ‘‘

πŸ“¦ where this page comes from