All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH 1/4] dm: move DMF_SUSPENDED flag set before postsuspend
@ 2009-11-20  7:08 Kiyoshi Ueda
  2009-11-20  7:12 ` [PATCH 2/4] dm: rename dm_suspended() to dm_suspended_md() Kiyoshi Ueda
                   ` (2 more replies)
  0 siblings, 3 replies; 4+ messages in thread
From: Kiyoshi Ueda @ 2009-11-20  7:08 UTC (permalink / raw)
  To: Alasdair Kergon, Mike Anderson; +Cc: device-mapper development

This patch moves DMF_SUSPENDED flag set before postsuspend.
No one should care about the ordering, because the flag set and
the postsuspend are protected by a single lock, md->suspend_lock,
and all strict flag-checkers take the lock.

Signed-off-by: Kiyoshi Ueda <k-ueda@ct.jp.nec.com>
Signed-off-by: Jun'ichi Nomura <j-nomura@ce.jp.nec.com>
Cc: Mike Anderson <andmike@linux.vnet.ibm.com>
Cc: Alasdair G Kergon <agk@redhat.com>
---
 drivers/md/dm.c |    4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

Index: 2.6.32-rc7/drivers/md/dm.c
===================================================================
--- 2.6.32-rc7.orig/drivers/md/dm.c
+++ 2.6.32-rc7/drivers/md/dm.c
@@ -2542,10 +2542,10 @@ int dm_suspend(struct mapped_device *md,
 	 * requests are being added to md->deferred list.
 	 */
 
-	dm_table_postsuspend_targets(map);
-
 	set_bit(DMF_SUSPENDED, &md->flags);
 
+	dm_table_postsuspend_targets(map);
+
 out:
 	dm_table_put(map);
 

^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2009-11-20  7:15 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2009-11-20  7:08 [PATCH 1/4] dm: move DMF_SUSPENDED flag set before postsuspend Kiyoshi Ueda
2009-11-20  7:12 ` [PATCH 2/4] dm: rename dm_suspended() to dm_suspended_md() Kiyoshi Ueda
2009-11-20  7:14 ` [PATCH 3/4] dm: export suspended state Kiyoshi Ueda
2009-11-20  7:15 ` [PATCH 4/4] dm-mpath: reject message when the device is suspended Kiyoshi Ueda

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.