Re: [PATCH 1/2] KVM: async_pf: kill the unnecessary use_mm/unuse_mm async_pf_execute()

2014-04-28 Thread Paolo Bonzini
Il 28/04/2014 16:06, Andrea Arcangeli ha scritto: > > "task" is only used to increment task_struct->xxx_flt. I don't think > async_pf_execute() actually needs this (current is PF_WQ_WORKER after > all), but I didn't dare to do another change in the code I can hardly > understand. Considering

Re: [PATCH 1/2] KVM: async_pf: kill the unnecessary use_mm/unuse_mm async_pf_execute()

2014-04-28 Thread Andrea Arcangeli
Hi, On Wed, Apr 23, 2014 at 09:32:28PM +0200, Oleg Nesterov wrote: > On 04/22, Christian Borntraeger wrote: > > > > On 22/04/14 22:15, Christian Borntraeger wrote: > > > On 21/04/14 15:25, Oleg Nesterov wrote: > > >> async_pf_execute() has no reasons to adopt apf->mm, gup(current, mm) > > >>

Re: [PATCH 1/2] KVM: async_pf: kill the unnecessary use_mm/unuse_mm async_pf_execute()

2014-04-28 Thread Andrea Arcangeli
Hi, On Wed, Apr 23, 2014 at 09:32:28PM +0200, Oleg Nesterov wrote: On 04/22, Christian Borntraeger wrote: On 22/04/14 22:15, Christian Borntraeger wrote: On 21/04/14 15:25, Oleg Nesterov wrote: async_pf_execute() has no reasons to adopt apf-mm, gup(current, mm) should work just fine

Re: [PATCH 1/2] KVM: async_pf: kill the unnecessary use_mm/unuse_mm async_pf_execute()

2014-04-28 Thread Paolo Bonzini
Il 28/04/2014 16:06, Andrea Arcangeli ha scritto: task is only used to increment task_struct-xxx_flt. I don't think async_pf_execute() actually needs this (current is PF_WQ_WORKER after all), but I didn't dare to do another change in the code I can hardly understand. Considering the faults

Re: [PATCH 1/2] KVM: async_pf: kill the unnecessary use_mm/unuse_mm async_pf_execute()

2014-04-23 Thread Oleg Nesterov
On 04/22, Christian Borntraeger wrote: > > On 22/04/14 22:15, Christian Borntraeger wrote: > > On 21/04/14 15:25, Oleg Nesterov wrote: > >> async_pf_execute() has no reasons to adopt apf->mm, gup(current, mm) > >> should work just fine even if current has another or NULL ->mm. > >> > >> Recently

Re: [PATCH 1/2] KVM: async_pf: kill the unnecessary use_mm/unuse_mm async_pf_execute()

2014-04-23 Thread Oleg Nesterov
On 04/22, Christian Borntraeger wrote: On 22/04/14 22:15, Christian Borntraeger wrote: On 21/04/14 15:25, Oleg Nesterov wrote: async_pf_execute() has no reasons to adopt apf-mm, gup(current, mm) should work just fine even if current has another or NULL -mm. Recently

Re: [PATCH 1/2] KVM: async_pf: kill the unnecessary use_mm/unuse_mm async_pf_execute()

2014-04-22 Thread Christian Borntraeger
On 22/04/14 22:15, Christian Borntraeger wrote: > On 21/04/14 15:25, Oleg Nesterov wrote: >> async_pf_execute() has no reasons to adopt apf->mm, gup(current, mm) >> should work just fine even if current has another or NULL ->mm. >> >> Recently kvm_async_page_present_sync() was added insedie the

Re: [PATCH 1/2] KVM: async_pf: kill the unnecessary use_mm/unuse_mm async_pf_execute()

2014-04-22 Thread Christian Borntraeger
On 21/04/14 15:25, Oleg Nesterov wrote: > async_pf_execute() has no reasons to adopt apf->mm, gup(current, mm) > should work just fine even if current has another or NULL ->mm. > > Recently kvm_async_page_present_sync() was added insedie the "use_mm" > section, but it seems that it doesn't need

Re: [PATCH 1/2] KVM: async_pf: kill the unnecessary use_mm/unuse_mm async_pf_execute()

2014-04-22 Thread Christian Borntraeger
On 21/04/14 15:25, Oleg Nesterov wrote: async_pf_execute() has no reasons to adopt apf-mm, gup(current, mm) should work just fine even if current has another or NULL -mm. Recently kvm_async_page_present_sync() was added insedie the use_mm section, but it seems that it doesn't need current-mm

Re: [PATCH 1/2] KVM: async_pf: kill the unnecessary use_mm/unuse_mm async_pf_execute()

2014-04-22 Thread Christian Borntraeger
On 22/04/14 22:15, Christian Borntraeger wrote: On 21/04/14 15:25, Oleg Nesterov wrote: async_pf_execute() has no reasons to adopt apf-mm, gup(current, mm) should work just fine even if current has another or NULL -mm. Recently kvm_async_page_present_sync() was added insedie the use_mm

[PATCH 1/2] KVM: async_pf: kill the unnecessary use_mm/unuse_mm async_pf_execute()

2014-04-21 Thread Oleg Nesterov
async_pf_execute() has no reasons to adopt apf->mm, gup(current, mm) should work just fine even if current has another or NULL ->mm. Recently kvm_async_page_present_sync() was added insedie the "use_mm" section, but it seems that it doesn't need current->mm too. Signed-off-by: Oleg Nesterov ---

[PATCH 1/2] KVM: async_pf: kill the unnecessary use_mm/unuse_mm async_pf_execute()

2014-04-21 Thread Oleg Nesterov
async_pf_execute() has no reasons to adopt apf-mm, gup(current, mm) should work just fine even if current has another or NULL -mm. Recently kvm_async_page_present_sync() was added insedie the use_mm section, but it seems that it doesn't need current-mm too. Signed-off-by: Oleg Nesterov