v4l2_src_cha...ev_subscribe(9)

πŸ“¦ version 7.3.1, in nixpkgs unstable

πŸ’… NAME πŸ’…

v4l2_src_change_event_subdev_subscribe β€” bestie, it's the variant of v4l2_event_subscribe() that's specifically meant to subscribe you to events of the type %V4L2_EVENT_SOURCE_CHANGE, and literally nothing else. It's giving "one job, and it does it."

So like, this page is from the Kernel API Manual, section 9, and the whole function name is v4l2_src_change_event_subdev_subscribe (the page title is just it getting cutely abbreviated to v4l2_src_cha...ev_subscribe(9) because terminal column budgets are real 😭). It's the subdev-flavoured sibling of v4l2_src_change_event_subscribe(9) β€” iykyk 🧚


✨ SYNOPSIS ✨

int v4l2_src_change_event_subdev_subscribe (struct v4l2_subdev *sd ,
struct v4l2_fh *fh , struct v4l2_event_subscription *sub );

Return type is int, three pointers go in, no cap. 🫢


πŸŽ€ ARGUMENTS πŸŽ€

  • sd β€” pointer to struct v4l2_subdev. Yes, the subdev. It's the main character here, we love her.
  • fh β€” pointer to struct v4l2_fh. This is the file handle situation, keeping track of who's subscribed to what.
  • sub β€” pointer to struct v4l2_event_subscription. The subscription itself, aka the actual thing you're signing up for. Slay.

That's it. Three args. No hidden extras, no jump scares. πŸ’€


πŸ¦‹ SEE ALSO πŸ¦‹

Kernel file ./include/media/v4l2-event.h β€” go read it, it's iconic.

And the whole friend group of related functions and structs, all of them, in their original order bestie:

Like, seriously, if you're poking at event subscriptions, at least skim v4l2_event_subscribe(9) and v4l2_event_unsubscribe(9) first β€” they're the blueprint. 🌸

Ok that's the whole page, love you, go forth and subscribe to source-change events responsibly βœ¨πŸ‘‘

β€” with love, from ./include/media, dated October 2026, signing off as v4l2_src_cha...ev_subscribe(9) πŸŽ€πŸ’œ

πŸ“¦ where this page comes from