summaryrefslogtreecommitdiff
AgeCommit message (Collapse)AuthorFilesLines
2013-09-16libfdisk: make default geom usage more robustKarel Zak1-10/+8
.. to avoid SIGFPE References: https://bugzilla.redhat.com/show_bug.cgi?id=1005566 Signed-off-by: Karel Zak <kzak@redhat.com>
2013-09-16fdisk: rewrite dump first sector add dump disklabel commandKarel Zak3-22/+80
Expert command (m for help): D PMBR: offset = 0, size = 512 bytes. 00000000 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 * 000001c0 01 00 ee fe ff ff 01 00 00 00 ff 9f 0f 00 00 00 000001d0 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 * 000001f0 00 00 00 00 00 00 00 00 00 00 00 00 00 00 55 aa GPT Header: offset = 512, size = 512 bytes. 00000200 45 46 49 20 50 41 52 54 00 00 01 00 00 02 00 00 00000210 ae 36 81 28 00 00 00 00 01 00 00 00 00 00 00 00 00000220 ff 9f 0f 00 00 00 00 00 00 08 00 00 00 00 00 00 00000230 de 9f 0f 00 00 00 00 00 e0 9d d8 d5 d6 da 1a 44 00000240 98 57 e4 11 64 88 ce 3b 02 00 00 00 00 00 00 00 00000250 80 00 00 00 80 00 00 00 4b c7 c9 54 00 00 00 00 00000260 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 * GPT Entries: offset = 1024, size = 16384 bytes. 00000400 af 3d c6 0f 83 84 72 47 8e 79 3d 69 d8 47 7d e4 00000410 bc ae 48 5e 22 e5 ca 4c aa 98 14 6d c9 1d 72 f4 00000420 00 08 00 00 00 00 00 00 de 9f 0f 00 00 00 00 00 00000430 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 * Signed-off-by: Karel Zak <kzak@redhat.com>
2013-09-16libfdisk: (gpt) support for disklabel dumpKarel Zak1-0/+40
Signed-off-by: Karel Zak <kzak@redhat.com>
2013-09-16libfdisk: add fdisk_locate_disklabel()Karel Zak3-0/+18
The function returns offset and size of disklabel elements. Signed-off-by: Karel Zak <kzak@redhat.com>
2013-09-16libfdisk: (gpt) use generic 'created partition' messageKarel Zak3-3/+6
Signed-off-by: Karel Zak <kzak@redhat.com>
2013-09-16libfdisk: use fdisk_colon() and fdisk_sinfo()Karel Zak6-105/+120
Signed-off-by: Karel Zak <kzak@redhat.com>
2013-09-16libfdisk: extend fdisk_info() functionalityKarel Zak4-24/+95
- add per message flags - add fdisk_colon() for "foo bar: bla bla..." messages - add fdisk_sinfo() as smart version of fdisk_info() Signed-off-by: Karel Zak <kzak@redhat.com>
2013-09-16fdisk: use fdisk_{info,warn} on more placesKarel Zak2-16/+15
Signed-off-by: Karel Zak <kzak@redhat.com>
2013-09-16libfdisk: (gpt) more robust PMBR partition size checkKarel Zak1-2/+3
According UEFI specification at least one (does not mean that the first) partition is 0xFF, it makes sense to check the size of the partition rather than check the first partition. Signed-off-by: Karel Zak <kzak@redhat.com>
2013-09-16fdisk: add -L to colorize outputKarel Zak7-15/+77
Signed-off-by: Karel Zak <kzak@redhat.com>
2013-09-16fdisk: improve info outputKarel Zak2-4/+18
Signed-off-by: Karel Zak <kzak@redhat.com>
2013-09-16fdisk: use fdisk_info() to print geometryKarel Zak1-21/+16
Signed-off-by: Karel Zak <kzak@redhat.com>
2013-09-16fdisk: -l refactoringKarel Zak1-25/+17
Signed-off-by: Karel Zak <kzak@redhat.com>
2013-09-16fdisk: mark -s option as deprecatedKarel Zak3-2/+10
Signed-off-by: Karel Zak <kzak@redhat.com>
2013-09-16fdisk: main() refactoringKarel Zak1-32/+35
Signed-off-by: Karel Zak <kzak@redhat.com>
2013-09-16libfdisk: add fdisk_has_user_device_properties()Karel Zak3-12/+21
Signed-off-by: Karel Zak <kzak@redhat.com>
2013-09-16fdisk: cleanup header fileKarel Zak2-0/+8
Signed-off-by: Karel Zak <kzak@redhat.com>
2013-09-16libfdisk: provide more details about GPTKarel Zak1-3/+10
Signed-off-by: Karel Zak <kzak@redhat.com>
2013-09-16libfdisk: move sync() and reread PT code from fdisk to libfdiskKarel Zak5-40/+57
Signed-off-by: Karel Zak <kzak@redhat.com>
2013-09-16fdisk: cleanup write table codeKarel Zak2-18/+9
Signed-off-by: Karel Zak <kzak@redhat.com>
2013-09-16fdisk: move remaining actions to menu callbacksKarel Zak2-98/+78
Signed-off-by: Karel Zak <kzak@redhat.com>
2013-09-16fdisk: move expect actions to menu callbackKarel Zak2-49/+45
Signed-off-by: Karel Zak <kzak@redhat.com>
2013-09-16fdisk: consolidate code in fdisk.cKarel Zak1-78/+36
Signed-off-by: Karel Zak <kzak@redhat.com>
2013-09-16libfdisk: cleanup SGI functions namesKarel Zak3-18/+17
Signed-off-by: Karel Zak <kzak@redhat.com>
2013-09-16fdisk: cleanup sgi menu callbackswqKarel Zak2-32/+53
Signed-off-by: Karel Zak <kzak@redhat.com>
2013-09-16fdisk: move "create label" actions to menu callbackKarel Zak2-13/+31
Signed-off-by: Karel Zak <kzak@redhat.com>
2013-09-16fdisk: remove common.hKarel Zak6-9/+5
Signed-off-by: Karel Zak <kzak@redhat.com>
2013-09-16libfdisk: explicitly add COPYING fileKarel Zak2-15/+8
Signed-off-by: Karel Zak <kzak@redhat.com>
2013-09-16libfdisk: add bsd driverKarel Zak7-112/+23
Signed-off-by: Karel Zak <kzak@redhat.com>
2013-09-16fdisk: (bsd) final code clean upKarel Zak1-6/+5
Signed-off-by: Karel Zak <kzak@redhat.com>
2013-09-16fdisk: (bsd) remove xbsd_ prefixKarel Zak1-37/+37
Signed-off-by: Karel Zak <kzak@redhat.com>
2013-09-16fdisk: (bsd) minor code clean upKarel Zak2-38/+14
Signed-off-by: Karel Zak <kzak@redhat.com>
2013-09-16fdisk: (bsd) rewrite list disklabel functionKarel Zak4-105/+147
Signed-off-by: Karel Zak <kzak@redhat.com>
2013-09-16fdisk: (bsd) coding style, remove unnecessary #ifdefKarel Zak1-18/+14
Signed-off-by: Karel Zak <kzak@redhat.com>
2013-09-16fdisk: (bsd) fix add/link partitionKarel Zak1-64/+22
Signed-off-by: Karel Zak <kzak@redhat.com>
2013-09-16fdisk: (bsd) remove dead codeKarel Zak1-19/+0
Signed-off-by: Karel Zak <kzak@redhat.com>
2013-09-16fdisk: (bsd) *OSF --> *BSDKarel Zak4-15/+15
Signed-off-by: Karel Zak <kzak@redhat.com>
2013-09-16fdisk: (bsd) implement regular bsd menu callbackKarel Zak4-71/+60
Signed-off-by: Karel Zak <kzak@redhat.com>
2013-09-16fdisk: (bsd) remove generic actions from bsd_command_prompt()Karel Zak2-31/+3
Signed-off-by: Karel Zak <kzak@redhat.com>
2013-09-16fdisk: allow to exchange context pointer in menu callbacksKarel Zak3-20/+47
... to make it possible to switch to nested contexts (nested partition tables). Signed-off-by: Karel Zak <kzak@redhat.com>
2013-09-16fdisk: (bsd) remove printf() from the driver codeKarel Zak1-14/+15
Signed-off-by: Karel Zak <kzak@redhat.com>
2013-09-16fdisk: (bsd) move bsdbuffer to fdisk_bsd_label structKarel Zak1-19/+16
Signed-off-by: Karel Zak <kzak@redhat.com>
2013-09-16fdisk: (bsd) move global label variables to fdisk_bsd_label structKarel Zak1-173/+143
Signed-off-by: Karel Zak <kzak@redhat.com>
2013-09-16fdisk: (bsd) write/read PT code cleanupKarel Zak2-82/+72
Signed-off-by: Karel Zak <kzak@redhat.com>
2013-09-16libblkid: fix kboff usage in BSD proberKarel Zak1-2/+2
Signed-off-by: Karel Zak <kzak@redhat.com>
2013-09-16fdisk: (bsd) add bsd_get_partition_status()Karel Zak1-16/+40
Signed-off-by: Karel Zak <kzak@redhat.com>
2013-09-16fdisk: ask for partition in charsKarel Zak1-13/+38
Signed-off-by: Karel Zak <kzak@redhat.com>
2013-09-16libfdisk: allow to address partition by charsKarel Zak3-14/+37
For example BSD uses letters rather tahn numbers to address partition, the fist partition is 'a', last partition is 'p'. Signed-off-by: Karel Zak <kzak@redhat.com>
2013-09-16fdisk: improve menus to make it more usable for BSD labelKarel Zak2-21/+26
Signed-off-by: Karel Zak <kzak@redhat.com>
2013-09-16fdisk: (bsd) cleanup driver initializationKarel Zak2-87/+93
- assume DOS partition only for nested BSD (cxt->parent is set) - don't create BSD label in label probe function, require fdisk_create_disklabel() call Signed-off-by: Karel Zak <kzak@redhat.com>