summaryrefslogtreecommitdiffstats
path: root/sys/geom/eli/g_eli.c
diff options
context:
space:
mode:
authorpjd <pjd@FreeBSD.org>2010-10-22 22:45:26 +0000
committerpjd <pjd@FreeBSD.org>2010-10-22 22:45:26 +0000
commitc24b1dbd261e0b6db3b3e6a580ea5866d2058fd8 (patch)
tree00d752a6b72602aee6f4516bae80b9e4b0859aff /sys/geom/eli/g_eli.c
parent8ba9fc913b2937f79c0fb33a3c4e7dc1601d7891 (diff)
downloadFreeBSD-src-c24b1dbd261e0b6db3b3e6a580ea5866d2058fd8.zip
FreeBSD-src-c24b1dbd261e0b6db3b3e6a580ea5866d2058fd8.tar.gz
Add State tag, so 'geli status' will report active/suspended status, eg:
# geli status Name Status Components da0.eli SUSPENDED da0 da1.eli ACTIVE da1
Diffstat (limited to 'sys/geom/eli/g_eli.c')
-rw-r--r--sys/geom/eli/g_eli.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/sys/geom/eli/g_eli.c b/sys/geom/eli/g_eli.c
index 08219dc..deffeb7 100644
--- a/sys/geom/eli/g_eli.c
+++ b/sys/geom/eli/g_eli.c
@@ -1247,6 +1247,8 @@ g_eli_dumpconf(struct sbuf *sb, const char *indent, struct g_geom *gp,
sc->sc_ekeylen);
sbuf_printf(sb, "%s<EncryptionAlgorithm>%s</EncryptionAlgorithm>\n", indent,
g_eli_algo2str(sc->sc_ealgo));
+ sbuf_printf(sb, "%s<State>%s</State>\n", indent,
+ (sc->sc_flags & G_ELI_FLAG_SUSPEND) ? "SUSPENDED" : "ACTIVE");
}
static void
OpenPOWER on IntegriCloud