1/*- 2 * Copyright (c) 2001 Wind River Systems 3 * Copyright (c) 1997, 1998, 1999, 2001 4 * Bill Paul <wpaul@windriver.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: --- 18 unchanged lines hidden (view full) --- 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 34#include <sys/cdefs.h> |
35__FBSDID("$FreeBSD: head/sys/dev/bge/if_bge.c 230337 2012-01-19 20:21:59Z yongari $"); |
36 37/* 38 * Broadcom BCM570x family gigabit ethernet driver for FreeBSD. 39 * 40 * The Broadcom BCM5700 is based on technology originally developed by 41 * Alteon Networks as part of the Tigon I and Tigon II gigabit ethernet 42 * MAC chips. The BCM5700, sometimes referred to as the Tigon III, has 43 * two on-board MIPS R4000 CPUs and can have as much as 16MB of external --- 2696 unchanged lines hidden (view full) --- 2740/* 2741 * Return true if MSI can be used with this device. 2742 */ 2743static int 2744bge_can_use_msi(struct bge_softc *sc) 2745{ 2746 int can_use_msi = 0; 2747 |
2748 if (sc->bge_msi != 0) |
2749 return (0); 2750 2751 /* Disable MSI for polling(4). */ 2752#ifdef DEVICE_POLLING 2753 return (0); 2754#endif 2755 switch (sc->bge_asicrev) { 2756 case BGE_ASICREV_BCM5714_A0: --- 2868 unchanged lines hidden (view full) --- 5625 sc->bge_forced_collapse = 0; 5626 snprintf(tn, sizeof(tn), "dev.bge.%d.forced_collapse", unit); 5627 TUNABLE_INT_FETCH(tn, &sc->bge_forced_collapse); 5628 SYSCTL_ADD_INT(ctx, children, OID_AUTO, "forced_collapse", 5629 CTLFLAG_RW, &sc->bge_forced_collapse, 0, 5630 "Number of fragmented TX buffers of a frame allowed before " 5631 "forced collapsing"); 5632 |
5633 sc->bge_msi = 1; 5634 snprintf(tn, sizeof(tn), "dev.bge.%d.msi", unit); 5635 TUNABLE_INT_FETCH(tn, &sc->bge_msi); 5636 SYSCTL_ADD_INT(ctx, children, OID_AUTO, "msi", 5637 CTLFLAG_RD, &sc->bge_msi, 0, "Enable MSI"); |
5638 5639 /* 5640 * It seems all Broadcom controllers have a bug that can generate UDP 5641 * datagrams with checksum value 0 when TX UDP checksum offloading is 5642 * enabled. Generating UDP checksum value 0 is RFC 768 violation. 5643 * Even though the probability of generating such UDP datagrams is 5644 * low, I don't want to see FreeBSD boxes to inject such datagrams 5645 * into network so disable UDP checksum offloading by default. Users --- 454 unchanged lines hidden --- |