vsp1_adjust_color_space(9)

πŸ“¦ version 7.3.1, in nixpkgs unstable

πŸ’… vsp1_adjust_color_space (9) β€” the kernel API manual, bestie edition πŸŽ€

okay so real talk, this is a page from the Kernel API Manual and it's about one VERY specific little helper, vsp1_adjust_color_space. she's not famous, she's not doing the most, but she's doing her job and honestly? obsessed. ✨


🌸 NAME 🌸

vsp1_adjust_color_space β€” literally just adjusting the color space fields in a format. that's it. that's the whole gig. πŸ’…


πŸ¦‹ SYNOPSIS πŸ¦‹

void vsp1_adjust_color_space (u32 code , u32 *colorspace , u8 *xfer_func
, u8 *encoding , u8 *quantization );

like… five whole parameters. she's thorough. no cap. πŸ”₯


✨ ARGUMENTS ✨

  • code β€” the media bus code πŸ‘‘
  • colorspace β€” the colorspace 🌈
  • xfer_func β€” the transfer function 🧚
  • encoding β€” the encoding πŸ’œ
  • quantization β€” the quantization ⭐

(not me listing them all because we do NOT skip the boring parts here, bestie 🫢)


πŸ’– DESCRIPTION πŸ’–

okay so here's the vibe check on what this function actually does: it adjusts all the color space fields of a video device of subdev format structure β€” and it does that while taking into account three things, in case you were wondering:

  1. the requested format
  2. the requested color space
  3. the limitations of the VSP1

and like, it should be used in the video device and subdev set format handlers. that's where she lives. main character energy only. πŸ’…

now the tea about what's configurable vs. what's not:

  • the colorspace and xfer_func fields are freely configurable, because they are out of scope for VSP processing β€” so do whatever, bestie, it's not her problem 🌸
  • the encoding and quantization are hardcoded for non-YUV formats πŸ’€ (yeah, sorry, fixed, no takebacks) and can be configured for YUV formats ✨

so basically: YUV formats get options, non-YUV formats get the default treatment. iykyk. πŸŽ€


πŸ”₯ SEE ALSO πŸ”₯

like the whole squad, fr fr. 🫢


⚠️ quick aside! the page says this function is meant to be used in the video device and subdev set format handlers β€” so if you're calling it from somewhere random, that's giving "did not read the docs" energy 😭

okay that's the page!! 🌟 one last thing: this lil beauty comes from ./drivers/media/platform/renes... (that's the source string, truncated on the page as-is, don't come for me πŸ™ˆ) and it's dated October 2026, and the whole page signs off as vsp1_adjust_color_space(9) because of course it does β€” she's the moment. πŸ’–βœ¨πŸŽ€

πŸ“¦ where this page comes from