summaryrefslogtreecommitdiff
path: root/sbin/fdisk
AgeCommit message (Expand)Author
2021-11-20Gather the setup of the initial OpenBSD MBR partition into oneKenneth R Westerback
2021-11-20No need for intermediate 'adj' variable. Add 'disksz'Kenneth R Westerback
2021-11-20Sectors-per-cylinder (spc) is a constant value, so make it constKenneth R Westerback
2021-11-14Calculate initial OpenBSD partition start/size using LBA valuesKenneth R Westerback
2021-11-10Set correct prt_flag to 0.Kenneth R Westerback
2021-11-09Try this again, with (__powerpc__ || __mips__) chunk actuallyKenneth R Westerback
2021-11-09no, that breaks architecturesTheo de Raadt
2021-11-08Use a couple of local 'struct prt' variables to make MBR_init()Kenneth R Westerback
2021-11-07Nuke unused file.Kenneth R Westerback
2021-10-29Tweak code to make it clear that MBR_init() uses just the boot code andKenneth R Westerback
2021-10-25Nuke a bunch of pointless #ifndef _<.h file>/#endif guards.Kenneth R Westerback
2021-10-21Remove 'disk' editing command. Determining the disk geometry on startup (fromKenneth R Westerback
2021-10-19Move get_default_mbr() invocation before DISK_open() invocation and removeKenneth R Westerback
2021-10-18Don't bother decoding a partition's c/h/s start or end from the MBR read fromKenneth R Westerback
2021-10-18r1.66 (May 2014) introduced a two #if 0/#else/#endif chunks to avoid "overKenneth R Westerback
2021-10-13Nuke builtin_mbr.Kenneth R Westerback
2021-10-10No need to assign dl.d_nsectors to disk.dk_sectors twice.Kenneth R Westerback
2021-09-29Don't constrain -b specified block count or block size to be greater than 63.Kenneth R Westerback
2021-09-26Revert '-b' change. Forgot required bsd.rd tweak.Kenneth R Westerback
2021-09-26MBR partitions created with '-b' should be marked DOSACTIVE.Kenneth R Westerback
2021-09-13disk.dk_size can't be 0 as we errx() if that happens duringKenneth R Westerback
2021-09-13Document that the editing command 'disk' takes an optional units argument.Kenneth R Westerback
2021-09-12Stop taking detour through unit_types[SECTORS] to findKenneth R Westerback
2021-09-10Stop using NULL as a synonym for "s" (SECTORS). Just use "s".Kenneth R Westerback
2021-09-09Simplify logic in USER_edit() loop to eliminate unnecessaryKenneth R Westerback
2021-09-09Scan unit_types[] array using nitems() and eliminate the NULLKenneth R Westerback
2021-09-02Split part_type into separate types 'mbr_type' and 'gpt_type',Kenneth R Westerback
2021-09-01Improve editing GPT partition type GUID's by rejecting partitionKenneth R Westerback
2021-08-29Nuke unused variable and unnecessary initialization.Kenneth R Westerback
2021-08-28Add hex_octet() so the strtol(..,16) dance is done in just oneKenneth R Westerback
2021-08-27Replace stray hand-rolled nitems() with nitems().Kenneth R Westerback
2021-08-25Two more Capt. Obvious comments go away.Kenneth R Westerback
2021-08-25Consolidate '-e' edit command parsing into ask_cmd(), simplifyingKenneth R Westerback
2021-08-24Add an #ifdef DEBUG/#endif chunk that dumps the entire GPT header whenKenneth R Westerback
2021-08-24A couple more Capt. Obvious comments can go.Kenneth R Westerback
2021-08-24Trim leading/trailing whitespace from -e input to make commandKenneth R Westerback
2021-08-15Don't check & errx() after each and every invocation ofKenneth R Westerback
2021-08-12Oops. Lost a 'nitems()' chunk during last commit. Don'tKenneth R Westerback
2021-08-12Further reduce cross-file confusion by adding USER_help() andKenneth R Westerback
2021-08-10Go back to using Xwrite() during initialization phase to makeKenneth R Westerback
2021-08-10Eliminate single use 'error' vars by directlyKenneth R Westerback
2021-08-07style(9) says sort getopt() options and the following switch {}Kenneth R Westerback
2021-08-07Nuke a few Capt. Obvious comments.Kenneth R Westerback
2021-08-07Nuke unneeded #include's, one param.h -> types.h.Kenneth R Westerback
2021-08-07Nuke 'p' that r1.97 snuck into getopt() invocation back in 2015.Kenneth R Westerback
2021-08-07Comment typo 'mmbr' -> 'mbr'.Kenneth R Westerback
2021-08-06Cleanup, clarify and generally polish the MBR/GPT initializationKenneth R Westerback
2021-07-26Report write() and ioctl() errors encountered when writing GPT or MBR to disk.Kenneth R Westerback
2021-07-22mbrfile can be const.Kenneth R Westerback
2021-07-22Have PRT_protected_guid() return 0/-1 like everything elseKenneth R Westerback