Re: [PATCH V11 13/17] RISC-V: paravirt: pvqspinlock: Add SBI implementation

2023-09-18 Thread Leonardo Bras
On Sun, Sep 17, 2023 at 11:06:48PM +0800, Guo Ren wrote: > On Fri, Sep 15, 2023 at 2:23 PM Leonardo Bras wrote: > > > > On Sun, Sep 10, 2023 at 04:29:07AM -0400, guo...@kernel.org wrote: > > > From: Guo Ren > > > > > > Implement pv_kick with SBI implementation, and add SBI_EXT_PVLOCK > > > extens

Re: [PATCH V11 12/17] RISC-V: paravirt: pvqspinlock: Add nopvspin kernel parameter

2023-09-18 Thread Leonardo Bras
On Sun, Sep 17, 2023 at 11:03:30PM +0800, Guo Ren wrote: > On Fri, Sep 15, 2023 at 2:05 PM Leonardo Bras wrote: > > > > On Sun, Sep 10, 2023 at 04:29:06AM -0400, guo...@kernel.org wrote: > > > From: Guo Ren > > > > > > Disables the qspinlock slow path using PV optimizations which > > > allow the

Re: [PATCH V11 11/17] RISC-V: paravirt: pvqspinlock: Add paravirt qspinlock skeleton

2023-09-18 Thread Leonardo Bras
On Sun, Sep 17, 2023 at 10:58:18PM +0800, Guo Ren wrote: > On Fri, Sep 15, 2023 at 1:42 PM Leonardo Bras wrote: > > > > On Sun, Sep 10, 2023 at 04:29:05AM -0400, guo...@kernel.org wrote: > > > From: Guo Ren > > > > > > Using static_call to switch between: > > > native_queued_spin_lock_slowpath(

Re: [PATCH V11 09/17] riscv: qspinlock: errata: Add ERRATA_THEAD_WRITE_ONCE fixup

2023-09-18 Thread Leonardo Bras
On Sun, Sep 17, 2023 at 11:15:51PM +0800, Guo Ren wrote: > On Thu, Sep 14, 2023 at 4:32 PM Leonardo Bras wrote: > > > > On Sun, Sep 10, 2023 at 04:29:03AM -0400, guo...@kernel.org wrote: > > > From: Guo Ren > > > > > > The early version of T-Head C9xx cores has a store merge buffer > > > delay pr

Re: [PATCH V11 08/17] riscv: qspinlock: Add virt_spin_lock() support for KVM guest

2023-09-18 Thread Leonardo Bras
On Sun, Sep 17, 2023 at 11:12:31PM +0800, Guo Ren wrote: > On Thu, Sep 14, 2023 at 4:02 PM Leonardo Bras wrote: > > > > On Sun, Sep 10, 2023 at 04:29:02AM -0400, guo...@kernel.org wrote: > > > From: Guo Ren > > > > > > Add a static key controlling whether virt_spin_lock() should be > > > called o

Re: [PATCH V11 05/17] riscv: qspinlock: Add basic queued_spinlock support

2023-09-18 Thread Leonardo Bras
On Sun, Sep 17, 2023 at 11:02:47PM +0800, Guo Ren wrote: > On Fri, Sep 15, 2023 at 5:08 PM Leonardo Bras wrote: > > > > On Fri, Sep 15, 2023 at 10:10:25AM +0800, Guo Ren wrote: > > > On Thu, Sep 14, 2023 at 5:43 PM Leonardo Bras wrote: > > > > > > > > On Thu, Sep 14, 2023 at 12:46:56PM +0800, Guo

Re: [PATCH V11 03/17] riscv: Use Zicbop in arch_xchg when available

2023-09-18 Thread Leonardo Bras
On Sun, Sep 17, 2023 at 10:34:36PM +0800, Guo Ren wrote: > On Sat, Sep 16, 2023 at 9:25 AM Leonardo Bras wrote: > > > > On Fri, Sep 15, 2023 at 08:36:31PM +0800, Guo Ren wrote: > > > On Wed, Sep 13, 2023 at 4:50 PM Leonardo Bras wrote: > > > > > > > > On Sun, Sep 10, 2023 at 04:28:57AM -0400, guo

Re: [RFC PATCH 00/14] Prevent cross-cache attacks in the SLUB allocator

2023-09-18 Thread Linus Torvalds
On Mon, 18 Sept 2023 at 10:39, Ingo Molnar wrote: > > What's the split of the increase in overhead due to SLAB_VIRTUAL=y, between > user-space execution and kernel-space execution? ... and equally importantly, what about DMA? Or what about the fixed-size slabs (aka kmalloc?) What's the point of

Re: [RFC PATCH 00/14] Prevent cross-cache attacks in the SLUB allocator

2023-09-18 Thread Ingo Molnar
* Matteo Rizzo wrote: > On Fri, 15 Sept 2023 at 18:30, Lameter, Christopher > wrote: > > > > On Fri, 15 Sep 2023, Dave Hansen wrote: > > > > > What's the cost? > > > > The only thing that I see is 1-2% on kernel compilations (and "more on > > machines with lots of cores")? > > I used kernel c

Re: [RFC PATCH 00/14] Prevent cross-cache attacks in the SLUB allocator

2023-09-18 Thread Matteo Rizzo
On Fri, 15 Sept 2023 at 18:30, Lameter, Christopher wrote: > > On Fri, 15 Sep 2023, Dave Hansen wrote: > > > What's the cost? > > The only thing that I see is 1-2% on kernel compilations (and "more on > machines with lots of cores")? I used kernel compilation time (wall clock time) as a benchmark

Re: [RFC PATCH 10/14] x86: Create virtual memory region for SLUB

2023-09-18 Thread Matteo Rizzo
On Fri, 15 Sept 2023 at 23:50, Dave Hansen wrote: > > I have the feeling folks just grabbed the first big-ish chunk they saw > free in the memory map and stole that one. Not a horrible approach, > mind you, but I have the feeling it didn't go through the most rigorous > sizing procedure. :) > > M