Re: [PATCH 3/4] s390/mm: prevent and break zero page mappings in case of storage keys

2014-10-22 Thread Paolo Bonzini
Reviewed-by: Paolo Bonzini On 10/22/2014 01:09 PM, Dominik Dingel wrote: > As soon as storage keys are enabled we need to stop working on zero page > mappings to prevent inconsistencies between storage keys and pgste. > > Otherwise following data corruption could happen: > 1) guest enables stora

[PATCH 3/4] s390/mm: prevent and break zero page mappings in case of storage keys

2014-10-22 Thread Dominik Dingel
As soon as storage keys are enabled we need to stop working on zero page mappings to prevent inconsistencies between storage keys and pgste. Otherwise following data corruption could happen: 1) guest enables storage key 2) guest sets storage key for not mapped page X -> change goes to PGSTE 3)

Re: [PATCH 3/4] s390/mm: prevent and break zero page mappings in case of storage keys

2014-10-22 Thread Dominik Dingel
On Wed, 22 Oct 2014 12:09:31 +0200 Paolo Bonzini wrote: > On 10/22/2014 10:30 AM, Dominik Dingel wrote: > > As use_skey is already the condition on which we call s390_enable_skey > > we need to introduce a new flag for the mm->context on which we decide > > if zero page mapping is allowed. > > C

Re: [PATCH 3/4] s390/mm: prevent and break zero page mappings in case of storage keys

2014-10-22 Thread Paolo Bonzini
On 10/22/2014 10:30 AM, Dominik Dingel wrote: > As use_skey is already the condition on which we call s390_enable_skey > we need to introduce a new flag for the mm->context on which we decide > if zero page mapping is allowed. Can you explain better why "mm->context.use_skey = 1" cannot be done be

[PATCH 3/4] s390/mm: prevent and break zero page mappings in case of storage keys

2014-10-22 Thread Dominik Dingel
As soon as storage keys are enabled we need to stop working on zero page mappings to prevent inconsistencies between storage keys and pgste. Otherwise following data corruption could happen: 1) guest enables storage key 2) guest sets storage key for not mapped page X -> change goes to PGSTE 3)

[PATCH 3/4] s390/mm: prevent and break zero page mappings in case of storage keys

2014-10-17 Thread Dominik Dingel
As soon as storage keys are enabled we need to work around of zero page mappings to prevent inconsistencies between storage keys and pgste. Otherwise following data corruption could happen: 1) guest enables storage key 2) guest sets storage key for not mapped page X -> change goes to PGSTE 3) g