[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <Z5ImE9RQXqIPvwXz@rli9-mobl>
Date: Thu, 23 Jan 2025 19:20:51 +0800
From: Philip Li <philip.li@...el.com>
To: Randy Dunlap <rdunlap@...radead.org>
CC: kernel test robot <lkp@...el.com>, "Rafael J. Wysocki"
<rafael@...nel.org>, <oe-kbuild-all@...ts.linux.dev>,
<linux-kernel@...r.kernel.org>, Andrew Morton <akpm@...ux-foundation.org>,
Linux Memory Management List <linux-mm@...ck.org>
Subject: Re: drivers/base/power/runtime.c:362: warning: Excess function
parameter 'dev' description in '__rpm_callback'
On Wed, Jan 22, 2025 at 11:44:21PM -0800, Randy Dunlap wrote:
> Hi robot,
>
> On 1/22/25 10:59 PM, kernel test robot wrote:
> > tree: https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git master
> > head: 21266b8df5224c4f677acf9f353eecc9094731f0
> > commit: 7be6a87c2473957090995b7eb541e31d57a2c801 sparc: allow PM configs for sparc32 COMPILE_TEST
>
> ^^^ Not relevant.
Sorry about this, we will configure the bot to avoid reporting similar
false positive for this commit.
Thanks
> > ad3c36a534bc7b Rafael J. Wysocki 2011-09-27 @362 {
> > 63d00be69348fd Ulf Hansson 2021-06-08 363 int retval = 0, idx;
> > 0cab893f409c53 Rafael J. Wysocki 2021-03-19 364 bool use_links = dev->power.links_count > 0;
> > ad3c36a534bc7b Rafael J. Wysocki 2011-09-27 365
> > 21d5c57b372616 Rafael J. Wysocki 2016-10-30 366 if (dev->power.irq_safe) {
> > ad3c36a534bc7b Rafael J. Wysocki 2011-09-27 367 spin_unlock(&dev->power.lock);
> > 21d5c57b372616 Rafael J. Wysocki 2016-10-30 368 } else {
> > ad3c36a534bc7b Rafael J. Wysocki 2011-09-27 369 spin_unlock_irq(&dev->power.lock);
> > ad3c36a534bc7b Rafael J. Wysocki 2011-09-27 370
> > 0cab893f409c53 Rafael J. Wysocki 2021-03-19 371 /*
> > 0cab893f409c53 Rafael J. Wysocki 2021-03-19 372 * Resume suppliers if necessary.
> > 0cab893f409c53 Rafael J. Wysocki 2021-03-19 373 *
> > 0cab893f409c53 Rafael J. Wysocki 2021-03-19 374 * The device's runtime PM status cannot change until this
> > 0cab893f409c53 Rafael J. Wysocki 2021-03-19 375 * routine returns, so it is safe to read the status outside of
> > 0cab893f409c53 Rafael J. Wysocki 2021-03-19 376 * the lock.
> > 0cab893f409c53 Rafael J. Wysocki 2021-03-19 377 */
> > 0cab893f409c53 Rafael J. Wysocki 2021-03-19 378 if (use_links && dev->power.runtime_status == RPM_RESUMING) {
> > 21d5c57b372616 Rafael J. Wysocki 2016-10-30 379 idx = device_links_read_lock();
> > 21d5c57b372616 Rafael J. Wysocki 2016-10-30 380
> > 21d5c57b372616 Rafael J. Wysocki 2016-10-30 381 retval = rpm_get_suppliers(dev);
> > 5244f5e2d80125 Rafael J. Wysocki 2021-03-19 382 if (retval) {
> > 5244f5e2d80125 Rafael J. Wysocki 2021-03-19 383 rpm_put_suppliers(dev);
> > 21d5c57b372616 Rafael J. Wysocki 2016-10-30 384 goto fail;
> > 5244f5e2d80125 Rafael J. Wysocki 2021-03-19 385 }
> > 21d5c57b372616 Rafael J. Wysocki 2016-10-30 386
> > 21d5c57b372616 Rafael J. Wysocki 2016-10-30 387 device_links_read_unlock(idx);
> > 21d5c57b372616 Rafael J. Wysocki 2016-10-30 388 }
> > 21d5c57b372616 Rafael J. Wysocki 2016-10-30 389 }
> > 21d5c57b372616 Rafael J. Wysocki 2016-10-30 390
> > 63d00be69348fd Ulf Hansson 2021-06-08 391 if (cb)
> > ad3c36a534bc7b Rafael J. Wysocki 2011-09-27 392 retval = cb(dev);
> > ad3c36a534bc7b Rafael J. Wysocki 2011-09-27 393
> > 21d5c57b372616 Rafael J. Wysocki 2016-10-30 394 if (dev->power.irq_safe) {
> > ad3c36a534bc7b Rafael J. Wysocki 2011-09-27 395 spin_lock(&dev->power.lock);
> > 0cab893f409c53 Rafael J. Wysocki 2021-03-19 396 } else {
> > 21d5c57b372616 Rafael J. Wysocki 2016-10-30 397 /*
> > 0cab893f409c53 Rafael J. Wysocki 2021-03-19 398 * If the device is suspending and the callback has returned
> > 0cab893f409c53 Rafael J. Wysocki 2021-03-19 399 * success, drop the usage counters of the suppliers that have
> > 0cab893f409c53 Rafael J. Wysocki 2021-03-19 400 * been reference counted on its resume.
> > 21d5c57b372616 Rafael J. Wysocki 2016-10-30 401 *
> > 0cab893f409c53 Rafael J. Wysocki 2021-03-19 402 * Do that if resume fails too.
> > 21d5c57b372616 Rafael J. Wysocki 2016-10-30 403 */
> > dbfa44782787dc Rafael J. Wysocki 2022-12-05 404 if (use_links &&
> > dbfa44782787dc Rafael J. Wysocki 2022-12-05 405 ((dev->power.runtime_status == RPM_SUSPENDING && !retval) ||
> > dbfa44782787dc Rafael J. Wysocki 2022-12-05 406 (dev->power.runtime_status == RPM_RESUMING && retval))) {
> > 21d5c57b372616 Rafael J. Wysocki 2016-10-30 407 idx = device_links_read_lock();
> > 21d5c57b372616 Rafael J. Wysocki 2016-10-30 408
> > 5244f5e2d80125 Rafael J. Wysocki 2021-03-19 409 __rpm_put_suppliers(dev, false);
> > 21d5c57b372616 Rafael J. Wysocki 2016-10-30 410
> > 5244f5e2d80125 Rafael J. Wysocki 2021-03-19 411 fail:
> > 21d5c57b372616 Rafael J. Wysocki 2016-10-30 412 device_links_read_unlock(idx);
> > 0cab893f409c53 Rafael J. Wysocki 2021-03-19 413 }
> > 21d5c57b372616 Rafael J. Wysocki 2016-10-30 414
> > :::::: ad3c36a534bc7b945d7bffdda1c62e13bf93489a PM / Runtime: Don't run callbacks under lock for power.irq_safe set
> >
> > :::::: TO: Rafael J. Wysocki <rjw@...k.pl>
> > :::::: CC: Rafael J. Wysocki <rjw@...k.pl>
>
> So why is this email not sent to Rafael?
Sorry for confusion, currently the mail recipients are only deduced by
the info of the first bad commit, thus the author of original code could
be missed as the reported issue may not be relavant to them.
> I added his email address.
>
> Thanks so much!
> --
> ~Randy
>
>
Powered by blists - more mailing lists