Revision a25fddced835ae53d18eb4bddabd719b4cebf624 authored by Miaohe Lin on 24 February 2021, 20:10:14 UTC, committed by Linus Torvalds on 24 February 2021, 21:38:35 UTC
The calculation 1U << (h->order + PAGE_SHIFT - 10) is actually equal to
(PAGE_SHIFT << (h->order)) >> 10.  So we can make it more readable by
replace it with huge_page_size(h) >> 10.

Link: https://lkml.kernel.org/r/20210122083141.24548-1-linmiaohe@huawei.com
Signed-off-by: Miaohe Lin <linmiaohe@huawei.com>
Reviewed-by: Mike Kravetz <mike.kravetz@oracle.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
1 parent 88ce3fe
History
File Mode Size
apparmor
bpf
integrity
keys
loadpin
lockdown
safesetid
selinux
smack
tomoyo
yama
Kconfig -rw-r--r-- 10.7 KB
Kconfig.hardening -rw-r--r-- 8.8 KB
Makefile -rw-r--r-- 1.3 KB
commoncap.c -rw-r--r-- 42.9 KB
device_cgroup.c -rw-r--r-- 21.1 KB
inode.c -rw-r--r-- 10.6 KB
lsm_audit.c -rw-r--r-- 10.9 KB
min_addr.c -rw-r--r-- 1.3 KB
security.c -rw-r--r-- 64.3 KB

back to top