drm_mode_validate_driver(9)
π drm_mode_validate_driver(9)
okay bestie, so this is a page from the Kernel API Manual β like, the group chat of kernel documentation β and today's main character is drm_mode_validate_driver. she's a little validation girlie and honestly she ate β¨
πΈ NAME
drm_mode_validate_driver β make sure the mode is, like, somewhat sane π«Ά
ngl "somewhat sane" is doing a lot of heavy lifting here but that's genuinely the vibe
π¦ SYNOPSIS
enum drm_mode_status drm_mode_validate_driver (struct drm_device *dev ,
const struct drm_display_mode *mode );
literally just hand her a device and a mode and she'll tell you what's up π
π ARGUMENTS
devβ the drm device, aka the whole situation πmodeβ the mode to check, the one on trial, the one getting a vibe check π
π DESCRIPTION
so the way this works is: first she does the basic validation on the mode β just the standard sanity stuff, no cap β and then she lets the driver have a turn. the driver gets to check for its own device/driver specific limitations through the optional drm_mode_config_helper_funcs.mode_valid hook π
the key word there is optional β iykyk, if the driver doesn't set that hook, that step just... doesn't happen. no drama, no error, she just moves on π§
β RETURN
the mode status π« (that enum drm_mode_status from the synopsis, she gives it right back to you)
π SEE ALSO
kernel file: ./drivers/gpu/drm/drm_modes.c
and now the entire extended friend group, everyone say hi π:
drm_mode_debug_printmodeline(9)drm_mode_create(9)drm_mode_destroy(9)drm_mode_probed_add(9)drm_analog_tv_mode(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_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)
okay that's the whole page, love u, go validate some modes responsibly ππ¦
this one lives in ./drivers/gpu/drm and the version of record is dated October 2026 β so like, future girlie behavior fr fr πβ¨π
π¦ 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