Commit Graph

106 Commits

Author SHA1 Message Date
mikel bcc644fd7e Add missing arguments to NIC_GET in debug code. Fixes kern/2875. 1996-11-17 04:11:18 +00:00
thorpej 769a499800 New bus.h implementation/interface:
- No more distinction between i/o-mapped and memory-mapped
	  devices.  It's all "bus space" now, and space tags
	  differentiate the space with finer grain than the
	  bus chipset tag.
	- Add memory barrier methods.
	- Implement space alloc/free methods.
	- Implement region read/write methods (like memcpy to/from
	  bus space).
This interface provides a better abstraction for dealing with
machine-independent chipset drivers.
1996-10-21 22:34:38 +00:00
christos 86373f8cf9 backout kprintf changes 1996-10-13 01:37:04 +00:00
christos 58953408cb printf -> kprintf, sprintf -> ksprintf 1996-10-10 22:04:48 +00:00
explorer 870052156e Better error message when the card is found but shared memory isn't enabled 1996-10-04 01:28:54 +00:00
thorpej 794614df64 In the 3c503 probe, map the correct number of ports. (Unmap already
unmapped the correct number of ports, thus causing the ISA io port
extent map to get corrupted.)
1996-06-25 20:47:02 +00:00
mycroft cec36bf8d5 Use intr.h. 1996-05-12 23:51:23 +00:00
thorpej 1040e97175 If accessing shared memory on a 16-bit card, be careful not to do any
8-bit memory access; some cards, notably some WD/SMC cards, can't handle
8-bit access if 16-bit access has been enabled.
1996-05-08 22:09:18 +00:00
thorpej 15354e899c Changed struct ifnet to have a pointer to the softc of the underlying
device and a printable "external name" (name + unit number), thus eliminating
if_name and if_unit.  Updated interface to (*if_watchdog)() and (*if_reset)()
to take a struct ifnet *, rather than a unit number.
1996-05-07 01:55:13 +00:00
thorpej 0bc154b367 Fix a bug I introduced when converting the driver to <machine/bus.h>.
Use the i/o handle for the `delay port' exported from the parent
ISA bus, rather than the totally bogus combination of [ioh, 0x84].
Also, fix a bug apparently introduced when the -Wall changes were checked
in which, under most circumstances, would cause a 16-bit WD8013EP to
be mis-identified as an 8-bit WD8003EP.
1996-05-05 01:28:52 +00:00
christos c3c1caa12a Remove unused err label; simplify the code in ed_probe_Novell 1996-05-03 19:05:30 +00:00
christos 05dbb85594 cleanup the memh mess:
- remove it from the Novell probe.
- cleanup the 3com probe.
1996-05-03 17:29:29 +00:00
christos e8a8a6298c - prototype fixes 1996-04-29 20:02:32 +00:00
cgd 51e85d07b9 update for addition of a machine-dependent cookie as the first argument
to isa_intr_{,dis}establish().
1996-04-11 22:27:59 +00:00
thorpej 43411d2e96 Convert to use <machine/bus.h>. 1996-04-09 00:46:15 +00:00
thorpej 6d9ea4cf59 New device attachment scheme:
- split softc size and match/attach out from cfdriver into
	  a new struct cfattach.

	- new "attach" directive for files.*.  May specify the name of
	  the cfattach structure, so that devices may be easily attached
	  to parents with different autoconfiguration semantics.
1996-03-17 00:43:52 +00:00
cgd 88b335392c rename asic_addr and nic_addr to asic_base and nic_base, in softc, as
they're base I/O ports, not really addresses.  rather than using those
softc fields directly, assign local variables (asicbase, nicbase) to have
their values, and use those.  (consistency, plus better optimization
potential in some cases.)
1996-03-16 07:24:15 +00:00
cgd 87abc9cdc7 Move contents of edprobe() into ed_find() -- they'll be used by edattach()
eventually.  rename the probe functions for the various boards to 'find' for
consistency/correctness (but the generic8390 check is still a 'probe').
Add protos for ed_find(), ed_probe_generic8390(), ed_find_WD80x3(),
ed_find_3Com(), and ed_find_Novell().  Fix one minor space nit.
1996-03-16 06:41:20 +00:00
cgd 4beac8eab6 convert NIC_GET and NIC_PUT to take NIC base port address, rather than softc. 1996-03-16 06:18:39 +00:00
chuck 75caa8c729 Imported from OpenBSD/FreeBSD:
Add support for the SMC8416 (EtherEZ) ISA ethernet card.
	The 8416 has an 8K shared mem (the old driver assumed 16K
	and failed at attach time).
1996-01-10 16:49:22 +00:00
mycroft 3da4b2a160 The IST_* and IPL_* constants are not bus-specific; don't treat them as such.
Change splimp -> splnet in Ethernet, ARCnet, and FDDI drivers.
1995-12-24 02:29:35 +00:00
mycroft e8c91e1129 Fix typos. 1995-07-25 05:11:11 +00:00
mycroft 2d37aba592 Add missing `break;'. 1995-07-24 02:46:47 +00:00
mycroft ff82158c19 Fix typo. 1995-07-24 02:43:11 +00:00
mycroft 4f36e42ff4 Various cleanup:
* Use standard function naming conventions.
* Only increment if_ipackets when a packet was actually received.
* Check for excessively large or small packets before trying to read them.
1995-07-24 02:40:38 +00:00
mycroft b5699db68d Rename new xmit_busy back to txb_inuse. 1995-07-23 23:42:47 +00:00
mycroft 799910cb2c Remove txb_inuse. Other stylistic changes. 1995-07-23 22:12:16 +00:00
mycroft 57528ce346 Init functions are always called at splimp(). 1995-07-23 20:36:51 +00:00
mycroft 465cfd15f0 Always use m_pkthdr.len on output. Panic if M_PKTHDR is not set. 1995-07-23 16:32:33 +00:00
cgd 2b71eae2c7 note that most of dev/ic's contents have changed names 1995-06-28 04:30:30 +00:00
mycroft d9fc8ef092 Remove check for if_addrlist == 0; if_attach() always puts one address on
the list, so this is a noop.
1995-06-12 00:09:42 +00:00
mycroft 488bc82ac3 Fix multicast filter calculation. 1995-05-28 11:29:46 +00:00
mycroft 03e77f5565 Tweak the output routine for slightly better performance. 1995-05-01 02:39:30 +00:00
cgd 8a640328ed clean up several ISA device interfaces: autoconfiguration, header
inclusion, and interrupt configuration.  more work still needs to be done,
but it's getting better...
1995-04-17 12:06:30 +00:00
mycroft 8d8af964a7 Move NIC register definitions to a global location. 1995-04-11 04:45:26 +00:00
mycroft b703c76655 Update for if.h. Define helper macros for accessing NIC registers. Optimize
edrint() a little more.
1995-04-11 04:38:42 +00:00
mycroft 70839d3b04 Change start and watchdog return values to void. 1995-04-10 18:21:42 +00:00
glass 48b5b94c4f fix some typos. from frank@fwi.uva.nl (Frank van der Linden) 1995-02-27 09:10:24 +00:00
mycroft 8b834a58ca Display more information when we get bogus data off the card. 1995-02-19 18:05:45 +00:00
cgd 3a7bbb1acd lip service to making ISA support machine-independent. This is the first
round: moving the drivers into a machine-independent directory.
Some drivers (e.g. fd.c) not moved because they use other pc features (e.g.
CMOS settings), and none of the non-driver files moved, because they're
still pretty much PC specific.  eventually (when other ports with ISA
busses really start using this code), more 'high-level' ISA support will
live here.
1995-01-29 07:36:54 +00:00
mycroft b5cf1b5ddd Add interrupt sharing types. 1995-01-03 01:30:14 +00:00
mycroft 894bb9145f Use soft configuration where possible. 1995-01-02 20:32:55 +00:00
mycroft 9a3840f2f0 Stylistic changes. 1994-11-18 22:25:12 +00:00
mycroft 35cdd801e6 Convert port, IRQ, and DRQ numbers to ints. 1994-11-18 21:57:40 +00:00
mycroft cfc4633919 Remove outdated comment. 1994-11-04 19:17:47 +00:00
mycroft b7acf321cd No longer needs icu.h. 1994-11-04 18:59:34 +00:00
mycroft 29414c5a0a Change all of the uses of IRQ{0-15} and bit masks to use plain numbers
rather than bit shifting.
1994-11-04 18:34:50 +00:00
mycroft 54cc63645d Update to match autoconfig code. 1994-11-03 23:08:27 +00:00
cgd 6ac2bbfc35 be more careful with types, also pull in headers where necessary. 1994-10-30 21:43:03 +00:00
cgd 022ee8f7fe new RCS ID format. 1994-10-27 04:14:23 +00:00