Warner Losh [Fri, 24 Aug 2001 07:43:35 +0000 (07:43 +0000)]
Move code to shutdown the pcic_pci_shutdown. Call it on system
shutdown and also before we get going with the device initialization.
This may fix the hangs some people are seeing on warmboot. It appears
that some machines will reset the cardbus bridge on boot, while others
don't. So we turn off the card, and ack the interrupts (which likely
is a nop in the shutdown case since we're still fielding interrupts).
This should turn off the interrupts.
Since I don't have hardware that hangs on reboot, I'm committing this
without testing that aspect of the patch (it causes no harm on my
Dell).
Warner Losh [Fri, 24 Aug 2001 07:30:18 +0000 (07:30 +0000)]
Two fixes. First, put into place a more generic chipset specific
initialization structure. Warn the user for those chipsets that
aren't yet customized that they might not work. Second, try to power
off the slot on attach and ack the interrupts. I don't know, but this
might solve the hangs that people will see on Thinkpads if they set
hw.pcic.init_routing=1.
Nick Sayer [Fri, 24 Aug 2001 02:14:26 +0000 (02:14 +0000)]
In order for the MA301 to pass interrupts from the PCCard, you must
go into the PLX 9052's interrupt control register and turn on the magic
interrupt enable bit.
Partial thanks are due to OpenBSD for pointing out that the chip is a
PLX 9052 and pointing me to the datasheet PDF.
John Baldwin [Thu, 23 Aug 2001 22:44:47 +0000 (22:44 +0000)]
Convert some KASSERT()'s into if (foo) panic() because they are testing
how locks are managed by the rest of the kernel, not verifying the internal
integrity of witness itself.
John Baldwin [Thu, 23 Aug 2001 20:32:21 +0000 (20:32 +0000)]
Add a new kernel option RESTARTABLE_PANICS. If this option is present,
then one can restart from a panic by resetting the panicstr variable to
NULL. This commit conditionalizes the previously committed functionality
on this variable. It also removes the __dead2 attribute from the panic()
function so that when one continues from a panic() the behavior will
be predictable.
Bill Paul [Thu, 23 Aug 2001 18:22:55 +0000 (18:22 +0000)]
Fix a bug in the ste_setmulti() routine. The NIC has 4 16-bit multicast
hash registers, not 2 32-bit ones. This would prevent the multicasr filter
from being programmed correctly in some cases.
Andrew Gallatin [Thu, 23 Aug 2001 17:08:26 +0000 (17:08 +0000)]
Bail if we go beyond the directory size, not just if we hit it.
Certain ISO fs's (like the one for 4.4-RC1 disc1 on alpha)
trigger this, and we end up opening a null file name. This causes us to get
a false match for "kernel.ko" when it does not exist.
Even better move: suppose that server is able to handle SEEK_END,
so check arguments for all but not SEEK_END case, leaving SEEK_END
handling for server
Cameron Grant [Thu, 23 Aug 2001 12:27:27 +0000 (12:27 +0000)]
the feederchain builder is currently broken for recording channels. disable
it until it is fixed. this limits recording to native formats and speeds
only.
Cameron Grant [Thu, 23 Aug 2001 12:21:12 +0000 (12:21 +0000)]
handle bogus values passed to SOUND_PCM_WRITE_CHANNELS/SNDCTL_DSP_CHANNELS
ioctls better- if 0 is passed, return the current setting. if 1 or 2 are
passed, behave accordingly. treat values >2 as 2.
Cameron Grant [Thu, 23 Aug 2001 11:30:52 +0000 (11:30 +0000)]
many changes:
* add new channels to the end of the list so channels used in order of
addition
* de-globalise definition of struct snddev_info and provide accessor
functions where necessary.
* move the $FreeBSD$ tag in each .c file into a macro and allow the
/dev/sndstat handler to display these when set to maximum verbosity to aid
debugging.
* allow each device to register its own sndstat handler to reduce the amount
of groping sndstat must do in foreign structs.
Kenneth D. Merry [Thu, 23 Aug 2001 03:19:54 +0000 (03:19 +0000)]
Bring in some iostat fixes that bde reminded me about. These fixes were
originally written in January, 2000, but have been substantially updated.
- No longer use hz/stathz and the CPU times in computing the TTY stats,
but rather use etime, like the disk stats.
- Clean up malloc/realloc failure tests.
- Use a new integrated routine to fetch devstat information via sysctl or
KVM.
- Get rid of the X() macro for calculating CPU stats
- Use rint() on the CPU state display to avoid truncation errors. (this
requires libm)
- Clean up flag usage somewhat.
Nick Sayer [Thu, 23 Aug 2001 00:57:40 +0000 (00:57 +0000)]
Add support for the Netgear MA301 PCI adapter for the MA401.
It appears that a number of PrismII card vendors seem to be doing the
same thing (that is, using the same PCI bridge chip) to support PCI,
but each with their own vendor/product ID. So rather than cut-n-paste
another if statement into the probe routine, it's probably better to
provide support for a table. Adding new devices will be a lot easier
that way.
Thomas Moestl [Wed, 22 Aug 2001 23:22:47 +0000 (23:22 +0000)]
Add padding before each element of the syscall argument structures in
sysproto.h in addition to the existing padding afterwards.
This is needed to support big-endian architectures like sparc64.