head	1.15;
access;
symbols
	RELENG_8_4:1.15.0.2
	RELENG_9_1_0_RELEASE:1.14.4.1.4.2
	RELENG_9_1:1.14.4.1.0.4
	RELENG_9_1_BP:1.14.4.1
	RELENG_8_3_0_RELEASE:1.14.2.1.8.1
	RELENG_8_3:1.14.2.1.0.8
	RELENG_8_3_BP:1.14.2.1
	RELENG_9_0_0_RELEASE:1.14.4.1.2.1
	RELENG_9_0:1.14.4.1.0.2
	RELENG_9_0_BP:1.14.4.1
	RELENG_9:1.14.0.4
	RELENG_9_BP:1.14
	RELENG_7_4_0_RELEASE:1.13.2.1.8.1
	RELENG_8_2_0_RELEASE:1.14.2.1.6.1
	RELENG_7_4:1.13.2.1.0.8
	RELENG_7_4_BP:1.13.2.1
	RELENG_8_2:1.14.2.1.0.6
	RELENG_8_2_BP:1.14.2.1
	RELENG_8_1_0_RELEASE:1.14.2.1.4.1
	RELENG_8_1:1.14.2.1.0.4
	RELENG_8_1_BP:1.14.2.1
	RELENG_7_3_0_RELEASE:1.13.2.1.6.1
	RELENG_7_3:1.13.2.1.0.6
	RELENG_7_3_BP:1.13.2.1
	RELENG_8_0_0_RELEASE:1.14.2.1.2.1
	RELENG_8_0:1.14.2.1.0.2
	RELENG_8_0_BP:1.14.2.1
	RELENG_8:1.14.0.2
	RELENG_8_BP:1.14
	RELENG_7_2_0_RELEASE:1.13.2.1.4.1
	RELENG_7_2:1.13.2.1.0.4
	RELENG_7_2_BP:1.13.2.1
	RELENG_7_1_0_RELEASE:1.13.2.1.2.1
	RELENG_6_4_0_RELEASE:1.12.26.1
	RELENG_7_1:1.13.2.1.0.2
	RELENG_7_1_BP:1.13.2.1
	RELENG_6_4:1.12.0.26
	RELENG_6_4_BP:1.12
	RELENG_7_0_0_RELEASE:1.13
	RELENG_6_3_0_RELEASE:1.12
	RELENG_7_0:1.13.0.4
	RELENG_7_0_BP:1.13
	RELENG_6_3:1.12.0.24
	RELENG_6_3_BP:1.12
	RELENG_7:1.13.0.2
	RELENG_7_BP:1.13
	RELENG_6_2_0_RELEASE:1.12
	RELENG_6_2:1.12.0.22
	RELENG_6_2_BP:1.12
	RELENG_5_5_0_RELEASE:1.12
	RELENG_5_5:1.12.0.20
	RELENG_5_5_BP:1.12
	RELENG_6_1_0_RELEASE:1.12
	RELENG_6_1:1.12.0.18
	RELENG_6_1_BP:1.12
	RELENG_6_0_0_RELEASE:1.12
	RELENG_6_0:1.12.0.16
	RELENG_6_0_BP:1.12
	RELENG_6:1.12.0.14
	RELENG_6_BP:1.12
	RELENG_5_4_0_RELEASE:1.12
	RELENG_5_4:1.12.0.12
	RELENG_5_4_BP:1.12
	RELENG_4_11_0_RELEASE:1.8
	RELENG_4_11:1.8.0.20
	RELENG_4_11_BP:1.8
	RELENG_5_3_0_RELEASE:1.12
	RELENG_5_3:1.12.0.10
	RELENG_5_3_BP:1.12
	RELENG_5:1.12.0.8
	RELENG_5_BP:1.12
	RELENG_4_10_0_RELEASE:1.8
	RELENG_4_10:1.8.0.18
	RELENG_4_10_BP:1.8
	RELENG_5_2_1_RELEASE:1.12
	RELENG_5_2_0_RELEASE:1.12
	RELENG_5_2:1.12.0.6
	RELENG_5_2_BP:1.12
	RELENG_4_9_0_RELEASE:1.8
	RELENG_4_9:1.8.0.16
	RELENG_4_9_BP:1.8
	RELENG_5_1_0_RELEASE:1.12
	RELENG_5_1:1.12.0.4
	RELENG_5_1_BP:1.12
	RELENG_4_8_0_RELEASE:1.8
	RELENG_4_8:1.8.0.14
	RELENG_4_8_BP:1.8
	RELENG_5_0_0_RELEASE:1.12
	RELENG_5_0:1.12.0.2
	RELENG_5_0_BP:1.12
	RELENG_4_7_0_RELEASE:1.8
	RELENG_4_7:1.8.0.12
	RELENG_4_7_BP:1.8
	RELENG_4_6_2_RELEASE:1.8
	RELENG_4_6_1_RELEASE:1.8
	RELENG_4_6_0_RELEASE:1.8
	RELENG_4_6:1.8.0.10
	RELENG_4_6_BP:1.8
	RELENG_4_5_0_RELEASE:1.8
	RELENG_4_5:1.8.0.8
	RELENG_4_5_BP:1.8
	RELENG_4_4_0_RELEASE:1.8
	RELENG_4_4:1.8.0.6
	RELENG_4_4_BP:1.8
	KSE_MILESTONE_2:1.12
	KSE_PRE_MILESTONE_2:1.12
	RELENG_4_3_0_RELEASE:1.8
	RELENG_4_3:1.8.0.4
	RELENG_4_3_BP:1.8
	RELENG_4_2_0_RELEASE:1.8
	RELENG_4_1_1_RELEASE:1.8
	PRE_SMPNG:1.11
	RELENG_4_1_0_RELEASE:1.8
	RELENG_4_0_0_RELEASE:1.8
	RELENG_4:1.8.0.2
	RELENG_4_BP:1.8;
locks; strict;
comment	@# @;


1.15
date	2012.11.17.01.53.02;	author svnexp;	state Exp;
branches
	1.15.2.1;
next	1.14;

1.14
date	2008.03.11.03.50.57;	author yongari;	state Exp;
branches
	1.14.2.1
	1.14.4.1;
next	1.13;

1.13
date	2005.09.27.18.10.40;	author mlaier;	state Exp;
branches
	1.13.2.1;
next	1.12;

1.12
date	2001.01.06.14.00.40;	author obrien;	state Exp;
branches
	1.12.14.1
	1.12.26.1;
next	1.11;

1.11
date	2000.05.27.01.14.32;	author peter;	state Exp;
branches;
next	1.10;

1.10
date	2000.05.04.12.08.49;	author peter;	state Exp;
branches;
next	1.9;

1.9
date	2000.05.01.18.58.46;	author peter;	state Exp;
branches;
next	1.8;

1.8
date	2000.01.28.11.26.42;	author bde;	state Exp;
branches
	1.8.2.1;
next	1.7;

1.7
date	99.11.28.18.53.43;	author bde;	state Exp;
branches;
next	1.6;

1.6
date	99.09.27.01.04.44;	author peter;	state Exp;
branches;
next	1.5;

1.5
date	99.09.27.00.34.02;	author peter;	state Exp;
branches;
next	1.4;

1.4
date	99.09.20.06.11.46;	author obrien;	state Exp;
branches;
next	1.3;

1.3
date	99.09.19.22.03.31;	author wpaul;	state Exp;
branches;
next	1.2;

1.2
date	99.08.28.00.48.04;	author peter;	state Exp;
branches;
next	1.1;

1.1
date	99.08.10.17.15.18;	author wpaul;	state Exp;
branches;
next	;

1.15.2.1
date	2012.11.17.01.53.02;	author svnexp;	state dead;
branches;
next	1.15.2.2;

1.15.2.2
date	2013.03.28.13.05.25;	author svnexp;	state Exp;
branches;
next	;

1.14.2.1
date	2009.08.03.08.13.06;	author kensmith;	state Exp;
branches
	1.14.2.1.2.1
	1.14.2.1.4.1
	1.14.2.1.6.1
	1.14.2.1.8.1;
next	1.14.2.2;

1.14.2.2
date	2012.11.17.10.36.59;	author svnexp;	state Exp;
branches;
next	;

1.14.2.1.2.1
date	2009.10.25.01.10.29;	author kensmith;	state Exp;
branches;
next	;

1.14.2.1.4.1
date	2010.06.14.02.09.06;	author kensmith;	state Exp;
branches;
next	;

1.14.2.1.6.1
date	2010.12.21.17.09.25;	author kensmith;	state Exp;
branches;
next	;

1.14.2.1.8.1
date	2012.03.03.06.15.13;	author kensmith;	state Exp;
branches;
next	1.14.2.1.8.2;

1.14.2.1.8.2
date	2012.11.17.08.25.34;	author svnexp;	state Exp;
branches;
next	;

1.14.4.1
date	2011.09.23.00.51.37;	author kensmith;	state Exp;
branches
	1.14.4.1.2.1
	1.14.4.1.4.1;
next	1.14.4.2;

1.14.4.2
date	2012.11.17.11.37.19;	author svnexp;	state Exp;
branches;
next	;

1.14.4.1.2.1
date	2011.11.11.04.20.22;	author kensmith;	state Exp;
branches;
next	1.14.4.1.2.2;

1.14.4.1.2.2
date	2012.11.17.08.37.15;	author svnexp;	state Exp;
branches;
next	;

1.14.4.1.4.1
date	2012.08.05.23.54.33;	author kensmith;	state Exp;
branches;
next	1.14.4.1.4.2;

1.14.4.1.4.2
date	2012.11.17.08.48.06;	author svnexp;	state Exp;
branches;
next	;

1.13.2.1
date	2008.04.11.03.41.58;	author yongari;	state Exp;
branches
	1.13.2.1.2.1
	1.13.2.1.4.1
	1.13.2.1.6.1
	1.13.2.1.8.1;
next	1.13.2.2;

1.13.2.2
date	2012.11.17.08.06.59;	author svnexp;	state Exp;
branches;
next	;

1.13.2.1.2.1
date	2008.11.25.02.59.29;	author kensmith;	state Exp;
branches;
next	;

1.13.2.1.4.1
date	2009.04.15.03.14.26;	author kensmith;	state Exp;
branches;
next	;

1.13.2.1.6.1
date	2010.02.10.00.26.20;	author kensmith;	state Exp;
branches;
next	;

1.13.2.1.8.1
date	2010.12.21.17.10.29;	author kensmith;	state Exp;
branches;
next	1.13.2.1.8.2;

1.13.2.1.8.2
date	2012.11.17.08.17.28;	author svnexp;	state Exp;
branches;
next	;

1.12.14.1
date	2012.11.17.07.44.28;	author svnexp;	state Exp;
branches;
next	;

1.12.26.1
date	2008.10.02.02.57.24;	author kensmith;	state Exp;
branches;
next	;

1.8.2.1
date	2012.11.17.07.26.37;	author svnexp;	state Exp;
branches;
next	;


desc
@@


1.15
log
@Switching exporter and resync
@
text
@# $FreeBSD: head/sys/modules/vr/Makefile 177048 2008-03-11 03:50:57Z yongari $

.PATH: ${.CURDIR}/../../dev/vr

KMOD=	if_vr
SRCS=	if_vr.c device_if.h bus_if.h pci_if.h
SRCS+=	miibus_if.h

.include <bsd.kmod.mk>
@


1.15.2.1
log
@file Makefile was added on branch RELENG_8_4 on 2013-03-28 13:05:25 +0000
@
text
@d1 9
@


1.15.2.2
log
@## SVN ## Exported commit - http://svnweb.freebsd.org/changeset/base/248810
## SVN ## CVS IS DEPRECATED: http://wiki.freebsd.org/CvsIsDeprecated
@
text
@a0 9
# $FreeBSD: releng/8.4/sys/modules/vr/Makefile 177048 2008-03-11 03:50:57Z yongari $

.PATH: ${.CURDIR}/../../dev/vr

KMOD=	if_vr
SRCS=	if_vr.c device_if.h bus_if.h pci_if.h
SRCS+=	miibus_if.h

.include <bsd.kmod.mk>
@


1.14
log
@Update file list and Makefile after repocopying vr(4) from
src/sys/pci to src/sys/dev.
@
text
@d1 1
a1 1
# $FreeBSD$
@


1.14.4.1
log
@SVN rev 225736 on 2011-09-23 00:51:37Z by kensmith

Copy head to stable/9 as part of 9.0-RELEASE release cycle.

Approved by:	re (implicit)
@
text
@@


1.14.4.2
log
@## SVN ##
## SVN ## Exported commit - http://svnweb.freebsd.org/changeset/base/ 242902
## SVN ## CVS IS DEPRECATED: http://wiki.freebsd.org/CvsIsDeprecated
## SVN ##
## SVN ## ------------------------------------------------------------------------
## SVN ## r242902 | dteske | 2012-11-11 23:29:45 +0000 (Sun, 11 Nov 2012) | 10 lines
## SVN ##
## SVN ## Fix a regression introduced by SVN r211417 that saw the breakage of a feature
## SVN ## documented in usr.sbin/sysinstall/help/shortcuts.hlp (reproduced below):
## SVN ##
## SVN ## If /usr/sbin/sysinstall is linked to another filename, say
## SVN ## `/usr/local/bin/configPackages', then the basename will be used
## SVN ## as an implicit command name.
## SVN ##
## SVN ## Reviewed by:	adrian (co-mentor)
## SVN ## Approved by:	adrian (co-mentor)
## SVN ##
## SVN ## ------------------------------------------------------------------------
## SVN ##
@
text
@d1 1
a1 1
# $FreeBSD: stable/9/sys/modules/vr/Makefile 177048 2008-03-11 03:50:57Z yongari $
@


1.14.4.1.4.1
log
@SVN rev 239080 on 2012-08-05 23:54:33Z by kensmith

Copy stable/9 to releng/9.1 as part of the 9.1-RELEASE release process.

Approved by:	re (implicit)
@
text
@@


1.14.4.1.4.2
log
@Switch importer
@
text
@d1 1
a1 1
# $FreeBSD: releng/9.1/sys/modules/vr/Makefile 177048 2008-03-11 03:50:57Z yongari $
@


1.14.4.1.2.1
log
@SVN rev 227445 on 2011-11-11 04:20:22Z by kensmith

Copy stable/9 to releng/9.0 as part of the FreeBSD 9.0-RELEASE release
cycle.

Approved by:	re (implicit)
@
text
@@


1.14.4.1.2.2
log
@Switch importer
@
text
@d1 1
a1 1
# $FreeBSD: releng/9.0/sys/modules/vr/Makefile 177048 2008-03-11 03:50:57Z yongari $
@


1.14.2.1
log
@SVN rev 196045 on 2009-08-03 08:13:06Z by kensmith

Copy head to stable/8 as part of 8.0 Release cycle.

Approved by:	re (Implicit)
@
text
@@


1.14.2.2
log
@## SVN ##
## SVN ## Exported commit - http://svnweb.freebsd.org/changeset/base/ 242909
## SVN ## CVS IS DEPRECATED: http://wiki.freebsd.org/CvsIsDeprecated
## SVN ##
## SVN ## ------------------------------------------------------------------------
## SVN ## r242909 | dim | 2012-11-12 07:47:19 +0000 (Mon, 12 Nov 2012) | 20 lines
## SVN ##
## SVN ## MFC r242625:
## SVN ##
## SVN ## Remove duplicate const specifiers in many drivers (I hope I got all of
## SVN ## them, please let me know if not).  Most of these are of the form:
## SVN ##
## SVN ## static const struct bzzt_type {
## SVN ##       [...list of members...]
## SVN ## } const bzzt_devs[] = {
## SVN ##       [...list of initializers...]
## SVN ## };
## SVN ##
## SVN ## The second const is unnecessary, as arrays cannot be modified anyway,
## SVN ## and if the elements are const, the whole thing is const automatically
## SVN ## (e.g. it is placed in .rodata).
## SVN ##
## SVN ## I have verified this does not change the binary output of a full kernel
## SVN ## build (except for build timestamps embedded in the object files).
## SVN ##
## SVN ## Reviewed by:	yongari, marius
## SVN ##
## SVN ## ------------------------------------------------------------------------
## SVN ##
@
text
@d1 1
a1 1
# $FreeBSD: stable/8/sys/modules/vr/Makefile 177048 2008-03-11 03:50:57Z yongari $
@


1.14.2.1.8.1
log
@SVN rev 232438 on 2012-03-03 06:15:13Z by kensmith

Copy stable/8 to releng/8.3 as part of 8.3-RELEASE release cycle.

Approved by:	re (implicit)
@
text
@@


1.14.2.1.8.2
log
@Switch importer
@
text
@d1 1
a1 1
# $FreeBSD: releng/8.3/sys/modules/vr/Makefile 177048 2008-03-11 03:50:57Z yongari $
@


1.14.2.1.6.1
log
@SVN rev 216617 on 2010-12-21 17:09:25Z by kensmith

Copy stable/8 to releng/8.2 in preparation for FreeBSD-8.2 release.

Approved by:	re (implicit)
@
text
@@


1.14.2.1.4.1
log
@SVN rev 209145 on 2010-06-14 02:09:06Z by kensmith

Copy stable/8 to releng/8.1 in preparation for 8.1-RC1.

Approved by:	re (implicit)
@
text
@@


1.14.2.1.2.1
log
@SVN rev 198460 on 2009-10-25 01:10:29Z by kensmith

Copy stable/8 to releng/8.0 as part of 8.0-RELEASE release procedure.

Approved by:	re (implicit)
@
text
@@


1.13
log
@Remove bridge(4) from the tree.  if_bridge(4) is a full functional
replacement and has additional features which make it superior.

Discussed on:	-arch
Reviewed by:	thompsa
X-MFC-after:	never (RELENG_6 as transition period)
@
text
@d3 1
a3 1
.PATH: ${.CURDIR}/../../pci
@


1.13.2.1
log
@MFC vr(4) to latest HEAD.
  o vr(4) repocopied from sys/pci to sys/dev/vr.

  Teach vr(4) to use bus_dma(9) and major overhauling to handle link
  state change and reliable error recovery.
   o Moved vr_softc structure and relevant macros to header file.
   o Use PCIR_BAR macro to get BARs.
   o Implemented suspend/resume methods.
   o Implemented automatic Tx threshold configuration which will be
     activated when it suffers from Tx underrun. Also Tx underrun
     will try to restart only Tx path and resort to previous
     full-reset(both Rx/Tx) operation if restarting Tx path have failed.
   o Removed old bit-banging MII interface. Rhine provides simple and
     efficient MII interface. While I'm here show PHY address and PHY
     register number when its read/write operation was failed.
   o Define VR_MII_TIMEOUT constant and use it in MII access routines.
   o Always honor link up/down state reported by mii layers. The link
     state information is used in vr_start() to determine whether we
     got a valid link.
   o Removed vr_setcfg() which is now handled in vr_link_task(), link
     state taskqueue handler. When mii layer reports link state changes
     the taskqueue handler reprograms MAC to reflect negotiated duplex
     settings. Flow-control changes are not handled yet and it should
     be revisited when mii layer knows the notion of flow-control.
   o Added a new sysctl interface to get statistics of an instance of
     the driver.(sysctl dev.vr.0.stats=1)
   o Chip name was renamed to reflect the official name of the chips
     described in VIA Rhine I/II/III datasheet.
          REV_ID_3065_A -> REV_ID_VT6102_A
          REV_ID_3065_B -> REV_ID_VT6102_B
          REV_ID_3065_C -> REV_ID_VT6102_C
          REV_ID_3106_J -> REV_ID_VT6105_A0
          REV_ID_3106_S -> REV_ID_VT6105M_A0
     The following chip revisions were added.
          #define REV_ID_VT6105_B0        0x83
          #define REV_ID_VT6105_LOM       0x8A
          #define REV_ID_VT6107_A0        0x8C
          #define REV_ID_VT6107_A1        0x8D
          #define REV_ID_VT6105M_B1       0x94
   o Always show chip revision number in device attach. This shall help
     identifying revision specific issues.
   o Check whether EEPROM reloading is complete by inspecting the state
     of VR_EECSR_LOAD bit. This bit is self-cleared after the EEPROM
     reloading. Previously vr(4) blindly spins for 200us which may/may
     not enough to complete the EEPROM reload.
   o Removed if_mtu setup. It's done in ether_ifattach().
   o Use our own callout to drive watchdog timer.
   o In vr_attach disable further interrupts after reset. For VT6102 or
     newer hardwares, diable MII state change interrupt as well because
     mii state handling is done by mii layer.
   o Add more sane register initialization for VT6102 or newer chips.
      - Have NIC report error instead of retrying forever.
      - Let hardware detect MII coding error.
      - Enable MODE10T mode.
      - Enable memory-read-multiple for VT6107.
   o PHY address for VT6105 or newer chips is located at fixed address 1.
     For older chips the PHY address is stored in VR_PHYADDR register.
     Armed with these information, there is no need to re-read
     VR_PHYADDR register in miibus handler to get PHY address. This
     saves one register access cycle for each MII access.
   o Don't reprogram VR_PHYADDR register whenever access to a register
     located at a PHY address is made. Rhine fmaily allows reprogramming
     PHY address location via VR_PHYADDR register depending on
     VR_MIISTAT_PHYOPT bit of VR_MIISTAT register. This used to lead
     numerous phantom PHYs attached to miibus during phy probe phase and
     driver used to limit allowable PHY address in mii register accessors
     for certain chip revisions. This removes one more register access
     cycle for each MII access.
   o Correctly set VLAN header length.
   o bus_dma(9) conversion.
      - Limit DMA access to be in range of 32bit address space. Hardware
        doesn't support DAC.
      - Apply descriptor ring alignment requirements(16 bytes alignment)
      - Apply Rx buffer address alignment requirements(4 bytes alignment)
      - Apply Tx buffer address alignment requirements(4 bytes alignment)
        for Rhine I chip. Rhine II or III has no Tx buffer address
        alignment restrictions, though.
      - Reduce number of allowable number of DMA segments to 8.
      - Removed the atomic(9) used in descriptor ownership managements
        as it's job of bus_dmamap_sync(9).
      With these change vr(4) should work on all platforms.
   o Rhine uses two separated 8bits command registers to control Tx/Rx
     MAC. So don't access it as a single 16bit register.
   o For non-strict alignment architectures vr(4) no longer require
     time-consuming copy operation for received frames to align IP
     header. This greatly improves Rx performance on i386/amd64
     platforms. However the alignment is still necessary for
     strict-alignment platforms(e.g. sparc64). The alignment is handled
     in new fuction vr_fixup_rx().
   o vr_rxeof() now rejects multiple-segmented(fragmented) frames as
     vr(4) is not ready to handle this situation. Datasheet said nothing
     about the reason when/why it happens.
   o In vr_newbuf() don't set VR_RXSTAT_FIRSTFRAG/VR_RXSTAT_LASTFRAG
     bits as it's set by hardware.
   o Don't pass checksum offload information to upper layer for
     fragmented frames. The hardware assisted checksum is valid only
     when the frame is non-fragmented IP frames. Also mark the checksum
     is valid for corrupted frames such that upper layers doesn't need
     to recompute the checksum with software routine.
   o Removed vr_rxeoc(). RxDMA doesn't seem to need to be idle before
     sending VR_CMD_RX_GO command. Previously it used to stop RxDMA
     first which in turn resulted in long delays in Rx error recovery.
   o Rewrote Tx completion handler.
      - Always check VR_TXSTAT_OWN bit in status word prior to
        inspecting other status bits in the status word.
      - Collision counter updates were corrected as VT3071 or newer
        ones use different bits to notify collisions.
      - Unlike other chip revisions, VT86C100A uses different bit to
        indicate Tx underrun. For VT3071 or newer ones, check both
        VR_TXSTAT_TBUFF and VR_TXSTAT_UDF bits to see whether Tx
        underrun was happend. In case of Tx underrun requeue the failed
        frame and restart stalled Tx SM. Also double Tx DMA threshold
        size on each failure to mitigate future Tx underruns.
      - Disarm watchdog timer only if we have no queued packets,
        otherwise don't touch watchdog timer.
   o Rewrote interrupt handler.
      - status word in Tx/Rx descriptors indicates more detailed error
        state required to recover from the specific error. There is no
        need to rely on interrupt status word to recover from Tx/Rx
        error except PCI bus error. Other event notifications like
        statistics counter overflows or link state events will be
        handled in main interrupt handler.
      - Don't touch VR_IMR register if we are in suspend mode. Touching
        the register may hang the hardware if we are in suspended state.
        Previously it seems that touching VR_IMR register in interrupt
        handler was to work-around panic occurred in system shutdown
        stage on SMP systems. I think that work-around would hide
        root-cause of the panic and I couldn't reproduce the panic
        with multiple attempts on my box.
   o While padding space to meet minimum frame size, zero the pad data
     in order to avoid possibly leaking sensitive data.
   o Rewrote vr_start_locked().
      - Don't try to queue packets if number of available Tx descriptors
        are short than that of required one.
   o Don't reinitialize hardware whenever media configuration is
     changed. Media/link state changes are reported from mii layer if
     this happens and vr_link_task() will perform necessary changes.
   o Don't reinitialize hardware if only PROMISC bit was changed. Just
     toggle the PROMISC bit in hardware is sufficient to reflect the
     request.
   o Rearrganed the IFCAP_POLLING/IFCAP_HWCSUM handling in vr_ioctl().
   o Generate Tx completion interrupts for every VR_TX_INTR_THRESH-th
     frames. This reduces Tx completion interrupts under heavy network
     loads.
   o Since vr(4) doesn't request Tx interrupts for every queued frames,
     reclaim any pending descriptors not handled in Tx completion
     handler before actually firing up watchdog timeouts.
   o Added vr_tx_stop()/vr_rx_stop() to wait for the end of active
     TxDMA/RxDMA cycles(draining). These routines are used in vr_stop()
     to ensure sane state of MAC before releasing allocated Tx/Rx
     buffers. vr_link_task() also takes advantage of these functions to
     get to idle state prior to restarting Tx/Rx.
   o Added vr_tx_start()/vr_rx_start() to restart Rx/Tx. By separating
     Rx operation from Tx operation vr(4) no longer need to full-reset
     the hardware in case of Tx/Rx error recovery.
   o Implemented WOL.
   o Added VT6105M specific register definitions. VT6105M has the
     following hardware capabilities.
      - Tx/Rx IP/TCP/UDP checksum offload.
      - VLAN hardware tag insertion/extraction. Due to lack of information
         for getting extracted VLAN tag in Rx path, VLAN hardware support
         was not implemented yet.
      - CAM(Content Addressable Memory) based 32 entry perfect multicast/
        VLAN filtering.
      - 8 priority queues.
   o Implemented CAM based 32 entry perfect multicast filtering for
     VT6105M. If number of multicast entry is greater than 32, vr(4)
     uses traditional hash based filtering.
   o Reflect real Tx/Rx descriptor structure. Previously vr(4) used to
     embed other driver (private) data into these structure. This type
     of embedding make it hard to work on LP64 systems.
   o Removed unused vr_mii_frame structure and MII bit-baning
     definitions.
   o Added new PCI configuration registers that controls mii operation
     and mode selection.
   o Reduced number of Tx/Rx descriptors to 128 from 256. From my
     testing, increasing number of descriptors above than 64 didn't help
     increasing performance at all. Experimentations show 128 Rx
     descriptors seems to help a lot reducing Rx FIFO overruns under
     high system loads. It seems the poor Tx performance of Rhine
     hardwares comes from the limitation of hardware. You wouldn't
     satuarte the link with vr(4) no matter how fast CPU/large number of
     descriptors are used.
   o Added vr_statistics structure to hold various counter values.
@
text
@d3 1
a3 1
.PATH: ${.CURDIR}/../../dev/vr
@


1.13.2.2
log
@Switch importer
@
text
@d1 1
a1 1
# $FreeBSD: stable/7/sys/modules/vr/Makefile 178094 2008-04-11 03:41:59Z yongari $
@


1.13.2.1.8.1
log
@SVN rev 216618 on 2010-12-21 17:10:29Z by kensmith

Copy stable/7 to releng/7.4 in preparation for FreeBSD-7.4 release.

Approved by:	re (implicit)
@
text
@@


1.13.2.1.8.2
log
@Switch importer
@
text
@d1 1
a1 1
# $FreeBSD: releng/7.4/sys/modules/vr/Makefile 178094 2008-04-11 03:41:59Z yongari $
@


1.13.2.1.6.1
log
@SVN rev 203736 on 2010-02-10 00:26:20Z by kensmith

Copy stable/7 to releng/7.3 as part of the 7.3-RELEASE process.

Approved by:	re (implicit)
@
text
@@


1.13.2.1.4.1
log
@SVN rev 191087 on 2009-04-15 03:14:26Z by kensmith

Create releng/7.2 from stable/7 in preparation for 7.2-RELEASE.

Approved by:	re (implicit)
@
text
@@


1.13.2.1.2.1
log
@SVN rev 185281 on 2008-11-25 02:59:29Z by kensmith

Create releng/7.1 in preparation for moving into RC phase of 7.1 release
cycle.

Approved by:	re (implicit)
@
text
@@


1.12
log
@Use a consistent style and one much closer to the rest of /usr/src
@
text
@d1 1
a1 1
# $FreeBSD: src/sys/modules/vr/Makefile,v 1.11 2000/05/27 01:14:32 peter Exp $
d6 1
a6 1
SRCS=	if_vr.c opt_bdg.h device_if.h bus_if.h pci_if.h
@


1.12.14.1
log
@Switch importer
@
text
@d1 1
a1 1
# $FreeBSD: stable/6/sys/modules/vr/Makefile 70711 2001-01-06 14:00:42Z obrien $
@


1.12.26.1
log
@SVN rev 183531 on 2008-10-02 02:57:24Z by kensmith

Create releng/6.4 from stable/6 in preparation for 6.4-RC1.

Approved by:	re (implicit)
@
text
@d1 1
a1 1
# $FreeBSD$
@


1.11
log
@Use .include <bsd.kmod.mk> to get to ../../*/conf/kmod.mk instead of
encoding the relative path.
@
text
@d1 1
a1 1
# $FreeBSD: src/sys/modules/vr/Makefile,v 1.10 2000/05/04 12:08:49 peter Exp $
d3 5
a7 4
.PATH:	${.CURDIR}/../../pci
KMOD	= if_vr
SRCS	= if_vr.c opt_bdg.h device_if.h bus_if.h pci_if.h
SRCS	+= miibus_if.h
@


1.10
log
@Pull in sys/conf/kmod.mk, rather than /usr/share/mk/bsd.kmod.mk.
This means that the kernel can be totally self contained now and is not
dependent on the last buildworld to update /usr/share/mk.  This might
also make it easier to build 5.x kernels on 4.0 boxes etc, assuming
gensetdefs and config(8) are updated.
@
text
@d1 1
a1 1
# $FreeBSD: src/sys/modules/vr/Makefile,v 1.9 2000/05/01 18:58:46 peter Exp $
d8 1
a8 1
.include "${.CURDIR}/../../conf/kmod.mk"
@


1.9
log
@Zap KMODDEPS line
@
text
@d1 1
a1 1
# $FreeBSD: src/sys/modules/vr/Makefile,v 1.8 2000/01/28 11:26:42 bde Exp $
d8 1
a8 1
.include <bsd.kmod.mk>
@


1.8
log
@Add ${DEBUG_FLAGS} to CFLAGS in bsd.kmod.mk, not in scattered module
makefiles.  Bad examples in fxp/Makefile keep getting copied to new
makefiles.
@
text
@d1 1
a1 1
# $FreeBSD: src/sys/modules/vr/Makefile,v 1.7 1999/11/28 18:53:43 bde Exp $
a6 1
KMODDEPS = miibus
@


1.8.2.1
log
@Switch importer
@
text
@d1 1
a1 1
# $FreeBSD: stable/4/sys/modules/vr/Makefile 56735 2000-01-28 11:26:46Z bde $
@


1.7
log
@Removed special rules for building and cleaning device interface files
and empty options files.  The rules are now generated automatically in
bsd.kmod.mk.  Cleaned up related things ($S and ${CLEANFILES}).
@
text
@d1 1
a1 1
# $FreeBSD: src/sys/modules/vr/Makefile,v 1.6 1999/09/27 01:04:44 peter Exp $
a7 2

CFLAGS	+= ${DEBUG_FLAGS}
@


1.6
log
@Zap some unused echo "#define NFOO 1" > foo.h style defunct stuff.
@
text
@d1 1
a1 1
# $FreeBSD: src/sys/modules/vr/Makefile,v 1.5 1999/09/27 00:34:02 peter Exp $
d3 1
a3 2
S	= ${.CURDIR}/../..
.PATH:	$S/pci
a6 2
CLEANFILES	+= opt_bdg.h device_if.h bus_if.h pci_if.h
CLEANFILES	+= miibus_if.h
a9 15

opt_bdg.h:
	touch opt_bdg.h

device_if.h: $S/kern/makedevops.pl $S/kern/device_if.m
	perl $S/kern/makedevops.pl -h $S/kern/device_if.m

bus_if.h: $S/kern/makedevops.pl $S/kern/bus_if.m
	perl $S/kern/makedevops.pl -h $S/kern/bus_if.m

pci_if.h: $S/kern/makedevops.pl $S/pci/pci_if.m
	perl $S/kern/makedevops.pl -h $S/pci/pci_if.m

miibus_if.h: $S/kern/makedevops.pl $S/dev/mii/miibus_if.m
	perl $S/kern/makedevops.pl -h $S/dev/mii/miibus_if.m
@


1.5
log
@Don't generate 'bpf.h' since it's not used.
@
text
@d1 1
a1 1
# $FreeBSD: src/sys/modules/vr/Makefile,v 1.4 1999/09/20 06:11:46 obrien Exp $
d6 1
a6 1
SRCS	= if_vr.c vr.h opt_bdg.h device_if.h bus_if.h pci_if.h
d8 1
a8 1
CLEANFILES	+= vr.h opt_bdg.h device_if.h bus_if.h pci_if.h
a12 3

vr.h:
	echo "#define NVR 1" > vr.h
@


1.4
log
@Change the name of the installed KLM to contain a leading "if_".
Except for miibus which is now installed as miibus.ko.

Discussed by:	msmith, peter, and wpaul
@
text
@d1 1
a1 1
# $FreeBSD: src/sys/modules/vr/Makefile,v 1.3 1999/09/19 22:03:31 wpaul Exp $
d6 1
a6 1
SRCS	= if_vr.c vr.h bpf.h opt_bdg.h device_if.h bus_if.h pci_if.h
d8 1
a8 1
CLEANFILES	+= vr.h bpf.h opt_bdg.h device_if.h bus_if.h pci_if.h
a15 3

bpf.h:
	echo "#define NBPF 1" > bpf.h
@


1.3
log
@Convert the VIA Rhine driver to miibus.
@
text
@d1 1
a1 1
# $FreeBSD: src/sys/modules/vr/Makefile,v 1.2 1999/08/28 00:48:04 peter Exp $
d5 1
a5 1
KMOD	= vr
d10 1
@


1.2
log
@$Id$ -> $FreeBSD$
@
text
@d1 1
a1 1
# $FreeBSD$
d7 1
d9 2
d30 3
@


1.1
log
@Convert the VIA Rhine driver to newbus and set it up to be compiled as
a module. Also modified the code to work on FreeBSD/alpha and added
device vr0 to the alpha GENERIC config.

While I was in the neighborhood, I noticed that I was still using
#define NFPX 1 in all of the Makefiles that I'd copied from the fxp
module. I don't really use #define Nfoo X so it didn't matter, but
I decided to customize this correctly anyway.
@
text
@d1 1
a1 1
#	$Id: Makefile,v 1.1 1999/07/23 05:48:01 wpaul Exp $
@
