From: kernel test robot <lkp@intel.com>
To: James Morse <james.morse@arm.com>
Cc: kbuild-all@lists.01.org, linux-kernel@vger.kernel.org,
Catalin Marinas <catalin.marinas@arm.com>
Subject: arch/arm64/kernel/proton-pack.c:783:14: sparse: sparse: symbol 'spectre_bhb_patch_fw_mitigation_enabled' was not declared. Should it be static?
Date: Sat, 12 Mar 2022 21:37:56 +0800 [thread overview]
Message-ID: <202203122137.UnefPg5u-lkp@intel.com> (raw)
tree: https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git master
head: 68453767131a5deec1e8f9ac92a9042f929e585d
commit: ba2689234be92024e5635d30fe744f4853ad97db arm64: entry: Add vectors that have the bhb mitigation sequences
date: 3 weeks ago
config: arm64-randconfig-s032-20220311 (https://download.01.org/0day-ci/archive/20220312/202203122137.UnefPg5u-lkp@intel.com/config)
compiler: aarch64-linux-gcc (GCC) 11.2.0
reproduce:
wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross
chmod +x ~/bin/make.cross
# apt-get install sparse
# sparse version: v0.6.4-dirty
# https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit/?id=ba2689234be92024e5635d30fe744f4853ad97db
git remote add linus https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
git fetch --no-tags linus master
git checkout ba2689234be92024e5635d30fe744f4853ad97db
# save the config file to linux build tree
mkdir build_dir
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-11.2.0 make.cross C=1 CF='-fdiagnostic-prefix -D__CHECK_ENDIAN__' O=build_dir ARCH=arm64 SHELL=/bin/bash arch/arm64/kernel/
If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp@intel.com>
sparse warnings: (new ones prefixed by >>)
>> arch/arm64/kernel/proton-pack.c:783:14: sparse: sparse: symbol 'spectre_bhb_patch_fw_mitigation_enabled' was not declared. Should it be static?
vim +/spectre_bhb_patch_fw_mitigation_enabled +783 arch/arm64/kernel/proton-pack.c
773
774 static int ssbd_prctl_get(struct task_struct *task)
775 {
776 switch (spectre_v4_state) {
777 case SPECTRE_UNAFFECTED:
778 return PR_SPEC_NOT_AFFECTED;
779 case SPECTRE_MITIGATED:
780 if (spectre_v4_mitigations_on())
781 return PR_SPEC_NOT_AFFECTED;
782
> 783 if (spectre_v4_mitigations_dynamic())
784 break;
785
786 /* Mitigations are disabled, so we're vulnerable. */
787 fallthrough;
788 case SPECTRE_VULNERABLE:
789 fallthrough;
790 default:
791 return PR_SPEC_ENABLE;
792 }
793
794 /* Check the mitigation state for this task */
795 if (task_spec_ssb_force_disable(task))
796 return PR_SPEC_PRCTL | PR_SPEC_FORCE_DISABLE;
797
798 if (task_spec_ssb_noexec(task))
799 return PR_SPEC_PRCTL | PR_SPEC_DISABLE_NOEXEC;
800
801 if (task_spec_ssb_disable(task))
802 return PR_SPEC_PRCTL | PR_SPEC_DISABLE;
803
804 return PR_SPEC_PRCTL | PR_SPEC_ENABLE;
805 }
806
---
0-DAY CI Kernel Test Service
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org
reply other threads:[~2022-03-12 13:38 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=202203122137.UnefPg5u-lkp@intel.com \
--to=lkp@intel.com \
--cc=catalin.marinas@arm.com \
--cc=james.morse@arm.com \
--cc=kbuild-all@lists.01.org \
--cc=linux-kernel@vger.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