From: kernel test robot <lkp@intel.com>
To: Andy Shevchenko <andriy.shevchenko@linux.intel.com>,
linux-pci@vger.kernel.org, linux-acpi@vger.kernel.org,
linux-kernel@vger.kernel.org
Cc: oe-kbuild-all@lists.linux.dev, Bjorn Helgaas <helgaas@kernel.org>,
"Rafael J. Wysocki" <rafael@kernel.org>,
Len Brown <lenb@kernel.org>
Subject: Re: [PATCH v1 1/1] ACPI: PCI: simplify code with acpi_get_local_u64_address()
Date: Wed, 21 Jan 2026 15:15:35 +0800 [thread overview]
Message-ID: <202601211405.APuSRTdE-lkp@intel.com> (raw)
In-Reply-To: <20260120154015.1764021-1-andriy.shevchenko@linux.intel.com>
Hi Andy,
kernel test robot noticed the following build warnings:
[auto build test WARNING on pci/next]
[also build test WARNING on pci/for-linus linus/master v6.19-rc6 next-20260120]
[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/Andy-Shevchenko/ACPI-PCI-simplify-code-with-acpi_get_local_u64_address/20260121-004826
base: https://git.kernel.org/pub/scm/linux/kernel/git/pci/pci.git next
patch link: https://lore.kernel.org/r/20260120154015.1764021-1-andriy.shevchenko%40linux.intel.com
patch subject: [PATCH v1 1/1] ACPI: PCI: simplify code with acpi_get_local_u64_address()
config: x86_64-randconfig-161-20260121 (https://download.01.org/0day-ci/archive/20260121/202601211405.APuSRTdE-lkp@intel.com/config)
compiler: gcc-13 (Debian 13.3.0-16) 13.3.0
smatch version: v0.5.0-8985-g2614ff1a
reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20260121/202601211405.APuSRTdE-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/202601211405.APuSRTdE-lkp@intel.com/
All warnings (new ones prefixed by >>):
drivers/acpi/pci_slot.c: In function 'check_slot':
>> drivers/acpi/pci_slot.c:60:9: warning: this 'if' clause does not guard... [-Wmisleading-indentation]
60 | if (acpi_get_local_u64_address(handle, &adr))
| ^~
drivers/acpi/pci_slot.c:63:17: note: ...this statement, but the latter is misleadingly indented as if it were guarded by the 'if'
63 | goto out;
| ^~~~
drivers/acpi/pci_slot.c:63:17: error: label 'out' used but not defined
>> drivers/acpi/pci_slot.c:44:13: warning: unused variable 'device' [-Wunused-variable]
44 | int device = -1;
| ^~~~~~
>> drivers/acpi/pci_slot.c:64:9: warning: no return statement in function returning non-void [-Wreturn-type]
64 | }
| ^
drivers/acpi/pci_slot.c: At top level:
>> drivers/acpi/pci_slot.c:67:9: warning: data definition has no type or storage class
67 | status = acpi_evaluate_integer(handle, "_SUN", NULL, sun);
| ^~~~~~
drivers/acpi/pci_slot.c:67:9: error: type defaults to 'int' in declaration of 'status' [-Werror=implicit-int]
drivers/acpi/pci_slot.c:67:40: error: 'handle' undeclared here (not in a function)
67 | status = acpi_evaluate_integer(handle, "_SUN", NULL, sun);
| ^~~~~~
drivers/acpi/pci_slot.c:67:62: error: 'sun' undeclared here (not in a function)
67 | status = acpi_evaluate_integer(handle, "_SUN", NULL, sun);
| ^~~
drivers/acpi/pci_slot.c:68:9: error: expected identifier or '(' before 'if'
68 | if (ACPI_FAILURE(status)) {
| ^~
drivers/acpi/pci_slot.c:74:9: warning: data definition has no type or storage class
74 | device = (adr >> 16) & 0xffff;
| ^~~~~~
drivers/acpi/pci_slot.c:74:9: error: type defaults to 'int' in declaration of 'device' [-Werror=implicit-int]
drivers/acpi/pci_slot.c:74:19: error: 'adr' undeclared here (not in a function); did you mean 'idr'?
74 | device = (adr >> 16) & 0xffff;
| ^~~
| idr
drivers/acpi/pci_slot.c:75:4: error: expected '=', ',', ';', 'asm' or '__attribute__' before ':' token
75 | out:
| ^
drivers/acpi/pci_slot.c:77:9: error: expected identifier or '(' before 'return'
77 | return device;
| ^~~~~~
drivers/acpi/pci_slot.c:78:1: error: expected identifier or '(' before '}' token
78 | }
| ^
cc1: some warnings being treated as errors
vim +/if +60 drivers/acpi/pci_slot.c
40
41 static int
42 check_slot(acpi_handle handle, unsigned long long *sun)
43 {
> 44 int device = -1;
45 unsigned long long sta;
46 acpi_status status;
47 u64 adr;
48 struct acpi_buffer buffer = { ACPI_ALLOCATE_BUFFER, NULL };
49
50 acpi_get_name(handle, ACPI_FULL_PATHNAME, &buffer);
51 pr_debug("Checking slot on path: %s\n", (char *)buffer.pointer);
52
53 if (check_sta_before_sun) {
54 /* If SxFy doesn't have _STA, we just assume it's there */
55 status = acpi_evaluate_integer(handle, "_STA", NULL, &sta);
56 if (ACPI_SUCCESS(status) && !(sta & ACPI_STA_DEVICE_PRESENT))
57 goto out;
58 }
59
> 60 if (acpi_get_local_u64_address(handle, &adr))
61 pr_debug("_ADR returned with failure on %s\n",
62 (char *)buffer.pointer);
> 63 goto out;
> 64 }
65
66 /* No _SUN == not a slot == bail */
> 67 status = acpi_evaluate_integer(handle, "_SUN", NULL, sun);
68 if (ACPI_FAILURE(status)) {
69 pr_debug("_SUN returned %d on %s\n",
70 status, (char *)buffer.pointer);
71 goto out;
72 }
73
74 device = (adr >> 16) & 0xffff;
75 out:
76 kfree(buffer.pointer);
77 return device;
78 }
79
--
0-DAY CI Kernel Test Service
https://github.com/intel/lkp-tests/wiki
prev parent reply other threads:[~2026-01-21 7:15 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-01-20 15:40 [PATCH v1 1/1] ACPI: PCI: simplify code with acpi_get_local_u64_address() Andy Shevchenko
2026-01-21 1:44 ` kernel test robot
2026-01-21 2:39 ` kernel test robot
2026-01-21 7:15 ` kernel test robot [this message]
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=202601211405.APuSRTdE-lkp@intel.com \
--to=lkp@intel.com \
--cc=andriy.shevchenko@linux.intel.com \
--cc=helgaas@kernel.org \
--cc=lenb@kernel.org \
--cc=linux-acpi@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-pci@vger.kernel.org \
--cc=oe-kbuild-all@lists.linux.dev \
--cc=rafael@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