summaryrefslogtreecommitdiff
path: root/sbin/disklabel
AgeCommit message (Collapse)Author
2014-04-13At some point, we are going to switch the mandoc(1) defaultIngo Schwarze
from -Tascii to -Tlocale, even though not quite yet because there are more important things to do first. But let's already make -Tascii explicit in the build system right now, it is safer anyway.
2014-04-03Proper validation and computation of bsize in expert mode; ok krw@ millert@Otto Moerbeek
2014-03-18Retire hp300, mvme68k and mvme88k ports. These ports have no users, keepingMiod Vallat
this hardware alive is becoming increasingly difficult, and I should heed the message sent by the three disks which have died on me over the last few days. Noone sane will mourn these ports anyway. So long, and thanks for the fish.
2014-02-22Revert mountpoints tweaking. Needs much more serious surgery than timeKenneth R Westerback
permits before release, and is pointless without other following diffs to justify it that will not make release. Should fix segfault's during install reported by Rod Whitworth on tech@
2014-02-16Further tweak to mpfree(). Don't bother setting about-to-be-freedKenneth R Westerback
memory to NULL.
2014-02-15Don't risk dereferencing NULL pointer to mountpoints arrayKenneth R Westerback
when calling mpfree() with the array.
2014-02-15Stop leaking mount point strings in temporary copies of theKenneth R Westerback
mountpoints array.
2014-02-14Ooops. r1.169 was supposed to add 'total sectors' to the list ofKenneth R Westerback
fields that are ignored when reading an ascii disklabel. Actually remove the parsing of 'total sectors', which was just above the line trying to skip said parsing. Spotted when halex@ forced me to read this code again.
2013-11-22Whole bunch of (unsigned char) casts carefully added for ctype calls.Theo de Raadt
Careful second audit by millert
2013-11-12add a variety of missing prototypesTheo de Raadt
2013-10-31List all generated files in CLEANFILES.Ingo Schwarze
Issue mentioned by fgs@ on ICB. ok fgs@ bluhm@ krw@
2013-10-21improve on last commit: take 10% for swap, with a max of physmem plus a bitOtto Moerbeek
2013-10-18allow more space for swap with big disks, useful for hibernation;Otto Moerbeek
requested by deraadt@
2013-10-15The disklabel variables aflag and dflag are boolean, use logicalAlexander Bluhm
instead of binary operators for comparison. OK krw@
2013-10-03Print u_int64_t variables with %llu.Kenneth R Westerback
2013-09-10The rule is: daddr_t variables hold counts of 512-byte blocks, a.k.a.Kenneth R Westerback
DEV_BSIZE blocks. Counts of possibly other-sized blocks (e.g. disk sector addresses) are u_int64_t. The values stored in disklabels are counts of possibly other-sized blocks and hence should be handled with u_int64_t variables. Start enforcing this rule. No intended functional change. Rule strongly suggested by deraadt@
2013-08-14some Bx/Ox conversion;Jason McIntyre
From: Jan Stary
2013-06-18Initialize duid memory before shifting stuff into elements of it.Kenneth R Westerback
No doubt quiets one or more of the fringe compilers out there. Use variable 'part' rather than recalculating same value in the subsequent printf(). From dhill. ok otto@
2013-06-11final removal of daddr64_t. daddr_t has been 64 bit for a long enoughTheo de Raadt
test period; i think 3 years ago the last bugs fell out. ok otto beck others
2013-04-19make sure the fs blocksize doesn't get too big; ok krw@Otto Moerbeek
2012-07-13Replace a '512' with DEV_BSIZE. Calculate physmem size in blocks andKenneth R Westerback
not sectors, since the values being tested/manipulated in the auto_alloc tables are blocks at that point. Use MEG(256) instead of hand expanding it when testing physmem.
2012-04-06there is no need to cast an unsigned type with (unsigned).Theo de Raadt
ok jsing
2012-03-18getuint() -> getuint64() to make it crystal clear. No functionalKenneth R Westerback
change.
2012-03-18Wrap some long lines I keep fixing, shrinking various diffs. NoKenneth R Westerback
change to executable.
2012-01-30fix format stringCharles Longeau
ok krw@ otto@
2012-01-19Even 'X'perts should not be able to use the built in editor toKenneth R Westerback
create ffs partitions with invalid fsize and bsize values newfs will croak on. However, they should be able to set them to whatever consistent values they want, not just make them smaller. Also tweak some verbiage.
2012-01-17No need for saying out loud what we're thinking during auto-allocation.Kenneth R Westerback
i.e. when rounding off various values. ok deraadt@ sthen@
2012-01-17Avoid ffs fragsize < sector-size when 'a'dding a partition via theKenneth R Westerback
editor. Use logic from calculating fragsize for an auto-allocated partition. Noted when trying to add a small ffs partition to a 4K sector device.
2012-01-16Nuke unused parameter (f) to makebootarea(). Unused since r1.123Kenneth R Westerback
(2008), when '-r' support was removed. Spotted by jsg@ with the assistance of clang.
2012-01-02Remove more mentions of two stage boot loaders from man page.Kenneth R Westerback
2012-01-02Change last "#if (NUMBOOT == 1)" to "#if NUMBOOT > 0".Kenneth R Westerback
2012-01-02Tweak usage and man page into agreement.Kenneth R Westerback
There's nothing special about -c and -d requiring them to be separated from other flags or specified as mutually exclusive. So just show a single block of flags. Some flag combos are silly but harmless. Move all -B options inside NUMBOOT #if, eliminating confusing duplication of -w and -R usage lines. And some string declaration dancing. Since we only have NUMBOOT = 1, no need to try and finesse output for different values of NUMBOOT. Line shit up.
2012-01-02'-s' hasn't done anything for a couple of years. Garbage collectKenneth R Westerback
it and the associated 'bootxx' variable. Update man page accordingly.
2011-12-25miod@ reported problems reproducing a 'pre-4K fix' disklabel. So in theKenneth R Westerback
interest of rope sales allow the 'X'pert to suppress the rounding of partition locations to bsize boundaries. Also mention that such rounding is being done, so as to not surprise the user. ok otto@ a while ago
2011-12-01Fix negating of unsigned d_secsize. FIRST, cast to signed type,Kenneth R Westerback
THEN negate. Fixes issues with 'b' and 'k' size suffixes. Make error message more clear while here. Found, and fix provided, by David Imhoff via bugs@. Thanks!
2011-10-06mark ccd(4) deprecated in a few more placesTheo de Raadt
2011-09-04grammar fix; from Martin PelikanJason McIntyre
2011-07-05Add DIOCGPDINFO to rxioctl(), as a synonym for DIOCGDINFO, the lastKenneth R Westerback
place it was missing. Delete now redundant calls to DIOCGDINFO when getting physical disk info in disklabel(8) and fdisk(8). Reminded by a fdisk discussion with Andres Perera on tech@. ok deraadt@
2011-07-05More non-512-byte sector groundwork. Don't let disklabel hint thatKenneth R Westerback
a ffs frag size can be less than the d_secsize of the disk. Make sure amd64 writedisklabel() puts the disklabel where readdoslabel() will read it. Tweak i386/amd64 installboot/biosboot so sectors are indeed used where sectors are claimed. Lets me fdisk, newfs, mount and installboot onto 2048 and 4096 byte sector devices. Other filesystem utilites will still hold surprises. Note that actually booting from such devices will await BIOSen that acknowledge such devices as bootable. ok guenther@
2011-06-23switch to installing source manuals (base part)Ingo Schwarze
discussed with lots of people, tested by naddy@, "move fast" deraadt@
2011-06-05Nuke uses of and references to DIOCWLABEL, and the related 'W' andKenneth R Westerback
'N' command line options. ok matthew@
2011-06-02Hack to ensure that the in-core labels contain the current boundsKenneth R Westerback
info from the physical disk after 'disklabel -e' writes the label to disk. Saves having to reboot or do other contortions to initialize these fields. Toss in same treatment for total sectors so all fields forcibly set by kernel have current values. 0'ing of the bounds noted by matthew@. 'lovely' deraadt@
2011-05-24Allow for more room for /usr/obj on static linking only archs; ok krw@ deraadt@Otto Moerbeek
2011-05-23sync auto-allocation tableOtto Moerbeek
2011-05-23Make /usr/obj a bit bigger, on small disks it ends up just a littleOtto Moerbeek
bit too small. ok krw@
2011-05-22Apply proper rounding for the R command (changing of auto-allocatedOtto Moerbeek
partitions); ok krw@
2011-05-22sync auto-allocation table with codeOtto Moerbeek
2011-05-22zap unused varOtto Moerbeek
2011-05-22In addition to relative resizing, allow absolute resizing of partitionsOtto Moerbeek
in auto-allocated labels. ok krw@ sthen@
2011-04-30change one of our current examples to use duids; ken suggested we useJason McIntyre
-E rather than -e as it's more likely; ok krw