From: kernel test robot <lkp@intel.com>
To: Douglas Freimuth <freimuth@linux.ibm.com>,
borntraeger@linux.ibm.com, imbrenda@linux.ibm.com,
frankja@linux.ibm.com, david@kernel.org, hca@linux.ibm.com,
gor@linux.ibm.com, agordeev@linux.ibm.com, svens@linux.ibm.com,
kvm@vger.kernel.org, linux-s390@vger.kernel.org,
linux-kernel@vger.kernel.org
Cc: llvm@lists.linux.dev, oe-kbuild-all@lists.linux.dev,
mjrosato@linux.ibm.com, freimuth@linux.ibm.com
Subject: Re: [PATCH v1 1/3] Add map/unmap ioctl and clean mappings post-guest
Date: Sun, 8 Mar 2026 21:15:08 +0800 [thread overview]
Message-ID: <202603082108.iY5mWhWR-lkp@intel.com> (raw)
In-Reply-To: <20260308030438.88580-2-freimuth@linux.ibm.com>
Hi Douglas,
kernel test robot noticed the following build warnings:
[auto build test WARNING on v7.0-rc2]
[also build test WARNING on linus/master next-20260306]
[cannot apply to kvms390/next]
[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/Douglas-Freimuth/Add-map-unmap-ioctl-and-clean-mappings-post-guest/20260308-110653
base: v7.0-rc2
patch link: https://lore.kernel.org/r/20260308030438.88580-2-freimuth%40linux.ibm.com
patch subject: [PATCH v1 1/3] Add map/unmap ioctl and clean mappings post-guest
config: s390-allmodconfig (https://download.01.org/0day-ci/archive/20260308/202603082108.iY5mWhWR-lkp@intel.com/config)
compiler: clang version 18.1.8 (https://github.com/llvm/llvm-project 3b5b5c1ec4a3095ab096dd780e84d7ab81f3d7ff)
reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20260308/202603082108.iY5mWhWR-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/202603082108.iY5mWhWR-lkp@intel.com/
All warnings (new ones prefixed by >>):
arch/s390/kvm/interrupt.c:2478:16: warning: unused variable 'flags' [-Wunused-variable]
2478 | unsigned long flags;
| ^~~~~
>> arch/s390/kvm/interrupt.c:2578:7: warning: variable 'ret' is used uninitialized whenever 'if' condition is true [-Wsometimes-uninitialized]
2578 | if (kvm_s390_pv_is_protected(dev->kvm)) {
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
arch/s390/kvm/interrupt.c:2602:9: note: uninitialized use occurs here
2602 | return ret;
| ^~~
arch/s390/kvm/interrupt.c:2578:3: note: remove the 'if' if its condition is always false
2578 | if (kvm_s390_pv_is_protected(dev->kvm)) {
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
2579 | mutex_unlock(&dev->kvm->lock);
| ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
2580 | break;
| ~~~~~~
2581 | }
| ~
arch/s390/kvm/interrupt.c:2561:9: note: initialize the variable 'ret' to silence this warning
2561 | int ret, idx;
| ^
| = 0
2 warnings generated.
vim +2578 arch/s390/kvm/interrupt.c
2554
2555 static int modify_io_adapter(struct kvm_device *dev,
2556 struct kvm_device_attr *attr)
2557 {
2558 struct kvm_s390_io_adapter_req req;
2559 struct s390_io_adapter *adapter;
2560 __u64 host_addr;
2561 int ret, idx;
2562
2563 if (copy_from_user(&req, (void __user *)attr->addr, sizeof(req)))
2564 return -EFAULT;
2565
2566 adapter = get_io_adapter(dev->kvm, req.id);
2567 if (!adapter)
2568 return -EINVAL;
2569 switch (req.type) {
2570 case KVM_S390_IO_ADAPTER_MASK:
2571 ret = kvm_s390_mask_adapter(dev->kvm, req.id, req.mask);
2572 if (ret > 0)
2573 ret = 0;
2574 break;
2575 case KVM_S390_IO_ADAPTER_MAP:
2576 case KVM_S390_IO_ADAPTER_UNMAP:
2577 mutex_lock(&dev->kvm->lock);
> 2578 if (kvm_s390_pv_is_protected(dev->kvm)) {
2579 mutex_unlock(&dev->kvm->lock);
2580 break;
2581 }
2582 mutex_unlock(&dev->kvm->lock);
2583 idx = srcu_read_lock(&dev->kvm->srcu);
2584 host_addr = gpa_to_hva(dev->kvm, req.addr);
2585 if (kvm_is_error_hva(host_addr)) {
2586 srcu_read_unlock(&dev->kvm->srcu, idx);
2587 return -EFAULT;
2588 }
2589 srcu_read_unlock(&dev->kvm->srcu, idx);
2590 if (req.type == KVM_S390_IO_ADAPTER_MAP) {
2591 dev->kvm->stat.io_390_adapter_map++;
2592 ret = kvm_s390_adapter_map(dev->kvm, req.id, host_addr);
2593 } else {
2594 dev->kvm->stat.io_390_adapter_unmap++;
2595 ret = kvm_s390_adapter_unmap(dev->kvm, req.id, host_addr);
2596 }
2597 break;
2598 default:
2599 ret = -EINVAL;
2600 }
2601
2602 return ret;
2603 }
2604
--
0-DAY CI Kernel Test Service
https://github.com/intel/lkp-tests/wiki
next prev parent reply other threads:[~2026-03-08 13:15 UTC|newest]
Thread overview: 15+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-03-08 3:04 [PATCH v1 0/3] KVM: s390: Introducing kvm_arch_set_irq_inatomic Fast Inject Douglas Freimuth
2026-03-08 3:04 ` [PATCH v1 1/3] Add map/unmap ioctl and clean mappings post-guest Douglas Freimuth
2026-03-08 13:15 ` kernel test robot [this message]
2026-03-09 9:27 ` Christian Borntraeger
2026-03-09 17:12 ` Douglas Freimuth
2026-03-09 18:15 ` Christian Borntraeger
2026-03-09 14:41 ` Sean Christopherson
2026-03-11 20:24 ` Matthew Rosato
2026-03-08 3:04 ` [PATCH v1 2/3] Enable adapter_indicators_set to use mapped pages Douglas Freimuth
2026-03-11 20:24 ` Matthew Rosato
2026-03-08 3:04 ` [PATCH v1 3/3] Introducing kvm_arch_set_irq_inatomic fast inject Douglas Freimuth
2026-03-11 20:24 ` Matthew Rosato
2026-03-13 14:01 ` Douglas Freimuth
2026-03-16 15:41 ` Matthew Rosato
2026-03-17 13:06 ` Douglas Freimuth
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=202603082108.iY5mWhWR-lkp@intel.com \
--to=lkp@intel.com \
--cc=agordeev@linux.ibm.com \
--cc=borntraeger@linux.ibm.com \
--cc=david@kernel.org \
--cc=frankja@linux.ibm.com \
--cc=freimuth@linux.ibm.com \
--cc=gor@linux.ibm.com \
--cc=hca@linux.ibm.com \
--cc=imbrenda@linux.ibm.com \
--cc=kvm@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-s390@vger.kernel.org \
--cc=llvm@lists.linux.dev \
--cc=mjrosato@linux.ibm.com \
--cc=oe-kbuild-all@lists.linux.dev \
--cc=svens@linux.ibm.com \
/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