device drivers:
- Various native device entries in cdevsw/bdevsw.
- Rework the interrupt infrastructure to provide more flexibility to
the platform-dependent back-end. Rewrite the "ofwgen" simulated
interrupt routines to reflect the changes.
- Clear out the BAT registers and set the fixed battable entries before
calling the platform init routine. The platform init routine is allowed
to set entries in the battable.
- Don't call the platform cons_init routine until after translation is
enabled -- we might need translation to work in order to access bus
space.
- calculate the offset and length of the postbl before byteswapping.
problem noted by der Mouse.
- use offsetof() to determine # of fields to calculate in initial
loop, rather than hard-coding in `52 fields'
- improve comments.
check on the correct node
- apply_specentry(): if this node is a duplicate of another, apply the
changes to the `master' entry instead of this one.
- fix inotype() to DTRT
- comment out some debugging info that is too verbose
aren't going to do anything with the information anyway and there is
error checking later anyway.
We can now succeed in creating symlinks to locations that don't exist,
just as ln -s will let us do, and we can use install instead of ln -s
in several Makefiles. The code was written with the obvious intent to
let you do this but apparently it was never tested.
THAT accurate and microtime(9) is painlessly slow on i386 currently.
This speeds up small transfers much. The gain for large transfers
is less significant, but notable too.
Bottleneck was found by Andreas Persson (Re: kern/14246).
Performance improvement with PIII on 661 Mhz according to hbench (with
PIPE_MINDIRECT=8192):
buffersize before after
512 17 49
1024 33 110
2048 52 143
4096 77 163
8192 142 190
64K 577 662
128K 372 392
on PAGE_SIZE. The overhead of setting up Page Loan is pretty much constant
irregardless of page size, so it makes more sense to use fixed constant.
According to hbench, the overhead of Page Loan setup is still significantly
bigger than the performance gain for 4096 byte buffers on i386
(PIII/600Mhz). The difference is smaller on 386DX, but Page Loan is
still not faster for this case.
Also, there is some other code out there which expects 4KB writes
to not block even for 'blocking' write, since it works this
way on some other operating systems.
Partially addresses kern/14246 by Andreas Persson.
and it introduced problems (EBUSY error when opening the driver for
writing in securelevel >= 1, plus manipulating some unitialized data at
the end of chrtoblktbl[])
Make sure the CPUCLASS_686 entry has really 17 (i.e. 16 + default)
name entries as it's supposed to, so that code won't crash when
run on Intel CPUCLASS_686 processor which doesn't have name entry
in the table.
Reported and fix provided by Naoto Morishima in kern/14380.