Commit Graph

20602 Commits

Author SHA1 Message Date
Bruce Evans
29893f43a9 Fixed some style bugs in the signal handling funcations. This doesn't
change the object file.
2000-06-03 14:19:01 +00:00
Bruce Evans
7f3f3253ff Fixed style bugs that I unfortunately noticed because bsd.kmod.mk was
being reconstructed.
2000-06-03 11:45:00 +00:00
Bruce Evans
61b9b2965c The change to do a longword compare in the previous commit just broke an
apparently-intended micro-optimization ("testb" is equivalent and smaller)
and added a style bug (the size suffix for "testl" was missing).
linux-2.3.35 already had the correct fix.
2000-06-03 11:09:09 +00:00
Bruce Evans
8b788cbd86 Fixed regression of the type of the `header' member of struct pkthdr from
`void *' to caddr_t in rev.1.40.  This mainly caused an annoying warning
for compiling ip_input.c.
2000-06-03 10:30:56 +00:00
Doug Rabson
e347aadd85 Record the new PALcode revision in the pcs structure after changing to
run OSF/1 PALcode.

Obtained from: NetBSD
2000-06-03 08:24:37 +00:00
Bruce Evans
27d3393199 Use the genassym script here too. The linux and svr4 modules were broken. 2000-06-03 07:40:19 +00:00
Archie Cobbs
756fff0053 Don't try to apply ipfw filtering to non-IP packets.
Reported-by:	"Lachlan O'Dea" <lodea@vet.com.au>
2000-06-02 22:47:53 +00:00
Jonathan Lemon
707d00a304 Add boundary checks against IP options.
Obtained from:	OpenBSD
2000-06-02 20:18:38 +00:00
Daniel C. Sobral
11b96475f7 Apply a number of fixes for the Alpha platform. 2000-06-02 20:07:56 +00:00
Matt Jacob
60ed92ddd3 fix KASSERT usage 2000-06-02 19:06:33 +00:00
Jonathan Lemon
59f577ad8c When attempting to transmit a packet, if the system fails to allocate
a mbuf, it may return without setting any timers.  If no more data is
scheduled to be transmitted (this was a FIN) the system will sit in
LAST_ACK state forever.

Thus, when mbuf allocation fails, set the retransmit timer if neither
the retransmit or persist timer is already pending.

Problem discovered by:  Mike Silbersack (silby@silby.com)
Pushed for a fix by:    Bosko Milekic <bmilekic@dsuper.net>
Reviewed by:            jayanth
2000-06-02 17:38:45 +00:00
Daniel C. Sobral
b8e8da45a9 Add something that was missing from the original 2.04 distribution. 2000-06-02 13:49:09 +00:00
Bruce Evans
f47f0edde4 Use "nm | awk ..." instead of genassym(1) to generate symbol value headers.
Symbol values are now represented using array sizes (4 arrays per symbol
so that 16-bit machines can represent 64-bit values) instead of being raw
binary values.

Reviewed by:	marcel
2000-06-02 09:27:48 +00:00
Chris Costello
c1e15e06bb Update the comment for fdesc_setattr to reflect that we no longer
actually setattr() on underlying vnodes.
2000-06-02 07:08:18 +00:00
Chris Costello
908a81d424 - Do not allow VOP_SETATTR to modify underlying vnodes at all. This caused
problems when fetch(1) was passed `-o -'.  The rationale of this change
  is that applications attempting to change underlying vnodes for /dev/fd
  nodes are improperly written and the use of this interface should not
  ever have been encouraged.  Proper alternatives are fchmod, fchown and
  others.

  PR:		18952

- Remove stale, unused fdescnode->fd_link structure member.
2000-06-02 07:02:45 +00:00
Greg Lehey
b441812ca5 parityrebuild: write the parity block back to the correct subdisk.
HEADS UP: This fixes a serious data corruption bug when using the
userland command 'rebuildparity'.
2000-06-02 04:05:40 +00:00
Greg Lehey
cad166c211 Remove an incorrect comment, adjust white space. 2000-06-02 04:05:05 +00:00
Greg Lehey
fbbcd2e09c Add 'dumpconfig' keyword. 2000-06-02 04:04:31 +00:00
Greg Lehey
762166daca Remove a redundant statement. 2000-06-02 04:03:57 +00:00
Greg Lehey
c9180b28e7 open_drive: Recognize "wd" device type. This is going away, but it's
not gone yet.

format_config: print correct text when a volume has a preferred plex.
This is still broken, but not quite as badly.

Reported-by: Phil Regnauld <regnauld@ftf.net>

Change a rather silly comment.
2000-06-02 04:03:13 +00:00
Greg Lehey
d8c8f72dd9 give_sd_to_plex: Initialize sd->plexno correctly. Previously this was
only being done at plex creation time, and an attach would leave the
value uninitialized.
2000-06-02 04:02:15 +00:00
Bill Paul
7bc6fe296d Darn it... left if_aue.c out of the last commit. (Fix watchdog timeout
handling, turn of interrupt pipe stuff.)
2000-06-01 23:18:01 +00:00
Bill Paul
a2693d6d71 Handle watchdog timeouts better. We can't really call the foo_init()
routines from foo_watchdog() because foo_watchdog() is called at
interrupt context, and that's a no-no due to the way the USB stack
is currently set up.

What we do now is call the TX end of frame handler manually to clear
the completed transmission, then check the send queue and send off
any frames that are pending.

Also turned off the interrupt pipe stuff in if_aue, since it appears
to tickle a bug in the USB stack that I haven't found yet.
2000-06-01 23:16:42 +00:00
Poul-Henning Kamp
6e891d64ed Don't panic if ifpromisc() returnes ENXIO, it's probably just an pccard
which have been pulled.
2000-06-01 21:57:13 +00:00
Poul-Henning Kamp
855e8bb9ad ed_ioctl() can be called from ifpromisc() after the card has been removed,
don't panic on a NULL pointer in that case.
2000-06-01 21:55:49 +00:00
Daniel C. Sobral
b270590aeb Add "int" sized manipulation words. 2000-06-01 18:10:44 +00:00
Peter Wemm
3e0f102e57 With this evil hack the DS1 driver works on our Intel desktop
motherboards that use YMF740's.  It has a strange subvendor and subdevice
ID and requires a disturbingly long delay after the ac97 codec init.
Cameron hasn't had this driver tested on another 740 yet, so we don't know
if this is a quirk of all 740's, or if its just something about the codec
that Intel used.
2000-06-01 03:58:27 +00:00
Cameron Grant
17dbf67736 if a device has no play or no record channels, set its simplex flag. 2000-06-01 01:32:30 +00:00
Archie Cobbs
b4c44c30d8 Fix bug where receive statistics for the bundle were not getting updated. 2000-06-01 01:29:49 +00:00
Cameron Grant
e05327ee1b if we get bad values for playctrlsize, the firmware may not have initialised
yet so retry.
2000-06-01 01:29:05 +00:00
Mike Smith
c3c50c4e3a Further fixes for multiple-IO-APIC systems from Tor Egge:
Further experimentation showed that some Dell 2450 machines with the
prevention kludge installed still got T_RESERVED traps.  CPU interrupt
vector 0x7A was observed to be triggered.  This might have been the
bitwise OR of two different vectors sent from each of the IOAPICs at
the same time.

	IOAPIC #0: 0x68 --> irq 8: RTC timer interrupt
	IOAPIC #1: 0x32 --> irq 18: scsi host adapter or network interface
		   ----
		   0x7a --> T_RESERVED

Both IOAPICs had ID 0.

Appendix B.3 in the MP spec indicates that the operating system is
responsible for assigning unique IDs to the IOAPICs.

The enclosed patch programs the IOAPIC IDs according to the IOAPIC
entries in the MP table.

Submitted by:	tegge
2000-05-31 21:37:28 +00:00
Cameron Grant
2176a9588a add a bit more diagnostic info for the bus_dmamap_load failure case 2000-05-31 19:04:12 +00:00
Mike Smith
11ca1e30c7 Bump the default NBUS value to 8. 2000-05-31 19:01:45 +00:00
Mike Smith
c5234c81ed Bump the default NBUS value to 8, in lieu of actually sizing it
dynamically.  Too many systems have more than 4 busses now.
2000-05-31 18:55:02 +00:00
Bruce Evans
6b4a3ce242 Pack the SWI bits to save some time and space. 2000-05-31 16:36:20 +00:00
Bruce Evans
5f582114dd Add SWI_TQ_MASK to all interrupt masks except SWI_CLOCK_MASK. Use a
new macro SWI_LOW_MASK to give the mask for low priority SWIs instead
of hard-coding this mask as SWI_CLOCK_MASK.

Reviewed by:	dfr
2000-05-31 13:32:28 +00:00
Yoshihiro Takahashi
932d2288a0 Update of isa drivers using compatability shims to use COMPAT_ISA_DRIVER().
Submitted by:	haro@tk.kubota.co.jp (Munehiro Matsuda)
2000-05-31 10:51:53 +00:00
Yoshihiro Takahashi
6042137954 Sync with sys/isa/ppc.c revision 1.27. 2000-05-31 10:49:58 +00:00
Yoshihiro Takahashi
0a67fdf343 Removed ICMP_BANDLIM option. It no longer exists. 2000-05-31 10:49:19 +00:00
Yoshihiro Takahashi
51f48c44d1 Fixed most disordering. 2000-05-31 10:48:36 +00:00
Yoshihiro Takahashi
8ced9e302a Sync with sys/i386/include/bus_at386.h revision 1.9. 2000-05-31 10:47:55 +00:00
Bill Paul
318b02fdb9 Rework the support for the internal autonegotiation on the 21143 and
workalike chips (Macronix 98713A/98715 and PNIC II). Timing is somewhat
critical: you need to bring the link as soon as possible after NWAY
is done, and the old one second polling interval was too long. Now
we poll every 10th of a second until NWAY completes (at which point
we return to the 1 second interval again to keep an eye on the link
state).

I tested all the other cards I had on hand to make sure I didn't bust
any of them and they seem to work (including the MII-based 21143 card).
This should fix some autoneg problems with DE500-BA cards and the
built-in 10/100 ethernet on some alpha systems.

(Now before anyone asks why I never noticed this before, the old code
worked just find with the Intel swich I used for testing back in NY.
Apparently not all switches are as picky about the timing.)
2000-05-31 05:40:53 +00:00
Cameron Grant
bd68ce8be9 yamaha ds1/ds1e pci sound driver - work in progress, mixer and playback only.
tested on ymf724f only.

conf/files entry is commented out, enable it manually to test this code and
let me know results.
2000-05-31 03:21:36 +00:00
Brian Feldman
c0c5a953c0 Change sl(4) configuration lines to reflect its new dynamic nature. 2000-05-30 23:01:37 +00:00
Brian Feldman
bf095ac10a Make sl(4) SLIP devices dynamically expansible. Yay! =)
PR:		kern/17758
Submitted by:	David Malone <dwmalone@maths.tcd.ie>
2000-05-30 13:47:03 +00:00
Doug Rabson
d20743db3c Style fixes.
Submitted by: bde
2000-05-30 07:27:46 +00:00
Warner Losh
c373152ae6 Add support for the modem side of the 56k combo card.
Submitted by:	Duncan Barclay <dmlb@ragnet.demon.co.uk>
2000-05-30 05:42:57 +00:00
Matthew Dillon
8b03c8ed5e This is a cleanup patch to Peter's new OBJT_PHYS VM object type
and sysv shared memory support for it.  It implements a new
    PG_UNMANAGED flag that has slightly different characteristics
    from PG_FICTICIOUS.

    A new sysctl, kern.ipc.shm_use_phys has been added to enable the
    use of physically-backed sysv shared memory rather then swap-backed.
    Physically backed shm segments are not tracked with PV entries,
    allowing programs which use a large shm segment as a rendezvous
    point to operate without eating an insane amount of KVM in the
    PV entry management.  Read: Oracle.

    Peter's OBJT_PHYS object will also allow us to eventually implement
    page-table sharing and/or 4MB physical page support for such segments.
    We're half way there.
2000-05-29 22:40:54 +00:00
Guido van Rooij
bcc031b104 Fix a panic resulting from an obvious null pointer deref.
Apparently some other panics still exist in this driver, but with
this fix, it was at least possible to run the Nokia card at SANE 2000.
2000-05-29 19:58:10 +00:00
Doug Rabson
5550bcfce2 Declare splsoftqtassert(). 2000-05-29 19:57:52 +00:00
Doug Rabson
3e8965ac09 Add SWI_TQ_MASK to imask definition. 2000-05-29 19:40:42 +00:00
Doug Rabson
1536418a84 Brucify the pmap_enter_temporary() changes. 2000-05-29 19:21:01 +00:00
Andrey A. Chernov
b2f64c0141 Fix the TAB not cause scrolling when entered at the end of the last line.
It may cause misterious chars appearse in the middle of the scrolled lines.

The bug trigger: enter
grep P_32 /usr/include/*.h
command and see misterious "db.\" filename.
2000-05-29 18:35:13 +00:00
Yoshihiro Takahashi
c787eb8a72 Sync with the following changes.
sys/boot/i386/btx/btx/Makefile          1.8
sys/boot/i386/btx/btx/btx.s             1.16 and 1.17
sys/boot/i386/btx/btxldr/btxldr.s       1.10
sys/boot/i386/loader/Makefile           1.45
2000-05-29 11:58:01 +00:00
Jun Kuriyama
81c0587fa1 Add more ESS1869 PnP Sound Card PnPid.
Submitted by:	MIHIRA Yoshiro
PR:		kern/17349
2000-05-29 07:43:51 +00:00
Warner Losh
78ff6e4c7e ICMP_RATELIM is no longer an option. 2000-05-29 03:34:04 +00:00
Warner Losh
6a2b5130e3 Add ACTIONTECH #define for plug and play. Also add PnP support to NEWCARD
for this card.

Submitted by: Kazuya Kodama <kodama@rd.nacsis.ac.jp>
2000-05-29 02:44:33 +00:00
Matthew Dillon
883f3caa13 Fix bug in vm_pageout_page_stats() that always resulted in a full
scan of the active queue.  This fix is not expected to have any
    noticeable impact on performance.

Noticed by: Rik van Riel <riel@conectiva.com.br>
2000-05-29 02:31:55 +00:00
Duncan Barclay
66d7d8c631 Remove unused ioctl locking 2000-05-28 23:23:24 +00:00
Duncan Barclay
203e551839 Made RAY_COM_DUMP a real debug called RAY_DCOM
unsed ioctl locking
2000-05-28 23:11:47 +00:00
Duncan Barclay
9385b6d6d7 A bit of a messy monster.
Simple stuff
------------

	Split _download up so that the MIB settings are in their own functions.

	Made "tx completed but status is ..." a recoverable error

	Cut down verbosity of "unloaded" messages

	Moved ccs_free and com_runq from intr_ccs to ecf_done and runq_done
	to avoid embarasing mistakes and waits.

	Merged runq_add and runq_arr into one and called it runq_add

	Made RAY_COM_DUMP a real debug called RAY_DCOM

	Consistnet debugging around tsleeps.

	Use bus_activate_resource for attr/cm mapping, and set the flags
	correctly in the allocation routines (needs more hacks to
	sys/pccard/pcic.c)

	com_malloc is now seperated from the comq initialization. This was
	done whilst trying to set automatic variables for the comqs.

Harder Stuff
------------

	As part of the IFF_RUNNING fixes, remove the panic in runq if we are
	not running.

	Change, again, runq_add. This time we don't do any cleaning up
	if there were errors. This is so that callers get the chance
	to re-try (not that I ever see it being used).

	In runq_add, only sleep when there is something to sleep on!

	ioctl locking routines, stolen from awi.c but not used


Hardest Stuff
-------------

	Dealing with serialing ioctls correctly means that we must QUEUE
	changes to IFF_RUNNING and check it in the QUEUED commands, not
	in the user commands. Whilst simple to state, it took a few
	hours of head scratching to get it right. The realisation was that
	I only have to guarantee that sub-commands from a single process
	are serialised and "atomic", and that they check the status of the
	interface flags when invoked and not when they are queued.

	Another way of looking at it, is that the driver's state is stored
	in the runq and the IFF_RUNNING flag. These must be changed together.

	What this means practically, is that IFF_RUNNING is set after
	we have started/joined/associated with a network. And it is
	cleared by ray_stop via the runq so that unfinsished commands are
	not distrupted.

	I still have to fix up promisc, upp/repparams and mcast.

	Oh yeah, stop is essentially a noop in that it only
	changes IFF_RUNNING
2000-05-28 23:10:12 +00:00
Andrew Gallatin
4e5adf5f4a Part of AS2100 support that I neglected to commit last night
pointed out by: dfr
2000-05-28 17:52:08 +00:00
Gerard Roudier
94d057fdf4 - Make the NVRAM debug code compile and work.
- Get rid of a fiew uselessly `long' variables
  and casts to `long'.
- Estimate the PCI clock for all chips, except
  C1010 for now (we should do that for each PCI BUS)
- Refine a couple of C1010 errata work-arounds.
- For now, make sure AIP generation is disabled
  for the C1010-66.
2000-05-28 17:49:18 +00:00
Peter Wemm
2ce54ad34d Oops, nearly forgot to commit this one. Use correct register names, or
this will not compile without COMPAT_OLDPCI.
2000-05-28 16:38:28 +00:00
Peter Wemm
30d1c11e3a Encapsulate the old PCI compatability support and APIs completely under
"options COMPAT_OLDPCI".  This option already existed, but now also tidies
up the declarations in #include <pci/pci*.h>.  It is amazing how much stuff
was using the old pre-FreeBSD 3.x names and going silently undetected.
2000-05-28 16:35:57 +00:00
Peter Wemm
0a8e3ce8a5 Make this compile without depending on the FreeBSD 2.2 compatability
defines.
2000-05-28 16:31:35 +00:00
Peter Wemm
55b161a4d3 Make this compile without the old 2.2 compatability defines. 2000-05-28 16:24:17 +00:00
Peter Wemm
0db05e09fc Fix a reference to an old FreeBSD 2.2 register name.
s/PCI_COMMAND_STATUS_REG/PCIR_COMMAND/
2000-05-28 16:21:45 +00:00
Peter Wemm
2a26d3479b Do not depend on FreeBSD 2.2 compatability defines.
s/PCI_MAP_REG_START/PCIR_MAPS/
2000-05-28 16:18:58 +00:00
Peter Wemm
46dff442be Fix some leakage from inside #ifdef PCI_COMPAT (the FreeBSD 2.2 compat
stuff).
2000-05-28 16:17:18 +00:00
Peter Wemm
86b0a953e2 Use the correct register name. s/PCI_COMMAND_STATUS_REG/PCIR_COMMAND/ 2000-05-28 16:13:43 +00:00
Peter Wemm
94278c74bb Use the correct name for the PCI command register (PCIR_COMMAND). Don't
use constant that used to be a variable in our (very) old pci code.
2000-05-28 16:06:56 +00:00
Peter Wemm
c48cc9ce1e Use the correct register names. s/PCI_COMMAND_STATUS_REG/PCIR_COMMAND/ 2000-05-28 16:02:05 +00:00
Peter Wemm
3796d32b9c Warn that this as an oldpci device.. 2000-05-28 15:59:52 +00:00
Peter Wemm
403b9111fb Use correct register values. This one was in aic7xxx and advansys too. 2000-05-28 15:50:40 +00:00
Doug Rabson
31891bc2bd Add a new pmap entry point, pmap_enter_temporary() to be used during
dumps to create temporary page mappings. This replaces the use of CADDR1
which is fairly x86 specific.

Reviewed by: dillon
2000-05-28 15:49:55 +00:00
Peter Wemm
717f014e45 Use the correct register names. s/PCI_MAP_REG_START/PCIR_MAPS/ 2000-05-28 15:48:48 +00:00
Peter Wemm
9e5c01ffe6 Use the correct register names, not the FreeBSD 2.2 compatability ones. 2000-05-28 15:47:00 +00:00
Doug Rabson
ca2e05343b Add taskqueue system for easy-to-use SWIs among other things.
Reviewed by: arch
2000-05-28 15:45:30 +00:00
Peter Wemm
4cbef178df Use the correct name for a mapping register, not the old FreeBSD 2.x
compatability name.
2000-05-28 15:15:14 +00:00
Peter Wemm
6a4c2576dc Mass update of isa drivers using compatability shims to use
COMPAT_ISA_DRIVER() so that we can get rid of the evil isa_compat.h table.
2000-05-28 13:40:48 +00:00
Peter Wemm
23dff9e066 The dreaded isa_compat.h tables are no longer used, so there is no need
for a seperate pc98 version of this stuff.  Applying the same changes
from the i386 version yields identical files so remove these and use the
common ones.
2000-05-28 13:32:49 +00:00
Peter Wemm
e60463deed Redo the isa compat driver shim so that each driver is self contained
and does not require that evil list of drivers in isa_compat.h.
It uses the same strategy that pci drivers use, namely a
COMPAT_ISA_DRIVER() macro that creates the glue on the fly.
Theoretically old-style isa drivers should be preloadable now.
2000-05-28 13:30:44 +00:00
Andrey A. Chernov
2073104f87 Manipulate with AltGR Led (really CapsLock Led) only in K_XLATE mode, because
all other modes not set ALKED flag and it means that CapsLock always turned
off for them.
Real bug example is X11 which never turn on CapsLock with Russian keyboard.

PR:		18651
Submitted by:	"Mike E. Matsnev" <mike@po.cs.msu.su>
2000-05-28 12:43:24 +00:00
Peter Wemm
84c27d0735 ncr.c is no longer a COMPAT_OLDPCI device - remove the warning. 2000-05-28 10:45:06 +00:00
Peter Wemm
11ffbffb13 Remove haveseen_iobase() - it is no longer called from anywhere in the
kernel.
2000-05-28 10:11:49 +00:00
Søren Schmidt
724a60faf8 Cosmetics: dont say Unknown but Generic chipset in probe.. 2000-05-28 07:51:23 +00:00
Søren Schmidt
5158543d6a Fix alignment problem on the alpha reported by several parties. 2000-05-28 07:50:19 +00:00
Andrew Gallatin
6ab09a6376 Add AlphaServer 2000 (demi-sable), 2100 (sable), and 2100A (lynx) support.
Only PCI and on-board ISA peripherials are supported at this time.

This support has been only lightly tested due to a lack of response to my
call for testers on the freebsd-alpha mailing list.  It works quite well
on the one AS2100 on which it has been tested, but it may not work on
an AS2100A and should therefore be regarded as experimental.
2000-05-28 02:52:54 +00:00
Andrew Gallatin
521ff6f1b9 Allow platform specific isa interrupt setup & teardown routines in
preparation for sable/lynx support
2000-05-28 02:40:53 +00:00
David E. O'Brien
fe449a53f3 MFA: Add {kernel,module}-{depend,clean,cleandepend,tags,install,reinstall}
targets.  The {depend,clean,cleandepend,tags,install,reinstall} targets
are composits of the {kernel,module}-* targets (based on NO_MODULES).
2000-05-27 21:50:15 +00:00
David E. O'Brien
5415a4bd71 Use /sys/sys/*.h over /usr/include/sys.
No repsonce from:	Maintainer
2000-05-27 21:35:47 +00:00
Cameron Grant
94e3845ccd fix the return value of the SOUND_PCM_WRITE_CHANNELS ioctl
re-enable old pcm ioctls
2000-05-27 14:40:17 +00:00
Doug Rabson
44eb1261b4 Use bus_space_handle_t instead of bus_space_tag_t to hold the result
from rman_get_bushandle().
2000-05-27 10:02:32 +00:00
Doug Rabson
20e1658bc2 Update to use newbus and busspace. 2000-05-27 09:27:36 +00:00
John Baldwin
f20dd05a67 - Remove unnecessary 'data32' and 'addr32' prefixes and #define's.
- Go ahead and use 'lgdt' again instead of hand-assembling the instruction.
  During testing this code worked fine.  If for some reason a 32-bit offset
  is needed, 'lgdtl' should be used instead of reverting to manual machine
  code.

Tested by:	peter
2000-05-27 06:25:35 +00:00
Peter Wemm
64db83a8ab Use .include <bsd.kmod.mk> to get to ../../*/conf/kmod.mk instead of
encoding the relative path.
2000-05-27 01:14:33 +00:00
Daniel C. Sobral
b6b204a98b Strip spaces and comments more agressively. 2000-05-26 22:58:10 +00:00
Cameron Grant
d28089a10d move various fields from pcm_channel to snd_dbuf
improve chn_read code- don't stop/restart on overrun, just dump data

more error checking on ioctls
2000-05-26 21:55:13 +00:00
Cameron Grant
04553e63a5 if we have a codec init routine, fail the attach if init fails 2000-05-26 21:42:50 +00:00