lkml.org 
[lkml]   [2008]   [May]   [23]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
Subjectbad example in Documentation/atomic_ops.txt ?
Hi,

I it looks like the example in the Documentation/atomic_ops.txt
file at line 232 is not quite right. The obj->active = 0 will
be delayed, but not further than spin_unlock() in obj_timeout().
Becaus spin_unlock() has a memory barrier.

I guess you would need to move spin_lock(&global_list_lock) to
obj_list_del() to make the example valid.

This confused me when I read the file.

--
Best Regards,
Artem Bityutskiy (Артём Битюцкий)
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/

\
 
 \ /
  Last update: 2008-05-23 17:05    [W:0.109 / U:0.016 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site