]> git.baikalelectronics.ru Git - kernel.git/commit
s390/mm: correct allocate_pgste proc_handler callback
authorVasily Gorbik <gor@linux.ibm.com>
Sun, 24 Jun 2018 10:17:43 +0000 (12:17 +0200)
committerMartin Schwidefsky <schwidefsky@de.ibm.com>
Fri, 6 Jul 2018 06:47:52 +0000 (08:47 +0200)
commitfc5d1768a5642a5041b01ea093748579c2de1a90
tree902da81dbaf148a4b579860e6834059ac367a4ba
parent5a9658ac47e1d1517d5827c924218293b2dbf3ef
s390/mm: correct allocate_pgste proc_handler callback

Since proc_dointvec does not perform value range control,
proc_dointvec_minmax should be used to limit value range, which is
clearly intended here, as the internal representation of the value:

unsigned int alloc_pgste:1;

In fact it currently works, since we have

      mm->context.alloc_pgste = page_table_allocate_pgste || ...

... since commit 9bfdbaf2bd447 ("s390/kvm: avoid global config of vm.alloc_pgste=1")

Before that it was

       mm->context.alloc_pgste = page_table_allocate_pgste;

which was broken. That was introduced with commit ab6617af8548f ("s390/kvm:
remove delayed reallocation of page tables for KVM").

Fixes: ab6617af8548f ("s390/kvm: remove delayed reallocation of page tables for KVM")
Acked-by: Christian Borntraeger <borntraeger@de.ibm.com>
Reviewed-by: Heiko Carstens <heiko.carstens@de.ibm.com>
Signed-off-by: Vasily Gorbik <gor@linux.ibm.com>
Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com>
arch/s390/mm/pgalloc.c