> Subject: RE: [PATCH] drm/i915/backlight: Remove try_vesa_interface
> 
> > Subject: RE: [PATCH] drm/i915/backlight: Remove try_vesa_interface
> >
> > > Subject: Re: [PATCH] drm/i915/backlight: Remove try_vesa_interface
> > >
> > > On Tue, Feb 24, 2026 at 08:43:22AM +0530, Suraj Kandpal wrote:
> > > > Remove try_vesa_interface. This is because we now make VESA
> > > > Interface as a fallback mechanism for Panels which needs VESA DPCD
> > > > AUX backlight mechanism to work but have a broken VBT indicating
> > otherwise.
> > > > While at in sneak in a small comment cleanup too.
> > >
> > > This broke the backlight on my VLV chromebook.
> > >
> > >  i915 0000:00:02.0: [drm:intel_dp_aux_init_backlight_funcs [i915]]
> > > [CONNECTOR:98:eDP-1] Detected unsupported HDR backlight interface
> > > version
> > > 0
> > > +i915 0000:00:02.0: [drm:intel_dp_aux_init_backlight_funcs [i915]]
> > > [CONNECTOR:98:eDP-1] AUX Backlight Control Supported!
> > > +i915 0000:00:02.0: [drm:intel_dp_aux_init_backlight_funcs [i915]]
> > > +[CONNECTOR:98:eDP-1] Using VESA eDP backlight controls
> > >  i915 0000:00:02.0: [drm:intel_panel_init [i915]]
> > > [CONNECTOR:98:eDP-1] DRRS
> > > type: none
> > > +i915 0000:00:02.0: [drm:drm_edp_backlight_init
> > > +[drm_display_helper]] AUX C/DP C: Found backlight: aux_set=1
> > > +aux_enable=0 mode=1
> > > +i915 0000:00:02.0: [drm:drm_edp_backlight_init
> > > +[drm_display_helper]] AUX C/DP C: Backlight caps: level=1023/1023
> > > +pwm_freq_pre_divider=0
> > > +lsb_reg_used=1
> > > +i915 0000:00:02.0: [drm:intel_dp_aux_vesa_setup_backlight [i915]]
> > > +[CONNECTOR:98:eDP-1] AUX VESA backlight enable is controlled
> > > +through PWM
> > > +i915 0000:00:02.0: [drm:intel_dp_aux_vesa_setup_backlight [i915]]
> > > +[CONNECTOR:98:eDP-1] AUX VESA backlight level is controlled through
> > > +DPCD
> > >  i915 0000:00:02.0: [drm:vlv_setup_backlight [i915]]
> > > [CONNECTOR:98:eDP-1] Using native PWM for backlight control (on pipe
> > > A)
> > > -i915 0000:00:02.0: [drm:intel_backlight_setup [i915]]
> > > [CONNECTOR:98:eDP-1] backlight initialized, enabled, brightness
> > > 7812/7812
> > > +i915 0000:00:02.0: [drm:intel_dp_aux_vesa_setup_backlight [i915]]
> > > +[CONNECTOR:98:eDP-1] Using AUX VESA interface for backlight control
> > > +i915 0000:00:02.0: [drm:intel_backlight_setup [i915]]
> > > +[CONNECTOR:98:eDP-1] backlight initialized, disabled, brightness
> > > +1023/1023
> >
> > Hi Ville can you provide the full logs from boot with debug set to
> > 0x10e and also when you manipulate your backlight
> >
> > I did have a commit that checks if vesa is actually possible because
> > some panels report vesa support even though they really cannot
> > 0fb03890d182 drm/i915/backlight: Check if VESA backlight is possible
> >
> > Also what would be the edp Panel model I can try replicate this issue
> > locally after I find a vlv machine
> 
> Hi Ville,
> Never mind I found the actual issue, slight oversight by me thanks for 
> bringing
> this to my attention Went through the eDP spec again
> 
> So apparently if we are only relying only on
> BACKLIGHT_BRIGHTNESS_AUX_SET_CAPABLE
> BACKLIGHT_AUX_ENABLE_CAPABLE should also be set. The only case where
> one is independent of the other Is when we are using BL_ENABLE bit in which
> case the brightness is a production function of the level and pwm level.
> 
> Let me float a patch.
> 
> Regards,
> Suraj Kandpal
> 

I have sent the fix can you perhaps test it

Regards,
Suraj Kandpal

> >
> > Regards,
> > Suraj Kandpal
> >
> > >
> > > >
> > > > Closes:
> > > > https://gitlab.freedesktop.org/drm/i915/kernel/-/issues/15679
> > > > Signed-off-by: Suraj Kandpal <[email protected]>
> > > > ---
> > > >  .../drm/i915/display/intel_dp_aux_backlight.c | 19
> > > > +++++++------------
> > > >  1 file changed, 7 insertions(+), 12 deletions(-)
> > > >
> > > > diff --git a/drivers/gpu/drm/i915/display/intel_dp_aux_backlight.c
> > > > b/drivers/gpu/drm/i915/display/intel_dp_aux_backlight.c
> > > > index eb05ef4bd9f6..a8e9872566cd 100644
> > > > --- a/drivers/gpu/drm/i915/display/intel_dp_aux_backlight.c
> > > > +++ b/drivers/gpu/drm/i915/display/intel_dp_aux_backlight.c
> > > > @@ -644,9 +644,10 @@ int intel_dp_aux_init_backlight_funcs(struct
> > > intel_connector *connector)
> > > >         struct intel_dp *intel_dp = intel_attached_dp(connector);
> > > >         struct drm_device *dev = connector->base.dev;
> > > >         struct intel_panel *panel = &connector->panel;
> > > > -       bool try_intel_interface = false, try_vesa_interface = false;
> > > > +       bool try_intel_interface = false;
> > > >
> > > > -       /* Check the VBT and user's module parameters to figure out 
> > > > which
> > > > +       /*
> > > > +        * Check the VBT and user's module parameters to figure out
> > > > +which
> > > >          * interfaces to probe
> > > >          */
> > > >         switch (display->params.enable_dpcd_backlight) { @@ -655,7
> > > > +656,6
> > > @@
> > > > int intel_dp_aux_init_backlight_funcs(struct intel_connector *connector)
> > > >         case INTEL_DP_AUX_BACKLIGHT_AUTO:
> > > >                 switch (panel->vbt.backlight.type) {
> > > >                 case INTEL_BACKLIGHT_VESA_EDP_AUX_INTERFACE:
> > > > -                       try_vesa_interface = true;
> > > >                         break;
> > > >                 case INTEL_BACKLIGHT_DISPLAY_DDI:
> > > >                         try_intel_interface = true;
> > > > @@ -668,20 +668,12 @@ int intel_dp_aux_init_backlight_funcs(struct
> > > intel_connector *connector)
> > > >                 if (panel->vbt.backlight.type !=
> > > INTEL_BACKLIGHT_VESA_EDP_AUX_INTERFACE)
> > > >                         try_intel_interface = true;
> > > >
> > > > -               try_vesa_interface = true;
> > > > -               break;
> > > > -       case INTEL_DP_AUX_BACKLIGHT_FORCE_VESA:
> > > > -               try_vesa_interface = true;
> > > >                 break;
> > > >         case INTEL_DP_AUX_BACKLIGHT_FORCE_INTEL:
> > > >                 try_intel_interface = true;
> > > >                 break;
> > > >         }
> > > >
> > > > -       /* For eDP 1.5 and above we are supposed to use VESA interface 
> > > > for
> > > brightness control */
> > > > -       if (intel_dp->edp_dpcd[0] >= DP_EDP_15)
> > > > -               try_vesa_interface = true;
> > > > -
> > > >         /*
> > > >          * Since Intel has their own backlight control interface, the
> > > > majority of
> > > machines out there
> > > >          * using DPCD backlight controls with Intel GPUs will be using
> > > > this interface as opposed to @@ -694,6 +686,9 @@ int
> > > intel_dp_aux_init_backlight_funcs(struct intel_connector *connector)
> > > >          * panel with Intel's OUI - which is also required for us to be
> > > > able to
> > > detect Intel's
> > > >          * backlight interface at all. This means that the only sensible
> > > > way for us
> > > to detect both
> > > >          * interfaces is to probe for Intel's first, and VESA's second.
> > > > +        *
> > > > +        * Also there is a chance some VBT's may advertise false Intel
> > > > +backlight
> > > support even if the
> > > > +        * tcon's DPCD says otherwise. This mean we keep VESA interface
> > > > +as
> > > fallback in that case.
> > > >          */
> > > >         if (try_intel_interface &&
> > > intel_dp_aux_supports_hdr_backlight(connector) &&
> > > >             intel_dp->edp_dpcd[0] <= DP_EDP_14b) { @@ -703,7 +698,7 @@
> > > > int intel_dp_aux_init_backlight_funcs(struct intel_connector *connector)
> > > >                 return 0;
> > > >         }
> > > >
> > > > -       if (try_vesa_interface &&
> > > intel_dp_aux_supports_vesa_backlight(connector)) {
> > > > +       if (intel_dp_aux_supports_vesa_backlight(connector)) {
> > > >                 drm_dbg_kms(dev, "[CONNECTOR:%d:%s] Using VESA eDP
> > > backlight controls\n",
> > > >                             connector->base.base.id, 
> > > > connector->base.name);
> > > >                 panel->backlight.funcs = &intel_dp_vesa_bl_funcs;
> > > > --
> > > > 2.34.1
> > >
> > > --
> > > Ville Syrjälä
> > > Intel

Reply via email to