summaryrefslogtreecommitdiffstats
path: root/sbin/bsdlabel
Commit message (Collapse)AuthorAgeFilesLines
* Explain why the first partition should start at offset 16.pjd2006-03-081-0/+2
| | | | Requested by: hrs
* Fix evil examples - first partition should start at offset 16.pjd2006-03-041-5/+5
| | | | MFC after: 3 days
* -mdoc sweep.ru2005-11-181-6/+3
|
* Clarify wording for -m flag.rodrigc2005-09-171-2/+12
| | | | PR: docs/84704
* Attempt to improve the logic for automatically sizing partitionsiedowse2005-08-141-5/+62
| | | | | | | | | | | | to take into account the new default of starting the first partition after the boot blocks instead of at sector 0. If you used automatic sizing when the first partition did not start at 0, you would get an error that the automatically sized partition extended beyond the end of the disk. Note that there are probably still many more complex cases where automatic sizing and placement will not work (e.g. non-contiguous or out of order partitions).
* Scheduled mdoc(7) sweep.ru2005-01-101-2/+7
|
* Fix the derivation of the GEOM name from the specified device name byrse2005-01-071-0/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | complementing the existing special case of a not existing /dev prefix with the recognition of an already existing /dev prefix. This implicitly solves the following two issues related to working on GEOM devices /dev/foo/bar (which have the GEOM provider name "foo/bar") with the expected commands like "bsdlabel /dev/foo/bar": 1. the error "Geom not found" when trying to write or edit the BSD label (because previously the incorrect GEOM name "bar" instead of "foo/bar" was derived from "/dev/foo/bar"). 2. the multiple times reported "magically introduced" partition offset of 63 blocks and the resulting errors like "partition extends past end of unit" and "partition c doesn't start at 0!". This implicitly resulted because bsdlabel(8) determines the "MBR offset" via GEOM and (intentionally) silently falls back to an offset of 0 if it could not be queried (which is the case if the name was incorrectly derived). Usually (at least on PCs) the offset for the first slice is 63 blocks and bsdlabel(8) automatically subtracts them from the absolute offsets in the read on-disk BSD label, resulting in the display of an effective offset of 0. If the GEOM query fails, the assumed offset of 0 is subtracted and an incorrect effective offset of 63 is displayed and tried to be worked upon. Reviewed by: pjd MFC after: 1 week
* The disk labels generated by bsdlabel can no address more thanbrooks2004-09-092-7/+22
| | | | | | | | | | | 0xffffffff sectors. Document this limit and avoid installing bogus labels on disks with more sectors. Allowing the installation of labels addressing as much of the disk as possiable may be a useful addition in some situations, but this was easy to implement and should reduce confusion. PR: bin/71408
* The multiplier prefix is actually a multiplier suffix.des2004-08-091-1/+1
|
* Use fallthrough to simplify the multiplier logic; optimistically adddes2004-08-081-9/+14
| | | | | support for the T multiplier; improve the error message for unrecognized multipliers.
* Fix some whitespace issues, and move a curly brace out of an #ifdef todes2004-08-081-13/+14
| | | | avoid confusing auto-indenting editors.
* Assorted markup, grammar, and spelling fixes.ru2004-05-171-9/+7
|
* Remove advertising clause from University of California Regent's license,markm2004-04-093-12/+0
| | | | | | per letter dated July 22, 1999. Approved by: core, imp
* Implement a '-f' flag to teach bsdlabel to work on files instead ofluigi2004-03-302-13/+52
| | | | disk partitions.
* When installing boot blocks into an Alpha BSD label, setup the location,jhb2004-03-151-0/+10
| | | | | | | | length, and flags fields at the end of the SRM boot sector so that SRM can find the bootstrap code. This fixes bsdlabel -m alpha to generate bootable disklabels. Reviewed by: phk
* '-DPC98' is not needed.nyan2004-01-111-4/+0
|
* Only automatically create an 'a' partition when there is nothingphk2003-10-181-4/+22
| | | | but a 'c' partition.
* Remove the hardcoded default block/frag/cpg values from bsdlabeliedowse2003-10-051-44/+5
| | | | | | | | | and the logic for setting them according to the partition size. Instead, unspecified filesystem values are left at 0 so that newfs will use its own defaults. It just caused confusion to have the defaults duplicated in two different places. Reviewed by: phk
* mdoc(7): Properly mark C headers.ru2003-09-101-1/+1
|
* mdoc(7): Use the new feature of the .In macro.ru2003-09-081-1/+1
|
* When we initialize a disk with a virgin label, create also an 'a'phk2003-08-271-0/+4
| | | | | partition which starts after the bootstrap area and fills the entire disk.
* Augh! Fix the sparc64 build:phk2003-06-071-0/+8
| | | | | If we don't have a default label location for the compiled architecture, insist that a -m <architecture> option is specified.
* Sanitize setting of labeloffset and labelsector.phk2003-06-072-12/+5
|
* Give ia64 the exact same semantics as i386 with respect to non-512phk2003-06-041-1/+2
| | | | byte sector devices.
* Unbreak ia64. 'nuff said.marcel2003-06-041-0/+4
|
* Fix sectorsize != 512 on i386 and pc98. Add test cases for same.phk2003-06-022-21/+39
|
* Simplify the GEOM OAM api: Drop the request type, and let everythingphk2003-06-011-6/+6
| | | | | | | | hinge on the "verb" parameter which the class gets to interpret as it sees fit. Move the entire request into the kernel and move changed parameters back when done.
* Add pc98 arch to test set.phk2003-06-011-2/+2
| | | | Remove ktrace which leaked out of test-setup.
* Protext copyright[].obrien2003-05-311-3/+2
|
* mdoc(7) fixes.ru2003-05-241-19/+22
| | | | Approved by: re (blanket)
* Add amd64 to the MACHINE_ARCH list of systems that link bsdlabel topeter2003-05-231-1/+2
| | | | | | | | disklabel. I just got burnt again by having an old disklabel binary kicking around. Discussed with: phk Approved by: re (safe amd64 stuff)
* Style fixes.ru2003-05-171-13/+8
| | | | | Reviewed by: phk Approved by: re (scottl)
* Moved libgeom.so dependencies to where they belong.ru2003-05-171-2/+2
| | | | | Reviewed by: phk Approved by: re (scottl)
* Add pc98 archtecture entry.phk2003-05-131-0/+4
| | | | Approved by: re/rwatson
* Before reading an ascii label, initialize with defaults so thatphk2003-05-091-0/+1
| | | | | | getasciipartspec() has a sectorisize in case it needs one. Approved by: re/jhb
* Sigh, this shows just how much one can be conditioned my the environment:phk2003-05-091-9/+7
| | | | | | | | Just because we for the last ten years have fought for every byte in the boot code on i386, doesn't mean that other architectures could not actually have space to spare there. Remore debugging message.
* Compile bsdlabel on all platforms.phk2003-05-051-0/+10
| | | | | | | Install a link to the disklabel(8) name on i386 and alpha platforms. Leave old disklabel(8) sources intact but disconnected from the build for now.
* Add transparent handling of mbroffset for backwards compatibility.phk2003-05-041-1/+25
|
* More axe-work:phk2003-05-032-683/+192
| | | | | | | | | Hide all the historical fields of the label, unless people ask for them with -A, set them to intelligently chosen defaults otherwise. Distill the manual page to remove inaccuracies, misundertandings and obsolete information. It can probably still be done better but now at least it is not misinforming people.
* Some minor remodelling with a large axe.phk2003-05-031-279/+171
|
* Use new geom.ctl based OAM instead of ioctls.phk2003-05-032-95/+100
| | | | Various cleanup.
* bsd_disklabel_le_dec() takes an extra argument now.phk2003-05-021-1/+2
|
* Vastly simplify architecture handling: Use properties of label asphk2003-05-021-124/+19
| | | | | | | | recorded in global variables, rather than checks on the architecture. Drop horribly code to handle MBR/PC98's embedded in the BSD label area. If you need to have an MBR or PC98 on your disk, you should not overlap it with a BSDLABEL, if you don't need it, this code is nothing but trouble.
* Default the location to the compiled for architecture if no -m arg specified.phk2003-05-021-3/+9
|
* Add three global variables which contain the location, size and a flagphk2003-05-021-37/+20
| | | | | | | | | | | | for the alpha checksum, and set them depending on the specified architecture Don't look for disklabels every 16 bytes, look the only place they should be for the current architecture. Always read the label from the raw disk and decode it into struct disklabel rather than trust a cast from random addresses. When writing to the raw disk, encode the label properly.
* Pull in geom_bsd_enc.c from sys/geom to encode and decode our labels.phk2003-05-021-1/+3
|
* Remove the well-intentioned, but ill thought out check which prevents usphk2003-05-021-7/+0
| | | | | from dd(1)'ing the boot code off one drive and have bsdlabel write it on another.
* Update the test-script based on the sunlabel version, but put a for-loopphk2003-05-021-91/+151
| | | | in there to run over the various architectures.
* Add the beginning of a regression test.phk2003-04-182-0/+113
| | | | | | | So far it checks the overwrites of the BSD label inband (ie: dd if=/dev/ad0a of=/dev/ad2a). This excercises the geom::slice::hotspot code.
* First scrub of s/disklabel/bsdlabel/phk2003-04-183-28/+29
| | | | bsdlabel.5 deliberately exempted, its contents looks less than useful.
OpenPOWER on IntegriCloud