Commit Graph

15951 Commits

Author SHA1 Message Date
Mike Smith
29c7e03718 Remove unused real-mode APM init functions. 1999-07-28 20:07:12 +00:00
Mike Smith
30f41f1f8d Remove some erroneous comments about how APM is initialised. 1999-07-28 19:37:32 +00:00
Mike Smith
dce593b01e Remove some droppings left over from the removal of the APM hooks. 1999-07-28 19:34:16 +00:00
Alan Cox
3b5f11efe6 Clear error in nfsrv_create when we have a valid reply so that
that reply is actually transmitted.
Submitted by:	dillon
1999-07-28 08:20:49 +00:00
Doug Rabson
aa595accc9 Add support for SYS_RES_DENSE and SYS_RES_BWX resource types. These are
equivalent to SYS_RES_MEMORY for x86 but for alpha, the rman_get_virtual()
address of the resource is initialised to point into either dense-mapped
or bwx-mapped space respectively, allowing direct memory pointers to be
used to device memory.

Reviewed by: Andrew Gallatin <gallatin@cs.duke.edu>
1999-07-28 07:57:48 +00:00
Bill Paul
74432d0d13 Add a module Makefile for the PNIC driver. 1999-07-28 02:21:56 +00:00
Bill Paul
90f300bfb1 Convert the PNIC driver to newbus. 1999-07-28 02:19:52 +00:00
Nick Hibma
2cc20f83b3 Every reqh in an aborted pipe is given status CANCELED and the callback is
called. It might be necessary to split that routine into two parts in
which calling the callback is not done at splusb().
1999-07-27 20:22:29 +00:00
Bill Paul
070f62142c Roar! Finish what I started last night: somehow only the header file change
got committed.
1999-07-27 13:54:15 +00:00
Matthew N. Dodd
0158b2dcc3 Case matters.
DEv_METHOD to DEV_METHOD.
1999-07-27 05:08:36 +00:00
Matthew N. Dodd
5a8cee9a60 Implement the BUS_PROBE_NOMATCH method for the PCI bus.
This function is called for each device for which no driver
was found.

Output is similar to the eisa_probe_nomatch() function but with the
added benefit of displaying the assigned IRQ (since PCI gives us
this information up front.)

Output is like so:

pci0: unknown card CPQ0508 (vendor=0x0e11, dev=0x0508) at 11.0 irq 9
pci0: unknown card DFZ0508 (vendor=0x10da, dev=0x0508) at 11.0 irq 9
pci0: unknown card DBL0508 (vendor=0x104c, dev=0x0508) at 11.0 irq 9
pci0: unknown card DDM0011 (vendor=0x108d, dev=0x0011) at 11.0 irq 9

I'm not happy with the 3 lines of macro cruft that got added but
I consider it a temporary annoyance as those bits will be moved to
some place where PCI, EISA and ISAPNP code will be able to use them.

(Not surprisingly, this message is longer than the code in question.)

Reviewed by: peter, dfr
1999-07-27 04:28:14 +00:00
Bill Paul
af1c062105 On FreeBSD/i386, when you use the SYS_RES_MEMORY resource to allocate
a PCI memory mapped region, rman_get_bushandle() returns what happens
to be a kernel virtual address pointing to the base of the PCI shared
memory window. However this is not the behavior on all platforms:
the only thing you should do with the bushandle is pass it to the
bus_spare_read()/bus_space_write() routines. If you actually do want
the kernel virtual address of the base of the PCI memory window, you
need to use rman_get_virtual().

The problem is that at the moment, rman_get_virtual() returns a physical
address, which is bad. In order to get the kernel virtual address we
need, we have to play with it a little.

Presumeably this behavior will be changed, but in the meantime the
Tigon driver won't work. So for the moment, I'm adding a kludge to
make things happy on the alpha: the correct kernel virtual address
is calculated from the value returned by rman_get_virtual(). This
should be removed once rman_get_virtual() starts doing the right
thing.

This should make the Tigon actuall work on the alpha now.
1999-07-27 03:54:48 +00:00
KATO Takenori
d13d34c3c5 Sync with sys/i386/isa/npx.c revision up to 1.75. 1999-07-26 12:22:41 +00:00
KATO Takenori
3311081bea Sync with sys/i386/isa/clock.c revision up to 1.140.
This commit may break 8MHz system clock mode.
1999-07-26 12:21:09 +00:00
KATO Takenori
5add1a23f3 Sync with sys/i386/i386/userconfig.c revision up to 1.150. 1999-07-26 12:14:59 +00:00
KATO Takenori
7da0fca153 Sync with sys/i386/i386/machdep.c revision 1.356. 1999-07-26 12:14:00 +00:00
KATO Takenori
9365d83b9c Sync with sys/i386/conf/files.i386 revision 1.254. 1999-07-26 12:12:58 +00:00
Brian Somers
3145c58d33 Don't complain if 0 bytes are written to the tun device, simply
do nothing.
1999-07-26 12:11:10 +00:00
KATO Takenori
a42377eaa1 Sync with sys/i386/conf/GENERIC revision 1.178. 1999-07-26 12:10:33 +00:00
Poul-Henning Kamp
8343d904fd Pave the way for the fla driver. 1999-07-26 07:43:26 +00:00
Alan Cox
6745299365 Add sysctl and support code to allow directories to be VMIO'd. The default
setting for the sysctl is OFF, which is the historical operation.

Submitted by:	dillon
1999-07-26 06:25:53 +00:00
Martin Cracauer
784648c675 Various formatting fixes on my FPE trapcode commit.
Submitted by:	BDE
1999-07-26 05:47:31 +00:00
Nick Hibma
6d38342e16 Add comments, change variable names to make them consistent (r -> err,
timo_handle -> timeout_handle, p -> pipe, *pipe -> *rpipe, etc.)
1999-07-25 18:54:22 +00:00
Martin Cracauer
a7674320e9 On FPU exceptions, pass a useful error code (one of the FPE_...
macros) to the signal handler, for old-style BSD signal handlers as
the second (int) argument, for SA_SIGINFO signal handlers as
siginfo_t->si_code. This is source-compatible with Solaris, except
that we have no <siginfo.h> (which isn't even mentioned in POSIX
1003.1b).

An rather complete example program is at
  http://www3.cons.org/cracauer/freebsd-signal.c
This will be added to the regression tests in src/.

This commit also adds code to disable the (hardware) FPU from
userconfig, so that you can use a software FP emulator on a machine
that has hardware floating point. See LINT.
1999-07-25 13:16:09 +00:00
Peter Wemm
eda5a3370a Make this compile on the Alpha. I'm not 100% sure about this but I
think it's ok.  ti_bhandle is fetched from newbus on both the Alpha
and x86, the Alpha-only ti_vhandle is gone.
1999-07-25 06:46:19 +00:00
Bill Paul
c9ce464cb7 Remember to clear the IFF_RUNNING and IFF_OACTIVE flags in sf_stop() and
sk_stop().
1999-07-25 05:16:05 +00:00
Bill Paul
691c152864 This commit adds device driver support for Adaptec Duralink PCI fast
ethernet controllers based on the AIC-6915 "Starfire" controller chip.
There are single port, dual port and quad port cards, plus one 100baseFX
card. All are 64-bit PCI devices, except one single port model.

The Starfire would be a very nice chip were it not for the fact that
receive buffers have to be longword aligned. This requires buffer
copying in order to achieve proper payload alignment on the alpha.
Payload alignment is enforced on both the alpha and x86 platforms.
The Starfire has several different DMA descriptor formats and transfer
mechanisms. This driver uses frame descriptors for transmission which
can address up to 14 packet fragments, and a single fragment descriptor
for receive. It also uses the producer/consumer model and completion
queues for both transmit and receive. The transmit ring has 128
descriptors and the receive ring has 256.

This driver supports both FreeBSD/i386 and FreeBSD/alpha, and uses newbus
so that it can be compiled as a loadable kernel module. Support for BPF
and hardware multicast filtering is included.
1999-07-25 04:32:50 +00:00
Bruce Evans
a2a0b22c90 Don't set DE_ACCESS for unsuccessful reads.
Translated from: a similar fix in ufs_readwrite.c rev.1.61.

Don't forget to set DE_ACCESS for short reads.

Check for invalid (negative) offsets before checking for reads of
0 bytes, as in ufs, although checking for invalid offsets at all
is probably a bug.
1999-07-25 04:01:32 +00:00
Bruce Evans
2ac6e74655 Don't set IN_ACCESS for requests to read 0 bytes or for unsuccessful reads.
Translated from: similar fixes in ufs_readwrite.c rev.1.61.  Things
are simpler (but annoyingly different) here because there are no
vm optimisations.
1999-07-25 02:56:17 +00:00
Bruce Evans
3dfdfdb27f Fixed access timestamp bugs:
Set IN_ACCESS for successful reads of 0 bytes (except for requests to
read 0 bytes).  This was broken in rev.1.42.
PR:		misc/10148

Don't set IN_ACCESS for requests to read 0 bytes.

Don't set IN_ACCESS for unsuccessful reads.
1999-07-25 02:07:16 +00:00
Tatsumi Hosokawa
6afaf5d480 3C574TX 16bit FastEtherlink PC-card support.
Reviewed by:	HAMADA Naoki <nao@tom-yam.or.jp>
Submitted by:	Osamu MIHARA <mihara@prd.fc.nec.co.jp>
1999-07-25 01:20:37 +00:00
David Greenman
6704748cf6 Increased max kmem to 200MB. This should fix some out-of-kmem panics on
large systems.
1999-07-24 22:26:42 +00:00
Bill Paul
8b1b6ae5a6 Add mx and ax modules for the Macronix and ASIX drivers and update the
modules Makefile so they get built.
1999-07-24 20:55:05 +00:00
Bill Paul
d2aaa9a7a6 Convert the ASIX and Macronix drivers to newbus. 1999-07-24 20:52:57 +00:00
Bruce Evans
a1a10fdfc0 Oops, the previous commit only worked in the one case it was tested for. 1999-07-24 20:21:10 +00:00
Nicolas Souchu
e23ebb9b30 Update intpm driver.
PR:             kern/12631
Submitted by:   Takanori Watanabe <takawata@shidahara1.planet.sci.kobe-u.ac.jp>
1999-07-24 19:13:54 +00:00
Robert Nordier
fad2f0e686 Recognise NetBSD slices.
Submitted by : Lars Koeller <lkoeller@cc.fh-lippe.de>
PR           : 12772
1999-07-24 17:40:40 +00:00
Kazutaka YOKOTA
3d03248c70 - Correctly initialize cn_dev_t and cn_udev_t.
- Add D_TTY for alpha.

Reviewed by: bde, dfr
1999-07-24 09:41:06 +00:00
Kazutaka YOKOTA
828cb0403d Do not print resource values which are not set.
Reviewed by: dfr
1999-07-24 09:35:21 +00:00
Doug Rabson
f1550d9d41 This makes the in kernel printf routines conform to the documented
behavior of their userland counterparts with respect to return values.

Submitted by: Matthew N. Dodd <winter@jurai.net>
1999-07-24 09:34:12 +00:00
Alan Cox
03e3bc8e62 atomic.h:
Change "void *" to "volatile TYPE *", improving type safety
	and eliminating some warnings (e.g., mp_machdep.c rev 1.106).

cpufunc.h:
	Eliminate setbits.  As defined, it's not precisely correct;
	and it's redundant.  (Use atomic_set_int instead.)

ipl_funcs.c:
	Use atomic_set_int instead of setbits.

systm.h:
	Include atomic.h.

Reviewed by:	bde
1999-07-23 23:45:50 +00:00
John-Mark Gurney
37735ca6ea fix a problem w/ zero byte writes to the tunnel device. It would bypass
the loop and not set an error, so we would then try to access an invalid
mbuf...

PR:		12780
Submitted by:	bright@rush.net aka zb^3

a new record in length a pr was open... only about a half hour...
1999-07-23 20:08:27 +00:00
Bill Paul
571a80b261 Clean up the buffer allocation code a bit. Make sure to initialize certain
critical mbuf fields to sane values. Simplify the use of ETHER_ALIGN to
enforce payload alignment, and turn it on on the x86 as well as alpha
since it helps with NFS which wants the payload to be longword aligned
even though the hardware doesn't require it.

This fixes a problem with the ti driver causing an unaligned access trap
on the Alpha due to m_adj() sometimes not setting the alignment correctly
because of incomplete mbuf initialization.
1999-07-23 18:46:24 +00:00
Bill Paul
43a095a5fd Grrr. Return the rman_get_bustag()/rman_get_bushandle() lines to their
proper place in ti_attach(). I'm positive I typed them in there, but
they must have fallen victim to a drive-by cut & pasting.
1999-07-23 16:21:43 +00:00
Bill Paul
09590dc4c1 One last tweak before I turn in for the evening: the driver name in
the driver_t declaration should be "skc" not "sk". Technically, "skc"
is the parent PCI device (the SysKonnect GEnesis controller) and "sk0"
and "sk1" are the network interfaces that get attached to it.
1999-07-23 05:50:35 +00:00
Bill Paul
98edb3e178 Create module directories for the xl, ti, tl and sk drivers and add
them to the Makefile so that modules will be generated for /modules.
1999-07-23 05:48:01 +00:00
Bill Paul
39d837d4b5 Dangit. Somehow the pmap_kextract hack for alpha snuck back into these
files. Change them back to alpha_XXX_dmamap().

Pointed out by: Andrew Gallatin
1999-07-23 02:18:01 +00:00
Bill Paul
89ca84e6db Convert the Alteon Tigon gigabit ethernet driver to newbus. Also upgrade
to the latest firmware release from Alteon (12.3.12).
1999-07-23 02:10:11 +00:00
Bill Paul
5c9e5de3e3 Some more small newbus cleanups. Remember to free all resources in case
of failures in foo_attach(), simplify iospace/memspace things a little.
1999-07-23 02:06:57 +00:00
Julian Elischer
47d7025f9f Revert out part of the last patch that can be done better elsewhere.
The complexity added isn't worth it.
1999-07-22 21:08:02 +00:00