acpi_video_device_EDID(9)

πŸ“¦ version 7.3.1, in nixpkgs unstable

πŸ’– acpi_video_device_EDID ✨

okay so bestie, gather round, because today we're reading a function from the Kernel API Manual and honestly? it's iconic. it's giving "small function, big job" energy. it lives in the kernel, it talks to your monitor, and it's literally just trying to find out what kind of screen you plugged in πŸ–₯️🌸


✨ SYNOPSIS ✨

int acpi_video_device_EDID (struct acpi_video_device *device , void
**edid , int length );

that's the whole signature, no cap. three arguments, one int coming back at you 🫢


πŸŽ€ ARGUMENTS πŸŽ€

  • device β€” the video output device, bestie. like your LCD, your CRT, whatever .. means here (yes the original literally says LCD, CRT, .. and we're keeping it exactly like that πŸ’…). it's the thing you're asking about.
  • edid β€” this is the address where the returned EDID pointer gets dropped off. think of it as a lil mailbox πŸ“¬ and the function is the mail carrier.
  • length β€” the _DDC length you wanna request. and listen, this one's important: it must be a multiple of 128. not vibing with 128? the function's not vibing with you. no exceptions πŸ™ˆ

🌸 DESCRIPTION 🌸

so what does it actually do? it gets the EDID from ACPI _DDC. that's it, that's the whole plot πŸ¦‹

on success, a pointer to the EDID data gets written to the edid address, and the length of the EDID is returned. and here's the part where you have to be a responsible main character: the caller is responsible for freeing the edid pointer. don't just walk away from it, bestie, that's a memory leak and we don't do those here 🧚

the return value is giving very clear vibes:

  • a positive value means success, and that value is the length of the EDID πŸ’–
  • a negative value means error 😭
so like, genuinely, keep track of that pointer. the function hands you the EDID and then it's your problem. iconique, but also: free it. please. πŸ™

πŸ‘‘ SEE ALSO πŸ‘‘

  • Kernel file ./drivers/acpi/acpi_video.c β€” go read the source, iykyk ⭐

and that's the whole page, bestie! sourced from ./drivers/acpi, dated October 2026, and yeah β€” this absolutely ate πŸ’…βœ¨πŸ”₯

πŸ“¦ where this page comes from