Hi Suraj,

kernel test robot noticed the following build warnings:

[auto build test WARNING on next-20250411]
[cannot apply to linus/master drm-intel/for-linux-next 
drm-intel/for-linux-next-fixes v6.15-rc2 v6.15-rc1 v6.14 v6.15-rc5]
[If your patch is applied to the wrong git tree, kindly drop us a note.
And when submitting patch, we suggest to use '--base' as documented in
https://git-scm.com/docs/git-format-patch#_base_tree_information]

url:    
https://github.com/intel-lab-lkp/linux/commits/Suraj-Kandpal/drm-dp-Introduce-new-member-in-drm_backlight_info/20250414-132323
base:   next-20250411
patch link:    
https://lore.kernel.org/r/20250414041637.128039-7-suraj.kandpal%40intel.com
patch subject: [PATCH 06/13] drm/dp: Modify drm_edp_probe_state
config: i386-randconfig-141-20250414 
(https://download.01.org/0day-ci/archive/20250507/202505071939.iq3zwvvx-...@intel.com/config)
compiler: gcc-12 (Debian 12.2.0-14) 12.2.0

If you fix the issue in a separate patch/commit (i.e. not just a new version of
the same patch/commit), kindly add following tags
| Reported-by: kernel test robot <l...@intel.com>
| Closes: 
https://lore.kernel.org/oe-kbuild-all/202505071939.iq3zwvvx-...@intel.com/

smatch warnings:
drivers/gpu/drm/display/drm_dp_helper.c:4215 drm_edp_backlight_probe_state() 
warn: inconsistent indenting

vim +4215 drivers/gpu/drm/display/drm_dp_helper.c

  4182  
  4183  static inline int
  4184  drm_edp_backlight_probe_state(struct drm_dp_aux *aux, struct 
drm_edp_backlight_info *bl,
  4185                                u8 *current_mode)
  4186  {
  4187          int ret;
  4188          u8 buf[3];
  4189          u8 mode_reg;
  4190  
  4191          ret = drm_dp_dpcd_read_byte(aux, 
DP_EDP_BACKLIGHT_MODE_SET_REGISTER, &mode_reg);
  4192          if (ret < 0) {
  4193                  drm_dbg_kms(aux->drm_dev, "%s: Failed to read backlight 
mode: %d\n",
  4194                              aux->name, ret);
  4195                  return ret < 0 ? ret : -EIO;
  4196          }
  4197  
  4198          *current_mode = (mode_reg & DP_EDP_BACKLIGHT_CONTROL_MODE_MASK);
  4199          if (!bl->aux_set)
  4200                  return 0;
  4201  
  4202          if (*current_mode == DP_EDP_BACKLIGHT_CONTROL_MODE_DPCD) {
  4203                  int size = 1 + bl->lsb_reg_used;
  4204  
  4205                  if (bl->luminance_set) {
  4206                          ret = drm_dp_dpcd_read_data(aux, 
DP_EDP_PANEL_TARGET_LUMINANCE_VALUE,
  4207                                                      buf, sizeof(buf));
  4208                          if (ret < 0) {
  4209                                  drm_dbg_kms(aux->drm_dev,
  4210                                              "%s: Failed to read 
backlight level: %d\n",
  4211                                              aux->name, ret);
  4212                                  return ret;
  4213                  }
  4214  
> 4215                  return (buf[0] | buf[1] << 8 | buf[2] << 16) / 1000;
  4216                  } else {
  4217                          ret = drm_dp_dpcd_read_data(aux, 
DP_EDP_BACKLIGHT_BRIGHTNESS_MSB,
  4218                                                      buf, size);
  4219                          if (ret < 0) {
  4220                                  drm_dbg_kms(aux->drm_dev,
  4221                                              "%s: Failed to read 
backlight level: %d\n",
  4222                                              aux->name, ret);
  4223                                  return ret;
  4224                          }
  4225  
  4226                          if (bl->lsb_reg_used)
  4227                                  return (buf[0] << 8) | buf[1];
  4228                          else
  4229                                  return buf[0];
  4230                  }
  4231          }
  4232  
  4233          /*
  4234           * If we're not in DPCD control mode yet, the programmed 
brightness value is meaningless and
  4235           * the driver should assume max brightness
  4236           */
  4237          return bl->max;
  4238  }
  4239  

-- 
0-DAY CI Kernel Test Service
https://github.com/intel/lkp-tests/wiki

Reply via email to