From: kernel test robot <lkp@intel.com>
To: Mark Rutland <mark.rutland@arm.com>
Cc: llvm@lists.linux.dev, oe-kbuild-all@lists.linux.dev
Subject: [mark:arm64/kvm/fpsimd-fixes 8/11] arch/arm64/kvm/hyp/include/hyp/switch.h:380:15: warning: variable 'zcr_el2' set but not used
Date: Thu, 6 Feb 2025 13:13:15 +0800 [thread overview]
Message-ID: <202502061341.FvsCMKEH-lkp@intel.com> (raw)
tree: https://git.kernel.org/pub/scm/linux/kernel/git/mark/linux.git arm64/kvm/fpsimd-fixes
head: 246fa113d11e53f51bf13b25bcf85161c2290b37
commit: 9b573af2d7bae55e446e8d422b6ec87a144d3148 [8/11] KVM: arm64: Eagerly switch ZCR_EL{1,2}
config: arm64-randconfig-003-20250206 (https://download.01.org/0day-ci/archive/20250206/202502061341.FvsCMKEH-lkp@intel.com/config)
compiler: clang version 15.0.7 (https://github.com/llvm/llvm-project 8dfdcc7b7bf66834a761bd8de445840ef68e4d1a)
reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20250206/202502061341.FvsCMKEH-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/202502061341.FvsCMKEH-lkp@intel.com/
All warnings (new ones prefixed by >>):
In file included from arch/arm64/kvm/hyp/vhe/switch.c:7:
>> arch/arm64/kvm/hyp/include/hyp/switch.h:380:15: warning: variable 'zcr_el2' set but not used [-Wunused-but-set-variable]
u64 zcr_el1, zcr_el2;
^
arch/arm64/kvm/hyp/include/hyp/switch.h:401:15: warning: variable 'zcr_el2' set but not used [-Wunused-but-set-variable]
u64 zcr_el1, zcr_el2;
^
2 warnings generated.
vim +/zcr_el2 +380 arch/arm64/kvm/hyp/include/hyp/switch.h
377
378 static inline void fpsimd_lazy_switch_to_guest(struct kvm_vcpu *vcpu)
379 {
> 380 u64 zcr_el1, zcr_el2;
381
382 if (!guest_owns_fp_regs())
383 return;
384
385 if (vcpu_has_sve(vcpu)) {
386 /* A guest hypervisor may restrict the effective max VL. */
387 if (vcpu_has_nv(vcpu) && !is_hyp_ctxt(vcpu))
388 zcr_el2 = __vcpu_sys_reg(vcpu, ZCR_EL2);
389 else
390 zcr_el2 = vcpu_sve_max_vq(vcpu) - 1;
391
392 sve_cond_update_zcr_vq(zcr_el2, SYS_ZCR_EL2);
393
394 zcr_el1 = __vcpu_sys_reg(vcpu, vcpu_sve_zcr_elx(vcpu));
395 write_sysreg_el1(zcr_el1, SYS_ZCR);
396 }
397 }
398
--
0-DAY CI Kernel Test Service
https://github.com/intel/lkp-tests/wiki
reply other threads:[~2025-02-06 5:13 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=202502061341.FvsCMKEH-lkp@intel.com \
--to=lkp@intel.com \
--cc=llvm@lists.linux.dev \
--cc=mark.rutland@arm.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.