lkml.org 
[lkml]   [2009]   [Jan]   [15]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
Patch in this message
/
Date
From
Subject[patch 1/3] sgi-xpc: ensure flags are updated before bte_copy
From: Robin Holt <holt@sgi.com>

The clearing of the msg->flags needs a barrier between it and the notify
of the channel threads that the messages are cleaned and ready for use.

Signed-off-by: Robin Holt <holt@sgi.com>
Signed-off-by: Dean Nelson <dcn@sgi.com>
Cc: <stable@kernel.org>

---
drivers/misc/sgi-xp/xpc_sn2.c | 1 +
1 file changed, 1 insertion(+)
Index: xpc-fixes-20090115/drivers/misc/sgi-xp/xpc_sn2.c
===================================================================
--- xpc-fixes-20090115.orig/drivers/misc/sgi-xp/xpc_sn2.c 2009-01-15 10:21:53.700266968 -0600
+++ xpc-fixes-20090115/drivers/misc/sgi-xp/xpc_sn2.c 2009-01-15 10:51:10.165613058 -0600
@@ -1836,6 +1836,7 @@ xpc_process_msg_chctl_flags_sn2(struct x
*/
xpc_clear_remote_msgqueue_flags_sn2(ch);

+ wmb(); /* ensure flags have been cleared before bte_copy */
ch_sn2->w_remote_GP.put = ch_sn2->remote_GP.put;

dev_dbg(xpc_chan, "w_remote_GP.put changed to %ld, partid=%d, "


\
 
 \ /
  Last update: 2009-01-15 18:53    [from the cache]
©2003-2011 Jasper Spaans