summaryrefslogtreecommitdiff
path: root/src/umount.h
diff options
context:
space:
mode:
authorFabiano Fidencio <fidencio@profusion.mobi>2010-10-07 05:43:57 -0700
committerLennart Poettering <lennart@poettering.net>2010-10-07 19:23:26 +0200
commite3478379751fda30316204c68112b5a2b9ffd5a7 (patch)
treeabd2d0a3241c31a2cddb4b82d88f315673f2688b /src/umount.h
parent3846aeeba29a31628ec7a8b34884916073585e06 (diff)
umount: Adding unmount functions to be used in shutdown
This functions will: - umount all mount points that aren't API - remount read-only all mount points that can't be umounted - umount all swap devices. - detach all loopback devices TODO: - umount dms Mountpoints are being read from /proc/self/mountinfo. Swaps are being read from /proc/swaps. Loop devices from /sys/class/block/loop*.
Diffstat (limited to 'src/umount.h')
-rw-r--r--src/umount.h31
1 files changed, 31 insertions, 0 deletions
diff --git a/src/umount.h b/src/umount.h
new file mode 100644
index 000000000..aeccc00f1
--- /dev/null
+++ b/src/umount.h
@@ -0,0 +1,31 @@
+/*-*- Mode: C; c-basic-offset: 8; indent-tabs-mode: nil -*-*/
+
+#ifndef fooumounthfoo
+#define fooumounthfoo
+
+/***
+ This file is part of systemd.
+
+ Copyright 2010 ProFUSION embedded systems
+
+ systemd is free software; you can redistribute it and/or modify it
+ under the terms of the GNU General Public License as published by
+ the Free Software Foundation; either version 2 of the License, or
+ (at your option) any later version.
+
+ systemd is distributed in the hope that it will be useful, but
+ WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ General Public License for more details.
+
+ You should have received a copy of the GNU General Public License
+ along with systemd; If not, see <http://www.gnu.org/licenses/>.
+***/
+
+int umount_all(void);
+
+int swapoff_all(void);
+
+int loopback_detach_all(void);
+
+#endif