From: kernel test robot <lkp@intel.com>
To: Jiri Pirko <jiri@nvidia.com>
Cc: oe-kbuild-all@lists.linux.dev
Subject: [jpirko-mlxsw:wip_attestation_pre_rfc_draft1 23/26] drivers/attestation/core/mr.c:57:1: error: static declaration of 'attestation_mr_info_alloc' follows non-static declaration
Date: Wed, 30 Sep 2026 09:29:03 +0200 [thread overview]
Message-ID: <202609300905.9hycDcRI-lkp@intel.com> (raw)
tree: https://github.com/jpirko/linux_mlxsw wip_attestation_pre_rfc_draft1
head: a18af4e1b514bf11f88ca42d29b7b68f3b375378
commit: 1fbb59be0a8c4b5d5f56b10f397f6b085018733e [23/26] attestation: add core KUnit tests
config: arc-randconfig-r2101-20260930 (https://download.01.org/0day-ci/archive/20260930/202609300905.9hycDcRI-lkp@intel.com/config)
compiler: arc-linux-gcc (GCC) 8.5.0
reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20260930/202609300905.9hycDcRI-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/202609300905.9hycDcRI-lkp@intel.com/
All error/warnings (new ones prefixed by >>):
>> drivers/attestation/core/core.c:247:1: warning: 'attestation_test_find_device' defined but not used [-Wunused-function]
attestation_test_find_device(const struct ctlv_device *ctlvdev)
^~~~~~~~~~~~~~~~~~~~~~~~~~~~
--
>> drivers/attestation/core/mr.c:57:1: error: static declaration of 'attestation_mr_info_alloc' follows non-static declaration
attestation_mr_info_alloc(const struct attestation_mr *mr)
^~~~~~~~~~~~~~~~~~~~~~~~~
In file included from drivers/attestation/core/mr.c:10:
drivers/attestation/core/internal.h:150:1: note: previous declaration of 'attestation_mr_info_alloc' was here
attestation_mr_info_alloc(const struct attestation_mr *mr);
^~~~~~~~~~~~~~~~~~~~~~~~~
vim +/attestation_mr_info_alloc +57 drivers/attestation/core/mr.c
7c3e9198f02658 Jiri Pirko 2026-09-29 54
1fbb59be0a8c4b Jiri Pirko 2026-09-29 55 VISIBLE_IF_KUNIT
7c3e9198f02658 Jiri Pirko 2026-09-29 56 struct attestation_mr_log_entry_info *
7c3e9198f02658 Jiri Pirko 2026-09-29 @57 attestation_mr_info_alloc(const struct attestation_mr *mr)
7c3e9198f02658 Jiri Pirko 2026-09-29 58 {
7c3e9198f02658 Jiri Pirko 2026-09-29 59 struct attestation_mr_log_entry_info *info;
7c3e9198f02658 Jiri Pirko 2026-09-29 60 enum hash_algo *algorithms;
7c3e9198f02658 Jiri Pirko 2026-09-29 61 char *name;
7c3e9198f02658 Jiri Pirko 2026-09-29 62
1fbb59be0a8c4b Jiri Pirko 2026-09-29 63 KUNIT_STATIC_STUB_REDIRECT(attestation_mr_info_alloc, mr);
1fbb59be0a8c4b Jiri Pirko 2026-09-29 64
7c3e9198f02658 Jiri Pirko 2026-09-29 65 info = kzalloc_obj(*info, GFP_KERNEL);
7c3e9198f02658 Jiri Pirko 2026-09-29 66 if (!info)
7c3e9198f02658 Jiri Pirko 2026-09-29 67 return ERR_PTR(-ENOMEM);
7c3e9198f02658 Jiri Pirko 2026-09-29 68 name = kstrdup(mr->props->name, GFP_KERNEL);
7c3e9198f02658 Jiri Pirko 2026-09-29 69 if (!name)
7c3e9198f02658 Jiri Pirko 2026-09-29 70 goto err_info;
7c3e9198f02658 Jiri Pirko 2026-09-29 71 algorithms = kmemdup_array(mr->props->algorithms,
7c3e9198f02658 Jiri Pirko 2026-09-29 72 mr->props->algorithms_count,
7c3e9198f02658 Jiri Pirko 2026-09-29 73 sizeof(*algorithms), GFP_KERNEL);
7c3e9198f02658 Jiri Pirko 2026-09-29 74 if (!algorithms)
7c3e9198f02658 Jiri Pirko 2026-09-29 75 goto err_name;
7c3e9198f02658 Jiri Pirko 2026-09-29 76 info->entry.type = ATTESTATION_MR_LOG_ENTRY_INFO;
7c3e9198f02658 Jiri Pirko 2026-09-29 77 info->entry.mr_id = mr->props->id;
7c3e9198f02658 Jiri Pirko 2026-09-29 78 info->props = *mr->props;
7c3e9198f02658 Jiri Pirko 2026-09-29 79 info->props.name = name;
7c3e9198f02658 Jiri Pirko 2026-09-29 80 info->props.algorithms = algorithms;
7c3e9198f02658 Jiri Pirko 2026-09-29 81 return info;
7c3e9198f02658 Jiri Pirko 2026-09-29 82
7c3e9198f02658 Jiri Pirko 2026-09-29 83 err_name:
7c3e9198f02658 Jiri Pirko 2026-09-29 84 kfree(name);
7c3e9198f02658 Jiri Pirko 2026-09-29 85 err_info:
7c3e9198f02658 Jiri Pirko 2026-09-29 86 kfree(info);
7c3e9198f02658 Jiri Pirko 2026-09-29 87 return ERR_PTR(-ENOMEM);
7c3e9198f02658 Jiri Pirko 2026-09-29 88 }
1fbb59be0a8c4b Jiri Pirko 2026-09-29 89 EXPORT_SYMBOL_IF_KUNIT(attestation_mr_info_alloc);
7c3e9198f02658 Jiri Pirko 2026-09-29 90
:::::: The code at line 57 was first introduced by commit
:::::: 7c3e9198f02658988c2f0ea335cdfd75b93236e0 attestation: introduce the core framework
:::::: TO: Jiri Pirko <jiri@nvidia.com>
:::::: CC: Jiri Pirko <jiri@nvidia.com>
--
0-DAY CI Kernel Test Service
https://github.com/intel/lkp-tests/wiki
reply other threads:[~2026-09-30 7:29 UTC|newest]
Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
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=202609300905.9hycDcRI-lkp@intel.com \
--to=lkp@intel.com \
--cc=jiri@nvidia.com \
--cc=oe-kbuild-all@lists.linux.dev \
/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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.