and cannot handle it going away, add an explicit reference to the kobj
class inside each linker class. Without this, a class with no modules
loaded will sit with an idle refcount of 0. Loading and unloading
a module with it causes a 0->1->0 transition which frees the ops table
and causes subsequent loads using that class to explode. Normally, the
"kernel" module will remain forever loaded and prevent this happening, but
if you have more than one linker class active, only one owns the "kernel".
This finishes making modules work for kldload(8) on amd64.
(nobits) tables to simplify some code. Try and shorten some of the very
wide lines. Somewhere along the way, I think I fixed the memory
corruption that caused panics after going multiuser.
to avoid lock order problems when manipulating the sockets associated
with the fifo.
Minor optimization of a couple of calls to fifo_cleanup() from
fifo_open().
reimplementations of enodev() (for the smbread() and smbwrite()
functions), as well as fixing various errno values to conform to
errno(3).
Bruce also points out that a number of the pointer == NULL tests
are probably nonsense because the respective checks are already
done at upper layers.
(Mostly) submitted by: bde
remove the empty line between the fdc and sio devices. The empty
line suggests that the comment applies to fdc only while it applies
to all following devices and options.
Typo spotted by: ru@
controllers and allows the controller to prefetch 1-2k on certain
PCI memory reads to the host. The spec says this should only be
used for IA32 based systems.
Informed of feature by: John Cagle <first.last@hp.com>
gets the relocation base passed in relocbase, we cannot declare a
local variable with the same name. Assume the argument holds the
same value as the local variable did...
repocopied. Soon there will be additional bus attachments and
specialization for isa, acpi and pccard (and maybe pc98's cbus).
This was approved by nate, joerg and myself. bde dissented on the new
location, but appeared to be OK after some discussion.
different context support for 32 vs 64 bit processes. This simply omits
the save/restore of the segment selector registers for non 32 bit
processes. This avoids the rdmsr/rwmsr juggling when restoring %gs
clobbers the kernel msr that holds the gsbase.
However, I suspect it might be better to conditionally do this at
user<->kernel transition where we wouldn't need to do the juggling in the
first place. Or have per-thread extended context save/restore hooks.
hal_raise_irql(void) doesn't take an argument, but it is called with one.
eg: irql = FASTCALL1(hal_raise_irql, DISPATCH_LEVEL);
This is hidden by the macros on i386, but becomes a compile error on amd64
since the arguments are actually checked.
to help the AMD cpus (which have a hardware tlb flush filter). I held
off to see what the 64 bit Intel cpus did, but it doesn't seem to help
much there either. Oh well, store it in the Attic.
properly using copyin/copyout for more than 5 years? This one did. :-)
Properly encapsulate all user<->kernel data transfers using copy{in,out}.
MFC after: 1 month
NULL name in device_add_child(), explicitly name all of our known
child drivers in order to give them a chance to attach to us.
Otherwise, only the first one present would be probed and attached.
Reviewed by: nsouch
MFC after: 1 month
yet, but building kld's is OK now and they can be loaded by kldload(2).
(but the machine will likely crash soon afterwards, a "minor" problem :-)
Brought to you by: my injured knee (from moving)
elf_reloc() backends for two reasons. First, to support the possibility
of there being two elf linkers in the kernel (eg: amd64), and second, to
pass the relocbase explicitly (for relocating .o format kld files).