iPXE
Data Structures | Defines | Typedefs | Enumerations | Functions
phantom.h File Reference

NetXen Phantom NICs. More...

#include <stdint.h>
#include "nx_bitops.h"
#include "phantom_hw.h"
#include "nxhal_nic_interface.h"

Go to the source code of this file.

Data Structures

struct  phantom_rds
struct  phantom_sds
union  phantom_cds

Defines

#define NXHAL_VERSION   1
#define UNM_DMA_BUFFER_ALIGN   16
 DMA buffer alignment.
#define __unm_dma_aligned   __attribute__ (( aligned ( UNM_DMA_BUFFER_ALIGN ) ))
 Mark structure as DMA-aligned.
#define UNM_128M_CRB_WINDOW   0x6110210UL
#define UNM_32M_CRB_WINDOW   0x0110210UL
#define UNM_2M_CRB_WINDOW   0x0130060UL
#define UNM_CRB_BASE(blk)   ( (blk) << 20 )
#define UNM_CRB_BLK(reg)   ( (reg) >> 20 )
#define UNM_CRB_OFFSET(reg)   ( (reg) & 0x000fffff )
#define UNM_CRB_PCIE   UNM_CRB_BASE ( UNM_CRB_BLK_PCIE )
#define UNM_PCIE_SEM2_LOCK   ( UNM_CRB_PCIE + 0x1c010 )
#define UNM_PCIE_SEM2_UNLOCK   ( UNM_CRB_PCIE + 0x1c014 )
#define UNM_PCIE_IRQ_VECTOR   ( UNM_CRB_PCIE + 0x10100 )
#define UNM_PCIE_IRQ_VECTOR_BIT(n)   ( 1 << ( (n) + 7 ) )
#define UNM_PCIE_IRQ_STATE   ( UNM_CRB_PCIE + 0x1206c )
#define UNM_PCIE_IRQ_STATE_TRIGGERED(state)   (( (state) & 0x300 ) == 0x200 )
#define UNM_PCIE_IRQ_MASK_F0   ( UNM_CRB_PCIE + 0x10128 )
#define UNM_PCIE_IRQ_MASK_F1   ( UNM_CRB_PCIE + 0x10170 )
#define UNM_PCIE_IRQ_MASK_F2   ( UNM_CRB_PCIE + 0x10174 )
#define UNM_PCIE_IRQ_MASK_F3   ( UNM_CRB_PCIE + 0x10178 )
#define UNM_PCIE_IRQ_MASK_F4   ( UNM_CRB_PCIE + 0x10370 )
#define UNM_PCIE_IRQ_MASK_F5   ( UNM_CRB_PCIE + 0x10374 )
#define UNM_PCIE_IRQ_MASK_F6   ( UNM_CRB_PCIE + 0x10378 )
#define UNM_PCIE_IRQ_MASK_F7   ( UNM_CRB_PCIE + 0x1037c )
#define UNM_PCIE_IRQ_MASK_MAGIC   0x0000fbffUL
#define UNM_PCIE_IRQ_STATUS_F0   ( UNM_CRB_PCIE + 0x10118 )
#define UNM_PCIE_IRQ_STATUS_F1   ( UNM_CRB_PCIE + 0x10160 )
#define UNM_PCIE_IRQ_STATUS_F2   ( UNM_CRB_PCIE + 0x10164 )
#define UNM_PCIE_IRQ_STATUS_F3   ( UNM_CRB_PCIE + 0x10168 )
#define UNM_PCIE_IRQ_STATUS_F4   ( UNM_CRB_PCIE + 0x10360 )
#define UNM_PCIE_IRQ_STATUS_F5   ( UNM_CRB_PCIE + 0x10364 )
#define UNM_PCIE_IRQ_STATUS_F6   ( UNM_CRB_PCIE + 0x10368 )
#define UNM_PCIE_IRQ_STATUS_F7   ( UNM_CRB_PCIE + 0x1036c )
#define UNM_PCIE_IRQ_STATUS_MAGIC   0xffffffffUL
#define UNM_CRB_CAM   UNM_CRB_BASE ( UNM_CRB_BLK_CAM )
#define UNM_CAM_RAM   ( UNM_CRB_CAM + 0x02000 )
#define UNM_CAM_RAM_PORT_MODE   ( UNM_CAM_RAM + 0x00024 )
#define UNM_CAM_RAM_PORT_MODE_AUTO_NEG   4
#define UNM_CAM_RAM_PORT_MODE_AUTO_NEG_1G   5
#define UNM_CAM_RAM_DMESG_HEAD(n)   ( UNM_CAM_RAM + 0x00030 + (n) * 0x10 )
#define UNM_CAM_RAM_DMESG_LEN(n)   ( UNM_CAM_RAM + 0x00034 + (n) * 0x10 )
#define UNM_CAM_RAM_DMESG_TAIL(n)   ( UNM_CAM_RAM + 0x00038 + (n) * 0x10 )
#define UNM_CAM_RAM_DMESG_SIG(n)   ( UNM_CAM_RAM + 0x0003c + (n) * 0x10 )
#define UNM_CAM_RAM_DMESG_SIG_MAGIC   0xcafebabeUL
#define UNM_CAM_RAM_NUM_DMESG_BUFFERS   5
#define UNM_CAM_RAM_CLP_COMMAND   ( UNM_CAM_RAM + 0x000c0 )
#define UNM_CAM_RAM_CLP_COMMAND_LAST   0x00000080UL
#define UNM_CAM_RAM_CLP_DATA_LO   ( UNM_CAM_RAM + 0x000c4 )
#define UNM_CAM_RAM_CLP_DATA_HI   ( UNM_CAM_RAM + 0x000c8 )
#define UNM_CAM_RAM_CLP_STATUS   ( UNM_CAM_RAM + 0x000cc )
#define UNM_CAM_RAM_CLP_STATUS_START   0x00000001UL
#define UNM_CAM_RAM_CLP_STATUS_DONE   0x00000002UL
#define UNM_CAM_RAM_CLP_STATUS_ERROR   0x0000ff00UL
#define UNM_CAM_RAM_CLP_STATUS_UNINITIALISED   0xffffffffUL
#define UNM_CAM_RAM_BOOT_ENABLE   ( UNM_CAM_RAM + 0x000fc )
#define UNM_CAM_RAM_WOL_PORT_MODE   ( UNM_CAM_RAM + 0x00198 )
#define UNM_CAM_RAM_MAC_ADDRS   ( UNM_CAM_RAM + 0x001c0 )
#define UNM_CAM_RAM_COLD_BOOT   ( UNM_CAM_RAM + 0x001fc )
#define UNM_CAM_RAM_COLD_BOOT_MAGIC   0x55555555UL
#define UNM_NIC_REG   ( UNM_CRB_CAM + 0x02200 )
#define UNM_NIC_REG_NX_CDRP   ( UNM_NIC_REG + 0x00018 )
#define UNM_NIC_REG_NX_ARG1   ( UNM_NIC_REG + 0x0001c )
#define UNM_NIC_REG_NX_ARG2   ( UNM_NIC_REG + 0x00020 )
#define UNM_NIC_REG_NX_ARG3   ( UNM_NIC_REG + 0x00024 )
#define UNM_NIC_REG_NX_SIGN   ( UNM_NIC_REG + 0x00028 )
#define UNM_NIC_REG_DUMMY_BUF_ADDR_HI   ( UNM_NIC_REG + 0x0003c )
#define UNM_NIC_REG_DUMMY_BUF_ADDR_LO   ( UNM_NIC_REG + 0x00040 )
#define UNM_NIC_REG_CMDPEG_STATE   ( UNM_NIC_REG + 0x00050 )
#define UNM_NIC_REG_CMDPEG_STATE_INITIALIZED   0xff01
#define UNM_NIC_REG_CMDPEG_STATE_INITIALIZE_ACK   0xf00f
#define UNM_NIC_REG_DUMMY_BUF   ( UNM_NIC_REG + 0x000fc )
#define UNM_NIC_REG_DUMMY_BUF_INIT   0
#define UNM_NIC_REG_XG_STATE_P3   ( UNM_NIC_REG + 0x00098 )
#define UNM_NIC_REG_XG_STATE_P3_LINK(port, state_p3)   ( ( (state_p3) >> ( (port) * 4 ) ) & 0x0f )
#define UNM_NIC_REG_XG_STATE_P3_LINK_UP   0x01
#define UNM_NIC_REG_XG_STATE_P3_LINK_DOWN   0x02
#define UNM_NIC_REG_RCVPEG_STATE   ( UNM_NIC_REG + 0x0013c )
#define UNM_NIC_REG_RCVPEG_STATE_INITIALIZED   0xff01
#define UNM_CRB_ROMUSB   UNM_CRB_BASE ( UNM_CRB_BLK_ROMUSB )
#define UNM_ROMUSB_GLB   ( UNM_CRB_ROMUSB + 0x00000 )
#define UNM_ROMUSB_GLB_STATUS   ( UNM_ROMUSB_GLB + 0x00004 )
#define UNM_ROMUSB_GLB_STATUS_ROM_DONE   ( 1 << 1 )
#define UNM_ROMUSB_GLB_SW_RESET   ( UNM_ROMUSB_GLB + 0x00008 )
#define UNM_ROMUSB_GLB_SW_RESET_MAGIC   0x0080000fUL
#define UNM_ROMUSB_GLB_PEGTUNE_DONE   ( UNM_ROMUSB_GLB + 0x0005c )
#define UNM_ROMUSB_GLB_PEGTUNE_DONE_MAGIC   0x31
#define UNM_ROMUSB_ROM   ( UNM_CRB_ROMUSB + 0x10000 )
#define UNM_ROMUSB_ROM_INSTR_OPCODE   ( UNM_ROMUSB_ROM + 0x00004 )
#define UNM_ROMUSB_ROM_ADDRESS   ( UNM_ROMUSB_ROM + 0x00008 )
#define UNM_ROMUSB_ROM_WDATA   ( UNM_ROMUSB_ROM + 0x0000c )
#define UNM_ROMUSB_ROM_ABYTE_CNT   ( UNM_ROMUSB_ROM + 0x00010 )
#define UNM_ROMUSB_ROM_DUMMY_BYTE_CNT   ( UNM_ROMUSB_ROM + 0x00014 )
#define UNM_ROMUSB_ROM_RDATA   ( UNM_ROMUSB_ROM + 0x00018 )
#define UNM_CRB_TEST   UNM_CRB_BASE ( UNM_CRB_BLK_TEST )
#define UNM_TEST_CONTROL   ( UNM_CRB_TEST + 0x00090 )
#define UNM_TEST_CONTROL_START   0x01
#define UNM_TEST_CONTROL_ENABLE   0x02
#define UNM_TEST_CONTROL_BUSY   0x08
#define UNM_TEST_ADDR_LO   ( UNM_CRB_TEST + 0x00094 )
#define UNM_TEST_ADDR_HI   ( UNM_CRB_TEST + 0x00098 )
#define UNM_TEST_RDDATA_LO   ( UNM_CRB_TEST + 0x000a8 )
#define UNM_TEST_RDDATA_HI   ( UNM_CRB_TEST + 0x000ac )
#define UNM_CRB_PEG_0   UNM_CRB_BASE ( UNM_CRB_BLK_PEG_0 )
#define UNM_PEG_0_HALT_STATUS   ( UNM_CRB_PEG_0 + 0x00030 )
#define UNM_PEG_0_HALT   ( UNM_CRB_PEG_0 + 0x0003c )
#define UNM_CRB_PEG_1   UNM_CRB_BASE ( UNM_CRB_BLK_PEG_1 )
#define UNM_PEG_1_HALT_STATUS   ( UNM_CRB_PEG_1 + 0x00030 )
#define UNM_PEG_1_HALT   ( UNM_CRB_PEG_1 + 0x0003c )
#define UNM_CRB_PEG_2   UNM_CRB_BASE ( UNM_CRB_BLK_PEG_2 )
#define UNM_PEG_2_HALT_STATUS   ( UNM_CRB_PEG_2 + 0x00030 )
#define UNM_PEG_2_HALT   ( UNM_CRB_PEG_2 + 0x0003c )
#define UNM_CRB_PEG_3   UNM_CRB_BASE ( UNM_CRB_BLK_PEG_3 )
#define UNM_PEG_3_HALT_STATUS   ( UNM_CRB_PEG_3 + 0x00030 )
#define UNM_PEG_3_HALT   ( UNM_CRB_PEG_3 + 0x0003c )
#define UNM_CRB_PEG_4   UNM_CRB_BASE ( UNM_CRB_BLK_PEG_4 )
#define UNM_PEG_4_HALT_STATUS   ( UNM_CRB_PEG_4 + 0x00030 )
#define UNM_PEG_4_HALT   ( UNM_CRB_PEG_4 + 0x0003c )

Typedefs

typedef uint8_t U8
typedef uint16_t U16
typedef uint32_t U32
typedef uint64_t U64
typedef uint32_t nx_rcode_t

Enumerations

enum  unm_reg_blocks {
  UNM_CRB_BLK_PCIE = 0x01, UNM_CRB_BLK_CAM = 0x22, UNM_CRB_BLK_ROMUSB = 0x33, UNM_CRB_BLK_TEST = 0x02,
  UNM_CRB_BLK_PEG_0 = 0x11, UNM_CRB_BLK_PEG_1 = 0x12, UNM_CRB_BLK_PEG_2 = 0x13, UNM_CRB_BLK_PEG_3 = 0x14,
  UNM_CRB_BLK_PEG_4 = 0x0f
}
 Phantom register blocks. More...

Functions

 FILE_LICENCE (GPL2_OR_LATER_OR_UBDL)

Detailed Description

NetXen Phantom NICs.

Definition in file phantom.h.


Define Documentation

#define NXHAL_VERSION   1

Definition at line 52 of file phantom.h.

Referenced by phantom_issue_cmd().

#define UNM_DMA_BUFFER_ALIGN   16

DMA buffer alignment.

Definition at line 56 of file phantom.h.

Referenced by phantom_create_rx_ctx(), phantom_create_tx_ctx(), and phantom_open().

#define __unm_dma_aligned   __attribute__ (( aligned ( UNM_DMA_BUFFER_ALIGN ) ))

Mark structure as DMA-aligned.

Definition at line 59 of file phantom.h.

#define UNM_128M_CRB_WINDOW   0x6110210UL

Definition at line 67 of file phantom.h.

Referenced by phantom_crb_access_128m().

#define UNM_32M_CRB_WINDOW   0x0110210UL

Definition at line 68 of file phantom.h.

Referenced by phantom_crb_access_32m().

#define UNM_2M_CRB_WINDOW   0x0130060UL

Definition at line 69 of file phantom.h.

Referenced by phantom_crb_access_2m().

#define UNM_CRB_BASE (   blk)    ( (blk) << 20 )

Definition at line 90 of file phantom.h.

#define UNM_CRB_BLK (   reg)    ( (reg) >> 20 )

Definition at line 91 of file phantom.h.

Referenced by phantom_crb_access_2m().

#define UNM_CRB_OFFSET (   reg)    ( (reg) & 0x000fffff )

Definition at line 92 of file phantom.h.

Referenced by phantom_crb_access_2m().

Definition at line 94 of file phantom.h.

#define UNM_PCIE_SEM2_LOCK   ( UNM_CRB_PCIE + 0x1c010 )

Definition at line 95 of file phantom.h.

#define UNM_PCIE_SEM2_UNLOCK   ( UNM_CRB_PCIE + 0x1c014 )

Definition at line 96 of file phantom.h.

#define UNM_PCIE_IRQ_VECTOR   ( UNM_CRB_PCIE + 0x10100 )

Definition at line 97 of file phantom.h.

Referenced by phantom_poll().

#define UNM_PCIE_IRQ_VECTOR_BIT (   n)    ( 1 << ( (n) + 7 ) )

Definition at line 98 of file phantom.h.

Referenced by phantom_poll().

#define UNM_PCIE_IRQ_STATE   ( UNM_CRB_PCIE + 0x1206c )

Definition at line 99 of file phantom.h.

Referenced by phantom_poll().

#define UNM_PCIE_IRQ_STATE_TRIGGERED (   state)    (( (state) & 0x300 ) == 0x200 )

Definition at line 100 of file phantom.h.

Referenced by phantom_poll().

#define UNM_PCIE_IRQ_MASK_F0   ( UNM_CRB_PCIE + 0x10128 )

Definition at line 101 of file phantom.h.

#define UNM_PCIE_IRQ_MASK_F1   ( UNM_CRB_PCIE + 0x10170 )

Definition at line 102 of file phantom.h.

#define UNM_PCIE_IRQ_MASK_F2   ( UNM_CRB_PCIE + 0x10174 )

Definition at line 103 of file phantom.h.

#define UNM_PCIE_IRQ_MASK_F3   ( UNM_CRB_PCIE + 0x10178 )

Definition at line 104 of file phantom.h.

#define UNM_PCIE_IRQ_MASK_F4   ( UNM_CRB_PCIE + 0x10370 )

Definition at line 105 of file phantom.h.

#define UNM_PCIE_IRQ_MASK_F5   ( UNM_CRB_PCIE + 0x10374 )

Definition at line 106 of file phantom.h.

#define UNM_PCIE_IRQ_MASK_F6   ( UNM_CRB_PCIE + 0x10378 )

Definition at line 107 of file phantom.h.

#define UNM_PCIE_IRQ_MASK_F7   ( UNM_CRB_PCIE + 0x1037c )

Definition at line 108 of file phantom.h.

#define UNM_PCIE_IRQ_MASK_MAGIC   0x0000fbffUL

Definition at line 109 of file phantom.h.

Referenced by phantom_irq().

#define UNM_PCIE_IRQ_STATUS_F0   ( UNM_CRB_PCIE + 0x10118 )

Definition at line 110 of file phantom.h.

#define UNM_PCIE_IRQ_STATUS_F1   ( UNM_CRB_PCIE + 0x10160 )

Definition at line 111 of file phantom.h.

#define UNM_PCIE_IRQ_STATUS_F2   ( UNM_CRB_PCIE + 0x10164 )

Definition at line 112 of file phantom.h.

#define UNM_PCIE_IRQ_STATUS_F3   ( UNM_CRB_PCIE + 0x10168 )

Definition at line 113 of file phantom.h.

#define UNM_PCIE_IRQ_STATUS_F4   ( UNM_CRB_PCIE + 0x10360 )

Definition at line 114 of file phantom.h.

#define UNM_PCIE_IRQ_STATUS_F5   ( UNM_CRB_PCIE + 0x10364 )

Definition at line 115 of file phantom.h.

#define UNM_PCIE_IRQ_STATUS_F6   ( UNM_CRB_PCIE + 0x10368 )

Definition at line 116 of file phantom.h.

#define UNM_PCIE_IRQ_STATUS_F7   ( UNM_CRB_PCIE + 0x1036c )

Definition at line 117 of file phantom.h.

#define UNM_PCIE_IRQ_STATUS_MAGIC   0xffffffffUL

Definition at line 118 of file phantom.h.

Referenced by phantom_poll().

Definition at line 120 of file phantom.h.

#define UNM_CAM_RAM   ( UNM_CRB_CAM + 0x02000 )

Definition at line 122 of file phantom.h.

Referenced by phantom_create_rx_ctx(), and phantom_create_tx_ctx().

#define UNM_CAM_RAM_PORT_MODE   ( UNM_CAM_RAM + 0x00024 )

Definition at line 123 of file phantom.h.

Definition at line 124 of file phantom.h.

Definition at line 125 of file phantom.h.

Referenced by phantom_init_cmdpeg().

#define UNM_CAM_RAM_DMESG_HEAD (   n)    ( UNM_CAM_RAM + 0x00030 + (n) * 0x10 )

Definition at line 126 of file phantom.h.

Referenced by phantom_dmesg().

#define UNM_CAM_RAM_DMESG_LEN (   n)    ( UNM_CAM_RAM + 0x00034 + (n) * 0x10 )

Definition at line 127 of file phantom.h.

#define UNM_CAM_RAM_DMESG_TAIL (   n)    ( UNM_CAM_RAM + 0x00038 + (n) * 0x10 )

Definition at line 128 of file phantom.h.

Referenced by phantom_dmesg().

#define UNM_CAM_RAM_DMESG_SIG (   n)    ( UNM_CAM_RAM + 0x0003c + (n) * 0x10 )

Definition at line 129 of file phantom.h.

Referenced by phantom_dmesg().

#define UNM_CAM_RAM_DMESG_SIG_MAGIC   0xcafebabeUL

Definition at line 130 of file phantom.h.

Referenced by phantom_dmesg().

Definition at line 131 of file phantom.h.

Referenced by phantom_dmesg_all().

#define UNM_CAM_RAM_CLP_COMMAND   ( UNM_CAM_RAM + 0x000c0 )

Definition at line 132 of file phantom.h.

Referenced by phantom_clp_cmd().

#define UNM_CAM_RAM_CLP_COMMAND_LAST   0x00000080UL

Definition at line 133 of file phantom.h.

#define UNM_CAM_RAM_CLP_DATA_LO   ( UNM_CAM_RAM + 0x000c4 )

Definition at line 134 of file phantom.h.

Referenced by phantom_clp_cmd().

#define UNM_CAM_RAM_CLP_DATA_HI   ( UNM_CAM_RAM + 0x000c8 )

Definition at line 135 of file phantom.h.

Referenced by phantom_clp_cmd().

#define UNM_CAM_RAM_CLP_STATUS   ( UNM_CAM_RAM + 0x000cc )

Definition at line 136 of file phantom.h.

Referenced by phantom_clp_cmd(), and phantom_clp_wait().

#define UNM_CAM_RAM_CLP_STATUS_START   0x00000001UL

Definition at line 137 of file phantom.h.

Referenced by phantom_clp_cmd().

#define UNM_CAM_RAM_CLP_STATUS_DONE   0x00000002UL

Definition at line 138 of file phantom.h.

Referenced by phantom_clp_wait().

#define UNM_CAM_RAM_CLP_STATUS_ERROR   0x0000ff00UL

Definition at line 139 of file phantom.h.

#define UNM_CAM_RAM_CLP_STATUS_UNINITIALISED   0xffffffffUL

Definition at line 140 of file phantom.h.

#define UNM_CAM_RAM_BOOT_ENABLE   ( UNM_CAM_RAM + 0x000fc )

Definition at line 141 of file phantom.h.

Referenced by phantom_check_boot_enable().

#define UNM_CAM_RAM_WOL_PORT_MODE   ( UNM_CAM_RAM + 0x00198 )

Definition at line 142 of file phantom.h.

Referenced by phantom_init_cmdpeg().

#define UNM_CAM_RAM_MAC_ADDRS   ( UNM_CAM_RAM + 0x001c0 )

Definition at line 143 of file phantom.h.

Referenced by phantom_get_macaddr().

#define UNM_CAM_RAM_COLD_BOOT   ( UNM_CAM_RAM + 0x001fc )

Definition at line 144 of file phantom.h.

Referenced by phantom_init_cmdpeg().

#define UNM_CAM_RAM_COLD_BOOT_MAGIC   0x55555555UL

Definition at line 145 of file phantom.h.

Referenced by phantom_init_cmdpeg().

#define UNM_NIC_REG   ( UNM_CRB_CAM + 0x02200 )

Definition at line 147 of file phantom.h.

#define UNM_NIC_REG_NX_CDRP   ( UNM_NIC_REG + 0x00018 )

Definition at line 148 of file phantom.h.

Referenced by phantom_issue_cmd(), and phantom_wait_for_cmd().

#define UNM_NIC_REG_NX_ARG1   ( UNM_NIC_REG + 0x0001c )

Definition at line 149 of file phantom.h.

Referenced by phantom_issue_cmd().

#define UNM_NIC_REG_NX_ARG2   ( UNM_NIC_REG + 0x00020 )

Definition at line 150 of file phantom.h.

Referenced by phantom_issue_cmd().

#define UNM_NIC_REG_NX_ARG3   ( UNM_NIC_REG + 0x00024 )

Definition at line 151 of file phantom.h.

Referenced by phantom_issue_cmd().

#define UNM_NIC_REG_NX_SIGN   ( UNM_NIC_REG + 0x00028 )

Definition at line 152 of file phantom.h.

Referenced by phantom_issue_cmd().

#define UNM_NIC_REG_DUMMY_BUF_ADDR_HI   ( UNM_NIC_REG + 0x0003c )

Definition at line 153 of file phantom.h.

Referenced by phantom_init_cmdpeg().

#define UNM_NIC_REG_DUMMY_BUF_ADDR_LO   ( UNM_NIC_REG + 0x00040 )

Definition at line 154 of file phantom.h.

Referenced by phantom_init_cmdpeg().

#define UNM_NIC_REG_CMDPEG_STATE   ( UNM_NIC_REG + 0x00050 )

Definition at line 155 of file phantom.h.

Referenced by phantom_init_cmdpeg().

Definition at line 156 of file phantom.h.

Referenced by phantom_init_cmdpeg().

Definition at line 157 of file phantom.h.

Referenced by phantom_init_cmdpeg().

#define UNM_NIC_REG_DUMMY_BUF   ( UNM_NIC_REG + 0x000fc )

Definition at line 158 of file phantom.h.

Referenced by phantom_init_cmdpeg().

Definition at line 159 of file phantom.h.

Referenced by phantom_init_cmdpeg().

#define UNM_NIC_REG_XG_STATE_P3   ( UNM_NIC_REG + 0x00098 )

Definition at line 160 of file phantom.h.

Referenced by phantom_poll_link_state().

#define UNM_NIC_REG_XG_STATE_P3_LINK (   port,
  state_p3 
)    ( ( (state_p3) >> ( (port) * 4 ) ) & 0x0f )

Definition at line 161 of file phantom.h.

Referenced by phantom_poll_link_state().

Definition at line 163 of file phantom.h.

Referenced by phantom_poll_link_state().

Definition at line 164 of file phantom.h.

Referenced by phantom_poll_link_state().

#define UNM_NIC_REG_RCVPEG_STATE   ( UNM_NIC_REG + 0x0013c )

Definition at line 165 of file phantom.h.

Referenced by phantom_init_rcvpeg().

Definition at line 166 of file phantom.h.

Referenced by phantom_init_rcvpeg().

Definition at line 168 of file phantom.h.

#define UNM_ROMUSB_GLB   ( UNM_CRB_ROMUSB + 0x00000 )

Definition at line 170 of file phantom.h.

#define UNM_ROMUSB_GLB_STATUS   ( UNM_ROMUSB_GLB + 0x00004 )

Definition at line 171 of file phantom.h.

#define UNM_ROMUSB_GLB_STATUS_ROM_DONE   ( 1 << 1 )

Definition at line 172 of file phantom.h.

#define UNM_ROMUSB_GLB_SW_RESET   ( UNM_ROMUSB_GLB + 0x00008 )

Definition at line 173 of file phantom.h.

Referenced by phantom_init_cmdpeg().

#define UNM_ROMUSB_GLB_SW_RESET_MAGIC   0x0080000fUL

Definition at line 174 of file phantom.h.

Referenced by phantom_init_cmdpeg().

#define UNM_ROMUSB_GLB_PEGTUNE_DONE   ( UNM_ROMUSB_GLB + 0x0005c )

Definition at line 175 of file phantom.h.

Referenced by phantom_init_cmdpeg().

Definition at line 176 of file phantom.h.

Referenced by phantom_init_cmdpeg().

#define UNM_ROMUSB_ROM   ( UNM_CRB_ROMUSB + 0x10000 )

Definition at line 178 of file phantom.h.

#define UNM_ROMUSB_ROM_INSTR_OPCODE   ( UNM_ROMUSB_ROM + 0x00004 )

Definition at line 179 of file phantom.h.

#define UNM_ROMUSB_ROM_ADDRESS   ( UNM_ROMUSB_ROM + 0x00008 )

Definition at line 180 of file phantom.h.

#define UNM_ROMUSB_ROM_WDATA   ( UNM_ROMUSB_ROM + 0x0000c )

Definition at line 181 of file phantom.h.

#define UNM_ROMUSB_ROM_ABYTE_CNT   ( UNM_ROMUSB_ROM + 0x00010 )

Definition at line 182 of file phantom.h.

#define UNM_ROMUSB_ROM_DUMMY_BYTE_CNT   ( UNM_ROMUSB_ROM + 0x00014 )

Definition at line 183 of file phantom.h.

#define UNM_ROMUSB_ROM_RDATA   ( UNM_ROMUSB_ROM + 0x00018 )

Definition at line 184 of file phantom.h.

Definition at line 186 of file phantom.h.

#define UNM_TEST_CONTROL   ( UNM_CRB_TEST + 0x00090 )

Definition at line 188 of file phantom.h.

Referenced by phantom_read_test_mem_block().

#define UNM_TEST_CONTROL_START   0x01

Definition at line 189 of file phantom.h.

Referenced by phantom_read_test_mem_block().

#define UNM_TEST_CONTROL_ENABLE   0x02

Definition at line 190 of file phantom.h.

Referenced by phantom_read_test_mem_block().

#define UNM_TEST_CONTROL_BUSY   0x08

Definition at line 191 of file phantom.h.

Referenced by phantom_read_test_mem_block().

#define UNM_TEST_ADDR_LO   ( UNM_CRB_TEST + 0x00094 )

Definition at line 192 of file phantom.h.

Referenced by phantom_read_test_mem_block().

#define UNM_TEST_ADDR_HI   ( UNM_CRB_TEST + 0x00098 )

Definition at line 193 of file phantom.h.

Referenced by phantom_read_test_mem_block().

#define UNM_TEST_RDDATA_LO   ( UNM_CRB_TEST + 0x000a8 )

Definition at line 194 of file phantom.h.

Referenced by phantom_read_test_mem_block().

#define UNM_TEST_RDDATA_HI   ( UNM_CRB_TEST + 0x000ac )

Definition at line 195 of file phantom.h.

Referenced by phantom_read_test_mem_block().

Definition at line 197 of file phantom.h.

#define UNM_PEG_0_HALT_STATUS   ( UNM_CRB_PEG_0 + 0x00030 )

Definition at line 198 of file phantom.h.

Referenced by phantom_unhalt_pegs().

#define UNM_PEG_0_HALT   ( UNM_CRB_PEG_0 + 0x0003c )

Definition at line 199 of file phantom.h.

Definition at line 201 of file phantom.h.

#define UNM_PEG_1_HALT_STATUS   ( UNM_CRB_PEG_1 + 0x00030 )

Definition at line 202 of file phantom.h.

Referenced by phantom_unhalt_pegs().

#define UNM_PEG_1_HALT   ( UNM_CRB_PEG_1 + 0x0003c )

Definition at line 203 of file phantom.h.

Definition at line 205 of file phantom.h.

#define UNM_PEG_2_HALT_STATUS   ( UNM_CRB_PEG_2 + 0x00030 )

Definition at line 206 of file phantom.h.

Referenced by phantom_unhalt_pegs().

#define UNM_PEG_2_HALT   ( UNM_CRB_PEG_2 + 0x0003c )

Definition at line 207 of file phantom.h.

Definition at line 209 of file phantom.h.

#define UNM_PEG_3_HALT_STATUS   ( UNM_CRB_PEG_3 + 0x00030 )

Definition at line 210 of file phantom.h.

Referenced by phantom_unhalt_pegs().

#define UNM_PEG_3_HALT   ( UNM_CRB_PEG_3 + 0x0003c )

Definition at line 211 of file phantom.h.

Definition at line 213 of file phantom.h.

#define UNM_PEG_4_HALT_STATUS   ( UNM_CRB_PEG_4 + 0x00030 )

Definition at line 214 of file phantom.h.

Referenced by phantom_unhalt_pegs().

#define UNM_PEG_4_HALT   ( UNM_CRB_PEG_4 + 0x0003c )

Definition at line 215 of file phantom.h.


Typedef Documentation

typedef uint8_t U8

Definition at line 47 of file phantom.h.

typedef uint16_t U16

Definition at line 48 of file phantom.h.

typedef uint32_t U32

Definition at line 49 of file phantom.h.

typedef uint64_t U64

Definition at line 50 of file phantom.h.

Definition at line 51 of file phantom.h.


Enumeration Type Documentation

Phantom register blocks.

The upper address bits vary between cards. We define an abstract address space in which the upper 8 bits of the 32-bit register address encode the register block. This gets translated to a bus address by the phantom_crb_access_xxx() methods.

Enumerator:
UNM_CRB_BLK_PCIE 
UNM_CRB_BLK_CAM 
UNM_CRB_BLK_ROMUSB 
UNM_CRB_BLK_TEST 
UNM_CRB_BLK_PEG_0 
UNM_CRB_BLK_PEG_1 
UNM_CRB_BLK_PEG_2 
UNM_CRB_BLK_PEG_3 
UNM_CRB_BLK_PEG_4 

Definition at line 79 of file phantom.h.


Function Documentation

FILE_LICENCE ( GPL2_OR_LATER_OR_UBDL  )