From: kernel test robot <lkp@intel.com>
To: Matthew Rosato <mjrosato@linux.ibm.com>
Cc: kbuild-all@lists.01.org,
Linux Memory Management List <linux-mm@kvack.org>,
Christian Borntraeger <borntraeger@linux.ibm.com>
Subject: [linux-next:master 8282/13104] arch/s390/kvm/pci.c:58:68: sparse: sparse: Using plain integer as NULL pointer
Date: Wed, 27 Jul 2022 19:31:45 +0800 [thread overview]
Message-ID: <202207271954.IctLQQYT-lkp@intel.com> (raw)
tree: https://git.kernel.org/pub/scm/linux/kernel/git/next/linux-next.git master
head: 058affafc65a74cf54499fb578b66ad0b18f939b
commit: 98b1d33dac5fd09060486762c02fd1a78baeb1e0 [8282/13104] KVM: s390: pci: do initial setup for AEN interpretation
config: s390-randconfig-s051-20220727 (https://download.01.org/0day-ci/archive/20220727/202207271954.IctLQQYT-lkp@intel.com/config)
compiler: s390-linux-gcc (GCC) 12.1.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-39-gce1a6720-dirty
# https://git.kernel.org/pub/scm/linux/kernel/git/next/linux-next.git/commit/?id=98b1d33dac5fd09060486762c02fd1a78baeb1e0
git remote add linux-next https://git.kernel.org/pub/scm/linux/kernel/git/next/linux-next.git
git fetch --no-tags linux-next master
git checkout 98b1d33dac5fd09060486762c02fd1a78baeb1e0
# save the config file
mkdir build_dir && cp config build_dir/.config
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-12.1.0 make.cross C=1 CF='-fdiagnostic-prefix -D__CHECK_ENDIAN__' O=build_dir ARCH=s390 SHELL=/bin/bash arch/s390/kvm/
If you fix the issue, kindly add following tag where applicable
Reported-by: kernel test robot <lkp@intel.com>
sparse warnings: (new ones prefixed by >>)
>> arch/s390/kvm/pci.c:58:68: sparse: sparse: Using plain integer as NULL pointer
vim +58 arch/s390/kvm/pci.c
48
49 static int zpci_setup_aipb(u8 nisc)
50 {
51 struct page *page;
52 int size, rc;
53
54 zpci_aipb = kzalloc(sizeof(union zpci_sic_iib), GFP_KERNEL);
55 if (!zpci_aipb)
56 return -ENOMEM;
57
> 58 aift->sbv = airq_iv_create(ZPCI_NR_DEVICES, AIRQ_IV_ALLOC, 0);
59 if (!aift->sbv) {
60 rc = -ENOMEM;
61 goto free_aipb;
62 }
63 zpci_aif_sbv = aift->sbv;
64 size = get_order(PAGE_ALIGN(ZPCI_NR_DEVICES *
65 sizeof(struct zpci_gaite)));
66 page = alloc_pages(GFP_KERNEL | __GFP_ZERO, size);
67 if (!page) {
68 rc = -ENOMEM;
69 goto free_sbv;
70 }
71 aift->gait = (struct zpci_gaite *)page_to_phys(page);
72
73 zpci_aipb->aipb.faisb = virt_to_phys(aift->sbv->vector);
74 zpci_aipb->aipb.gait = virt_to_phys(aift->gait);
75 zpci_aipb->aipb.afi = nisc;
76 zpci_aipb->aipb.faal = ZPCI_NR_DEVICES;
77
78 /* Setup Adapter Event Notification Interpretation */
79 if (zpci_set_irq_ctrl(SIC_SET_AENI_CONTROLS, 0, zpci_aipb)) {
80 rc = -EIO;
81 goto free_gait;
82 }
83
84 return 0;
85
86 free_gait:
87 free_pages((unsigned long)aift->gait, size);
88 free_sbv:
89 airq_iv_release(aift->sbv);
90 zpci_aif_sbv = NULL;
91 free_aipb:
92 kfree(zpci_aipb);
93 zpci_aipb = NULL;
94
95 return rc;
96 }
97
--
0-DAY CI Kernel Test Service
https://01.org/lkp
reply other threads:[~2022-07-27 11:32 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=202207271954.IctLQQYT-lkp@intel.com \
--to=lkp@intel.com \
--cc=borntraeger@linux.ibm.com \
--cc=kbuild-all@lists.01.org \
--cc=linux-mm@kvack.org \
--cc=mjrosato@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