From: kernel test robot <lkp@intel.com>
To: "David Hildenbrand (Arm)" <david@kernel.org>
Cc: llvm@lists.linux.dev, oe-kbuild-all@lists.linux.dev
Subject: [davidhildenbrand:b4/bootmem_info 10/19] arch/s390/mm/vmem.c:42:15: warning: unused variable 'nr_pages'
Date: Wed, 06 May 2026 16:24:42 +0800 [thread overview]
Message-ID: <202605061622.0MCmYK6p-lkp@intel.com> (raw)
tree: https://github.com/davidhildenbrand/linux b4/bootmem_info
head: 9bd8b9ac2bf1b3e7ffee070da9c2f0607c507207
commit: ad0ab8ac08f34bb72542795d52e15d8b5d174973 [10/19] s390/mm: use free_reserved_pages() in vmem_free_pages()
config: s390-allnoconfig (https://download.01.org/0day-ci/archive/20260506/202605061622.0MCmYK6p-lkp@intel.com/config)
compiler: clang version 23.0.0git (https://github.com/llvm/llvm-project 5bac06718f502014fade905512f1d26d578a18f3)
reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20260506/202605061622.0MCmYK6p-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/202605061622.0MCmYK6p-lkp@intel.com/
All warnings (new ones prefixed by >>):
>> arch/s390/mm/vmem.c:42:15: warning: unused variable 'nr_pages' [-Wunused-variable]
42 | unsigned int nr_pages = 1 << order;
| ^~~~~~~~
1 warning generated.
vim +/nr_pages +42 arch/s390/mm/vmem.c
67060d9c1f5d91 Heiko Carstens 2008-05-30 39
1a65b73ae9abd6 Sumanth Korikkar 2024-01-08 40 static void vmem_free_pages(unsigned long addr, int order, struct vmem_altmap *altmap)
9ec8fa8dc331be David Hildenbrand 2020-07-22 41 {
d5e88d32de4e4c Sumanth Korikkar 2025-10-10 @42 unsigned int nr_pages = 1 << order;
d5e88d32de4e4c Sumanth Korikkar 2025-10-10 43 struct page *page;
d5e88d32de4e4c Sumanth Korikkar 2025-10-10 44
1a65b73ae9abd6 Sumanth Korikkar 2024-01-08 45 if (altmap) {
1a65b73ae9abd6 Sumanth Korikkar 2024-01-08 46 vmem_altmap_free(altmap, 1 << order);
1a65b73ae9abd6 Sumanth Korikkar 2024-01-08 47 return;
1a65b73ae9abd6 Sumanth Korikkar 2024-01-08 48 }
d5e88d32de4e4c Sumanth Korikkar 2025-10-10 49 page = virt_to_page((void *)addr);
d5e88d32de4e4c Sumanth Korikkar 2025-10-10 50 if (PageReserved(page)) {
d5e88d32de4e4c Sumanth Korikkar 2025-10-10 51 /* allocated from memblock */
ad0ab8ac08f34b David Hildenbrand (Arm 2026-03-12 52) free_reserved_pages(page, order);
d5e88d32de4e4c Sumanth Korikkar 2025-10-10 53 } else {
9ec8fa8dc331be David Hildenbrand 2020-07-22 54 free_pages(addr, order);
9ec8fa8dc331be David Hildenbrand 2020-07-22 55 }
d5e88d32de4e4c Sumanth Korikkar 2025-10-10 56 }
9ec8fa8dc331be David Hildenbrand 2020-07-22 57
:::::: The code at line 42 was first introduced by commit
:::::: d5e88d32de4e4ce289d107939da970763669d631 s390/mm: Support removal of boot-allocated virtual memory map
:::::: TO: Sumanth Korikkar <sumanthk@linux.ibm.com>
:::::: CC: Heiko Carstens <hca@linux.ibm.com>
--
0-DAY CI Kernel Test Service
https://github.com/intel/lkp-tests/wiki
reply other threads:[~2026-05-06 8:25 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=202605061622.0MCmYK6p-lkp@intel.com \
--to=lkp@intel.com \
--cc=david@kernel.org \
--cc=llvm@lists.linux.dev \
--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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox