* [powerpc:next-test 103/106] arch/powerpc/mm/book3s64/radix_pgtable.c:513:21: error: use of undeclared identifier 'SECTION_SIZE_BITS'
@ 2020-07-18 20:58 kernel test robot
2020-07-19 6:35 ` Aneesh Kumar K.V
0 siblings, 1 reply; 4+ messages in thread
From: kernel test robot @ 2020-07-18 20:58 UTC (permalink / raw)
To: Aneesh Kumar K.V
Cc: clang-built-linux, Bharata B Rao, kbuild-all, linuxppc-dev
[-- Attachment #1: Type: text/plain, Size: 2808 bytes --]
tree: https://git.kernel.org/pub/scm/linux/kernel/git/powerpc/linux.git next-test
head: 5fed3b3e21db21f9a7002426f456fd3a8a8c0772
commit: 21407f39b9d547da527ad5224c4323e1f62bb514 [103/106] powerpc/mm/radix: Create separate mappings for hot-plugged memory
config: powerpc-randconfig-r016-20200719 (attached as .config)
compiler: clang version 12.0.0 (https://github.com/llvm/llvm-project ed6b578040a85977026c93bf4188f996148f3218)
reproduce (this is a W=1 build):
wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross
chmod +x ~/bin/make.cross
# install powerpc cross compiling tool for clang build
# apt-get install binutils-powerpc-linux-gnu
git checkout 21407f39b9d547da527ad5224c4323e1f62bb514
# save the attached .config to linux build tree
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=clang make.cross ARCH=powerpc
If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp@intel.com>
All errors (new ones prefixed by >>):
>> arch/powerpc/mm/book3s64/radix_pgtable.c:513:21: error: use of undeclared identifier 'SECTION_SIZE_BITS'
*mem_block_size = MIN_MEMORY_BLOCK_SIZE;
^
include/linux/memory.h:24:43: note: expanded from macro 'MIN_MEMORY_BLOCK_SIZE'
#define MIN_MEMORY_BLOCK_SIZE (1UL << SECTION_SIZE_BITS)
^
arch/powerpc/mm/book3s64/radix_pgtable.c:521:33: error: use of undeclared identifier 'SECTION_SIZE_BITS'
unsigned long mem_block_size = MIN_MEMORY_BLOCK_SIZE;
^
include/linux/memory.h:24:43: note: expanded from macro 'MIN_MEMORY_BLOCK_SIZE'
#define MIN_MEMORY_BLOCK_SIZE (1UL << SECTION_SIZE_BITS)
^
2 errors generated.
vim +/SECTION_SIZE_BITS +513 arch/powerpc/mm/book3s64/radix_pgtable.c
494
495 static int __init probe_memory_block_size(unsigned long node, const char *uname, int
496 depth, void *data)
497 {
498 unsigned long *mem_block_size = (unsigned long *)data;
499 const __be64 *prop;
500 int len;
501
502 if (depth != 1)
503 return 0;
504
505 if (strcmp(uname, "ibm,dynamic-reconfiguration-memory"))
506 return 0;
507
508 prop = of_get_flat_dt_prop(node, "ibm,lmb-size", &len);
509 if (!prop || len < sizeof(__be64))
510 /*
511 * Nothing in the device tree
512 */
> 513 *mem_block_size = MIN_MEMORY_BLOCK_SIZE;
514 else
515 *mem_block_size = be64_to_cpup(prop);
516 return 1;
517 }
518
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org
[-- Attachment #2: .config.gz --]
[-- Type: application/gzip, Size: 28028 bytes --]
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [powerpc:next-test 103/106] arch/powerpc/mm/book3s64/radix_pgtable.c:513:21: error: use of undeclared identifier 'SECTION_SIZE_BITS'
2020-07-18 20:58 [powerpc:next-test 103/106] arch/powerpc/mm/book3s64/radix_pgtable.c:513:21: error: use of undeclared identifier 'SECTION_SIZE_BITS' kernel test robot
@ 2020-07-19 6:35 ` Aneesh Kumar K.V
2020-07-20 16:39 ` Christophe Leroy
0 siblings, 1 reply; 4+ messages in thread
From: Aneesh Kumar K.V @ 2020-07-19 6:35 UTC (permalink / raw)
To: kernel test robot
Cc: clang-built-linux, Bharata B Rao, kbuild-all, linuxppc-dev
kernel test robot <lkp@intel.com> writes:
> tree: https://git.kernel.org/pub/scm/linux/kernel/git/powerpc/linux.git next-test
> head: 5fed3b3e21db21f9a7002426f456fd3a8a8c0772
> commit: 21407f39b9d547da527ad5224c4323e1f62bb514 [103/106] powerpc/mm/radix: Create separate mappings for hot-plugged memory
> config: powerpc-randconfig-r016-20200719 (attached as .config)
> compiler: clang version 12.0.0 (https://github.com/llvm/llvm-project ed6b578040a85977026c93bf4188f996148f3218)
> reproduce (this is a W=1 build):
> wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross
> chmod +x ~/bin/make.cross
> # install powerpc cross compiling tool for clang build
> # apt-get install binutils-powerpc-linux-gnu
> git checkout 21407f39b9d547da527ad5224c4323e1f62bb514
> # save the attached .config to linux build tree
> COMPILER_INSTALL_PATH=$HOME/0day COMPILER=clang make.cross ARCH=powerpc
>
> If you fix the issue, kindly add following tag as appropriate
> Reported-by: kernel test robot <lkp@intel.com>
>
> All errors (new ones prefixed by >>):
>
>>> arch/powerpc/mm/book3s64/radix_pgtable.c:513:21: error: use of undeclared identifier 'SECTION_SIZE_BITS'
> *mem_block_size = MIN_MEMORY_BLOCK_SIZE;
> ^
> include/linux/memory.h:24:43: note: expanded from macro 'MIN_MEMORY_BLOCK_SIZE'
> #define MIN_MEMORY_BLOCK_SIZE (1UL << SECTION_SIZE_BITS)
> ^
> arch/powerpc/mm/book3s64/radix_pgtable.c:521:33: error: use of undeclared identifier 'SECTION_SIZE_BITS'
> unsigned long mem_block_size = MIN_MEMORY_BLOCK_SIZE;
> ^
> include/linux/memory.h:24:43: note: expanded from macro 'MIN_MEMORY_BLOCK_SIZE'
> #define MIN_MEMORY_BLOCK_SIZE (1UL << SECTION_SIZE_BITS)
> ^
> 2 errors generated.
>
> vim +/SECTION_SIZE_BITS +513 arch/powerpc/mm/book3s64/radix_pgtable.c
>
> 494
> 495 static int __init probe_memory_block_size(unsigned long node, const char *uname, int
> 496 depth, void *data)
> 497 {
> 498 unsigned long *mem_block_size = (unsigned long *)data;
> 499 const __be64 *prop;
> 500 int len;
> 501
> 502 if (depth != 1)
> 503 return 0;
> 504
> 505 if (strcmp(uname, "ibm,dynamic-reconfiguration-memory"))
> 506 return 0;
> 507
> 508 prop = of_get_flat_dt_prop(node, "ibm,lmb-size", &len);
> 509 if (!prop || len < sizeof(__be64))
> 510 /*
> 511 * Nothing in the device tree
> 512 */
> > 513 *mem_block_size = MIN_MEMORY_BLOCK_SIZE;
> 514 else
> 515 *mem_block_size = be64_to_cpup(prop);
> 516 return 1;
> 517 }
> 518
>
arch/powerpc/mm/book3s64/radix_pgtable.c | 10 ++++++++++
1 file changed, 10 insertions(+)
diff --git a/arch/powerpc/mm/book3s64/radix_pgtable.c b/arch/powerpc/mm/book3s64/radix_pgtable.c
index bba45fc0b7b2..c5bf2ef73c36 100644
--- a/arch/powerpc/mm/book3s64/radix_pgtable.c
+++ b/arch/powerpc/mm/book3s64/radix_pgtable.c
@@ -492,6 +492,7 @@ static int __init radix_dt_scan_page_sizes(unsigned long node,
return 1;
}
+#ifdef CONFIG_MEMORY_HOTPLUG
static int __init probe_memory_block_size(unsigned long node, const char *uname, int
depth, void *data)
{
@@ -532,6 +533,15 @@ static unsigned long radix_memory_block_size(void)
return mem_block_size;
}
+#else /* CONFIG_MEMORY_HOTPLUG */
+
+static unsigned long radix_memory_block_size(void)
+{
+ return 1UL * 1024 * 1024 * 1024;
+}
+
+#endif /* CONFIG_MEMORY_HOTPLUG */
+
void __init radix__early_init_devtree(void)
{
--
2.26.2
-aneesh
^ permalink raw reply related [flat|nested] 4+ messages in thread
* Re: [powerpc:next-test 103/106] arch/powerpc/mm/book3s64/radix_pgtable.c:513:21: error: use of undeclared identifier 'SECTION_SIZE_BITS'
2020-07-19 6:35 ` Aneesh Kumar K.V
@ 2020-07-20 16:39 ` Christophe Leroy
2020-07-21 3:13 ` Michael Ellerman
0 siblings, 1 reply; 4+ messages in thread
From: Christophe Leroy @ 2020-07-20 16:39 UTC (permalink / raw)
To: Aneesh Kumar K.V
Cc: kbuild-all, kernel test robot, linuxppc-dev, clang-built-linux,
Bharata B Rao
"Aneesh Kumar K.V" <aneesh.kumar@linux.ibm.com> a écrit :
> kernel test robot <lkp@intel.com> writes:
>
>> tree:
>> https://git.kernel.org/pub/scm/linux/kernel/git/powerpc/linux.git
>> next-test
>> head: 5fed3b3e21db21f9a7002426f456fd3a8a8c0772
>> commit: 21407f39b9d547da527ad5224c4323e1f62bb514 [103/106]
>> powerpc/mm/radix: Create separate mappings for hot-plugged memory
>> config: powerpc-randconfig-r016-20200719 (attached as .config)
>> compiler: clang version 12.0.0
>> (https://github.com/llvm/llvm-project
>> ed6b578040a85977026c93bf4188f996148f3218)
>> reproduce (this is a W=1 build):
>> wget
>> https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O
>> ~/bin/make.cross
>> chmod +x ~/bin/make.cross
>> # install powerpc cross compiling tool for clang build
>> # apt-get install binutils-powerpc-linux-gnu
>> git checkout 21407f39b9d547da527ad5224c4323e1f62bb514
>> # save the attached .config to linux build tree
>> COMPILER_INSTALL_PATH=$HOME/0day COMPILER=clang make.cross
>> ARCH=powerpc
>>
>> If you fix the issue, kindly add following tag as appropriate
>> Reported-by: kernel test robot <lkp@intel.com>
>>
>> All errors (new ones prefixed by >>):
>>
>>>> arch/powerpc/mm/book3s64/radix_pgtable.c:513:21: error: use of
>>>> undeclared identifier 'SECTION_SIZE_BITS'
>> *mem_block_size = MIN_MEMORY_BLOCK_SIZE;
>> ^
>> include/linux/memory.h:24:43: note: expanded from macro
>> 'MIN_MEMORY_BLOCK_SIZE'
>> #define MIN_MEMORY_BLOCK_SIZE (1UL << SECTION_SIZE_BITS)
>> ^
>> arch/powerpc/mm/book3s64/radix_pgtable.c:521:33: error: use of
>> undeclared identifier 'SECTION_SIZE_BITS'
>> unsigned long mem_block_size = MIN_MEMORY_BLOCK_SIZE;
>> ^
>> include/linux/memory.h:24:43: note: expanded from macro
>> 'MIN_MEMORY_BLOCK_SIZE'
>> #define MIN_MEMORY_BLOCK_SIZE (1UL << SECTION_SIZE_BITS)
>> ^
>> 2 errors generated.
>>
>> vim +/SECTION_SIZE_BITS +513 arch/powerpc/mm/book3s64/radix_pgtable.c
>>
>> 494
>> 495 static int __init probe_memory_block_size(unsigned long
>> node, const char *uname, int
>> 496 depth, void *data)
>> 497 {
>> 498 unsigned long *mem_block_size = (unsigned long *)data;
>> 499 const __be64 *prop;
>> 500 int len;
>> 501
>> 502 if (depth != 1)
>> 503 return 0;
>> 504
>> 505 if (strcmp(uname, "ibm,dynamic-reconfiguration-memory"))
>> 506 return 0;
>> 507
>> 508 prop = of_get_flat_dt_prop(node, "ibm,lmb-size", &len);
>> 509 if (!prop || len < sizeof(__be64))
>> 510 /*
>> 511 * Nothing in the device tree
>> 512 */
>> > 513 *mem_block_size = MIN_MEMORY_BLOCK_SIZE;
>> 514 else
>> 515 *mem_block_size = be64_to_cpup(prop);
>> 516 return 1;
>> 517 }
>> 518
>>
>
> arch/powerpc/mm/book3s64/radix_pgtable.c | 10 ++++++++++
> 1 file changed, 10 insertions(+)
>
> diff --git a/arch/powerpc/mm/book3s64/radix_pgtable.c
> b/arch/powerpc/mm/book3s64/radix_pgtable.c
> index bba45fc0b7b2..c5bf2ef73c36 100644
> --- a/arch/powerpc/mm/book3s64/radix_pgtable.c
> +++ b/arch/powerpc/mm/book3s64/radix_pgtable.c
> @@ -492,6 +492,7 @@ static int __init
> radix_dt_scan_page_sizes(unsigned long node,
> return 1;
> }
>
> +#ifdef CONFIG_MEMORY_HOTPLUG
> static int __init probe_memory_block_size(unsigned long node, const
> char *uname, int
> depth, void *data)
> {
> @@ -532,6 +533,15 @@ static unsigned long radix_memory_block_size(void)
> return mem_block_size;
> }
>
> +#else /* CONFIG_MEMORY_HOTPLUG */
> +
> +static unsigned long radix_memory_block_size(void)
> +{
> + return 1UL * 1024 * 1024 * 1024;
Use SZ_1G instead ?
Christophe
> +}
> +
> +#endif /* CONFIG_MEMORY_HOTPLUG */
> +
>
> void __init radix__early_init_devtree(void)
> {
> --
> 2.26.2
>
>
> -aneesh
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [powerpc:next-test 103/106] arch/powerpc/mm/book3s64/radix_pgtable.c:513:21: error: use of undeclared identifier 'SECTION_SIZE_BITS'
2020-07-20 16:39 ` Christophe Leroy
@ 2020-07-21 3:13 ` Michael Ellerman
0 siblings, 0 replies; 4+ messages in thread
From: Michael Ellerman @ 2020-07-21 3:13 UTC (permalink / raw)
To: Christophe Leroy, Aneesh Kumar K.V
Cc: linuxppc-dev, Bharata B Rao, kbuild-all, kernel test robot,
clang-built-linux
Christophe Leroy <christophe.leroy@csgroup.eu> writes:
> "Aneesh Kumar K.V" <aneesh.kumar@linux.ibm.com> a écrit :
...
>>
>> diff --git a/arch/powerpc/mm/book3s64/radix_pgtable.c
>> b/arch/powerpc/mm/book3s64/radix_pgtable.c
>> index bba45fc0b7b2..c5bf2ef73c36 100644
>> --- a/arch/powerpc/mm/book3s64/radix_pgtable.c
>> +++ b/arch/powerpc/mm/book3s64/radix_pgtable.c
>> @@ -492,6 +492,7 @@ static int __init
>> @@ -532,6 +533,15 @@ static unsigned long radix_memory_block_size(void)
>> return mem_block_size;
>> }
>>
>> +#else /* CONFIG_MEMORY_HOTPLUG */
>> +
>> +static unsigned long radix_memory_block_size(void)
>> +{
>> + return 1UL * 1024 * 1024 * 1024;
>
> Use SZ_1G instead ?
I've already squashed that in.
I'd take a patch to convert all cases though, I see at least:
arch/powerpc/boot/ep8248e.c: mem_size *= 1024 * 1024;
arch/powerpc/boot/ep88xc.c: mem_size *= 1024 * 1024;
arch/powerpc/include/asm/kexec.h:#define KEXEC_SOURCE_MEMORY_LIMIT (2 * 1024 * 1024 * 1024UL - 1)
arch/powerpc/include/asm/kexec.h:#define KEXEC_DESTINATION_MEMORY_LIMIT (2 * 1024 * 1024 * 1024UL - 1)
arch/powerpc/include/asm/kexec.h:#define KEXEC_CONTROL_MEMORY_LIMIT (2 * 1024 * 1024 * 1024UL - 1)
arch/powerpc/kernel/iommu.c: if ((tbl->it_size << tbl->it_page_shift) >= (1UL * 1024 * 1024 * 1024))
arch/powerpc/kernel/setup-common.c: (unsigned int)(total_memory / (1024 * 1024)));
arch/powerpc/mm/book3s64/radix_pgtable.c: mem_block_size = 1UL * 1024 * 1024 * 1024;
arch/powerpc/mm/book3s64/radix_pgtable.c: return 1UL * 1024 * 1024 * 1024;
arch/powerpc/mm/ioremap_32.c: if (p < 16 * 1024 * 1024)
arch/powerpc/platforms/powernv/setup.c: return 256UL * 1024 * 1024;
arch/powerpc/platforms/pseries/cmm.c: signed long min_mem_pages = (min_mem_mb * 1024 * 1024) / PAGE_SIZE;
cheers
^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2020-07-21 3:15 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-07-18 20:58 [powerpc:next-test 103/106] arch/powerpc/mm/book3s64/radix_pgtable.c:513:21: error: use of undeclared identifier 'SECTION_SIZE_BITS' kernel test robot
2020-07-19 6:35 ` Aneesh Kumar K.V
2020-07-20 16:39 ` Christophe Leroy
2020-07-21 3:13 ` Michael Ellerman
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).