summaryrefslogtreecommitdiffstats
path: root/sys/geom
diff options
context:
space:
mode:
authormarcel <marcel@FreeBSD.org>2008-06-12 05:28:47 +0000
committermarcel <marcel@FreeBSD.org>2008-06-12 05:28:47 +0000
commitd210ed3b77ff848367902abc59341746d906fb31 (patch)
tree8513736b5327d450ad1e169e91712f32fb1b3c14 /sys/geom
parent169adaca5e7035f357df3db94920b11459a21554 (diff)
downloadFreeBSD-src-d210ed3b77ff848367902abc59341746d906fb31.zip
FreeBSD-src-d210ed3b77ff848367902abc59341746d906fb31.tar.gz
Add the raw partiton type to the XML.
Diffstat (limited to 'sys/geom')
-rw-r--r--sys/geom/part/g_part_gpt.c20
1 files changed, 14 insertions, 6 deletions
diff --git a/sys/geom/part/g_part_gpt.c b/sys/geom/part/g_part_gpt.c
index d2df420..1df9242 100644
--- a/sys/geom/part/g_part_gpt.c
+++ b/sys/geom/part/g_part_gpt.c
@@ -437,13 +437,21 @@ g_part_gpt_dumpconf(struct g_part_table *table, struct g_part_entry *baseentry,
struct sbuf *sb, const char *indent)
{
struct g_part_gpt_entry *entry;
-
- if (indent != NULL)
- return (0);
-
+
entry = (struct g_part_gpt_entry *)baseentry;
- sbuf_printf(sb, " xs GPT xt ");
- sbuf_printf_uuid(sb, &entry->ent.ent_type);
+ if (indent == NULL) {
+ /* conftxt: libdisk compatibility */
+ sbuf_printf(sb, " xs GPT xt ");
+ sbuf_printf_uuid(sb, &entry->ent.ent_type);
+ } else if (entry != NULL) {
+ /* confxml: partition entry information */
+ // sbuf_printf(sb, "%s<label>%s</label>\n", indent, NULL);
+ sbuf_printf(sb, "%s<rawtype>", indent);
+ sbuf_printf_uuid(sb, &entry->ent.ent_type);
+ sbuf_printf(sb, "</rawtype>\n");
+ } else {
+ /* confxml: scheme information */
+ }
return (0);
}
OpenPOWER on IntegriCloud