Deleted Added
full compact
if_nge.c (95673) if_nge.c (95718)
1/*
2 * Copyright (c) 2001 Wind River Systems
3 * Copyright (c) 1997, 1998, 1999, 2000, 2001
4 * Bill Paul <wpaul@bsdi.com>. All rights reserved.
5 *
6 * Redistribution and use in source and binary forms, with or without
7 * modification, are permitted provided that the following conditions
8 * are met:

--- 16 unchanged lines hidden (view full) ---

25 * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
26 * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
27 * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
28 * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
29 * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
30 * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF
31 * THE POSSIBILITY OF SUCH DAMAGE.
32 *
1/*
2 * Copyright (c) 2001 Wind River Systems
3 * Copyright (c) 1997, 1998, 1999, 2000, 2001
4 * Bill Paul <wpaul@bsdi.com>. All rights reserved.
5 *
6 * Redistribution and use in source and binary forms, with or without
7 * modification, are permitted provided that the following conditions
8 * are met:

--- 16 unchanged lines hidden (view full) ---

25 * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
26 * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
27 * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
28 * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
29 * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
30 * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF
31 * THE POSSIBILITY OF SUCH DAMAGE.
32 *
33 * $FreeBSD: head/sys/dev/nge/if_nge.c 95673 2002-04-28 20:34:20Z phk $
33 * $FreeBSD: head/sys/dev/nge/if_nge.c 95718 2002-04-29 11:57:30Z phk $
34 */
35
36/*
37 * National Semiconductor DP83820/DP83821 gigabit ethernet driver
38 * for FreeBSD. Datasheets are available from:
39 *
40 * http://www.national.com/ds/DP/DP83820.pdf
41 * http://www.national.com/ds/DP/DP83821.pdf

--- 85 unchanged lines hidden (view full) ---

127
128MODULE_DEPEND(nge, miibus, 1, 1, 1);
129
130/* "controller miibus0" required. See GENERIC if you get errors here. */
131#include "miibus_if.h"
132
133#ifndef lint
134static const char rcsid[] =
34 */
35
36/*
37 * National Semiconductor DP83820/DP83821 gigabit ethernet driver
38 * for FreeBSD. Datasheets are available from:
39 *
40 * http://www.national.com/ds/DP/DP83820.pdf
41 * http://www.national.com/ds/DP/DP83821.pdf

--- 85 unchanged lines hidden (view full) ---

127
128MODULE_DEPEND(nge, miibus, 1, 1, 1);
129
130/* "controller miibus0" required. See GENERIC if you get errors here. */
131#include "miibus_if.h"
132
133#ifndef lint
134static const char rcsid[] =
135 "$FreeBSD: head/sys/dev/nge/if_nge.c 95673 2002-04-28 20:34:20Z phk $";
135 "$FreeBSD: head/sys/dev/nge/if_nge.c 95718 2002-04-29 11:57:30Z phk $";
136#endif
137
138#define NGE_CSUM_FEATURES (CSUM_IP | CSUM_TCP | CSUM_UDP)
139
140/*
141 * Various supported device vendors/types and their names.
142 */
143static struct nge_type nge_devs[] = {

--- 1831 unchanged lines hidden (view full) ---

1975 * Isolate/power down the PHY, but leave the media selection
1976 * unchanged so that things will be put back to normal when
1977 * we bring the interface back up.
1978 */
1979 itmp = ifp->if_flags;
1980 ifp->if_flags |= IFF_UP;
1981 ifm = mii->mii_media.ifm_cur;
1982 mtmp = ifm->ifm_media;
136#endif
137
138#define NGE_CSUM_FEATURES (CSUM_IP | CSUM_TCP | CSUM_UDP)
139
140/*
141 * Various supported device vendors/types and their names.
142 */
143static struct nge_type nge_devs[] = {

--- 1831 unchanged lines hidden (view full) ---

1975 * Isolate/power down the PHY, but leave the media selection
1976 * unchanged so that things will be put back to normal when
1977 * we bring the interface back up.
1978 */
1979 itmp = ifp->if_flags;
1980 ifp->if_flags |= IFF_UP;
1981 ifm = mii->mii_media.ifm_cur;
1982 mtmp = ifm->ifm_media;
1983 ifm->ifm_media = IFM_ETHER|IFM_NONE;
1983#if 0
1984 ifm->ifm_media = IFM_ETHER|IFM_AUTO;
1984 mii_mediachg(mii);
1985 ifm->ifm_media = mtmp;
1986 ifp->if_flags = itmp;
1985 mii_mediachg(mii);
1986 ifm->ifm_media = mtmp;
1987 ifp->if_flags = itmp;
1988#endif
1987
1988 sc->nge_link = 0;
1989
1990 /*
1991 * Free data in the RX lists.
1992 */
1993 for (i = 0; i < NGE_RX_LIST_CNT; i++) {
1994 if (sc->nge_ldata->nge_rx_list[i].nge_mbuf != NULL) {

--- 41 unchanged lines hidden ---
1989
1990 sc->nge_link = 0;
1991
1992 /*
1993 * Free data in the RX lists.
1994 */
1995 for (i = 0; i < NGE_RX_LIST_CNT; i++) {
1996 if (sc->nge_ldata->nge_rx_list[i].nge_mbuf != NULL) {

--- 41 unchanged lines hidden ---