Thomas Moestl [Sun, 24 Mar 2002 02:50:53 +0000 (02:50 +0000)]
Revamp the busdma implementation a bit:
- change the IOMMU support code so that it supports overcommittting the
available DVMA memory, while still allocating as lazily as possible.
This is achieved by limiting the preallocation, and deferring the
allocation to map load time when it fails. In the latter case, the
DVMA memory reserved for unloaded maps can be stolen to free up enough
memory for loading a map.
- allow NULL settings in the method tables, and search the parent tags
until an appropriate implementation is found. This allows to remove some
kluges in the old implementation.
Thomas Moestl [Sun, 24 Mar 2002 02:11:06 +0000 (02:11 +0000)]
Make the OpenFirmware interrupt mapping code more generic, to reduce
the bus-dependent code and to be able to support more systems. The core
of the new code is mostly obtained from NetBSD.
Kluge the interrupt routing methods of the psycho and apb drivers so
that an intline of 0 can be handled for now; real routing is still not
possible (all intline registers are preinitialized instead); this will
require a sparc64-specific adaption of the driver for generic PCI-PCI
bridges with a custom routing method to work right.
Thomas Moestl [Sat, 23 Mar 2002 20:42:23 +0000 (20:42 +0000)]
Add code to print the fault virtual address for uncorrectable DMA errors
caused by IOMMU misses to aid debugging. This will only work on
UltraSPARC-IIi and IIe.
Thomas Moestl [Sat, 23 Mar 2002 19:43:15 +0000 (19:43 +0000)]
In some cases, RX descriptors that are signalled to have been completed
by the hardware are still marked as owned. Handle this by installing a
timeout handler to collect this descriptor to avoid having received
packets remain unhandled until the next one arrives.
Thomas Moestl [Sat, 23 Mar 2002 19:37:11 +0000 (19:37 +0000)]
Assorted fixes:
- remove some useless code from the status change handler that was intended
to enable the the MII drivers for external phys; this is already done
during interface initialization, and the deleted code made some
assumptions about phy addresses that do not seem to hold true on newer
cards. This should get at least one of the two hmes of newer Netra t1
machines working.
- correct the interrupt resource allocation
- bump the number of RX descriptors, lower values cause promblems on some
machines
Automatically detect devices that do not support READ(6)/WRITE(6)
and upgrade to using 10 byte cdbs.
As far as I tested, this works efficiently for most of the
SBP-II/Firewire devices but most of the umass devices still need
ad-hoc work around because umass-sim doesn't return any SCSI errors.
A sysctl nob is also added for the last resort.
I hope we don't need DA_Q_NO_6_BYTE quirks anymore.
Install headers with -C. Ideally, these Makefiles should not need to
override the beforeinstall target at all, but this has proven difficult
to achieve.
Warner Losh [Sat, 23 Mar 2002 17:24:55 +0000 (17:24 +0000)]
Breath deep and take __P out of the system include files.
# This appears to not break X11, but I'm having problems compiling the
# glide part of the server with or without this patch, so I can't tell
# for sure.
Jake Burkholder [Sat, 23 Mar 2002 17:04:41 +0000 (17:04 +0000)]
Cleanup the trace back routine slightly. Print the leaf return value so
that traps inside of leaf functions are less confusing. Add a function
to print a non-symbolic trace of the user stack.
Bruce Evans [Sat, 23 Mar 2002 16:01:49 +0000 (16:01 +0000)]
Fixed some style bugs in the removal of __P(()). The main ones were
not removing tabs before "__P((", and not outdenting continuation lines
to preserve non-KNF lining up of code with parentheses. Switch to KNF
formatting and/or rewrap the whole prototype in some cases.
Bruce Evans [Sat, 23 Mar 2002 15:09:35 +0000 (15:09 +0000)]
Fixed some style bugs in the removal of __P(()). The main ones were
not removing tabs before "__P((", and not outdenting continuation lines
to preserve non-KNF lining up of code with parentheses. Switch to KNF
formatting and/or rewrap the whole prototype in some cases.
Bruce Evans [Sat, 23 Mar 2002 14:27:06 +0000 (14:27 +0000)]
Fixed some style bugs in the removal of __P(()). The main ones were
not removing tabs before "__P((", and not outdenting continuation lines
to preserve non-KNF lining up of code with parentheses. Switch to KNF
formatting and/or rewrap the whole prototype in some cases.
Bruce Evans [Sat, 23 Mar 2002 13:10:13 +0000 (13:10 +0000)]
Fixed some style bugs in the removal of __P(()). Continuation lines
were not outdented to preserve non-KNF lining up of code with parentheses.
Switch to KNF formatting.
Bruce Evans [Sat, 23 Mar 2002 12:38:05 +0000 (12:38 +0000)]
Fixed some style bugs in the removal of __P(()). Continuation lines
were not outdented to preserve non-KNF lining up of code with parentheses.
Switch to KNF formatting.
Bruce Evans [Sat, 23 Mar 2002 12:13:34 +0000 (12:13 +0000)]
Fixed some style bugs in the removal of __P(()). The main ones were
not removing tabs before "__P((", and not outdenting continuation lines
to preserve non-KNF lining up of code with parentheses. Switch to KNF
formatting and/or rewrap the whole prototype in some cases.
Bruce Evans [Sat, 23 Mar 2002 11:53:03 +0000 (11:53 +0000)]
Fixed some style bugs in the removal of __P(()). Continuation lines
were not outdented to preserve non-KNF lining up of code with parentheses.
Switch to KNF formatting.
Bruce Evans [Sat, 23 Mar 2002 08:46:52 +0000 (08:46 +0000)]
Fixed some style bugs in the removal of __P(()). The main ones were
not removing tabs before "__P((", and not outdenting continuation lines
to preserve non-KNF lining up of code with parentheses. Switch to KNF
formatting and/or rewrap the whole prototype in some cases.
Jake Burkholder [Sat, 23 Mar 2002 04:20:00 +0000 (04:20 +0000)]
Fix a deadlock condition with tlb shootdown ipi delivery. Since ipis are
not blocked by raising the pil, a reciever may be interrupted while holding
a spinlock. If the sender does not defer interrupts throughout the entire
operation it may be interrupted and try to acquire a spinlock held by a
reciever, leading to a deadlock due to the synchronization used by the
ipi handlers themselves.
Bruce A. Mah [Sat, 23 Mar 2002 00:23:53 +0000 (00:23 +0000)]
Don't use graphics in callouts for the release documentation. The
little graphics images are a pain to deal with, and they don't work in
the *.TXT files anyways.
Warner Losh [Fri, 22 Mar 2002 22:36:23 +0000 (22:36 +0000)]
Use int (ioctl)(...) rather than int ioctl(...) so that ioctl can be defined
as a macro w/o messing things up. This is really an abuse and we will back
this out as soon as the abusers have been fixed. Add a comment to this
effect.
John Baldwin [Fri, 22 Mar 2002 21:02:02 +0000 (21:02 +0000)]
Use explicit Giant locks and unlocks for rather than instrumented ones for
code that is still not safe. suser() reads p_ucred so it still needs
Giant for the time being. This should allow kern.giant.proc to be set
to 0 for the time being.
Alfred Perlstein [Fri, 22 Mar 2002 20:02:54 +0000 (20:02 +0000)]
Use char foo[] = "BAR" to avoid direct assignment of const char * into char *.
rpcgen can't really make those fields const because the remote side might
want to munge them, so we need to pass non-const in. Hackish, but should
work.
Robert Watson [Fri, 22 Mar 2002 19:57:41 +0000 (19:57 +0000)]
Merge from TrustedBSD MAC branch:
Move the network code from using cr_cansee() to check whether a
socket is visible to a requesting credential to using a new
function, cr_canseesocket(), which accepts a subject credential
and object socket. Implement cr_canseesocket() so that it does a
prison check, a uid check, and add a comment where shortly a MAC
hook will go. This will allow MAC policies to seperately
instrument the visibility of sockets from the visibility of
processes.
Obtained from: TrustedBSD Project
Sponsored by: DARPA, NAI Labs