x86/mm: Unexport __cachemode2pte_tbl
authorChristoph Hellwig <hch@lst.de>
Wed, 8 Apr 2020 15:27:45 +0000 (17:27 +0200)
committerBorislav Petkov <bp@suse.de>
Thu, 23 Apr 2020 09:34:31 +0000 (11:34 +0200)
commitde17a37896e1ad9e17ebd5274a50c33e18c9cb90
tree498e5b938b9bdeec5d19b4ece900b92bb94e4100
parentd073569363d9f076a568ce8c31250d332ccf33ce
x86/mm: Unexport __cachemode2pte_tbl

Exporting the raw data for a table is generally a bad idea. Move
cachemode2protval() out of line given that it isn't really used in the
fast path, and then mark __cachemode2pte_tbl static.

Signed-off-by: Christoph Hellwig <hch@lst.de>
Signed-off-by: Borislav Petkov <bp@suse.de>
Acked-by: Peter Zijlstra (Intel) <peterz@infradead.org>
Link: https://lkml.kernel.org/r/20200408152745.1565832-5-hch@lst.de
arch/x86/include/asm/pgtable_types.h
arch/x86/mm/init.c
arch/x86/mm/pat/set_memory.c