Age | Commit message (Collapse) | Author |
|
on the disk lock we can find that code rather than wondering where "sd0"
gets passed to tsleep.
ok deraadt@
|
|
on; prompted by Thorsten Glaser; ok miod@ krw@
|
|
three-byte jmp will be acceptable as the preamble to a FAT boot
sector for the purposes of spoofing an 'i' partition. Problem noted
most recently by mbalmer@.
Fixes mbalmer@, fkr@ and jmc@'s Nokia E71 phones.
"seems silly" tedu@ "disgusting" deraadt@ "makes sense" fkr@
ok jmc@ "looks ok" weingart@
|
|
correct address to write the passed label. Don't spoof partitions
while looking for the address, as this could result in an invalid
label being written out.
"That looks right" deraadt@ "Looks good to me" miod@
|
|
|
|
512) bytes; ffs is inextricably tied to using b_blkno and disklabel
always uses sectorsize units.
Thus use DEV_BSIZE units for all fields describing ffs filesystems
and convert to/from sectors where required. This enables the creation
and use of ffs filesystems on non-512 byte sectorsize devices.
This diff allows i386 and sgi (the two test platforms) to find
disklabels that are not on a sectorsize boundary. Same change to
further archs coming.
This is a no-op on 512-byte sectorsize devices.
This work triggered by jsing@'s need to create ffs filesystems on
sgi cdroms so we can create cdrom install media for sgi.
sgi testing by jsing@
ok jsing@ pedro@ "looks sane" beck@ weingart@
|
|
extended DOS partition. the concept of extended partitions is very
simple, it is just another mbr at the partition offset (well, the
standard "EBR" is a linked list with a few limitations, but this diff
works with both variants).
this diff has been in the snapshots for a while.
with input from weingart@ and krw@
ok deraadt@
|
|
ok thib beck art
|
|
file copies to nfsv2 causes the system to eventually peg the console.
On the console ^T indicates that the load is increasing rapidly, ddb
indicates many calls to getbuf, there is some very slow nfs traffic
making none (or extremely slow) progress. Eventually some machines
seize up entirely.
|
|
biowait() reads that do *not* come from the buffer cache - we use the
B_RAW flag to identify these at art's suggestion - since it makes sense
and the flag was not being used. this just flags all these buffers with
B_RAW - biodone already ignores returned buffers marked B_RAW.
ok art@
|
|
1) remove multiple size queues, introduced as a stopgap.
2) decouple pages containing data from their mappings
3) only keep buffers mapped when they actually have to be mapped
(right now, this is when buffers are B_BUSY)
4) New functions to make a buffer busy, and release the busy flag
(buf_acquire and buf_release)
5) Move high/low water marks and statistics counters into a structure
6) Add a sysctl to retrieve buffer cache statistics
Tested in several variants and beat upon by bob and art for a year. run
accidentally on henning's nfs server for a few months...
ok deraadt@, krw@, art@ - who promises to be around to deal with any fallout
|
|
'fakerootdev' hackery. This allows us to bring back miod@'s r1.70 subr_disk.c
change to avoid the GENERIC dance when rootdev has been initialized. This
in turn re-enables raidframe root devices.
Add a nice panic if rootdev can't be initialized, displaying the name of the
device that didn't work rather than just blowing up by de-referencing NULL.
ok deraadt@
|
|
ok deraadt@
|
|
the basic idea is that ramdisks boot the same way as swap generic -- this
commit also improves the comment in that area. in this case the one
outlier is raidframe, and those who use it will no longer be able to
put off repairing it -- raidframe must follow the same setroot() / bootdv
API that everything else in the system uses.
debugged with krw
|
|
booted from to the most precision; preferring the boot device, or if that
is not known, the root device
discussed with miod and reyk
tested by beck
|
|
setroot(), as this neuters RAIDframe autoconfiguration; found the hard way
by naddy@
|
|
for RB_DFLTROOT; ok miod
|
|
ok tedu@ kettenis@
|
|
|
|
ok miod@ krw@
|
|
eyeballed and ok dlg@
|
|
under #ifdef DEBUG. Adjust the verbiage. Some minor tweaks while in
the area.
ok deraadt@
|
|
DISKPART(dev). Thus making the idiom the same everywhere.
pointed out by deraadt@
|
|
ok deraadt@
|
|
cpu_disklabel can go away, since nothing anymore needs to use it; ok miod
|
|
to support hotplug media on most architectures. disklabel setup and
verification done using new helper functions. Disklabels must *always*
have a correct checksum now. Same code paths are used to learn on-disk
location disklabels, to avoid new errors sneaking in. Tested on almost all
cases, testing help from todd, kettenis, krw, otto, dlg, robert, gwk, drahn
|
|
if it was ok beforehands)
|
|
bounds_check_with_label(). Tweak error path to eliminate duplicate
code.
|
|
routines (alpha, vax) prove to be not worth keeping. Move
bounds_check_with_label() into the MI world. Eliminate unreliable and
almost certainly useless checks for overwriting a disklabel.
After discussion with deraadt@
|
|
|
|
|
|
implimentations were simply either missing code, or spacing and such.
setdisklabel() can become MI now.
|
|
temporary, place
|
|
|
|
also spotted one more)
|
|
type of all variables to daddr64_t. this includes the APIs for XXsize()
and XXdump(), all range checks inside bio drivers, internal variables
for disklabel handling, and even uvm's swap offsets. re-read numerous
times by otto, miod, krw, thib to look for errors
|
|
|
|
|
|
to size. tested on almost all machines, double checked by miod and krw
next comes the type handling surrounding these values
|
|
have contradictory information in their cyl-based labels
|
|
convert version 0 to version 1 disklabels.
Suggested by deraadt@.
ok deraadt@ otto@
|
|
1) All partitions must start before the end of the disk. 2) All
partitions must end at or before the end of the disk.
Partitions not satisfying these constraints will be truncated and
marked FS_UNUSED.
ok otto@ deraadt@
|
|
free room in struct partition by packing fragment size and
fragments/block more tighlty and use the resulting space to make
offset and size 48 bits. For the disk part we use spare fields in
struct disklabel. Kernel converts in-mem copy of the on-disk
label if needed, disklabel(8) writes new version.
We are careful to only change fields not used by bootloaders.
Conception of basic scheme by deraadt.
ok deraadt@ krw@
|
|
|
|
|
|
root on sd0a swap on sd0b dump on sd0b
we can skip printing:
rootdev=0x400 rrootdev=0xd00 rawdev=0xd02
ok miod, no objections from other lazy slackers
|
|
|
|
them, they are still in cvs.
|
|
setting that pre-setroot() code did (for instance a network boot)
found by phessler, tested by reyk
|
|
|