Commit Graph

135 Commits

Author SHA1 Message Date
Gleb Smirnoff
aecb98c94d Check IFF_DRV_RUNNING and presense of packets in queue before calling
em_start_locked(). This fixes panic on shutdown with active traffic
passing through router.

Sponsored by:	Rambler
2005-09-20 13:37:17 +00:00
Warner Losh
ad4f426ef6 Make sure that we call if_free(ifp) after bus_teardown_intr. Since we
could get an interrupt after we free the ifp, and the interrupt
handler depended on the ifp being still alive, this could, in theory,
cause a crash.  Eliminate this possibility by moving the if_free to
after the bus_teardown_intr() call.
2005-09-19 03:10:21 +00:00
Ruslan Ermilov
5e6e79f718 Fix "Memory modified after free" panic on detach, caused by accessing
already freed struct ifnet.
2005-09-14 10:28:01 +00:00
Robert Watson
13f4c340ae Propagate rename of IFF_OACTIVE and IFF_RUNNING to IFF_DRV_OACTIVE and
IFF_DRV_RUNNING, as well as the move from ifnet.if_flags to
ifnet.if_drv_flags.  Device drivers are now responsible for
synchronizing access to these flags, as they are in if_drv_flags.  This
helps prevent races between the network stack and device driver in
maintaining the interface flags field.

Many __FreeBSD__ and __FreeBSD_version checks maintained and continued;
some less so.

Reviewed by:	pjd, bz
MFC after:	7 days
2005-08-09 10:20:02 +00:00
Robert Watson
13b203d0d7 Modify device drivers supporting multicast addresses to lock if_addr_mtx
over iteration of their multicast address lists when synchronizing the
hardware address filter with the network stack-maintained list.

Problem reported by:	Ed Maste (emaste at phaedrus dot sandvine dot ca>
MFC after:		1 week
2005-08-03 00:18:35 +00:00
Ruslan Ermilov
b34b221d77 Add missing ether_poll_deregister(). This is still not enough to
kldunload/kldload without a panic.  The same (but worse) problem
is also present in ixgb(4).
2005-08-02 08:44:45 +00:00
Xin LI
5b7ff138f0 Correct a minor typo.
Pointed out by:	Xuefeng DENG <dengxf at dengh com>
Approved by:	re (scottl)
2005-07-11 02:33:25 +00:00
Brooks Davis
fc74a9f93a Stop embedding struct ifnet at the top of driver softcs. Instead the
struct ifnet or the layer 2 common structure it was embedded in have
been replaced with a struct ifnet pointer to be filled by a call to the
new function, if_alloc(). The layer 2 common structure is also allocated
via if_alloc() based on the interface type. It is hung off the new
struct ifnet member, if_l2com.

This change removes the size of these structures from the kernel ABI and
will allow us to better manage them as interfaces come and go.

Other changes of note:
 - Struct arpcom is no longer referenced in normal interface code.
   Instead the Ethernet address is accessed via the IFP2ENADDR() macro.
   To enforce this ac_enaddr has been renamed to _ac_enaddr.
 - The second argument to ether_ifattach is now always the mac address
   from driver private storage rather than sometimes being ac_enaddr.

Reviewed by:	sobomax, sam
2005-06-10 16:49:24 +00:00
Tony Ackerman
54fa8c991d Latest README to correspond to latest Intel version 2.1.7 2005-05-26 23:33:24 +00:00
Tony Ackerman
7e518cf0e8 Changes to update driver with latest Intel driver version 2.1.7
- Changed from using explicit devices id to using descriptive labels.
- Added support for 82573 and 82546 Quad adapters.
- Corrected support for 82547EI and 82541ER (mac_type was not assigned)
- Removed #ifdef DBG_STATS and extraneous code.

if_em_hw.c/if_em_hw.h
- Added support for 82573 and 82546 Quad adapters.
- Brought forward Intel's most current mac and phy changes.
2005-05-26 23:32:02 +00:00
Gleb Smirnoff
4369bfad31 Run em_local_timer() once per second instead of running it once per 2 seconds.
This makes gathering of error stats more precise, and netstat(1) output look
right.

Reviewed by:	tackerman
2005-04-05 07:06:47 +00:00
Warner Losh
538565c4a5 Use BUS_PROBE_DEFAULT for pci probe return value 2005-03-05 18:30:12 +00:00
Gleb Smirnoff
e5d73ca252 Call if_link_state_change() when link status changes.
PR:		kern/76890
Reviewed by:	rwatson, sam
2005-02-04 18:36:04 +00:00
Yaroslav Tykhiy
c96a57bbf5 Respect the current setting of IFCAP_VLAN_HWTAGGING on
the interface when going to toggle VLAN support for
internal reasons.  If the IFCAP_VLAN_HWTAGGING bit is
cleared, we should rely on the (re)init routine to turn
VLAN support off and never touch the relevant hardware bits.

This applies to other capability bits, too.  The user
obviously has a reason for clearing a capability bit,
e.g., if his particular NIC is buggy and hangs if a
certain hardware capability is turned on even for a
fraction of a second.

The flag adapter->em_insert_vlan_header still is set or
reset irrespective of the IFCAP_VLAN_HWTAGGING setting,
as before, in order to handle the case when a user sets
promiscuous mode on an interface first and later turns
its IFCAP_VLAN_HWTAGGING bit on.

This change might look orthogonal to rev#1.85, but in fact
it is not.  It introduces bugfixes that hopefully will make
implementing the general scheme mentioned in the commit
message of rev#1.85 easier.
2005-01-26 13:44:47 +00:00
Robert Watson
de13c80e9b Disable use of hardware VLAN tagging and stripping in if_em in the default
configuration: it appears to work properly in the non-promiscuous case, but
we've not yet implemented a more general solution that maintains full
functionality with promiscuous mode enabled.  While my hope is that we can
get one implemented soon, this will improve functionality substantially in
the mean time.

MFC after:	3 days
2005-01-26 11:40:58 +00:00
Scott Long
0ab6412830 Convert if_em to the new bus_dmamap_load_sg() interface. The old callback
was really just a waste of cycles, so this streamlines it considerably.
2005-01-15 20:52:15 +00:00
Warner Losh
098ca2bda9 Start each of the license/copyright comments with /*-, minor shuffle of lines 2005-01-06 01:43:34 +00:00
Tony Ackerman
b1ffdfc7c2 Corrected a workaround that should only be applied to one adapter. Workaround
was causing device hangs when incorrectly applied to other adapters.

PR:		kern/66634
2005-01-01 19:57:23 +00:00
Tony Ackerman
66fe651294 Added device id support for Intel 82541ER and 82546GB dual port PCIE adapter.
PR:		 None
2005-01-01 19:54:39 +00:00
Robert Watson
1eef0330d9 Further refine the if_em vlan fix in if_em.c:1.53:
- Because em_encap() can now fail in a way that leaves us without an
  mbuf chain, potentially set *m_headp to NULL if that happens, so that
  the caller can do the right thing.  This case can occur when we try
  to prepend the vlan header mbuf but can't allocate additional memory.

- Modify the caller of em_encap() to detect a NULL m_head and not try
  to queue the mbuf if that happens.

- When em_encap() fails, make sure to call bus_dmamap_destroy() to
  clean up.
2004-11-14 20:20:28 +00:00
Robert Watson
16142b2b03 Correct a bug in the if_em driver relating to the use of vlans with
promiscuous mode introduced in 1.45, which programs the em card not
to strip or prepend tags when in promiscuous mode without also
modifying behavior to manually prepend a vlan header in the event
that the card isn't doing it on transmit.  Due to a feature of card
operation, if the global VLAN prepend/strip register isn't set,
setting the VLAN tag flag on individual packet descriptors will
cause the packet to be transmitted using ISL encapsulation rather
than 802.1Q VLAN encapsulation.

This fix causes em_encap() to prepend the header by tracking whether
the card is configured to temporarily disable prepending/stripping
due to promiscuous mode.  As a result, entering promiscuous mode on
the parent em interface no longer causes vlans to appear to "wedge"
or transmit ISL-encapsulated frames, which typically will not be
configured/spoken by the other endpoints on the VLAN trunk.  This
bug may also exist in other drivers, and the additional vlan
encapsulation logic should be abstracted and centralized in
if_vlan.c if so.

RELENG_5_3 candidate.

MFC after:	1 week
Tested by:	pjd, rwatson
Reported by:	astesin at ukrtelecom dot net
Reported by:	Mike Tancsa <mike at sentex dot net>
Reported by:	Iasen Kostov <tbyte at OTEL dot net>
2004-11-12 11:03:07 +00:00
Dag-Erling Smørgrav
611f86ee5f Unbreak the build.
Pointy hat to:	bms
2004-11-11 19:00:51 +00:00
Bruce M Simpson
a1d77c4e01 Remove now-unused sysctl members. 2004-11-11 15:33:40 +00:00
Bruce M Simpson
97fa91743c Move per-instance sysctls under the per-device-instance tree.
Reviewed by:	mux
Prodded by:	rwatson
2004-11-11 15:31:38 +00:00
Poul-Henning Kamp
5b410dcf85 Put the "Link is up/down" printfs behind bootverbose. gigE is not so uncommon
that we need to tell people about every cable in the network anymore.  It can
be enabled for debugging purposes with "boot -v".
2004-11-03 14:11:18 +00:00
Maxime Henrion
2534c4f99c Add missing bus_dmamap_sync() calls. If you are using an architecture
with a weak memory model or x86 + PAE (or more specifically, your
driver is using bounce pages) and you have had problems with em(4),
this may fix it.  At least this is needed to have em(4) work properly
on FreeBSD/arm.

Original version by:	cognet
Reviewed by:		tackerman
Tested by:		cognet
2004-10-19 23:31:44 +00:00
Scott Long
25ba7fd287 Use an alignment of 1 instead of PAGE_SIZE for the rx and tx buffer tags.
Since the e1000 DMA engines hava no constraints on the alignment of buffer
transfers, there is no reason to tell busdma that there is.  This save a
minimum of 1 malloc call per packet, which translates to eliminating 4 locks.
It also means that buffers are not needlessly bounced when transfered.  The
end result is a 38% improvement in pps in a 4 way bridging environment.

Obtained from: Sandvine, Inc.
2004-10-19 02:39:27 +00:00
Scott Long
2f93f011ec Don't count RNBC (internal buffer full) towards the RX error count since it's
not really an error.

Submitted by: Gerrit Nagelhout
2004-10-09 07:27:03 +00:00
Max Laier
a8b4525f63 Fix typeo. Should read ***!***IFQ_DRV_IS_EMPTY.
This might fix some of the trouble around em(4) filling up its buffers.

Submitted by:	mtm
Pointy hat to:	mlaier
MFC after:	2 days
2004-09-29 18:28:28 +00:00
Olivier Houchard
2ae0fcd220 Do not use the IO-mapping to issue the reset on the 82546 on arm. For some
reason, it results in corrupted descriptors.
2004-09-23 22:57:53 +00:00
Prafulla Deuskar
9821d34f43 Added support for Intel PRO/1000 GT Desktop Adapter(Device ID 8086 107C)
Removed support for Intel 82541ER
Added fix for 82547 which corrects an issue with Jumbo frames larger than 10k.
Added fix for vlan tagged frames not being properly bridged.
Corrected TBI workaround.
Corrected incorrect LED operation issues

Submitted by:	tackerman (Tony Ackerman)
MFC after:	2 weeks
2004-09-01 23:22:41 +00:00
Max Laier
7929aa036c Bring in the first chunk of altq driver modifications. This covers the
following drivers: bfe(4), em(4), fxp(4), lnc(4), tun(4), de(4) rl(4),
sis(4) and xl(4)

More patches are pending on: http://peoples.freebsd.org/~mlaier/ Please take
a look and tell me if "your" driver is missing, so I can fix this.

Tested-by:	many
No-objection:	-current, -net
2004-07-02 12:16:02 +00:00
Yaroslav Tykhiy
3e4482412b Implement support for controlling VLAN_HWTAGGING through ioctl(SIOCSIFCAP).
This includes not only toggling the flag in if_capenable, but also really
reconfiguring the hardware.

Approved by:	tackerman (as the em(4) maintainer)
2004-06-04 16:57:18 +00:00
Poul-Henning Kamp
fe12f24bb0 Add missing <sys/module.h> includes 2004-05-30 20:08:47 +00:00
Maxime Henrion
866a788cc2 We don't need to initialize if_output, ether_ifattach() does it
for us.
2004-05-23 16:11:53 +00:00
Yaroslav Tykhiy
1df1a82541 Stylistic changes around the previous commit:
- since the number of supported capabilities is growing,
  set bits in if_cap* in a consistent way;

- unexpand(1) leading SPACE characters.
2004-05-20 11:04:09 +00:00
Yaroslav Tykhiy
388305aceb Set the VLAN bits in if_capenable as well as in if_capabilities
because VLAN hardware features are enabled in em(4) by default.

Note: Currently vlan(4) has a bug that it consults
if_capabilities, not if_capenable.  This will be fixed
after all the network drivers set VLAN bits in
if_capenable properly.
2004-05-20 10:57:33 +00:00
Ruslan Ermilov
6707138161 Implemented per-interface polling(4) control. 2004-04-11 21:01:12 +00:00
Nate Lawson
5f96beb9e0 Convert callers to the new bus_alloc_resource_any(9) API.
Submitted by:	Mark Santcroos <marks@ripe.net>
Reviewed by:	imp, dfr, bde
2004-03-17 17:50:55 +00:00
Prafulla Deuskar
b81490427d Only reset the phy when it is absolutely required.
This should fix the issues with long *init* times when
you do ifconfig em0 alias.

MFC after:	3 days
2004-02-10 21:31:09 +00:00
Daniel Eischen
f850af3016 Don't call em_stop() from the watchdog since it requires the controller
mutex to be locked.  It is redundant since em_init() is called and this
correctly locks the mutex and calls em_stop().

5.2 release candidate since this can cause a panic if the watchdog
expires.

Tested by:	kuriyama
2003-12-07 06:50:04 +00:00
Prafulla Deuskar
20109fa046 Use if_flags to check for IFF_POLLING instead of if_ipending.
Submitted by:	jroberson (Jeff Roberson)
Approved by:	re (scottl)
2003-12-02 22:13:08 +00:00
Prafulla Deuskar
3c2ef4e7e2 - Code cleanup
- In the receive routine handle the case where last descriptor could have
  less than 4 bytes of data.
- Handle race between detach/ioctl routine.

MFC after:	3 days
2003-11-14 18:02:25 +00:00
Brooks Davis
9bf40ede4a Replace the if_name and if_unit members of struct ifnet with new members
if_xname, if_dname, and if_dunit. if_xname is the name of the interface
and if_dname/unit are the driver name and instance.

This change paves the way for interface renaming and enhanced pseudo
device creation and configuration symantics.

Approved By:	re (in principle)
Reviewed By:	njl, imp
Tested On:	i386, amd64, sparc64
Obtained From:	NetBSD (if_xname)
2003-10-31 18:32:15 +00:00
Daniel Eischen
0bea487cfa Add a wrapper for a function that takes and releases the adapter
lock around a call to the original function.  Make the timeout
function in callout_reset() use the wrapped function to avoid a
lock assertion panic.

Reviewed by:	sam
Reported by:	cgiordano@ids.net
2003-10-15 05:34:41 +00:00
Sam Leffler
7f59ff24d8 locking fixups:
o correct recursive locking when polling and in em_82547_move_tail
o destroy mutex on detach
o add EM_LOCK_ASSERT and similar macros for creating+deleteing the mtx

Submitted by:	Daniel Eischen <eischen@vigrid.com>
2003-10-10 23:14:21 +00:00
Sam Leffler
266f0707bb add locking
Reviewed by:	Prafulla Deuskar <pdeuskar@FreeBSD.ORG>
Sponsored by:	FreeBSD Foundation
2003-09-23 00:18:25 +00:00
Prafulla Deuskar
3a47a99d78 Add support for new devices.
Bug Fixes:
	- Allow users to use LAA
	- Remember promiscuous mode settings while bridging
	- Allow gratuitous arp's to be sent

PR:		52966/54488
MFC after:	1 week
2003-08-27 21:52:37 +00:00
David E. O'Brien
aad970f1fe Use __FBSDID().
Also some minor style cleanups.
2003-08-24 17:55:58 +00:00
Warner Losh
4fbd232c86 Prefer new location of pci include files (which have only been in the
tree for two or more years now), except in a few places where there's
code to be compatible with older versions of FreeBSD.
2003-08-22 05:54:52 +00:00
John Polstra
515d4440fe Add facilities for tuning the "em" driver's interrupt delays without
recompiling the driver.  See the comments near the top of "if_em.h"
for descriptions of these delays.  Four new loader tunables control
the system-wide default values:

    hw.em.tx_int_delay
    hw.em.rx_int_delay
    hw.em.tx_abs_int_delay
    hw.em.rx_abs_int_delay

The tunables are specified in microseconds.  The valid range is
0-67108 usec., and 0 means that the timer is disabled.

There are also four new sysctls (actually, a set of four for each
"em" device in the system) to query and change the interrupt delays
after the system is up:

    hw.em0.tx_int_delay
    hw.em0.rx_int_delay
    hw.em0.tx_abs_int_delay (not present for 82542/3/4 adapters)
    hw.em0.rx_abs_int_delay (not present for 82542/3/4 adapters)

It seems to be OK to change these values even while the adapter is
passing traffic.

Approved by:	Prafulla Deuskar <pdeuskar@FreeBSD.ORG>
MFC after:	4 weeks
2003-08-01 17:33:59 +00:00
John Polstra
c7cc6a4d9f Correct comments to indicate that the EM_RADV and EM_TADV parameters
are not applicable to the 82544.
2003-07-17 19:02:34 +00:00
Maxime Henrion
dbe4792865 The em(4) driver has been converted to busdma and doesn't use
vtophys() anymore, so remove the alpha hack which defines
vtophys() to alpha_XXX_dmamap().
2003-07-04 10:15:16 +00:00
Scott Long
f6b1c44d1f Mega busdma API commit.
Add two new arguments to bus_dma_tag_create(): lockfunc and lockfuncarg.
Lockfunc allows a driver to provide a function for managing its locking
semantics while using busdma.  At the moment, this is used for the
asynchronous busdma_swi and callback mechanism.  Two lockfunc implementations
are provided: busdma_lock_mutex() performs standard mutex operations on the
mutex that is specified from lockfuncarg.  dftl_lock() is a panic
implementation and is defaulted to when NULL, NULL are passed to
bus_dma_tag_create().  The only time that NULL, NULL should ever be used is
when the driver ensures that bus_dmamap_load() will not be deferred.
Drivers that do not provide their own locking can pass
busdma_lock_mutex,&Giant args in order to preserve the former behaviour.

sparc64 and powerpc do not provide real busdma_swi functions, so this is
largely a noop on those platforms.  The busdma_swi on is64 is not properly
locked yet, so warnings will be emitted on this platform when busdma
callback deferrals happen.

If anyone gets panics or warnings from dflt_lock() being called, please
let me know right away.

Reviewed by:	tmm, gibbs
2003-07-01 15:52:06 +00:00
Prafulla Deuskar
d30350e524 Add support for Quad port adapter
Add sysctl's to display statistics/debug_info
Set WAIT_FOR_AUTONEG_DEFAULT to zero by default
Increment packet in/out statistics inline instead of every two seconds.

MFC after:	3 days
2003-06-05 17:51:38 +00:00
Dag-Erling Smørgrav
88b1e0bc5b Fix a printf() format error which broke the ia64 GENERIC build. 2003-05-06 03:55:12 +00:00
Prafulla Deuskar
bc93b4de0e - Fix breakage on PAE enabled kernel
- Don't use vtophys when you can get physical address using bus_dma API

Submitted by:	jake (Jake Burkholder)
2003-05-03 07:35:47 +00:00
Prafulla Deuskar
a9cbe07958 - Bus DMA'fy the driver
- Use htole* macros where appropriate so that the driver could work on non-x86 architectures
- Use m_getcl() instead of MGETHDR/MCLGET macros
Submitted by:	sam (Sam Leffler)
2003-05-02 21:17:08 +00:00
Prafulla Deuskar
a40f7e92e2 Tell the upper layer(s) that we support long frames.
Not doing this caused the vlan mtu to be reduced by 4 bytes.

Submitted by:	Doug Ambrisko (ambrisko)
MFC after:	1 day
2003-04-18 17:36:13 +00:00
Matthew N. Dodd
f246e4a17f - Express hard dependencies on bus (pci, isa, pccard) and
network layer (ether).
- Don't abuse module names to facilitate ifconfig module loading;
  such abuse isn't really needed.  (And if we do need type information
  associated with a module then we should make it explicit and not
  use hacks.)
2003-04-15 06:37:30 +00:00
Prafulla Deuskar
55cbc7f8bd Added support for 82541 and 82547 based adapters.
- These have Intel gigabit PHY
 - 82547 uses CSA interface

MFC after:	1 week
2003-03-21 21:47:31 +00:00
Warner Losh
a163d034fa Back out M_* changes, per decision of the TRB.
Approved by: trb
2003-02-19 05:47:46 +00:00
Alfred Perlstein
44956c9863 Remove M_TRYWAIT/M_WAITOK/M_WAIT. Callers should use 0.
Merge M_NOWAIT/M_DONTWAIT into a single flag M_NOWAIT.
2003-01-21 08:56:16 +00:00
Prafulla Deuskar
bddfcc8792 The README refers to a LICENSE file, so add that file too.
BTW the license is also embedded in the source files.

MFC after:	1 day
2003-01-07 19:36:00 +00:00
Jens Schweikhardt
9d5abbddbf Correct typos, mostly s/ a / an / where appropriate. Some whitespace cleanup,
especially in troff files.
2003-01-01 18:49:04 +00:00
Prafulla Deuskar
a58e485d36 - Move to array based indexing for TX/RX descriptor/buffer management
- Added support for ITR (interrupt throttle register). This feature is available on
adapters based on 82545 and above
- Fixed problem with vlan support when traffic has priority bits set. (kern/45907)

PR:			kern/45907
MFC after:		1 week
2002-12-23 19:11:23 +00:00
Luigi Rizzo
1efbdcd10f Fix IFF_ALLMULTI handling.
Reviewed by: pdeuskar (maintainer)
Approved by: re
2002-11-25 20:00:13 +00:00
Luigi Rizzo
d535facffe Add polling support to the "em" driver.
Reviewed by: pdeuskar (maintainer)
Approved by: re
2002-11-25 19:56:16 +00:00
Sam Leffler
673d91916d network interface driver changes:
o don't strip the Ethernet header from inbound packets; pass packets
  up the stack intact (required significant changes to some drivers)
o reference common definitions in net/ethernet.h (e.g. ETHER_ALIGN)
o track ether_ifattach/ether_ifdetach API changes
o track bpf changes (use BPF_TAP and BPF_MTAP)
o track vlan changes (ifnet capabilities, revised processing scheme, etc.)
o use if_input to pass packets "up"
o call ether_ioctl for default handling of ioctls

Reviewed by:	many
Approved by:	re
2002-11-14 23:54:55 +00:00
Prafulla Deuskar
1d966d27b1 - Set RS (Report Status) bit on all descriptors of a packet instead of just the last one.
- Set RDTR to zero by default instead of 28.
- Fixed a problem with TX hangs with jumbo frames when number of fragments in the mbuf chain
is large.
- Added support for 82540EP based cards.

MFC after:	3 days
2002-11-08 18:14:17 +00:00
Prafulla Deuskar
587edcdc95 Corrected license in the source files. It should say "MUST" instead of "MAY".
MFC after:	2 days
2002-09-24 16:27:59 +00:00
Prafulla Deuskar
90fd36aac8 Back out TX/RX descriptor/buffer management changes from earier commit.
We are having panics with the driver under stress with jumbo frames.
Unfortunately we didnot catch it during our regular test cycle.
I am going to MFC the backout immediately.
2002-08-26 18:59:16 +00:00
Prafulla Deuskar
a237f70d50 TX/RX descriptor/buffer management changes.
Use array based scheme instead of queueing macros.

Submitted by:	Luigi Rizzo (rizzo@icir.org)
MFC after:	3 days
2002-08-21 23:44:15 +00:00
Prafulla Deuskar
802baa70eb - Use IO mode to reset the controller (82544 and beyond)
- Read the Mac address only once during attach.
  (This fixes the failover issue observed using the bonding driver)

MFC after:	3 days
2002-07-16 16:55:03 +00:00
Prafulla Deuskar
bc4df5df23 Removed unneeded files.
if_em_fxhw.[c,h] and if_em_phy.[c,h]
have been merged into one [c,h] file.

MFC after:	3 days
2002-06-18 22:51:26 +00:00
Prafulla Deuskar
a7fabc2b60 Added support for 82545EM and 82546EB based adapters.
Added Vlan support.

MFC after:	1 week
2002-06-03 22:30:51 +00:00
Peter Wemm
9c580bea80 Fix new gcc-3.1 warnings. I think this gets GENERIC compiling cleanly
again.
2002-05-24 05:21:36 +00:00
Prafulla Deuskar
29c4c8ed2b Make em driver compilable on IA64/alpha.
Submitted by:	peter
MFC after:	3 days
2002-05-02 22:21:01 +00:00
Poul-Henning Kamp
b418ad5c2e Follow NetBSD and s/IFM_1000_TX/IFM_1000_T/ 2002-04-28 20:34:20 +00:00
Prafulla Deuskar
076c4c2633 Added support for 82540EM based cards.
Cosmetic changes to make code more unix-like.

MFC after:	1 week
2002-04-06 00:36:53 +00:00
Alfred Perlstein
e51a25f850 Remove __P. 2002-03-20 02:08:01 +00:00
Prafulla Deuskar
a59716d2d8 - Added support for receive in multiple
descriptors. This simplifies code for jumbo frames.
- Cleaned up coding conventions to make code more unix-like.
- Cleaned up code in if_em_fxhw.c and if_em_phy.c.
  Added relevant comments.

MFC after:	1 week
2002-02-13 18:19:27 +00:00
Prafulla Deuskar
8bf402ad91 -Remove unneeded include stddef.h
-Modify modules Makefile so that em driver compiles only on
i386 platform. (Alpha not supported yet)

PR:	kern/32993
MFC after:	1
2001-12-20 17:55:49 +00:00
Prafulla Deuskar
8798701fd5 Fixed two problems:
1. Changed incorrect conditional in fxhw.c which would never
evaluate to true. Thanks to John Polstra for pointing that out.
2. Write to PCI config space by default, enabling memory access and
bus master enable.

Submitted by:Prafulla Deuskar
MFC after:3 days
2001-12-06 17:50:21 +00:00
Prafulla Deuskar
e6770f4c46 This is the first commit of the Intel gigabit driver for
PRO/1000 cards.

Submitted by:Prafulla Deuskar
Reviewed by: Paul Saab
MFC after:1 week
2001-12-02 07:37:17 +00:00