[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <202507040001.Jm6FQyH6-lkp@intel.com>
Date: Fri, 4 Jul 2025 01:04:47 +0800
From: kernel test robot <lkp@...el.com>
To: Nick Hu <nick.hu@...ive.com>, conor+dt@...nel.org, krzk+dt@...nel.org,
Alexandre Ghiti <alex@...ti.fr>, linux-kernel@...r.kernel.org,
linux-pm@...r.kernel.org, linux-riscv@...ts.infradead.org
Cc: oe-kbuild-all@...ts.linux.dev, Nick Hu <nick.hu@...ive.com>,
Samuel Holland <samuel.holland@...ive.com>,
Anup Patel <anup@...infault.org>,
"Rafael J. Wysocki" <rafael@...nel.org>,
Daniel Lezcano <daniel.lezcano@...aro.org>,
Paul Walmsley <paul.walmsley@...ive.com>,
Palmer Dabbelt <palmer@...belt.com>,
Albert Ou <aou@...s.berkeley.edu>
Subject: Re: [PATCH v3 2/3] cpuidle: riscv-sbi: Work with the external
pmdomain driver
Hi Nick,
kernel test robot noticed the following build warnings:
[auto build test WARNING on rafael-pm/linux-next]
[also build test WARNING on rafael-pm/bleeding-edge robh/for-next linus/master v6.16-rc4 next-20250703]
[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/Nick-Hu/cpuidle-riscv-sbi-Work-with-the-external-pmdomain-driver/20250702-181250
base: https://git.kernel.org/pub/scm/linux/kernel/git/rafael/linux-pm.git linux-next
patch link: https://lore.kernel.org/r/20250702091236.5281-3-nick.hu%40sifive.com
patch subject: [PATCH v3 2/3] cpuidle: riscv-sbi: Work with the external pmdomain driver
config: riscv-randconfig-001-20250703 (https://download.01.org/0day-ci/archive/20250704/202507040001.Jm6FQyH6-lkp@intel.com/config)
compiler: riscv64-linux-gcc (GCC) 13.4.0
reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20250704/202507040001.Jm6FQyH6-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@...el.com>
| Closes: https://lore.kernel.org/oe-kbuild-all/202507040001.Jm6FQyH6-lkp@intel.com/
All warnings (new ones prefixed by >>):
drivers/cpuidle/cpuidle-riscv-sbi.c: In function 'sbi_cpuidle_probe':
>> drivers/cpuidle/cpuidle-riscv-sbi.c:569:1: warning: label 'out' defined but not used [-Wunused-label]
569 | out:
| ^~~
vim +/out +569 drivers/cpuidle/cpuidle-riscv-sbi.c
493
494 static int sbi_cpuidle_probe(struct platform_device *pdev)
495 {
496 int cpu, ret;
497 struct cpuidle_driver *drv;
498 struct cpuidle_device *dev;
499 struct device_node *pds_node;
500
501 /* Detect OSI support based on CPU DT nodes */
502 sbi_cpuidle_use_osi = true;
503 for_each_possible_cpu(cpu) {
504 struct device_node *np __free(device_node) = of_cpu_device_node_get(cpu);
505 if (np &&
506 of_property_present(np, "power-domains") &&
507 of_property_present(np, "power-domain-names")) {
508 continue;
509 } else {
510 sbi_cpuidle_use_osi = false;
511 break;
512 }
513 }
514
515 /* Populate generic power domains from DT nodes */
516 pds_node = of_find_node_by_path("/cpus/power-domains");
517 if (pds_node) {
518 ret = sbi_genpd_probe(pds_node);
519 of_node_put(pds_node);
520 if (ret)
521 return ret;
522 }
523
524 /* Attaching the cpu to the corresponding power domain */
525 if (sbi_cpuidle_use_osi) {
526 for_each_present_cpu(cpu) {
527 struct sbi_cpuidle_data *data = per_cpu_ptr(&sbi_cpuidle_data, cpu);
528
529 data->dev = dt_idle_attach_cpu(cpu, "sbi");
530 if (IS_ERR_OR_NULL(data->dev)) {
531 ret = PTR_ERR_OR_ZERO(data->dev);
532 if (ret != -EPROBE_DEFER)
533 pr_debug("Hart%ld: fail to attach the power domain\n",
534 cpuid_to_hartid_map(cpu));
535
536 while (--cpu >= 0)
537 dt_idle_detach_cpu(data->dev);
538 return ret;
539 }
540 }
541 /* Setup CPU hotplut notifiers */
542 sbi_idle_init_cpuhp();
543 }
544
545 /* Initialize CPU idle driver for each present CPU */
546 for_each_present_cpu(cpu) {
547 ret = sbi_cpuidle_init_cpu(&pdev->dev, cpu);
548 if (ret) {
549 pr_debug("HART%ld: idle driver init failed\n",
550 cpuid_to_hartid_map(cpu));
551 goto out_fail;
552 }
553 }
554
555 if (cpuidle_disabled())
556 pr_info("cpuidle is disabled\n");
557 else
558 pr_info("idle driver registered for all CPUs\n");
559
560 return 0;
561
562 out_fail:
563 while (--cpu >= 0) {
564 dev = per_cpu(cpuidle_devices, cpu);
565 drv = cpuidle_get_cpu_driver(dev);
566 cpuidle_unregister(drv);
567 sbi_cpuidle_deinit_cpu(cpu);
568 }
> 569 out:
570 return ret;
571 }
572
--
0-DAY CI Kernel Test Service
https://github.com/intel/lkp-tests/wiki
Powered by blists - more mailing lists