media_entit...pad_interdep(9)
π media_entity_has_pad_interdep(9) β like, the Kernel API Manual, section 9 bestie π
okay so this is a page from the Kernel API Manual, section 9, and the whole thing lives under the very cute (and very truncated) name media_entit...pad_interdep(9). yes the header really is that dramatic. anyway. buckle up π¦
β¨ NAME β¨
media_entity_has_pad_interdep β checks the interdependency between two pads, no cap π
πΈ SYNOPSIS πΈ
bool media_entity_has_pad_interdep (struct media_entity *entity ,
unsigned int pad0 , unsigned int pad1 );
literally that's it. three arguments and a bool. iconic. β¨
π«Ά ARGUMENTS π«Ά
entityβ the entity we're snooping on, main character energy fr π§pad0β the first pad index πpad1β the second pad index π
π DESCRIPTION π
so what this function actually does: it checks the interdependency inside the entity between pad0 and pad1. and if two pads are interdependent, that means they're part of the same pipeline, and enabling one of the pads means the other pad becomes "locked" β so it doesn't allow configuration changes. locked in. no edits. periodt. π
the way it works is it uses the media_entity_operations.has_pad_interdep operation to check the dependency inside the entity between pad0 and pad1. and here's the plot twist: if the has_pad_interdep operation is not implemented, then all pads of the entity are considered to be interdependent. all of them. the whole friend group π«Ά
one more thing bestie β one of pad0 and pad1 must be a sink pad and the other one a source pad. the function returns false if both pads are sinks or both pads are sources. like, no. that's not how this works. π
β οΈ the caller must hold entity->graph_obj.mdev->mutex. not me reminding you and you still forgetting. lock it. π
π RETURN π
true if the pads are connected internally, false otherwise. that's the whole vibe check π«
β SEE ALSO β
- Kernel file
./drivers/media/mc/mc-entity.cπ dev_dbg_obj(9)media_graph_walk_init(9)media_graph_walk_cleanup(9)struct media_pipeline_walk_entry(9)struct media_pipeline_walk(9)
go read them. iykyk. π¦
okay so that's the page!! sourced from ./drivers/media/mc, dated October 2026, and honestly? she ate. mwah π go hold that mutex and slay π₯π
π¦ where this page comes from
- nixpkgs unstable: linux-manual 7.3.1
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash-1017 on : a language model's rewrite of the original, under its terms