drm/tests: hdmi: handle empty modes in find_preferred_mode()
If the connector->modes list is empty, then list_first_entry() returns a bogus entry. Change that to use list_first_entry_or_null(). Reviewed-by:Maxime Ripard <mripard@kernel.org> Link: https://patchwork.freedesktop.org/patch/msgid/20241130-hdmi-mode-valid-v5-1-742644ec3b1f@linaro.org Signed-off-by:
Dmitry Baryshkov <dmitry.baryshkov@linaro.org>
Loading
Please sign in to comment