Re: [PATCH] x86/paravirt: merge activate_mm and dup_mmap callbacks

2023-01-17 Thread Peter Zijlstra
On Sun, Jan 15, 2023 at 08:27:50PM -0800, Srivatsa S. Bhat wrote: > I see that's not an issue right now since there is no other actual > user for these callbacks. But are we sure that merging the callbacks > just because the current user (Xen PV) has the same implementation for > both is a good

Re: [PATCH] x86/paravirt: merge activate_mm and dup_mmap callbacks

2023-01-16 Thread Srivatsa S. Bhat
On 1/15/23 10:43 PM, Juergen Gross wrote: > On 16.01.23 05:27, Srivatsa S. Bhat wrote: >> >> Hi Juergen, >> >> On 1/12/23 7:21 AM, Juergen Gross wrote: >>> The two paravirt callbacks .mmu.activate_mm and .mmu.dup_mmap are >>> sharing the same implementations in all cases: for Xen PV guests they

Re: [PATCH] x86/paravirt: merge activate_mm and dup_mmap callbacks

2023-01-15 Thread Juergen Gross
On 16.01.23 05:27, Srivatsa S. Bhat wrote: Hi Juergen, On 1/12/23 7:21 AM, Juergen Gross wrote: The two paravirt callbacks .mmu.activate_mm and .mmu.dup_mmap are sharing the same implementations in all cases: for Xen PV guests they are pinning the PGD of the new mm_struct, and for all other

Re: [PATCH] x86/paravirt: merge activate_mm and dup_mmap callbacks

2023-01-15 Thread Srivatsa S. Bhat
Hi Juergen, On 1/12/23 7:21 AM, Juergen Gross wrote: > The two paravirt callbacks .mmu.activate_mm and .mmu.dup_mmap are > sharing the same implementations in all cases: for Xen PV guests they > are pinning the PGD of the new mm_struct, and for all other cases > they are a NOP. > I was

Re: [PATCH] x86/paravirt: merge activate_mm and dup_mmap callbacks

2023-01-12 Thread Boris Ostrovsky
On 1/12/23 10:21 AM, Juergen Gross wrote: The two paravirt callbacks .mmu.activate_mm and .mmu.dup_mmap are sharing the same implementations in all cases: for Xen PV guests they are pinning the PGD of the new mm_struct, and for all other cases they are a NOP. So merge them to a common

[PATCH] x86/paravirt: merge activate_mm and dup_mmap callbacks

2023-01-12 Thread Juergen Gross
The two paravirt callbacks .mmu.activate_mm and .mmu.dup_mmap are sharing the same implementations in all cases: for Xen PV guests they are pinning the PGD of the new mm_struct, and for all other cases they are a NOP. So merge them to a common callback .mmu.enter_mmap (in contrast to the