From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from kanga.kvack.org (kanga.kvack.org [205.233.56.17]) by smtp.lore.kernel.org (Postfix) with ESMTP id 4A506C001DE for ; Fri, 28 Jul 2023 08:31:03 +0000 (UTC) Received: by kanga.kvack.org (Postfix) id 811D86B0072; Fri, 28 Jul 2023 04:31:02 -0400 (EDT) Received: by kanga.kvack.org (Postfix, from userid 40) id 79A4E6B0074; Fri, 28 Jul 2023 04:31:02 -0400 (EDT) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id 6149F8D0001; Fri, 28 Jul 2023 04:31:02 -0400 (EDT) X-Delivered-To: linux-mm@kvack.org Received: from relay.hostedemail.com (smtprelay0010.hostedemail.com [216.40.44.10]) by kanga.kvack.org (Postfix) with ESMTP id 4C2CE6B0072 for ; Fri, 28 Jul 2023 04:31:02 -0400 (EDT) Received: from smtpin10.hostedemail.com (a10.router.float.18 [10.200.18.1]) by unirelay06.hostedemail.com (Postfix) with ESMTP id 1388CB1E39 for ; Fri, 28 Jul 2023 08:31:02 +0000 (UTC) X-FDA: 81060350364.10.C73148E Received: from mgamail.intel.com (unknown [192.55.52.93]) by imf25.hostedemail.com (Postfix) with ESMTP id 49000A0002 for ; Fri, 28 Jul 2023 08:30:59 +0000 (UTC) Authentication-Results: imf25.hostedemail.com; dkim=pass header.d=intel.com header.s=Intel header.b=Uv3MHkqI; spf=pass (imf25.hostedemail.com: domain of lkp@intel.com designates 192.55.52.93 as permitted sender) smtp.mailfrom=lkp@intel.com; dmarc=pass (policy=none) header.from=intel.com ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=hostedemail.com; s=arc-20220608; t=1690533060; h=from:from:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:mime-version: content-type:content-type:content-transfer-encoding:in-reply-to: references:dkim-signature; bh=y8ajrxNgQU8Z7CWs213IyBD8TbwVE3YZ8aiUv6Wmq0E=; b=mSCHkeFGeg+bCtyqVMlSXMDWG8p3OfUqyJuzWUHlYQbZa6A/FnMfJojULh+K+nh86h7b+h bRV7WtiAg6Ev2GBbziQwuU3D4VUYadB4EhNdokitkm4hdIYPIbDOdowaaFZZgLGMyi2UyW W+mDI7hbcUQNHp39cWE/T7xLNFxFhsY= ARC-Seal: i=1; s=arc-20220608; d=hostedemail.com; t=1690533060; a=rsa-sha256; cv=none; b=nO3bFhbSfo2dL+PYxRKgEHaBaIb+fMBFYjntkvy/kGhUIXSm2QelMTe9BjhUiZc9f/+86X SstVNAhpvHXop/9zeQIpeTEDFV+z7zIF28wyxbQevXDCYrf+Kkqrq/4/eCVPDssCy7fnCk Y16WYaHmsaueA+SwaHy9JCHSMOSaGnk= ARC-Authentication-Results: i=1; imf25.hostedemail.com; dkim=pass header.d=intel.com header.s=Intel header.b=Uv3MHkqI; spf=pass (imf25.hostedemail.com: domain of lkp@intel.com designates 192.55.52.93 as permitted sender) smtp.mailfrom=lkp@intel.com; dmarc=pass (policy=none) header.from=intel.com DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1690533059; x=1722069059; h=date:from:to:cc:subject:message-id:mime-version; bh=29/niJndPeZ3E+e15le0HpMBhvjA0mlq6ZWEZErA8H4=; b=Uv3MHkqIfB7BiYFovm0to3Gq3t72Qt0B7KqZQUcmr+xwFgcAGL8jufkJ Cz7TeJ5eFVPkpzFeZi8eCM6IREGod99mYO5R9Ea7tcyWwKNf8kcRhAZTC hOkH62zdkc3o4ShC181FqR4jKhSyjidcd+nc8Y/N45zFejRTI0KYQtWII tuT/nG8tTVaMSPmgSwGxjxGsi7qVDgohDbIr+kZJYQFPUuAQ4AeX9pIRp 1QN3Le4P5VMmTBgin4YWplSsr2le8LTdq+AN3TsfPRLTlZXbf3Px+a3Id TzJYIxaA5xhlP4bVys5//qhClUqqqLUUeavbyXzdwhoCJ6qrkBTDf8oYt w==; X-IronPort-AV: E=McAfee;i="6600,9927,10784"; a="365999506" X-IronPort-AV: E=Sophos;i="6.01,236,1684825200"; d="scan'208";a="365999506" Received: from fmsmga003.fm.intel.com ([10.253.24.29]) by fmsmga102.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 28 Jul 2023 01:30:57 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=McAfee;i="6600,9927,10784"; a="817415413" X-IronPort-AV: E=Sophos;i="6.01,236,1684825200"; d="scan'208";a="817415413" Received: from lkp-server02.sh.intel.com (HELO 953e8cd98f7d) ([10.239.97.151]) by FMSMGA003.fm.intel.com with ESMTP; 28 Jul 2023 01:30:55 -0700 Received: from kbuild by 953e8cd98f7d with local (Exim 4.96) (envelope-from ) id 1qPIqs-00032F-1K; Fri, 28 Jul 2023 08:30:03 +0000 Date: Fri, 28 Jul 2023 16:29:13 +0800 From: kernel test robot To: "Aneesh Kumar K.V" Cc: llvm@lists.linux.dev, oe-kbuild-all@lists.linux.dev, Linux Memory Management List , Andrew Morton Subject: [linux-next:master 5015/5284] arch/powerpc/mm/init_64.c:201:15: error: no previous prototype for function '__vmemmap_populate' Message-ID: <202307281617.OxcXz84j-lkp@intel.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline X-Stat-Signature: 3xet11gamtydbowjiahsn3utgb87eacd X-Rspamd-Server: rspam10 X-Rspamd-Queue-Id: 49000A0002 X-Rspam-User: X-HE-Tag: 1690533059-333782 X-HE-Meta: U2FsdGVkX18oO5sgHJSUOIQs/SR5Cg877XpHdcnUG+gcDPOfGiW7iHZrcMn0Yf53k966ojIitXjCK3KPlmcBxw0QKANufsCn5iEfxWIFeqw9RkzaObE6l9JdqfAcMbij6EoFqkQOIOp7Gu5eK5qjSWTHBesTnJVB/bhr8Uy72yxa6ECFAtSxVv0whTD4rUb+B3veMdGIMmA8YFR7Y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dEEyD9kxKI6+bicSEyKkGsDqCCRtE8yO4bjth7vkAUHlOk2DwtnpSsFAccNb97rcpsMeLyEJjBOFOONB3+xshiJcs5BLybJgr8o7P2BqzIDQ== X-Bogosity: Ham, tests=bogofilter, spamicity=0.000000, version=1.2.4 Sender: owner-linux-mm@kvack.org Precedence: bulk X-Loop: owner-majordomo@kvack.org List-ID: tree: https://git.kernel.org/pub/scm/linux/kernel/git/next/linux-next.git master head: d7b3af5a77e8d8da28f435f313e069aea5bcf172 commit: 5d1acc0d9b24e48fde5297a6a40cb9c1a682d740 [5015/5284] powerpc/book3s64/radix: remove mmu_vmemmap_psize config: powerpc-ppc64e_defconfig (https://download.01.org/0day-ci/archive/20230728/202307281617.OxcXz84j-lkp@intel.com/config) compiler: clang version 14.0.6 (https://github.com/llvm/llvm-project.git f28c006a5895fc0e329fe15fead81e37457cb1d1) reproduce: (https://download.01.org/0day-ci/archive/20230728/202307281617.OxcXz84j-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 | Closes: https://lore.kernel.org/oe-kbuild-all/202307281617.OxcXz84j-lkp@intel.com/ All errors (new ones prefixed by >>): __do_##name al; \ ^~~~~~~~~~~~~~ :231:1: note: expanded from here __do_insw ^ arch/powerpc/include/asm/io.h:610:56: note: expanded from macro '__do_insw' #define __do_insw(p, b, n) readsw((PCI_IO_ADDR)_IO_BASE+(p), (b), (n)) ~~~~~~~~~~~~~~~~~~~~~^ In file included from arch/powerpc/mm/init_64.c:27: In file included from include/linux/swap.h:9: In file included from include/linux/memcontrol.h:13: In file included from include/linux/cgroup.h:26: In file included from include/linux/kernel_stat.h:9: In file included from include/linux/interrupt.h:11: In file included from include/linux/hardirq.h:11: In file included from arch/powerpc/include/asm/hardirq.h:6: In file included from include/linux/irq.h:20: In file included from include/linux/io.h:13: In file included from arch/powerpc/include/asm/io.h:672: arch/powerpc/include/asm/io-defs.h:47:1: error: performing pointer arithmetic on a null pointer has undefined behavior [-Werror,-Wnull-pointer-arithmetic] DEF_PCI_AC_NORET(insl, (unsigned long p, void *b, unsigned long c), ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ arch/powerpc/include/asm/io.h:669:3: note: expanded from macro 'DEF_PCI_AC_NORET' __do_##name al; \ ^~~~~~~~~~~~~~ :233:1: note: expanded from here __do_insl ^ arch/powerpc/include/asm/io.h:611:56: note: expanded from macro '__do_insl' #define __do_insl(p, b, n) readsl((PCI_IO_ADDR)_IO_BASE+(p), (b), (n)) ~~~~~~~~~~~~~~~~~~~~~^ In file included from arch/powerpc/mm/init_64.c:27: In file included from include/linux/swap.h:9: In file included from include/linux/memcontrol.h:13: In file included from include/linux/cgroup.h:26: In file included from include/linux/kernel_stat.h:9: In file included from include/linux/interrupt.h:11: In file included from include/linux/hardirq.h:11: In file included from arch/powerpc/include/asm/hardirq.h:6: In file included from include/linux/irq.h:20: In file included from include/linux/io.h:13: In file included from arch/powerpc/include/asm/io.h:672: arch/powerpc/include/asm/io-defs.h:49:1: error: performing pointer arithmetic on a null pointer has undefined behavior [-Werror,-Wnull-pointer-arithmetic] DEF_PCI_AC_NORET(outsb, (unsigned long p, const void *b, unsigned long c), ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ arch/powerpc/include/asm/io.h:669:3: note: expanded from macro 'DEF_PCI_AC_NORET' __do_##name al; \ ^~~~~~~~~~~~~~ :235:1: note: expanded from here __do_outsb ^ arch/powerpc/include/asm/io.h:612:58: note: expanded from macro '__do_outsb' #define __do_outsb(p, b, n) writesb((PCI_IO_ADDR)_IO_BASE+(p),(b),(n)) ~~~~~~~~~~~~~~~~~~~~~^ In file included from arch/powerpc/mm/init_64.c:27: In file included from include/linux/swap.h:9: In file included from include/linux/memcontrol.h:13: In file included from include/linux/cgroup.h:26: In file included from include/linux/kernel_stat.h:9: In file included from include/linux/interrupt.h:11: In file included from include/linux/hardirq.h:11: In file included from arch/powerpc/include/asm/hardirq.h:6: In file included from include/linux/irq.h:20: In file included from include/linux/io.h:13: In file included from arch/powerpc/include/asm/io.h:672: arch/powerpc/include/asm/io-defs.h:51:1: error: performing pointer arithmetic on a null pointer has undefined behavior [-Werror,-Wnull-pointer-arithmetic] DEF_PCI_AC_NORET(outsw, (unsigned long p, const void *b, unsigned long c), ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ arch/powerpc/include/asm/io.h:669:3: note: expanded from macro 'DEF_PCI_AC_NORET' __do_##name al; \ ^~~~~~~~~~~~~~ :237:1: note: expanded from here __do_outsw ^ arch/powerpc/include/asm/io.h:613:58: note: expanded from macro '__do_outsw' #define __do_outsw(p, b, n) writesw((PCI_IO_ADDR)_IO_BASE+(p),(b),(n)) ~~~~~~~~~~~~~~~~~~~~~^ In file included from arch/powerpc/mm/init_64.c:27: In file included from include/linux/swap.h:9: In file included from include/linux/memcontrol.h:13: In file included from include/linux/cgroup.h:26: In file included from include/linux/kernel_stat.h:9: In file included from include/linux/interrupt.h:11: In file included from include/linux/hardirq.h:11: In file included from arch/powerpc/include/asm/hardirq.h:6: In file included from include/linux/irq.h:20: In file included from include/linux/io.h:13: In file included from arch/powerpc/include/asm/io.h:672: arch/powerpc/include/asm/io-defs.h:53:1: error: performing pointer arithmetic on a null pointer has undefined behavior [-Werror,-Wnull-pointer-arithmetic] DEF_PCI_AC_NORET(outsl, (unsigned long p, const void *b, unsigned long c), ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ arch/powerpc/include/asm/io.h:669:3: note: expanded from macro 'DEF_PCI_AC_NORET' __do_##name al; \ ^~~~~~~~~~~~~~ :239:1: note: expanded from here __do_outsl ^ arch/powerpc/include/asm/io.h:614:58: note: expanded from macro '__do_outsl' #define __do_outsl(p, b, n) writesl((PCI_IO_ADDR)_IO_BASE+(p),(b),(n)) ~~~~~~~~~~~~~~~~~~~~~^ >> arch/powerpc/mm/init_64.c:201:15: error: no previous prototype for function '__vmemmap_populate' [-Werror,-Wmissing-prototypes] int __meminit __vmemmap_populate(unsigned long start, unsigned long end, int node, ^ arch/powerpc/mm/init_64.c:201:1: note: declare 'static' if the function is not intended to be used outside of this translation unit int __meminit __vmemmap_populate(unsigned long start, unsigned long end, int node, ^ static 13 errors generated. vim +/__vmemmap_populate +201 arch/powerpc/mm/init_64.c 200 > 201 int __meminit __vmemmap_populate(unsigned long start, unsigned long end, int node, 202 struct vmem_altmap *altmap) 203 { 204 bool altmap_alloc; 205 unsigned long page_size = 1 << mmu_psize_defs[mmu_vmemmap_psize].shift; 206 207 /* Align to the page size of the linear mapping. */ 208 start = ALIGN_DOWN(start, page_size); 209 210 pr_debug("vmemmap_populate %lx..%lx, node %d\n", start, end, node); 211 212 for (; start < end; start += page_size) { 213 void *p = NULL; 214 int rc; 215 216 /* 217 * This vmemmap range is backing different subsections. If any 218 * of that subsection is marked valid, that means we already 219 * have initialized a page table covering this range and hence 220 * the vmemmap range is populated. 221 */ 222 if (vmemmap_populated(start, page_size)) 223 continue; 224 225 /* 226 * Allocate from the altmap first if we have one. This may 227 * fail due to alignment issues when using 16MB hugepages, so 228 * fall back to system memory if the altmap allocation fail. 229 */ 230 if (altmap && !altmap_cross_boundary(altmap, start, page_size)) { 231 p = vmemmap_alloc_block_buf(page_size, node, altmap); 232 if (!p) 233 pr_debug("altmap block allocation failed, falling back to system memory"); 234 else 235 altmap_alloc = true; 236 } 237 if (!p) { 238 p = vmemmap_alloc_block_buf(page_size, node, NULL); 239 altmap_alloc = false; 240 } 241 if (!p) 242 return -ENOMEM; 243 244 if (vmemmap_list_populate(__pa(p), start, node)) { 245 /* 246 * If we don't populate vmemap list, we don't have 247 * the ability to free the allocated vmemmap 248 * pages in section_deactivate. Hence free them 249 * here. 250 */ 251 int nr_pfns = page_size >> PAGE_SHIFT; 252 unsigned long page_order = get_order(page_size); 253 254 if (altmap_alloc) 255 vmem_altmap_free(altmap, nr_pfns); 256 else 257 free_pages((unsigned long)p, page_order); 258 return -ENOMEM; 259 } 260 261 pr_debug(" * %016lx..%016lx allocated at %p\n", 262 start, start + page_size, p); 263 264 rc = vmemmap_create_mapping(start, page_size, __pa(p)); 265 if (rc < 0) { 266 pr_warn("%s: Unable to create vmemmap mapping: %d\n", 267 __func__, rc); 268 return -EFAULT; 269 } 270 } 271 272 return 0; 273 } 274 -- 0-DAY CI Kernel Test Service https://github.com/intel/lkp-tests/wiki