lkml.org 
[lkml]   [2014]   [Apr]   [17]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
SubjectRe: question on read_barrier_depends
From
Date
On Wed, 2014-04-16 at 11:26 -0400, Alan Stern wrote:

> In addition, the following code in kfifo_get() does this:
>
> *(typeof(__tmp->type))__val = \
> (__is_kfifo_ptr(__tmp) ? \
> ((typeof(__tmp->type))__kfifo->data) : \
> (__tmp->buf) \
> )[__kfifo->out & __tmp->kfifo.mask]; \
> smp_wmb(); \
> __kfifo->out++; \
>
> It looks like the smp_wmb() should really be smp_mb(), because it
> separates the _read_ for val from the _write_ of kfifo->out.

But where is kfifo->out read at all?

Regards
Oliver





\
 
 \ /
  Last update: 2014-04-17 18:21    [W:0.129 / U:0.292 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site