Hi Linus,

I love your patch! Perhaps something to improve:

[auto build test WARNING on backlight/for-backlight-next]
[also build test WARNING on arm-soc/for-next spi/for-next 
tegra-drm/drm/tegra/for-next v5.7-rc3 next-20200428]
[if your patch is applied to the wrong git tree, please drop us a note to help
improve the system. BTW, we also suggest to use '--base' option to specify the
base tree in git format-patch, please see https://stackoverflow.com/a/37406982]

url:    
https://github.com/0day-ci/linux/commits/Linus-Walleij/backlight-lms283gf05-Convert-to-GPIO-descriptors/20200429-181222
base:   https://git.kernel.org/pub/scm/linux/kernel/git/lee/backlight.git 
for-backlight-next
config: c6x-allyesconfig (attached as .config)
compiler: c6x-elf-gcc (GCC) 9.3.0
reproduce:
        wget 
https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O 
~/bin/make.cross
        chmod +x ~/bin/make.cross
        # save the attached .config to linux build tree
        COMPILER_INSTALL_PATH=$HOME/0day GCC_VERSION=9.3.0 make.cross ARCH=c6x 

If you fix the issue, kindly add following tag as appropriate
Reported-by: kbuild test robot <l...@intel.com>

All warnings (new ones prefixed by >>):

   drivers/video/backlight/lms283gf05.c: In function 'lms283gf05_probe':
   drivers/video/backlight/lms283gf05.c:151:6: warning: unused variable 'ret' 
[-Wunused-variable]
     151 |  int ret = 0;
         |      ^~~
>> drivers/video/backlight/lms283gf05.c:153:12: warning: 'st' is used 
>> uninitialized in this function [-Wuninitialized]
     153 |  st->reset = gpiod_get_optional(&spi->dev, "reset", GPIOD_OUT_HIGH);
         |  ~~~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

vim +/st +153 drivers/video/backlight/lms283gf05.c

   146  
   147  static int lms283gf05_probe(struct spi_device *spi)
   148  {
   149          struct lms283gf05_state *st;
   150          struct lcd_device *ld;
 > 151          int ret = 0;
   152  
 > 153          st->reset = gpiod_get_optional(&spi->dev, "reset", 
 > GPIOD_OUT_HIGH);
   154          if (st->reset)
   155                  gpiod_set_consumer_name(st->reset, "LMS283GF05 RESET");
   156  
   157          st = devm_kzalloc(&spi->dev, sizeof(struct lms283gf05_state),
   158                                  GFP_KERNEL);
   159          if (st == NULL)
   160                  return -ENOMEM;
   161  
   162          ld = devm_lcd_device_register(&spi->dev, "lms283gf05", 
&spi->dev, st,
   163                                          &lms_ops);
   164          if (IS_ERR(ld))
   165                  return PTR_ERR(ld);
   166  
   167          st->spi = spi;
   168          st->ld = ld;
   169  
   170          spi_set_drvdata(spi, st);
   171  
   172          /* kick in the LCD */
   173          if (st->reset)
   174                  lms283gf05_reset(st->reset);
   175          lms283gf05_toggle(spi, disp_initseq, ARRAY_SIZE(disp_initseq));
   176  
   177          return 0;
   178  }
   179  

---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-...@lists.01.org

Attachment: .config.gz
Description: application/gzip

_______________________________________________
dri-devel mailing list
dri-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/dri-devel

Reply via email to