Re: [RESEND PATCH v4 10/11] powerpc: Protect patching_mm with a lock

2021-05-07 Thread Peter Zijlstra
On Fri, May 07, 2021 at 03:03:51PM -0500, Christopher M. Riedl wrote: > On Thu May 6, 2021 at 5:51 AM CDT, Peter Zijlstra wrote: > > On Wed, May 05, 2021 at 11:34:51PM -0500, Christopher M. Riedl wrote: > > > Powerpc allows for multiple CPUs to patch concurrently. When patching > > > with

Re: [RESEND PATCH v4 10/11] powerpc: Protect patching_mm with a lock

2021-05-07 Thread Christopher M. Riedl
On Thu May 6, 2021 at 5:51 AM CDT, Peter Zijlstra wrote: > On Wed, May 05, 2021 at 11:34:51PM -0500, Christopher M. Riedl wrote: > > Powerpc allows for multiple CPUs to patch concurrently. When patching > > with STRICT_KERNEL_RWX a single patching_mm is allocated for use by all > > CPUs for the

Re: [RESEND PATCH v4 10/11] powerpc: Protect patching_mm with a lock

2021-05-06 Thread Peter Zijlstra
On Wed, May 05, 2021 at 11:34:51PM -0500, Christopher M. Riedl wrote: > Powerpc allows for multiple CPUs to patch concurrently. When patching > with STRICT_KERNEL_RWX a single patching_mm is allocated for use by all > CPUs for the few times that patching occurs. Use a spinlock to protect > the