Re: [PATCH RT 2/3] swait: Add memory barrier before checking list empty

2013-08-19 Thread Steven Rostedt
On Mon, 19 Aug 2013 11:51:55 -0400 Steven Rostedt wrote: > On Mon, 19 Aug 2013 11:35:32 -0400 > Steven Rostedt wrote: > > > From: Steven Rostedt > > > > There's a race condition with swait wakeups and adding to the list. The > > __swait_wake() does a check for swait_head_has_waiters(), and if

Re: [PATCH RT 2/3] swait: Add memory barrier before checking list empty

2013-08-19 Thread Steven Rostedt
On Mon, 19 Aug 2013 11:35:32 -0400 Steven Rostedt wrote: > From: Steven Rostedt > > There's a race condition with swait wakeups and adding to the list. The > __swait_wake() does a check for swait_head_has_waiters(), and if it is > empty it will exit without doing any wake ups. The problem is th

[PATCH RT 2/3] swait: Add memory barrier before checking list empty

2013-08-19 Thread Steven Rostedt
From: Steven Rostedt There's a race condition with swait wakeups and adding to the list. The __swait_wake() does a check for swait_head_has_waiters(), and if it is empty it will exit without doing any wake ups. The problem is that the check does not include any memory barriers before it makes a d