Commit Graph

1377 Commits

Author SHA1 Message Date
Poul-Henning Kamp
a5b5959dc8 Account for packets we clean out when we disconnect. 2000-07-03 13:08:56 +00:00
Alfred Perlstein
ff56ceb1da use warnings
use strict
add 'usage'
2000-06-27 22:41:12 +00:00
Matt Jacob
55b59b50f2 If swdpio1 doesn't clear, we have a reversed (or disconnected) cable. Change
the message to indicate that it could also be a disconnected cable, and
return okay from wx_hw_intialize *anyway*. This allows us to contineu to
set the station address and when we do get link up, we're ready to roll.
2000-06-25 02:04:27 +00:00
Semen Ustimenko
afb279b54b Added support for SMC9432BTX cards. 2000-06-21 19:19:49 +00:00
David Greenman
aed5349598 Implemented some optimizations which result in 14 fewer instructions in the
receive path.
2000-06-19 00:58:34 +00:00
David Greenman
55ce7b5117 Added support for the i82559ER (10/100Mbps NIC for embedded applications).
Product device ID provided by:	Les Biffle <les@ns3.safety.net>
2000-06-18 10:26:09 +00:00
Matt Jacob
56aef50302 Clean up firmware load issues and remove darn near all config options.
Force alphas to prefer mem mapping as the default.

Basically, we have a pointer to a function which we can call which will
return us a pointer to firmware for the card we have. We call this function
(if it's non-NULL) with the address of our mdvec f/w pointer.

The way this works is that if ispfw (as a module or a static) is loaded,
it initializes the pointer in isp_pci, so we can call into to it to fetch
a pointer to a f/w set.

If ispfw is MOD_UNLOADed, it's retained a pointer to our mdvec f/w pointers,
which then get zeroed out so we don't have any references to data that's
now gone from kernel memory. Removing the f/w saves ~360KBytes.

Alas, there is no autounload mechanism that works for is here.
2000-06-18 05:18:55 +00:00
Matt Jacob
a46c6a5114 Fix this driver to (finally) work with switches. Some more black
magic from the linux driver.
2000-06-16 06:28:31 +00:00
Jeroen Ruigrok van der Werven
9ca710f699 Add support for the Accton EN1217.
PR:		18735
Submitted by:	Adoal Xu <adoal@iname.com>
2000-06-11 11:54:52 +00:00
Doug Rabson
068b0778a3 Release resources properly in detach. 2000-06-10 17:53:20 +00:00
Doug Rabson
111618cb42 Fix the AMD 751 AGP minidriver so that it works with my test code. 2000-06-10 17:44:53 +00:00
Doug Rabson
597472167a A driver for programming the AGP hardware. This is only very lightly
tested on Intel BX chipsets only. The other agp minidrivers are totally
untested.

The programming api is a subset of the Linux api and is only intended to
be enough for the X server to use. There is also an in-kernel api for the
use of other kernel modules such as the 3D DRI.
2000-06-09 16:04:30 +00:00
Doug Rabson
f1954f5752 Nuke the useless chip driver. It gets in the way when you want to load
a functional driver for the device.
2000-06-09 16:00:29 +00:00
Bill Paul
042c8f6ee1 When I tweaked if_dc.c to alter the polling interval for non-MII
21143 chips, I accidentally removed the DC_MII_REDUCED_POLL flag
for all 21143 cards. This caused problems with timer-instigated
TCP retransmits, which happened to occur at the same time as an
MII poll tick on MII-based cards (e.g. D-Link DFE-570TX). Fixed this,
plus made some other cleanups. The autoneg fixes for the non-MII
cards still work. Also tested the PNIC II now that I have one again.
2000-06-07 17:07:44 +00:00
Bill Paul
4d1f3470e3 - Call mii_pollstat() after we bring up the link on a 1000baseTX card
after autoneg so we make sure to set the link state and duplex mode
  correctly.
- Make sure to set the 'ignore pause frames' bit on the XMAC.
- Small linewrap fix.
2000-06-06 02:56:37 +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
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
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
84c27d0735 ncr.c is no longer a COMPAT_OLDPCI device - remove the warning. 2000-05-28 10:45:06 +00:00
Doug Rabson
20e1658bc2 Update to use newbus and busspace. 2000-05-27 09:27:36 +00:00
Jake Burkholder
e39756439c Back out the previous change to the queue(3) interface.
It was not discussed and should probably not happen.

Requested by:		msmith and others
2000-05-26 02:09:24 +00:00
Jun Kuriyama
569e965893 Add OPTi 82C700 chipset.
Submitted by:	sanpei@sanpei.org
PR:		kern/18155 (part of)
2000-05-24 09:03:30 +00:00
Jun Kuriyama
3cc13eb5b1 Add 440MX chipset.
Submitted by:	YOSHIMURA Hideaki <hideakiy@cs-tokyo01.chuosystem.co.jp>
References:	[bsd-nomads:13764]
2000-05-24 02:24:38 +00:00
Archie Cobbs
d61b89e4b3 Avoid double-call to bpf_mtap(). This is now handled in ether_input(). 2000-05-24 00:05:44 +00:00
Jake Burkholder
740a1973a6 Change the way that the queue(3) structures are declared; don't assume that
the type argument to *_HEAD and *_ENTRY is a struct.

Suggested by:	phk
Reviewed by:	phk
Approved by:	mdodd
2000-05-23 20:41:01 +00:00
Warner Losh
df28f2b764 It turns out that I was wrong. The chip in my machine is not a
CXD1847A, but a CXD1947A.  I checked by visual inspection after
prompting from onoe-san.
2000-05-22 03:43:16 +00:00
Jun Kuriyama
119c7d5d6a CXD1847A and CXD1947A have same product ID.
Approved by:	imp (original CXD1847A addition)
2000-05-22 03:20:18 +00:00
Doug Rabson
2e9a65c474 Print the correct value for the map type on a verbose boot.
PR:	kern/18662
Submitted by: tamaru@ap.t.u-tokyo.ac.jp
2000-05-18 20:28:15 +00:00
Paul Richards
b78111b137 Remove if_pci_p.c from old location. 2000-05-14 18:25:51 +00:00
Archie Cobbs
2e2de7f23f Move code to handle BPF and bridging for incoming Ethernet packets out
of the individual drivers and into the common routine ether_input().
Also, remove the (incomplete) hack for matching ethernet headers
in the ip_fw code.

The good news: net result of 1016 lines removed, and this should make
bridging now work with *all* Ethernet drivers.

The bad news: it's nearly impossible to test every driver, especially
for bridging, and I was unable to get much testing help on the mailing
lists.

Reviewed by:	freebsd-net
2000-05-14 02:18:43 +00:00
Doug Rabson
ff13eb73c1 Use bus_space for all register accesses. 2000-05-13 18:47:24 +00:00
John Baldwin
6492f6750d Only display the 'Disable PNP-OS BIOS option' message on the i386 arch.
Alpha's don't have a PNP BIOS option.

Reviewed by:	n_hibma
2000-05-11 20:17:28 +00:00
Nick Hibma
659df154a5 Do the attach (and detach) properly. Store the cookies.
This is a first step to make usb unloadable.
2000-05-07 20:16:25 +00:00
Matt Jacob
ec3da347ca Update 'hose' (actually, MCPCIA instance #) for Alpha Rawhide systems.
We have *got* to fix this bogosity of trying to steal part of the PCI
address space for this stuff.
2000-05-07 04:56:19 +00:00
Jonathan Lemon
3e48370f70 Bounce a copy of the mbuf to the bpf listener when we submit the frames
for transmit to the adapter, not when we receive a transmit interrupt
indicating that they were sent.  This fix now allows tcpdump to produce
sane results by recording the timestamp at the point where the mbuf was
actually transmitted.
2000-05-06 15:53:59 +00:00
Bill Paul
af020b6e13 Apply patch to rl_rxeof() to really enforce payload alignment in
the case where we receive a packet that wraps from the end of the
RX buffer back to the start. This fixes an unaligned access trap on
the alpha with NFS.
2000-05-05 12:47:47 +00:00
Poul-Henning Kamp
9626b608de Separate the struct bio related stuff out of <sys/buf.h> into
<sys/bio.h>.

<sys/bio.h> is now a prerequisite for <sys/buf.h> but it shall
not be made a nested include according to bdes teachings on the
subject of nested includes.

Diskdrivers and similar stuff below specfs::strategy() should no
longer need to include <sys/buf.> unless they need caching of data.

Still a few bogus uses of struct buf to track down.

Repocopy by:    peter
2000-05-05 09:59:14 +00:00
Peter Wemm
365c5db0a7 Add $FreeBSD$ 2000-05-01 20:32:07 +00:00
Bruce Evans
3aae7b16d2 Fixed the type of some ivar access functions. Ivars have type uintptr_t,
not u_long.  On i386's with 64-bit longs, returning u_longs indirectly
in (more than) the space reserved for uintptr_t's tended to corrupt the
previous frame pointer in the stack frame, so it was not easy to debug.
The type mismatches are hidden by the bogus cast in DEVMETHOD().
2000-04-30 10:01:56 +00:00
Peter Wemm
5a54cb4145 Add a missing MODULE_DEPEND() on miibus.. I was working from
KMODDEPS which this driver didn't have.
2000-04-29 15:25:56 +00:00
Peter Wemm
95a1645553 Depend on miibus.
Note that if_aue doesn't strictly depend on usb because it uses the
method interface for calls rather than using internal symbols, and
because it's a child driver of usb and therefore will not try and do
anything unless the parent usb code is loaded at some point.  if_aue does
strictly depend on miibus as it will fail to link if it is missing.
2000-04-29 13:41:57 +00:00
Julian Elischer
a4ec03cfa8 Two simple changes to the kernel internal API for netgraph modules,
to support future work in flow-control and 'packet reject/replace'
processing modes.

reviewed by: phk, archie
2000-04-28 17:09:00 +00:00
Poul-Henning Kamp
d4032b0b10 Ignore tulip chips on LanMedia WAN cards. 2000-04-25 21:45:45 +00:00
Bill Paul
27440dd237 Update the Tigon firmware to 12.3.21. This fixes a few bugs and adds support
for cards with 2MB of on-board SRAM.
2000-04-24 17:44:45 +00:00
Bill Paul
bd80fa2c7f Reoganize/update the SysKonnect driver:
- Break out the support for the XMAC II's PHY into an miibus driver.

- Reorganize the probe/attach stuff using newbus. Each XMAC is now
  attached to the parent GEnesis controller using newbus. This is
  necessary since each XMAC must also have an attached miibus, and
  the miibus read/write register routines need to be able to get
  at the softc struct for each XMAC, not the one for the parent
  controller. This allows me to get rid of the grotty code I added
  for selecting the unit numbers for the ifnet interfaces: the unit
  numbers are now derived from the newbus-assigned unit numbers,
  which should track with the ifnet interface numbers. I think.
  At the very least, there should never be any collisions.

- Add support for the SK-9821 and SK-9822 1000baseTX adapters. Special
  thanks to SysKonnect for loaning me two adapters for testing.
2000-04-22 02:16:41 +00:00