aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/md/dm-ioctl.c
diff options
context:
space:
mode:
authorKiyoshi Ueda <k-ueda@ct.jp.nec.com>2006-12-08 05:41:07 -0500
committerLinus Torvalds <torvalds@woody.osdl.org>2006-12-08 11:29:09 -0500
commit81fdb096dbcedcc3b94c7e47b59362b5214891e2 (patch)
treece40376d3c16e3105e73d84b0129ab4bfb06dedf /drivers/md/dm-ioctl.c
parentd2a7ad29a810441e9dacbaddcc2f0c6045390008 (diff)
[PATCH] dm: ioctl: add noflush suspend
Provide a dm ioctl option to request noflush suspending. (See next patch for what this is for.) As the interface is extended, the version number is incremented. Other than accepting the new option through the interface, There is no change to existing behaviour. Test results: Confirmed the option is given from user-space correctly. Signed-off-by: Kiyoshi Ueda <k-ueda@ct.jp.nec.com> Signed-off-by: Jun'ichi Nomura <j-nomura@ce.jp.nec.com> Signed-off-by: Alasdair G Kergon <agk@redhat.com> Cc: dm-devel@redhat.com Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
Diffstat (limited to 'drivers/md/dm-ioctl.c')
-rw-r--r--drivers/md/dm-ioctl.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/drivers/md/dm-ioctl.c b/drivers/md/dm-ioctl.c
index 6d7a3d0c8f88..cd6a184536a1 100644
--- a/drivers/md/dm-ioctl.c
+++ b/drivers/md/dm-ioctl.c
@@ -774,6 +774,8 @@ static int do_suspend(struct dm_ioctl *param)
774 774
775 if (param->flags & DM_SKIP_LOCKFS_FLAG) 775 if (param->flags & DM_SKIP_LOCKFS_FLAG)
776 suspend_flags &= ~DM_SUSPEND_LOCKFS_FLAG; 776 suspend_flags &= ~DM_SUSPEND_LOCKFS_FLAG;
777 if (param->flags & DM_NOFLUSH_FLAG)
778 suspend_flags |= DM_SUSPEND_NOFLUSH_FLAG;
777 779
778 if (!dm_suspended(md)) 780 if (!dm_suspended(md))
779 r = dm_suspend(md, suspend_flags); 781 r = dm_suspend(md, suspend_flags);
@@ -815,6 +817,8 @@ static int do_resume(struct dm_ioctl *param)
815 /* Suspend if it isn't already suspended */ 817 /* Suspend if it isn't already suspended */
816 if (param->flags & DM_SKIP_LOCKFS_FLAG) 818 if (param->flags & DM_SKIP_LOCKFS_FLAG)
817 suspend_flags &= ~DM_SUSPEND_LOCKFS_FLAG; 819 suspend_flags &= ~DM_SUSPEND_LOCKFS_FLAG;
820 if (param->flags & DM_NOFLUSH_FLAG)
821 suspend_flags |= DM_SUSPEND_NOFLUSH_FLAG;
818 if (!dm_suspended(md)) 822 if (!dm_suspended(md))
819 dm_suspend(md, suspend_flags); 823 dm_suspend(md, suspend_flags);
820 824