]> www.infradead.org Git - users/hch/misc.git/commitdiff
drm: panel-backlight-quirks: Make EDID match optional
authorAntheas Kapenekakis <lkml@antheas.dev>
Fri, 29 Aug 2025 14:55:36 +0000 (16:55 +0200)
committerMario Limonciello (AMD) <superm1@kernel.org>
Wed, 3 Sep 2025 15:22:47 +0000 (10:22 -0500)
Currently, having a valid panel_id match is required to use the quirk
system. For certain devices, we know that all SKUs need a certain quirk.
Therefore, allow not specifying ident by only checking for a match
if panel_id is non-zero.

Tested-by: Philip Müller <philm@manjaro.org>
Reviewed-by: Mario Limonciello <mario.limonciello@amd.com>
Signed-off-by: Antheas Kapenekakis <lkml@antheas.dev>
Link: https://lore.kernel.org/r/20250829145541.512671-2-lkml@antheas.dev
Acked-by: Alex Deucher <alexander.deucher@amd.com>
Signed-off-by: Mario Limonciello (AMD) <superm1@kernel.org>
drivers/gpu/drm/drm_panel_backlight_quirks.c

index 598f812b7cb38f4bca81a49648709ec26b6956e0..b38b33e26ea5c399058fb2b7378482153dfaee4a 100644 (file)
@@ -50,7 +50,7 @@ static bool drm_panel_min_backlight_quirk_matches(const struct drm_panel_min_bac
        if (!dmi_match(quirk->dmi_match.field, quirk->dmi_match.value))
                return false;
 
-       if (!drm_edid_match(edid, &quirk->ident))
+       if (quirk->ident.panel_id && !drm_edid_match(edid, &quirk->ident))
                return false;
 
        return true;