diff options
author | Karel Zak | 2012-04-03 13:20:32 +0200 |
---|---|---|
committer | Karel Zak | 2012-04-03 13:20:32 +0200 |
commit | ce4dd666f4e4cab7f0a41274c6b48da8e41860fd (patch) | |
tree | 00e2b8b3912ebf543239067ccae538d413b086fc /libmount/src/mountP.h | |
parent | libmount: clean up MNT_FMT_* usage in parser (diff) | |
download | kernel-qcow2-util-linux-ce4dd666f4e4cab7f0a41274c6b48da8e41860fd.tar.gz kernel-qcow2-util-linux-ce4dd666f4e4cab7f0a41274c6b48da8e41860fd.tar.xz kernel-qcow2-util-linux-ce4dd666f4e4cab7f0a41274c6b48da8e41860fd.zip |
libmount: add support to parse /proc/swaps
Signed-off-by: Karel Zak <kzak@redhat.com>
Diffstat (limited to 'libmount/src/mountP.h')
-rw-r--r-- | libmount/src/mountP.h | 11 |
1 files changed, 9 insertions, 2 deletions
diff --git a/libmount/src/mountP.h b/libmount/src/mountP.h index fa0edf50c..ee5e94fb2 100644 --- a/libmount/src/mountP.h +++ b/libmount/src/mountP.h @@ -194,7 +194,7 @@ struct libmnt_fs { char *bindsrc; /* utab, full path from fstab[1] for bind mounts */ - char *source; /* fstab[1], mountinfo[10]: + char *source; /* fstab[1], mountinfo[10], swaps[1]: * source dev, file, dir or TAG */ char *tagname; /* fstab[1]: tag name - "LABEL", "UUID", ..*/ char *tagval; /* tag value */ @@ -212,6 +212,12 @@ struct libmnt_fs { int freq; /* fstab[5]: dump frequency in days */ int passno; /* fstab[6]: pass number on parallel fsck */ + /* /proc/swaps */ + char *swaptype; /* swaps[2]: device type (partition, file, ...) */ + off_t size; /* swaps[3]: swaparea size */ + off_t usedsize; /* swaps[4]: used size */ + int priority; /* swaps[5]: swap priority */ + int flags; /* MNT_FS_* flags */ void *userdata; /* library independent data */ @@ -255,7 +261,8 @@ enum { MNT_FMT_FSTAB, /* /etc/{fs,m}tab */ MNT_FMT_MTAB = MNT_FMT_FSTAB, /* alias */ MNT_FMT_MOUNTINFO, /* /proc/#/mountinfo */ - MNT_FMT_UTAB /* /dev/.mount/utab */ + MNT_FMT_UTAB, /* /run/mount/utab */ + MNT_FMT_SWAPS /* /proc/swaps */ }; |