STRUCT V4L2_SUBDEV_AUDIO_OPS(9)

πŸ“¦ version 7.3.1, in nixpkgs unstable

🎧 NAME

okay bestie, this is the struct v4l2_...ev_audio_ops(9) page from the Kernel API Manual, and it's literally giving β€œcallbacks used for audio-related settings” β€” the whole cute little callback crew for struct v4l2_subdev_audio_ops. no cap, that's the name vibe. πŸ’–

πŸ“œ SYNOPSIS

struct v4l2_subdev_audio_ops {
    int (*s_clock_freq)(struct v4l2_subdev *sd, u32 freq);
    int (*s_i2s_clock_freq)(struct v4l2_subdev *sd, u32 freq);
    int (*s_routing)(struct v4l2_subdev *sd, u32 input, u32 output, u32 config);
    int (*s_stream)(struct v4l2_subdev *sd, int enable);
 };

🎀 Members

  • s_clock_freq β€” sets the frequency (in Hz) of the audio clock output. It's used to slave an audio processor to the video decoder, ensuring that audio and video remain synchronized. The usual values for the frequency are 48000, 44100 or 32000 Hz. If the frequency is not supported, then -EINVAL is returned. ⏰
  • s_i2s_clock_freq β€” sets I2S speed in bps. This is used to provide a standard way to select I2S clock used by driving digital audio streams at some board designs. The usual values for the frequency are 1024000 and 2048000. If the frequency is not supported, then -EINVAL is returned. 🎚️
  • s_routing β€” used to define the input and/or output pins of an audio chip, and any additional configuration data.
⚠️ Big warning, bestie: never attempt to use user-level input IDs (e.g. Composite, S-Video, Tuner) at this level. An i2c device shouldn't know about whether an input pin is connected to a Composite connector β€” because on another board or platform it might be connected to something else entirely. The calling driver is responsible for mapping a user-level input to the right pins on the i2c device. πŸ”Œ
  • s_stream β€” used to notify the audio code that stream will start or has stopped. ▢️⏹️

🌈 SEE ALSO

Here's the whole extended friend group 🫢 β€” every reference, no skips:


πŸ’– cute little sign-off πŸ’– source/version: ./include/media Β· date: October 2026 Β· page: struct v4l2_...ev_audio_ops(9). mwah, bye bestie 🫢

πŸ“¦ where this page comes from