DP8390 network interface definitions. More...
#include "../../structures/packet/packet.h"
#include "dp8390_port.h"
#include "local.h"
Data Structures | |
struct | dp_rcvhdr |
Type definition of the receive header. More... | |
struct | iovec_dat |
struct | dpeth |
struct | dpeth::sendq |
Defines | |
#define | DP8390_IO_SIZE 0x01f |
Input/output size. | |
#define | DP_CR 0x0 |
#define | DP_CLDA0 0x1 |
#define | DP_CLDA1 0x2 |
#define | DP_BNRY 0x3 |
#define | DP_TSR 0x4 |
#define | DP_NCR 0x5 |
#define | DP_FIFO 0x6 |
#define | DP_ISR 0x7 |
#define | DP_CRDA0 0x8 |
#define | DP_CRDA1 0x9 |
#define | DP_DUM1 0xA |
#define | DP_DUM2 0xB |
#define | DP_RSR 0xC |
#define | DP_CNTR0 0xD |
#define | DP_CNTR1 0xE |
#define | DP_CNTR2 0xF |
#define | DP_CR 0x0 |
#define | DP_PSTART 0x1 |
#define | DP_PSTOP 0x2 |
#define | DP_BNRY 0x3 |
#define | DP_TPSR 0x4 |
#define | DP_TBCR0 0x5 |
#define | DP_TBCR1 0x6 |
#define | DP_ISR 0x7 |
#define | DP_RSAR0 0x8 |
#define | DP_RSAR1 0x9 |
#define | DP_RBCR0 0xA |
#define | DP_RBCR1 0xB |
#define | DP_RCR 0xC |
#define | DP_TCR 0xD |
#define | DP_DCR 0xE |
#define | DP_IMR 0xF |
#define | DP_CR 0x0 |
#define | DP_PAR0 0x1 |
#define | DP_PAR1 0x2 |
#define | DP_PAR2 0x3 |
#define | DP_PAR3 0x4 |
#define | DP_PAR4 0x5 |
#define | DP_PAR5 0x6 |
#define | DP_CURR 0x7 |
#define | DP_MAR0 0x8 |
#define | DP_MAR1 0x9 |
#define | DP_MAR2 0xA |
#define | DP_MAR3 0xB |
#define | DP_MAR4 0xC |
#define | DP_MAR5 0xD |
#define | DP_MAR6 0xE |
#define | DP_MAR7 0xF |
#define | CR_STP 0x01 |
#define | CR_STA 0x02 |
#define | CR_TXP 0x04 |
#define | CR_DMA 0x38 |
#define | CR_DM_NOP 0x00 |
#define | CR_DM_RR 0x08 |
#define | CR_DM_RW 0x10 |
#define | CR_DM_SP 0x18 |
#define | CR_DM_ABORT 0x20 |
#define | CR_PS 0xC0 |
#define | CR_PS_P0 0x00 |
#define | CR_PS_P1 0x40 |
#define | CR_PS_P2 0x80 |
#define | CR_PS_T1 0xC0 |
#define | ISR_PRX 0x01 |
#define | ISR_PTX 0x02 |
#define | ISR_RXE 0x04 |
#define | ISR_TXE 0x08 |
#define | ISR_OVW 0x10 |
#define | ISR_CNT 0x20 |
#define | ISR_RDC 0x40 |
#define | ISR_RST 0x80 |
#define | IMR_PRXE 0x01 |
#define | IMR_PTXE 0x02 |
#define | IMR_RXEE 0x04 |
#define | IMR_TXEE 0x08 |
#define | IMR_OVWE 0x10 |
#define | IMR_CNTE 0x20 |
#define | IMR_RDCE 0x40 |
#define | DCR_WTS 0x01 |
#define | DCR_BYTEWIDE 0x00 |
#define | DCR_WORDWIDE 0x01 |
#define | DCR_BOS 0x02 |
#define | DCR_LTLENDIAN 0x00 |
#define | DCR_BIGENDIAN 0x02 |
#define | DCR_LAS 0x04 |
#define | DCR_BMS 0x08 |
#define | DCR_AR 0x10 |
#define | DCR_FTS 0x60 |
#define | DCR_2BYTES 0x00 |
#define | DCR_4BYTES 0x40 |
#define | DCR_8BYTES 0x20 |
#define | DCR_12BYTES 0x60 |
#define | TCR_CRC 0x01 |
#define | TCR_ELC 0x06 |
#define | TCR_NORMAL 0x00 |
#define | TCR_INTERNAL 0x02 |
#define | TCR_0EXTERNAL 0x04 |
#define | TCR_1EXTERNAL 0x06 |
#define | TCR_ATD 0x08 |
#define | TCR_OFST 0x10 |
#define | TSR_PTX 0x01 |
#define | TSR_DFR 0x02 |
#define | TSR_COL 0x04 |
#define | TSR_ABT 0x08 |
#define | TSR_CRS 0x10 |
#define | TSR_FU 0x20 |
#define | TSR_CDH 0x40 |
#define | TSR_OWC 0x80 |
#define | RCR_SEP 0x01 |
#define | RCR_AR 0x02 |
#define | RCR_AB 0x04 |
#define | RCR_AM 0x08 |
#define | RCR_PRO 0x10 |
#define | RCR_MON 0x20 |
#define | RSR_PRX 0x01 |
#define | RSR_CRC 0x02 |
#define | RSR_FAE 0x04 |
#define | RSR_FO 0x08 |
#define | RSR_MPA 0x10 |
#define | RSR_PHY 0x20 |
#define | RSR_DIS 0x40 |
#define | RSR_DFR 0x80 |
#define | DP_PAGESIZE 256 |
Page size. | |
#define | inb_reg0(dep, reg) (inb(dep->de_dp8390_port+reg)) |
Reads 1 byte from the zero page register. | |
#define | outb_reg0(dep, reg, data) (outb(dep->de_dp8390_port+reg, data)) |
Writes 1 byte zero page register. | |
#define | inb_reg1(dep, reg) (inb(dep->de_dp8390_port+reg)) |
Reads 1 byte from the first page register. | |
#define | outb_reg1(dep, reg, data) (outb(dep->de_dp8390_port+reg, data)) |
Writes 1 byte first page register. | |
#define | IOVEC_NR 1 |
#define | SENDQ_NR 1 |
#define | SENDQ_PAGES 6 |
#define | MAX_PACKETS 4 |
Maximum number of waiting packets to be sent or received. | |
#define | DEI_DEFAULT 0x8000 |
#define | DEF_EMPTY 0x000 |
#define | DEF_PACK_SEND 0x001 |
#define | DEF_PACK_RECV 0x002 |
#define | DEF_SEND_AVAIL 0x004 |
#define | DEF_READING 0x010 |
#define | DEF_PROMISC 0x040 |
#define | DEF_MULTI 0x080 |
#define | DEF_BROAD 0x100 |
#define | DEF_ENABLED 0x200 |
#define | DEF_STOPPED 0x400 |
#define | DEM_DISABLED 0x0 |
#define | DEM_SINK 0x1 |
#define | DEM_ENABLED 0x2 |
#define | debug 1 |
Typedefs | |
typedef struct dp_rcvhdr | dp_rcvhdr_t |
Type definition of the receive header. | |
typedef struct iovec_dat | iovec_dat_t |
typedef struct dpeth | dpeth_t |
Functions | |
_PROTOTYPE (typedef void(*dp_initf_t),(struct dpeth *dep)) | |
_PROTOTYPE (typedef void(*dp_user2nicf_t),(struct dpeth *dep, struct iovec_dat *iovp, vir_bytes offset, int nic_addr, vir_bytes count)) | |
_PROTOTYPE (typedef void(*dp_nic2userf_t),(struct dpeth *dep, int nic_addr, struct iovec_dat *iovp, vir_bytes offset, vir_bytes count)) | |
_PROTOTYPE (typedef void(*dp_getblock_t),(struct dpeth *dep, int page, size_t offset, size_t size, void *dst)) |
DP8390 network interface definitions.