summaryrefslogtreecommitdiffstats
path: root/fdisks/cfdisk.c
diff options
context:
space:
mode:
authorKarel Zak2012-09-24 11:30:26 +0200
committerKarel Zak2012-09-27 13:38:13 +0200
commit749af4b6095598feadc7b934afcdf2ac7450a3c9 (patch)
tree1d105e9919a681c59dd04f1c70b8f8ccc627649a /fdisks/cfdisk.c
parentblkdiscard: new command (diff)
downloadkernel-qcow2-util-linux-749af4b6095598feadc7b934afcdf2ac7450a3c9.tar.gz
kernel-qcow2-util-linux-749af4b6095598feadc7b934afcdf2ac7450a3c9.tar.xz
kernel-qcow2-util-linux-749af4b6095598feadc7b934afcdf2ac7450a3c9.zip
fdisk: move partition types to label specific part
- move MBR partition types to dos_part_types.h - make dos_part_types.h independent on datetypes to keep it useful in all fdisks - add struct fdisk_parrtype - move label specific partition types to context->label Signed-off-by: Karel Zak <kzak@redhat.com>
Diffstat (limited to 'fdisks/cfdisk.c')
-rw-r--r--fdisks/cfdisk.c9
1 files changed, 9 insertions, 0 deletions
diff --git a/fdisks/cfdisk.c b/fdisks/cfdisk.c
index 0ceed33ba..9dda1d4f4 100644
--- a/fdisks/cfdisk.c
+++ b/fdisks/cfdisk.c
@@ -107,6 +107,15 @@
#include "mbsalign.h"
#include "widechar.h"
+struct systypes {
+ unsigned char type;
+ char *name;
+};
+
+static struct systypes i386_sys_types[] = {
+ #include "dos_part_types.h"
+};
+
#ifdef __GNU__
#define DEFAULT_DEVICE "/dev/hd0"
#define ALTERNATE_DEVICE "/dev/sd0"