drm_analog_tv_mode(9)
π drm_analog_tv_mode π
okay so bestie, welcome to the Kernel API Manual β today's main character is drm_analog_tv_mode, and it literally makes a display mode for an analog TV. retro vibes only, no cap β¨
β¨ NAME β¨
drm_analog_tv_mode β creates a display mode for an analog TV πΊ
πΈ SYNOPSIS πΈ
struct drm_display_mode * drm_analog_tv_mode (struct drm_device *dev ,
enum drm_connector_tv_mode tv_mode , unsigned long pixel_clock_hz ,
unsigned int hdisplay , unsigned int vdisplay , bool interlace );
π¦ ARGUMENTS π¦
devβ the drm device, your main squeeze here π«Άtv_modeβ the TV Mode standard you're building a mode for. checkDRM_MODE_TV_MODE_*for the full lineup, iykykpixel_clock_hzβ Pixel Clock Frequency, in Hertz. hertz!! β‘hdisplayβ the hdisplay sizevdisplayβ the vdisplay sizeinterlaceβ whether to compute an interlaced mode. yes it's a bool, yes it matters π
π DESCRIPTION π
This function creates a struct drm_display_mode instance suited for an analog TV output, for one of the usual analog TV modes. the way it just⦠does that. iconic.
Where this is DRM_MODE_TV_MODE_MONOCHROME, a 625-line mode will be created π€π€ (monochrome excellence, we love to see it)
heads up bestie: note that hdisplay is larger than the usual constraints for the PAL and NTSC timings, and we'll choose to ignore most timings constraints to reach those resolutions. so likeβ¦ yeah, she's bending the rules a lil π but on purpose, fr fr.
π RETURN π
A pointer to the mode, allocated with drm_mode_create. Returns NULL on error π (sad girl hours if that happens)
π SEE ALSO π
the Kernel file ./drivers/gpu/drm/drm_modes.c β go read her, she's the source of truth π§
and the whole bestie group chat:
drm_mode_debug_printmodeline(9),drm_mode_create(9),drm_mode_destroy(9),drm_mode_probed_add(9),drm_cvt_mode(9),drm_gtf_mode_complex(9),drm_gtf_mode(9),drm_display_mode_from_videomode(9),drm_display_mode_to_videomode(9),drm_bus_flags_from_videomode(9),of_get_drm_display_mode(9),of_get_drm_panel_display_mode(9),drm_mode_set_name(9),drm_mode_vrefresh(9),drm_mode_get_hv_timing(9),drm_mode_set_crtcinfo(9),drm_mode_copy(9),drm_mode_init(9),drm_mode_duplicate(9),drm_mode_match(9),drm_mode_equal(9),drm_mode_equal_no_clocks(9),drm_mode_equal_no_clocks_no_stereo(9),drm_mode_validate_driver(9),drm_mode_validate_size(9),drm_mode_validate_ycbcr420(9),drm_mode_prune_invalid(9),drm_mode_compare(9),drm_mode_sort(9),drm_connector_list_update(9),drm_mode_parse_command_line_for_connector(9),drm_mode_create_from_cmdline_mode(9),drm_mode_convert_to_umode(9),drm_mode_convert_umode(9),drm_mode_is_420_only(9),drm_mode_is_420_also(9),drm_mode_is_420(9),drm_set_preferred_mode(9)
that's the whole page, bestie π sourced from ./drivers/gpu/drm, dated October 2026, and it's literally called drm_analog_tv_mode(9) β 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