]> git.baikalelectronics.ru Git - kernel.git/commit
parisc: Drop PMD_SHIFT from calculation in pgtable.h
authorHelge Deller <deller@gmx.de>
Wed, 14 Dec 2022 21:17:57 +0000 (22:17 +0100)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Sat, 7 Jan 2023 10:11:56 +0000 (11:11 +0100)
commit6b50e4287f1300bbdd43130a97dba66db715010c
tree7dec23ae798ffd4c20481a306b418b76c2aa27e0
parent692000173ed326acbdc5651dbb29f2c242650e35
parisc: Drop PMD_SHIFT from calculation in pgtable.h

commit 5c37c5f509fc06b3909ff12734bb73672fa6d102 upstream.

PMD_SHIFT isn't defined if CONFIG_PGTABLE_LEVELS == 3, and as
such the kernel test robot found this warning:

 In file included from include/linux/pgtable.h:6,
                  from arch/parisc/kernel/head.S:23:
 arch/parisc/include/asm/pgtable.h:169:32: warning: "PMD_SHIFT" is not defined, evaluates to 0 [-Wundef]
     169 | #if (KERNEL_INITIAL_ORDER) >= (PMD_SHIFT)

Avoid the warning by using PLD_SHIFT and BITS_PER_PTE.

Signed-off-by: Helge Deller <deller@gmx.de>
Reported-by: kernel test robot <lkp@intel.com>
Cc: <stable@vger.kernel.org> # 6.0+
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
arch/parisc/include/asm/pgtable.h