bigbiff bigbiff | e60683a | 2013-02-22 20:55:50 -0500 | [diff] [blame] | 1 | #ifndef BLKID_PARTITIONS_H |
| 2 | #define BLKID_PARTITIONS_H |
| 3 | |
| 4 | #include "blkidP.h" |
bigbiff | 7b4c7a6 | 2015-01-01 19:44:14 -0500 | [diff] [blame] | 5 | #include "pt-mbr.h" |
bigbiff bigbiff | e60683a | 2013-02-22 20:55:50 -0500 | [diff] [blame] | 6 | |
| 7 | extern int blkid_partitions_get_flags(blkid_probe pr); |
| 8 | |
| 9 | extern blkid_parttable blkid_partlist_new_parttable(blkid_partlist ls, |
| 10 | const char *type, blkid_loff_t offset); |
| 11 | |
bigbiff | 7b4c7a6 | 2015-01-01 19:44:14 -0500 | [diff] [blame] | 12 | extern int blkid_parttable_set_uuid(blkid_parttable tab, const unsigned char *id); |
bigbiff bigbiff | e60683a | 2013-02-22 20:55:50 -0500 | [diff] [blame] | 13 | extern int blkid_parttable_set_id(blkid_parttable tab, const unsigned char *id); |
| 14 | |
| 15 | extern blkid_partition blkid_partlist_add_partition(blkid_partlist ls, |
| 16 | blkid_parttable tab, |
| 17 | blkid_loff_t start, blkid_loff_t size); |
| 18 | |
| 19 | extern int blkid_partlist_set_partno(blkid_partlist ls, int partno); |
| 20 | extern int blkid_partlist_increment_partno(blkid_partlist ls); |
| 21 | |
| 22 | extern blkid_partition blkid_partlist_get_parent(blkid_partlist ls); |
| 23 | |
| 24 | extern int blkid_partitions_do_subprobe(blkid_probe pr, |
| 25 | blkid_partition parent, const struct blkid_idinfo *id); |
| 26 | |
| 27 | extern int blkid_partitions_need_typeonly(blkid_probe pr); |
bigbiff | 7b4c7a6 | 2015-01-01 19:44:14 -0500 | [diff] [blame] | 28 | extern int blkid_partitions_set_ptuuid(blkid_probe pr, unsigned char *uuid); |
| 29 | extern int blkid_partitions_strcpy_ptuuid(blkid_probe pr, char *str); |
| 30 | |
| 31 | |
bigbiff bigbiff | e60683a | 2013-02-22 20:55:50 -0500 | [diff] [blame] | 32 | extern int blkid_is_nested_dimension(blkid_partition par, |
| 33 | blkid_loff_t start, blkid_loff_t size); |
| 34 | |
| 35 | extern int blkid_partition_set_name(blkid_partition par, |
| 36 | const unsigned char *name, size_t len); |
| 37 | |
| 38 | extern int blkid_partition_set_utf8name(blkid_partition par, |
| 39 | const unsigned char *name, size_t len, int enc); |
| 40 | |
| 41 | extern int blkid_partition_set_uuid(blkid_partition par, |
| 42 | const unsigned char *uuid); |
bigbiff | 7b4c7a6 | 2015-01-01 19:44:14 -0500 | [diff] [blame] | 43 | extern int blkid_partition_gen_uuid(blkid_partition par); |
bigbiff bigbiff | e60683a | 2013-02-22 20:55:50 -0500 | [diff] [blame] | 44 | |
| 45 | extern int blkid_partition_set_type(blkid_partition par, int type); |
| 46 | |
| 47 | extern int blkid_partition_set_type_string(blkid_partition par, |
| 48 | const unsigned char *type, size_t len); |
| 49 | |
| 50 | extern int blkid_partition_set_type_uuid(blkid_partition par, |
| 51 | const unsigned char *uuid); |
| 52 | |
| 53 | extern int blkid_partition_set_flags(blkid_partition par, unsigned long long flags); |
| 54 | |
| 55 | /* |
| 56 | * partition probers |
| 57 | */ |
| 58 | extern const struct blkid_idinfo aix_pt_idinfo; |
| 59 | extern const struct blkid_idinfo bsd_pt_idinfo; |
| 60 | extern const struct blkid_idinfo unixware_pt_idinfo; |
| 61 | extern const struct blkid_idinfo solaris_x86_pt_idinfo; |
| 62 | extern const struct blkid_idinfo sun_pt_idinfo; |
| 63 | extern const struct blkid_idinfo sgi_pt_idinfo; |
| 64 | extern const struct blkid_idinfo mac_pt_idinfo; |
| 65 | extern const struct blkid_idinfo dos_pt_idinfo; |
| 66 | extern const struct blkid_idinfo minix_pt_idinfo; |
| 67 | extern const struct blkid_idinfo gpt_pt_idinfo; |
bigbiff | 7b4c7a6 | 2015-01-01 19:44:14 -0500 | [diff] [blame] | 68 | extern const struct blkid_idinfo pmbr_pt_idinfo; |
bigbiff bigbiff | e60683a | 2013-02-22 20:55:50 -0500 | [diff] [blame] | 69 | extern const struct blkid_idinfo ultrix_pt_idinfo; |
| 70 | |
| 71 | #endif /* BLKID_PARTITIONS_H */ |