* [pdx86-platform-drivers-x86:review-ilpo 13/17] drivers/platform/x86/amd/hsmp.c:405:8: error: call to undeclared function 'acpi_device_uid'; ISO C99 and later do not support implicit function declarations
@ 2024-01-28 6:26 kernel test robot
0 siblings, 0 replies; only message in thread
From: kernel test robot @ 2024-01-28 6:26 UTC (permalink / raw)
To: Suma Hegde
Cc: llvm, oe-kbuild-all, Andy Shevchenko, Hans de Goede,
Ilpo Järvinen, Naveen Krishna Chatradhi
tree: https://git.kernel.org/pub/scm/linux/kernel/git/pdx86/platform-drivers-x86.git review-ilpo
head: d04e52b47ab62cf36fddaa0feb1c5508e420e48d
commit: d6200c4e95eecd59fedb7c64a4ad7a201191b0b6 [13/17] platform/x86/amd/hsmp: Add support for ACPI based probing
config: x86_64-buildonly-randconfig-003-20240128 (https://download.01.org/0day-ci/archive/20240128/202401281437.aus91srb-lkp@intel.com/config)
compiler: clang version 17.0.6 (https://github.com/llvm/llvm-project 6009708b4367171ccdbf4b5905cb6a803753fe18)
reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20240128/202401281437.aus91srb-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/202401281437.aus91srb-lkp@intel.com/
All errors (new ones prefixed by >>):
>> drivers/platform/x86/amd/hsmp.c:405:8: error: call to undeclared function 'acpi_device_uid'; ISO C99 and later do not support implicit function declarations [-Wimplicit-function-declaration]
405 | uid = acpi_device_uid(ACPI_COMPANION(dev));
| ^
drivers/platform/x86/amd/hsmp.c:405:8: note: did you mean 'pci_device_add'?
include/linux/pci.h:1163:6: note: 'pci_device_add' declared here
1163 | void pci_device_add(struct pci_dev *dev, struct pci_bus *bus);
| ^
>> drivers/platform/x86/amd/hsmp.c:405:6: error: incompatible integer to pointer conversion assigning to 'char *' from 'int' [-Wint-conversion]
405 | uid = acpi_device_uid(ACPI_COMPANION(dev));
| ^ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
>> drivers/platform/x86/amd/hsmp.c:417:8: error: call to undeclared function 'acpi_dev_resource_memory'; ISO C99 and later do not support implicit function declarations [-Wimplicit-function-declaration]
417 | if (!acpi_dev_resource_memory(res, &r))
| ^
>> drivers/platform/x86/amd/hsmp.c:797:15: error: call to undeclared function 'acpi_match_device_ids'; ISO C99 and later do not support implicit function declarations [-Wimplicit-function-declaration]
797 | if (adev && !acpi_match_device_ids(adev, amd_hsmp_acpi_ids)) {
| ^
drivers/platform/x86/amd/hsmp.c:797:15: note: did you mean 'acpi_match_device'?
include/linux/acpi.h:933:44: note: 'acpi_match_device' declared here
933 | static inline const struct acpi_device_id *acpi_match_device(
| ^
4 errors generated.
vim +/acpi_device_uid +405 drivers/platform/x86/amd/hsmp.c
395
396 static inline int hsmp_get_uid(struct device *dev, u16 *sock_ind)
397 {
398 char *uid;
399
400 /*
401 * UID (ID00, ID01..IDXX) is used for differentiating sockets,
402 * read it and strip the "ID" part of it and convert the remaining
403 * bytes to integer.
404 */
> 405 uid = acpi_device_uid(ACPI_COMPANION(dev));
406
407 return kstrtou16(uid + 2, 10, sock_ind);
408 }
409
410 static acpi_status hsmp_resource(struct acpi_resource *res, void *data)
411 {
412 struct hsmp_socket *sock = data;
413 struct resource r;
414
415 switch (res->type) {
416 case ACPI_RESOURCE_TYPE_FIXED_MEMORY32:
> 417 if (!acpi_dev_resource_memory(res, &r))
418 return AE_ERROR;
419 if (!r.start || r.end < r.start || !(r.flags & IORESOURCE_MEM_WRITEABLE))
420 return AE_ERROR;
421 sock->mbinfo.base_addr = r.start;
422 sock->mbinfo.size = resource_size(&r);
423 break;
424 case ACPI_RESOURCE_TYPE_END_TAG:
425 break;
426 default:
427 return AE_ERROR;
428 }
429
430 return AE_OK;
431 }
432
--
0-DAY CI Kernel Test Service
https://github.com/intel/lkp-tests/wiki
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2024-01-28 6:27 UTC | newest]
Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2024-01-28 6:26 [pdx86-platform-drivers-x86:review-ilpo 13/17] drivers/platform/x86/amd/hsmp.c:405:8: error: call to undeclared function 'acpi_device_uid'; ISO C99 and later do not support implicit function declarations kernel test robot
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).