public inbox for stable@vger.kernel.org
 help / color / mirror / Atom feed
From: kernel test robot <lkp@intel.com>
To: "Michal Vokáč" <michal.vokac@ysoft.com>,
	"Pavel Machek" <pavel@ucw.cz>, "Lee Jones" <lee@kernel.org>
Cc: oe-kbuild-all@lists.linux.dev, "Dan Murphy" <dmurphy@ti.com>,
	"Jacek Anaszewski" <jacek.anaszewski@gmail.com>,
	linux-leds@vger.kernel.org, linux-kernel@vger.kernel.org,
	"Michal Vokáč" <michal.vokac@ysoft.com>,
	stable@vger.kernel.org
Subject: Re: [PATCH] leds: lp55xx: Fix check for invalid channel number
Date: Thu, 10 Oct 2024 14:00:08 +0800	[thread overview]
Message-ID: <202410101313.hQc9I8AL-lkp@intel.com> (raw)
In-Reply-To: <1728464547-31722-1-git-send-email-michal.vokac@ysoft.com>

Hi Michal,

kernel test robot noticed the following build errors:

[auto build test ERROR on lee-leds/for-leds-next]
[also build test ERROR on linus/master v6.12-rc2 next-20241009]
[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/Michal-Vok/leds-lp55xx-Fix-check-for-invalid-channel-number/20241009-171340
base:   https://git.kernel.org/pub/scm/linux/kernel/git/lee/leds.git for-leds-next
patch link:    https://lore.kernel.org/r/1728464547-31722-1-git-send-email-michal.vokac%40ysoft.com
patch subject: [PATCH] leds: lp55xx: Fix check for invalid channel number
config: xtensa-randconfig-r071-20241010 (https://download.01.org/0day-ci/archive/20241010/202410101313.hQc9I8AL-lkp@intel.com/config)
compiler: xtensa-linux-gcc (GCC) 14.1.0
reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20241010/202410101313.hQc9I8AL-lkp@intel.com/reproduce)

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 <lkp@intel.com>
| Closes: https://lore.kernel.org/oe-kbuild-all/202410101313.hQc9I8AL-lkp@intel.com/

All errors (new ones prefixed by >>):

   In file included from include/linux/device.h:15,
                    from include/linux/acpi.h:14,
                    from include/linux/i2c.h:13,
                    from drivers/leds/leds-lp55xx-common.c:17:
   drivers/leds/leds-lp55xx-common.c: In function 'lp55xx_parse_common_child':
>> drivers/leds/leds-lp55xx-common.c:1130:25: error: 'dev' undeclared (first use in this function); did you mean 'cdev'?
    1130 |                 dev_err(dev, "Use channel numbers between 0 and %d\n",
         |                         ^~~
   include/linux/dev_printk.h:110:25: note: in definition of macro 'dev_printk_index_wrap'
     110 |                 _p_func(dev, fmt, ##__VA_ARGS__);                       \
         |                         ^~~
   drivers/leds/leds-lp55xx-common.c:1130:17: note: in expansion of macro 'dev_err'
    1130 |                 dev_err(dev, "Use channel numbers between 0 and %d\n",
         |                 ^~~~~~~
   drivers/leds/leds-lp55xx-common.c:1130:25: note: each undeclared identifier is reported only once for each function it appears in
    1130 |                 dev_err(dev, "Use channel numbers between 0 and %d\n",
         |                         ^~~
   include/linux/dev_printk.h:110:25: note: in definition of macro 'dev_printk_index_wrap'
     110 |                 _p_func(dev, fmt, ##__VA_ARGS__);                       \
         |                         ^~~
   drivers/leds/leds-lp55xx-common.c:1130:17: note: in expansion of macro 'dev_err'
    1130 |                 dev_err(dev, "Use channel numbers between 0 and %d\n",
         |                 ^~~~~~~


vim +1130 drivers/leds/leds-lp55xx-common.c

  1111	
  1112	static int lp55xx_parse_common_child(struct device_node *np,
  1113					     struct lp55xx_led_config *cfg,
  1114					     int led_number, int *chan_nr)
  1115	{
  1116		int ret;
  1117	
  1118		of_property_read_string(np, "chan-name",
  1119					&cfg[led_number].name);
  1120		of_property_read_u8(np, "led-cur",
  1121				    &cfg[led_number].led_current);
  1122		of_property_read_u8(np, "max-cur",
  1123				    &cfg[led_number].max_current);
  1124	
  1125		ret = of_property_read_u32(np, "reg", chan_nr);
  1126		if (ret)
  1127			return ret;
  1128	
  1129		if (*chan_nr < 0 || *chan_nr >= cfg->max_channel) {
> 1130			dev_err(dev, "Use channel numbers between 0 and %d\n",
  1131				cfg->max_channel - 1);
  1132			return -EINVAL;
  1133		}
  1134	
  1135		return 0;
  1136	}
  1137	

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

  parent reply	other threads:[~2024-10-10  6:00 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-10-09  9:02 [PATCH] leds: lp55xx: Fix check for invalid channel number Michal Vokáč
2024-10-09  9:56 ` Michal Vokáč
2024-10-10  6:00 ` kernel test robot [this message]
2024-10-10  7:16   ` Michal Vokáč

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=202410101313.hQc9I8AL-lkp@intel.com \
    --to=lkp@intel.com \
    --cc=dmurphy@ti.com \
    --cc=jacek.anaszewski@gmail.com \
    --cc=lee@kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-leds@vger.kernel.org \
    --cc=michal.vokac@ysoft.com \
    --cc=oe-kbuild-all@lists.linux.dev \
    --cc=pavel@ucw.cz \
    --cc=stable@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox