if_bgereg.h (106937) | if_bgereg.h (108847) |
---|---|
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: --- 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, 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: --- 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/bge/if_bgereg.h 106937 2002-11-14 23:54:55Z sam $ | 33 * $FreeBSD: head/sys/dev/bge/if_bgereg.h 108847 2003-01-06 23:46:47Z jdp $ |
34 */ 35 36/* 37 * BCM570x memory map. The internal memory layout varies somewhat 38 * depending on whether or not we have external SSRAM attached. 39 * The BCM5700 can have up to 16MB of external memory. The BCM5701 40 * is apparently not designed to use external SSRAM. The mappings 41 * up to the first 4 send rings are the same for both internal and --- 1629 unchanged lines hidden (view full) --- 1671 * code from running. 1672 */ 1673#define BGE_MAGIC_NUMBER 0x4B657654 1674 1675typedef struct { 1676 u_int32_t bge_addr_hi; 1677 u_int32_t bge_addr_lo; 1678} bge_hostaddr; | 34 */ 35 36/* 37 * BCM570x memory map. The internal memory layout varies somewhat 38 * depending on whether or not we have external SSRAM attached. 39 * The BCM5700 can have up to 16MB of external memory. The BCM5701 40 * is apparently not designed to use external SSRAM. The mappings 41 * up to the first 4 send rings are the same for both internal and --- 1629 unchanged lines hidden (view full) --- 1671 * code from running. 1672 */ 1673#define BGE_MAGIC_NUMBER 0x4B657654 1674 1675typedef struct { 1676 u_int32_t bge_addr_hi; 1677 u_int32_t bge_addr_lo; 1678} bge_hostaddr; |
1679#define BGE_HOSTADDR(x) x.bge_addr_lo | 1679#define BGE_HOSTADDR(x) ((x).bge_addr_lo) |
1680 1681/* Ring control block structure */ 1682struct bge_rcb { 1683 bge_hostaddr bge_hostaddr; | 1680 1681/* Ring control block structure */ 1682struct bge_rcb { 1683 bge_hostaddr bge_hostaddr; |
1684 u_int16_t bge_flags; 1685 u_int16_t bge_max_len; | 1684 u_int32_t bge_maxlen_flags; |
1686 u_int32_t bge_nicaddr; 1687}; | 1685 u_int32_t bge_nicaddr; 1686}; |
1687#define BGE_RCB_MAXLEN_FLAGS(maxlen, flags) ((maxlen) << 16 | (flags)) |
|
1688 | 1688 |
1689struct bge_rcb_opaque { 1690 u_int32_t bge_reg0; 1691 u_int32_t bge_reg1; 1692 u_int32_t bge_reg2; 1693 u_int32_t bge_reg3; 1694}; 1695 | |
1696#define BGE_RCB_FLAG_USE_EXT_RX_BD 0x0001 1697#define BGE_RCB_FLAG_RING_DISABLED 0x0002 1698 1699struct bge_tx_bd { 1700 bge_hostaddr bge_addr; 1701 u_int16_t bge_flags; 1702 u_int16_t bge_len; 1703 u_int16_t bge_vlan_tag; --- 454 unchanged lines hidden --- | 1689#define BGE_RCB_FLAG_USE_EXT_RX_BD 0x0001 1690#define BGE_RCB_FLAG_RING_DISABLED 0x0002 1691 1692struct bge_tx_bd { 1693 bge_hostaddr bge_addr; 1694 u_int16_t bge_flags; 1695 u_int16_t bge_len; 1696 u_int16_t bge_vlan_tag; --- 454 unchanged lines hidden --- |