diff options
author | Dominik Dingel <dingel@linux.vnet.ibm.com> | 2014-01-29 10:02:32 -0500 |
---|---|---|
committer | Christian Borntraeger <borntraeger@de.ibm.com> | 2014-04-22 03:36:24 -0400 |
commit | d4cb11340be6a1613d40d2b546cb111ea2547066 (patch) | |
tree | a9f8509c2a9ca3ae530e848995a59961d3fed995 /arch/s390/kvm/diag.c | |
parent | 65eef33550f68e9a7f7d2dc64da94fb6cb85be2c (diff) |
KVM: s390: Clear storage keys
page_table_reset_pgste() already does a complete page table walk to
reset the pgste. Enhance it to initialize the storage keys to
PAGE_DEFAULT_KEY if requested by the caller. This will be used
for lazy storage key handling. Also provide an empty stub for
!CONFIG_PGSTE
Lets adopt the current code (diag 308) to not clear the keys.
Signed-off-by: Dominik Dingel <dingel@linux.vnet.ibm.com>
Acked-by: Martin Schwidefsky <schwidefsky@de.ibm.com>
Signed-off-by: Christian Borntraeger <borntraeger@de.ibm.com>
Diffstat (limited to 'arch/s390/kvm/diag.c')
-rw-r--r-- | arch/s390/kvm/diag.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/arch/s390/kvm/diag.c b/arch/s390/kvm/diag.c index 08dfc839a6cf..44dcfa8860b5 100644 --- a/arch/s390/kvm/diag.c +++ b/arch/s390/kvm/diag.c | |||
@@ -169,15 +169,15 @@ static int __diag_ipl_functions(struct kvm_vcpu *vcpu) | |||
169 | switch (subcode) { | 169 | switch (subcode) { |
170 | case 0: | 170 | case 0: |
171 | case 1: | 171 | case 1: |
172 | page_table_reset_pgste(current->mm, 0, TASK_SIZE); | 172 | page_table_reset_pgste(current->mm, 0, TASK_SIZE, false); |
173 | return -EOPNOTSUPP; | 173 | return -EOPNOTSUPP; |
174 | case 3: | 174 | case 3: |
175 | vcpu->run->s390_reset_flags = KVM_S390_RESET_CLEAR; | 175 | vcpu->run->s390_reset_flags = KVM_S390_RESET_CLEAR; |
176 | page_table_reset_pgste(current->mm, 0, TASK_SIZE); | 176 | page_table_reset_pgste(current->mm, 0, TASK_SIZE, false); |
177 | break; | 177 | break; |
178 | case 4: | 178 | case 4: |
179 | vcpu->run->s390_reset_flags = 0; | 179 | vcpu->run->s390_reset_flags = 0; |
180 | page_table_reset_pgste(current->mm, 0, TASK_SIZE); | 180 | page_table_reset_pgste(current->mm, 0, TASK_SIZE, false); |
181 | break; | 181 | break; |
182 | default: | 182 | default: |
183 | return -EOPNOTSUPP; | 183 | return -EOPNOTSUPP; |