Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

[S390] Enable guest page hinting by default.

Get rid of the PAGE_STATES config option and enable guest page hinting
by default.
It can be disabled by specifying "cmma=off" at the command line.

Signed-off-by: Heiko Carstens <heiko.carstens@de.ibm.com>
Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com>

authored by

Heiko Carstens and committed by
Martin Schwidefsky
2ddddf3e 5dd1d2ec

+4 -21
-7
arch/s390/Kconfig
··· 480 480 Select this option to enable the special message interface to 481 481 the cooperative memory management. 482 482 483 - config PAGE_STATES 484 - bool "Unused page notification" 485 - help 486 - This enables the notification of unused pages to the 487 - hypervisor. The ESSA instruction is used to do the states 488 - changes between a page that has content and the unused state. 489 - 490 483 config APPLDATA_BASE 491 484 bool "Linux - VM Monitor Stream, base infrastructure" 492 485 depends on PROC_FS
-4
arch/s390/include/asm/page.h
··· 125 125 return skey; 126 126 } 127 127 128 - #ifdef CONFIG_PAGE_STATES 129 - 130 128 struct page; 131 129 void arch_free_page(struct page *page, int order); 132 130 void arch_alloc_page(struct page *page, int order); 133 131 134 132 #define HAVE_ARCH_FREE_PAGE 135 133 #define HAVE_ARCH_ALLOC_PAGE 136 - 137 - #endif 138 134 139 135 #endif /* !__ASSEMBLY__ */ 140 136
-4
arch/s390/include/asm/system.h
··· 109 109 #define pfault_fini() do { } while (0) 110 110 #endif /* CONFIG_PFAULT */ 111 111 112 - #ifdef CONFIG_PAGE_STATES 113 112 extern void cmma_init(void); 114 - #else 115 - static inline void cmma_init(void) { } 116 - #endif 117 113 118 114 #define finish_arch_switch(prev) do { \ 119 115 set_fs(current->thread.mm_segment); \
+2 -2
arch/s390/mm/Makefile
··· 2 2 # Makefile for the linux s390-specific parts of the memory manager. 3 3 # 4 4 5 - obj-y := init.o fault.o extmem.o mmap.o vmem.o pgtable.o maccess.o 5 + obj-y := init.o fault.o extmem.o mmap.o vmem.o pgtable.o maccess.o \ 6 + page-states.o 6 7 obj-$(CONFIG_CMM) += cmm.o 7 8 obj-$(CONFIG_HUGETLB_PAGE) += hugetlbpage.o 8 - obj-$(CONFIG_PAGE_STATES) += page-states.o
+2 -4
arch/s390/mm/page-states.c
··· 1 1 /* 2 - * arch/s390/mm/page-states.c 3 - * 4 2 * Copyright IBM Corp. 2008 5 3 * 6 4 * Guest page hinting for unused pages. ··· 15 17 #define ESSA_SET_STABLE 1 16 18 #define ESSA_SET_UNUSED 2 17 19 18 - static int cmma_flag; 20 + static int cmma_flag = 1; 19 21 20 22 static int __init cmma(char *str) 21 23 { 22 24 char *parm; 25 + 23 26 parm = strstrip(str); 24 27 if (strcmp(parm, "yes") == 0 || strcmp(parm, "on") == 0) { 25 28 cmma_flag = 1; ··· 31 32 return 1; 32 33 return 0; 33 34 } 34 - 35 35 __setup("cmma=", cmma); 36 36 37 37 void __init cmma_init(void)