summaryrefslogtreecommitdiff
path: root/sbin/fdisk/mbr.c
AgeCommit message (Expand)Author
2016-09-01Nuke now unused 'sz' variable.Kenneth R Westerback
2016-09-01EFI firmware has been encountered that is (from our point of view) confusedKenneth R Westerback
2015-12-30Revert r1.59's over-enthusiatic MBR zero'ing in MBR_init(). It wasKenneth R Westerback
2015-12-27Use 'standard' gpt_chk_mbr() to check for protective MBR.Kenneth R Westerback
2015-11-19Reduce overburden of unnecessary #include's. Note that param.h isKenneth R Westerback
2015-11-18Change #include <memory.h> to #include <string.h>Kenneth R Westerback
2015-11-18Parse the original on-disk MBR into a local variable. Use theKenneth R Westerback
2015-11-13Move from opening/closing disk for every i/o to opening the disk onceKenneth R Westerback
2015-11-12'reinit mbr' must zero existing MBR and GPT partition informationKenneth R Westerback
2015-11-12Refresh the in-kernel copy of the disklabel from the disk *after* writingKenneth R Westerback
2015-11-10Use UINT32_MAX for the size of the EFI System partition on disks larger thanKenneth R Westerback
2015-10-26Add GPT editing. Based on GSOC 2014 work by Markus Muller.Kenneth R Westerback
2015-10-05Enhance '-g' to create a default GPT label in addition to the protectiveKenneth R Westerback
2015-09-04Add a -b option, to be used together with -i, that tells fdisk to add aMark Kettenis
2015-08-27Nuke some trailing whitespace that keeps coming back.Kenneth R Westerback
2015-04-02Don't printf("offset: ...) before every call to MBR_print(). Do itKenneth R Westerback
2015-03-30Even better -- readsector() and writesector() become DISK_readsector() andKenneth R Westerback
2015-03-29Rename MBR_readsector() and MBR_writesector() to just readsector()Kenneth R Westerback
2015-03-29A couple of letoh64() to make GPTSIGNATURE test work better onKenneth R Westerback
2015-03-18Stop passing around little used 'struct mbr tt' parameter. JustKenneth R Westerback
2015-03-16Stop passing around a pointer to the stack variable 'disk' in main().Kenneth R Westerback
2015-03-14Whitespace & KNF tweaks. Change functions whose return values areKenneth R Westerback
2015-03-14Zap unused variable.Kenneth R Westerback
2015-03-14Switch all the license blocks to the standard OpenBSD/ISC license.Kenneth R Westerback
2015-02-10If 'write' is issued after a 'reinit' command, and the MBR to beKenneth R Westerback
2015-01-16Replace <sys/param.h> with <limits.h> and other less dirty headers whereTheo de Raadt
2015-01-03Add support for creating a protective MBR for GPT.Joel Sing
2014-05-21Fix 'fdisk -u', a.k.a. MBR_pcopy(), on sparc64 and possibly others.Kenneth R Westerback
2014-03-31Nuke [get|put][short|long] and just use letoh[16|32] andKenneth R Westerback
2014-03-17Nuke pointless blank lines, defines, comments and casts. EliminateKenneth R Westerback
2014-03-17Un-revert, being careful to not break snap building. Add paranoia checkKenneth R Westerback
2014-03-14Revert last -- broke building snaps.Kenneth R Westerback
2014-03-13Merge 'struct DISK_metrics' and 'struct disk' into one, since we don'tKenneth R Westerback
2014-03-09Instead of passing around 'char buf[DEV_BSIZE]' buffers, pass aroundKenneth R Westerback
2014-03-07Relieve the code of an overburden of unnecessary typedefKenneth R Westerback
2014-02-05Always set the signature to DOSMBR_SIGNATURE when writing a MBR toKenneth R Westerback
2013-10-08Keep disk sector calcuations in u_int64_t as long as possible, andKenneth R Westerback
2013-06-11final removal of daddr64_t. daddr_t has been 64 bit for a long enoughTheo de Raadt
2013-03-21more substantial include cleanupTheo de Raadt
2012-04-04Don't 'reserve' a head/track if there is only only 1 head and 1Kenneth R Westerback
2011-06-20MBR_read() can be reading from a file as well as a raw partition.Kenneth R Westerback
2011-02-21Honour MBR_read() results and don't pretend we can parse blocks weKenneth R Westerback
2010-06-30Make 'fdisk -i' start the OpenBSD partition on a power of 2 512-byteKenneth R Westerback
2009-02-08Eliminate excessive verbiage for 'fdisk -i' and 'fdisk -u'. EspeciallyKenneth R Westerback
2006-12-10Read/write device sectors rather than assuming sector size ==Kenneth R Westerback
2006-05-29Change MBR_read() and MBR_write() to return -1 on error and setRay Lai
2004-09-18some delinting; ok ottoTheo de Raadt
2004-07-13Remove unused argument 'int pn' to PRT_fix_CHS(). The 'int pn'Tom Cosgrove
2003-07-29spacesTheo de Raadt
2003-06-11ansificationTheo de Raadt