media_entity_get_fwnode_pad(9)

πŸ“¦ version 7.3.1, in nixpkgs unstable

πŸ‘‘ NAME πŸ‘‘

media_entity_get_fwnode_pad(9) β€” Get pad number from fwnode. This icon is from the Kernel API Manual, and she's here to help you find the right pad without losing your whole entire mind πŸ’…βœ¨

πŸŽ€ SYNOPSIS πŸŽ€

int media_entity_get_fwnode_pad (struct media_entity *entity , const
       struct fwnode_handle *fwnode , unsigned long direction_flags );

πŸ’… ARGUMENTS πŸ’…

  • entity β€” The entity. That's the main character here.
  • fwnode β€” Pointer to the fwnode_handle which should be used to find the pad. This is the little clue that helps you track it down πŸ”
  • direction_flags β€” Expected direction of the pad, as defined in :ref: for include/uapi/linux/media.h (<media_header>) β€” seek for MEDIA_PAD_FL_* πŸ’«

🌸 DESCRIPTION 🌸

okay so bestie, this function can be used to resolve the media pad number from a fwnode. It's genuinely useful for devices which use more complex mappings of media pads β€” like when the pad situation is giving "custom layout" and not "one-size-fits-all" πŸ¦‹

If the entity does not implement the get_fwnode_pad operation then this function searches the entity for the first pad that matches the direction_flags. Lowkey a fallback queen πŸ‘‘

πŸ’– RETURN πŸ’–

returns the pad number on success or a negative error code. So on success you get the pad number, and on failure you get a negative error code β€” no cap, that's the whole vibe check 😭

πŸ¦‹ SEE ALSO πŸ¦‹

The whole extended media family is in the group chat too:


okay bestie, that's the whole page πŸ’– this one lives in ./include/media, stamped October 2026, and it's media_entity_get_fwnode_pad(9) signing off πŸŽ€βœ¨

πŸ“¦ where this page comes from