Re: [PATCH v8] um: Enable preemption in UML

2024-04-01 Thread Anton Ivanov
On 01/04/2024 12:04, Tiwei Bie wrote: On 3/29/24 3:50 AM, anton.iva...@cambridgegreys.com wrote: [...] + +void kernel_fpu_begin(void) +{ + preempt_disable(); + + WARN_ON(this_cpu_read(in_kernel_fpu)); + + this_cpu_write(in_kernel_fpu, true); + +#ifdef CONFIG_64BIT + if (l

Re: [PATCH v8] um: Enable preemption in UML

2024-04-01 Thread Tiwei Bie
On 3/29/24 3:50 AM, anton.iva...@cambridgegreys.com wrote: [...] > + > +void kernel_fpu_begin(void) > +{ > + preempt_disable(); > + > + WARN_ON(this_cpu_read(in_kernel_fpu)); > + > + this_cpu_write(in_kernel_fpu, true); > + > +#ifdef CONFIG_64BIT > + if (likely(cpu_has(&boot_cpu_dat