Re: [RFC PATCH v2 1/2] printk-rb: add a new printk ringbuffer implementation

From: Peter Zijlstra
Date: Wed Jun 26 2019 - 17:16:54 EST


On Mon, Jun 24, 2019 at 10:33:15AM +0200, John Ogness wrote:
> Here are the writer-relevant memory barriers and their associated
> variables:
>
> MB1: data_list.oldest
> MB2: data_list.newest
> MB3: data_block.id
> MB4: descr.data_next
> MB5: descr_list.newest
> MB6: descr.next

I think this is the fundamental divergence in parlance.

You seem to associate a barrier with a (single) variable, where normally
a barrier is between two (or more) variables.

As you wrote in that other email (I'm stlil going through all that);
your MB5 isn't desc_list.newest, but rather between desc_list.newest and
descr.next.

Remember, the topic is called 'memory ordering', and you cannot order
singles.