#ifndef _CHIP_H
#define _CHIP_H
#define BITS_PER_REGISTER …
#define NUM_INTERRUPT_SOURCES …
#define RXE_NUM_CONTEXTS …
#define RXE_PER_CONTEXT_SIZE …
#define RXE_NUM_TID_FLOWS …
#define RXE_NUM_DATA_VL …
#define TXE_NUM_CONTEXTS …
#define TXE_NUM_SDMA_ENGINES …
#define NUM_CONTEXTS_PER_SET …
#define VL_ARB_HIGH_PRIO_TABLE_SIZE …
#define VL_ARB_LOW_PRIO_TABLE_SIZE …
#define VL_ARB_TABLE_SIZE …
#define TXE_NUM_32_BIT_COUNTER …
#define TXE_NUM_64_BIT_COUNTER …
#define TXE_NUM_DATA_VL …
#define TXE_PIO_SIZE …
#define PIO_BLOCK_SIZE …
#define SDMA_BLOCK_SIZE …
#define RCV_BUF_BLOCK_SIZE …
#define PIO_CMASK …
#define MAX_EAGER_ENTRIES …
#define MAX_TID_PAIR_ENTRIES …
#define CM_VAU …
#define CM_GLOBAL_CREDITS …
#define MAX_PKEY_VALUES …
#include "chip_registers.h"
#define RXE_PER_CONTEXT_USER …
#define TXE_PIO_SEND …
#define PBC_INTR …
#define PBC_DC_INFO_SHIFT …
#define PBC_DC_INFO …
#define PBC_TEST_EBP …
#define PBC_PACKET_BYPASS …
#define PBC_CREDIT_RETURN …
#define PBC_INSERT_BYPASS_ICRC …
#define PBC_TEST_BAD_ICRC …
#define PBC_FECN …
#define PBC_IHCRC_LKDETH …
#define PBC_IHCRC_GKDETH …
#define PBC_IHCRC_NONE …
#define PBC_STATIC_RATE_CONTROL_COUNT_SHIFT …
#define PBC_STATIC_RATE_CONTROL_COUNT_MASK …
#define PBC_STATIC_RATE_CONTROL_COUNT_SMASK …
#define PBC_INSERT_HCRC_SHIFT …
#define PBC_INSERT_HCRC_MASK …
#define PBC_INSERT_HCRC_SMASK …
#define PBC_VL_SHIFT …
#define PBC_VL_MASK …
#define PBC_VL_SMASK …
#define PBC_LENGTH_DWS_SHIFT …
#define PBC_LENGTH_DWS_MASK …
#define PBC_LENGTH_DWS_SMASK …
#define CR_COUNTER_SHIFT …
#define CR_COUNTER_MASK …
#define CR_COUNTER_SMASK …
#define CR_STATUS_SHIFT …
#define CR_STATUS_MASK …
#define CR_STATUS_SMASK …
#define CR_CREDIT_RETURN_DUE_TO_PBC_SHIFT …
#define CR_CREDIT_RETURN_DUE_TO_PBC_MASK …
#define CR_CREDIT_RETURN_DUE_TO_PBC_SMASK …
#define CR_CREDIT_RETURN_DUE_TO_THRESHOLD_SHIFT …
#define CR_CREDIT_RETURN_DUE_TO_THRESHOLD_MASK …
#define CR_CREDIT_RETURN_DUE_TO_THRESHOLD_SMASK …
#define CR_CREDIT_RETURN_DUE_TO_ERR_SHIFT …
#define CR_CREDIT_RETURN_DUE_TO_ERR_MASK …
#define CR_CREDIT_RETURN_DUE_TO_ERR_SMASK …
#define CR_CREDIT_RETURN_DUE_TO_FORCE_SHIFT …
#define CR_CREDIT_RETURN_DUE_TO_FORCE_MASK …
#define CR_CREDIT_RETURN_DUE_TO_FORCE_SMASK …
#define CCE_ERR_INT …
#define RXE_ERR_INT …
#define MISC_ERR_INT …
#define PIO_ERR_INT …
#define SDMA_ERR_INT …
#define EGRESS_ERR_INT …
#define TXE_ERR_INT …
#define PBC_INT …
#define GPIO_ASSERT_INT …
#define QSFP1_INT …
#define QSFP2_INT …
#define TCRIT_INT …
#define IS_FIRST_SOURCE …
#define IS_GENERAL_ERR_START …
#define IS_SDMAENG_ERR_START …
#define IS_SENDCTXT_ERR_START …
#define IS_SDMA_START …
#define IS_SDMA_PROGRESS_START …
#define IS_SDMA_IDLE_START …
#define IS_VARIOUS_START …
#define IS_DC_START …
#define IS_RCVAVAIL_START …
#define IS_RCVURGENT_START …
#define IS_SENDCREDIT_START …
#define IS_RESERVED_START …
#define IS_LAST_SOURCE …
#define IS_GENERAL_ERR_END …
#define IS_SDMAENG_ERR_END …
#define IS_SENDCTXT_ERR_END …
#define IS_SDMA_END …
#define IS_SDMA_PROGRESS_END …
#define IS_SDMA_IDLE_END …
#define IS_VARIOUS_END …
#define IS_DC_END …
#define IS_RCVAVAIL_END …
#define IS_RCVURGENT_END …
#define IS_SENDCREDIT_END …
#define IS_RESERVED_END …
#define LSTATE_DOWN …
#define LSTATE_INIT …
#define LSTATE_ARMED …
#define LSTATE_ACTIVE …
#define LCB_RX_FPE_TX_FPE_INTO_RESET …
#define LCB_RX_FPE_TX_FPE_OUT_OF_RESET …
#define PLS_DISABLED …
#define PLS_OFFLINE …
#define PLS_OFFLINE_QUIET …
#define PLS_OFFLINE_PLANNED_DOWN_INFORM …
#define PLS_OFFLINE_READY_TO_QUIET_LT …
#define PLS_OFFLINE_REPORT_FAILURE …
#define PLS_OFFLINE_READY_TO_QUIET_BCC …
#define PLS_OFFLINE_QUIET_DURATION …
#define PLS_POLLING …
#define PLS_POLLING_QUIET …
#define PLS_POLLING_ACTIVE …
#define PLS_CONFIGPHY …
#define PLS_CONFIGPHY_DEBOUCE …
#define PLS_CONFIGPHY_ESTCOMM …
#define PLS_CONFIGPHY_ESTCOMM_TXRX_HUNT …
#define PLS_CONFIGPHY_ESTCOMM_LOCAL_COMPLETE …
#define PLS_CONFIGPHY_OPTEQ …
#define PLS_CONFIGPHY_OPTEQ_OPTIMIZING …
#define PLS_CONFIGPHY_OPTEQ_LOCAL_COMPLETE …
#define PLS_CONFIGPHY_VERIFYCAP …
#define PLS_CONFIGPHY_VERIFYCAP_EXCHANGE …
#define PLS_CONFIGPHY_VERIFYCAP_LOCAL_COMPLETE …
#define PLS_CONFIGLT …
#define PLS_CONFIGLT_CONFIGURE …
#define PLS_CONFIGLT_LINK_TRANSFER_ACTIVE …
#define PLS_LINKUP …
#define PLS_PHYTEST …
#define PLS_INTERNAL_SERDES_LOOPBACK …
#define PLS_QUICK_LINKUP …
#define HCMD_LOAD_CONFIG_DATA …
#define HCMD_READ_CONFIG_DATA …
#define HCMD_CHANGE_PHY_STATE …
#define HCMD_SEND_LCB_IDLE_MSG …
#define HCMD_MISC …
#define HCMD_READ_LCB_IDLE_MSG …
#define HCMD_READ_LCB_CSR …
#define HCMD_WRITE_LCB_CSR …
#define HCMD_INTERFACE_TEST …
#define HCMD_SUCCESS …
#define SPICO_ROM_FAILED …
#define UNKNOWN_FRAME …
#define TARGET_BER_NOT_MET …
#define FAILED_SERDES_INTERNAL_LOOPBACK …
#define FAILED_SERDES_INIT …
#define FAILED_LNI_POLLING …
#define FAILED_LNI_DEBOUNCE …
#define FAILED_LNI_ESTBCOMM …
#define FAILED_LNI_OPTEQ …
#define FAILED_LNI_VERIFY_CAP1 …
#define FAILED_LNI_VERIFY_CAP2 …
#define FAILED_LNI_CONFIGLT …
#define HOST_HANDSHAKE_TIMEOUT …
#define EXTERNAL_DEVICE_REQ_TIMEOUT …
#define FAILED_LNI …
#define HOST_REQ_DONE …
#define BC_PWR_MGM_MSG …
#define BC_SMA_MSG …
#define BC_BCC_UNKNOWN_MSG …
#define BC_IDLE_UNKNOWN_MSG …
#define EXT_DEVICE_CFG_REQ …
#define VERIFY_CAP_FRAME …
#define LINKUP_ACHIEVED …
#define LINK_GOING_DOWN …
#define LINK_WIDTH_DOWNGRADED …
#define HREQ_LOAD_CONFIG …
#define HREQ_SAVE_CONFIG …
#define HREQ_READ_CONFIG …
#define HREQ_SET_TX_EQ_ABS …
#define HREQ_SET_TX_EQ_REL …
#define HREQ_ENABLE …
#define HREQ_LCB_RESET …
#define HREQ_CONFIG_DONE …
#define HREQ_INTERFACE_TEST …
#define HREQ_INVALID …
#define HREQ_SUCCESS …
#define HREQ_NOT_SUPPORTED …
#define HREQ_FEATURE_NOT_SUPPORTED …
#define HREQ_REQUEST_REJECTED …
#define HREQ_EXECUTION_ONGOING …
#define HCMD_MISC_REQUEST_LCB_ACCESS …
#define HCMD_MISC_GRANT_LCB_ACCESS …
#define IDLE_PHYSICAL_LINK_MGMT …
#define IDLE_CRU …
#define IDLE_SMA …
#define IDLE_POWER_MGMT …
#define IDLE_PAYLOAD_MASK …
#define IDLE_PAYLOAD_SHIFT …
#define IDLE_MSG_TYPE_MASK …
#define IDLE_MSG_TYPE_SHIFT …
#define READ_IDLE_MSG_TYPE_MASK …
#define READ_IDLE_MSG_TYPE_SHIFT …
#define SMA_IDLE_ARM …
#define SMA_IDLE_ACTIVE …
#define DISABLE_SELF_GUID_CHECK …
#define BAD_L2_ERR …
#define MIN_EAGER_BUFFER …
#define MAX_EAGER_BUFFER …
#define MAX_EAGER_BUFFER_TOTAL …
#define MAX_EXPECTED_BUFFER …
#define HFI1_MIN_HDRQ_EGRBUF_CNT …
#define HFI1_MAX_HDRQ_EGRBUF_CNT …
#define RCV_SHIFT …
#define RCV_INCREMENT …
#define HDRQ_SIZE_SHIFT …
#define HDRQ_INCREMENT …
#define FREEZE_ABORT …
#define FREEZE_SELF …
#define FREEZE_LINK_DOWN …
#define ICODE_RTL_SILICON …
#define ICODE_RTL_VCS_SIMULATION …
#define ICODE_FPGA_EMULATION …
#define ICODE_FUNCTIONAL_SIMULATOR …
#define DC8051_DATA_MEM_SIZE …
#define NUM_GENERAL_FIELDS …
#define NUM_LANE_FIELDS …
#define LINK_OPTIMIZATION_SETTINGS …
#define LINK_TUNING_PARAMETERS …
#define DC_HOST_COMM_SETTINGS …
#define TX_SETTINGS …
#define VERIFY_CAP_LOCAL_PHY …
#define VERIFY_CAP_LOCAL_FABRIC …
#define VERIFY_CAP_LOCAL_LINK_MODE …
#define LOCAL_DEVICE_ID …
#define RESERVED_REGISTERS …
#define LOCAL_LNI_INFO …
#define REMOTE_LNI_INFO …
#define MISC_STATUS …
#define VERIFY_CAP_REMOTE_PHY …
#define VERIFY_CAP_REMOTE_FABRIC …
#define VERIFY_CAP_REMOTE_LINK_WIDTH …
#define LAST_LOCAL_STATE_COMPLETE …
#define LAST_REMOTE_STATE_COMPLETE …
#define LINK_QUALITY_INFO …
#define REMOTE_DEVICE_ID …
#define LINK_DOWN_REASON …
#define VERSION_PATCH …
#define TX_EQ_SETTINGS …
#define CHANNEL_LOSS_SETTINGS …
#define GENERAL_CONFIG …
#define TUNING_METHOD_SHIFT …
#define ENABLE_EXT_DEV_CONFIG_SHIFT …
#define LOAD_DATA_FIELD_ID_SHIFT …
#define LOAD_DATA_FIELD_ID_MASK …
#define LOAD_DATA_LANE_ID_SHIFT …
#define LOAD_DATA_LANE_ID_MASK …
#define LOAD_DATA_DATA_SHIFT …
#define LOAD_DATA_DATA_MASK …
#define READ_DATA_FIELD_ID_SHIFT …
#define READ_DATA_FIELD_ID_MASK …
#define READ_DATA_LANE_ID_SHIFT …
#define READ_DATA_LANE_ID_MASK …
#define READ_DATA_DATA_SHIFT …
#define READ_DATA_DATA_MASK …
#define ENABLE_LANE_TX_SHIFT …
#define ENABLE_LANE_TX_MASK …
#define TX_POLARITY_INVERSION_SHIFT …
#define TX_POLARITY_INVERSION_MASK …
#define RX_POLARITY_INVERSION_SHIFT …
#define RX_POLARITY_INVERSION_MASK …
#define MAX_RATE_SHIFT …
#define MAX_RATE_MASK …
#define CONTINIOUS_REMOTE_UPDATE_SUPPORT_SHIFT …
#define CONTINIOUS_REMOTE_UPDATE_SUPPORT_MASK …
#define POWER_MANAGEMENT_SHIFT …
#define POWER_MANAGEMENT_MASK …
#define SPICO_FW_VERSION …
#define SPICO_ROM_VERSION_SHIFT …
#define SPICO_ROM_VERSION_MASK …
#define SPICO_ROM_PROD_ID_SHIFT …
#define SPICO_ROM_PROD_ID_MASK …
#define VAU_SHIFT …
#define VAU_MASK …
#define Z_SHIFT …
#define Z_MASK …
#define VCU_SHIFT …
#define VCU_MASK …
#define VL15BUF_SHIFT …
#define VL15BUF_MASK …
#define CRC_SIZES_SHIFT …
#define CRC_SIZES_MASK …
#define LINK_WIDTH_SHIFT …
#define LINK_WIDTH_MASK …
#define LOCAL_FLAG_BITS_SHIFT …
#define LOCAL_FLAG_BITS_MASK …
#define MISC_CONFIG_BITS_SHIFT …
#define MISC_CONFIG_BITS_MASK …
#define REMOTE_TX_RATE_SHIFT …
#define REMOTE_TX_RATE_MASK …
#define LOCAL_DEVICE_REV_SHIFT …
#define LOCAL_DEVICE_REV_MASK …
#define LOCAL_DEVICE_ID_SHIFT …
#define LOCAL_DEVICE_ID_MASK …
#define REMOTE_DEVICE_REV_SHIFT …
#define REMOTE_DEVICE_REV_MASK …
#define REMOTE_DEVICE_ID_SHIFT …
#define REMOTE_DEVICE_ID_MASK …
#define ENABLE_LANE_RX_SHIFT …
#define ENABLE_LANE_RX_MASK …
#define MGMT_ALLOWED_SHIFT …
#define MGMT_ALLOWED_MASK …
#define LINK_QUALITY_SHIFT …
#define LINK_QUALITY_MASK …
#define DOWN_REMOTE_REASON_SHIFT …
#define DOWN_REMOTE_REASON_MASK …
#define HOST_INTERFACE_VERSION …
#define HOST_INTERFACE_VERSION_SHIFT …
#define HOST_INTERFACE_VERSION_MASK …
#define PWRM_BER_CONTROL …
#define PWRM_BANDWIDTH_CONTROL …
#define LDR_LINK_TRANSFER_ACTIVE_LOW …
#define LDR_RECEIVED_LINKDOWN_IDLE_MSG …
#define LDR_RECEIVED_HOST_OFFLINE_REQ …
enum { … };
#define SUPPORTED_CRCS …
#define STS_FM_VERSION_MINOR_SHIFT …
#define STS_FM_VERSION_MINOR_MASK …
#define STS_FM_VERSION_MAJOR_SHIFT …
#define STS_FM_VERSION_MAJOR_MASK …
#define STS_FM_VERSION_PATCH_SHIFT …
#define STS_FM_VERSION_PATCH_MASK …
#define LCB_CRC_16B …
#define LCB_CRC_14B …
#define LCB_CRC_48B …
#define LCB_CRC_12B_16B_PER_LANE …
enum { … };
#define LINK_RESTART_DELAY …
#define TIMEOUT_8051_START …
#define DC8051_COMMAND_TIMEOUT …
#define FREEZE_STATUS_TIMEOUT …
#define VL_STATUS_CLEAR_TIMEOUT …
#define CCE_STATUS_TIMEOUT …
#define ASIC_CCLOCK_PS …
#define FPGA_CCLOCK_PS …
#define DRIVER_MISC_MASK …
#define LOOPBACK_NONE …
#define LOOPBACK_SERDES …
#define LOOPBACK_LCB …
#define LOOPBACK_CABLE …
#define LOOPBACK_SERDES_CONFIG_BIT_MASK_SHIFT …
#define EXT_CFG_LCB_RESET_SUPPORTED_SHIFT …
u64 read_csr(const struct hfi1_devdata *dd, u32 offset);
void write_csr(const struct hfi1_devdata *dd, u32 offset, u64 value);
static inline u64 read_kctxt_csr(const struct hfi1_devdata *dd, int ctxt,
u32 offset0)
{ … }
static inline void write_kctxt_csr(struct hfi1_devdata *dd, int ctxt,
u32 offset0, u64 value)
{ … }
int read_lcb_csr(struct hfi1_devdata *dd, u32 offset, u64 *data);
int write_lcb_csr(struct hfi1_devdata *dd, u32 offset, u64 data);
void __iomem *get_csr_addr(
const struct hfi1_devdata *dd,
u32 offset);
static inline void __iomem *get_kctxt_csr_addr(
const struct hfi1_devdata *dd,
int ctxt,
u32 offset0)
{ … }
static inline u64 read_uctxt_csr(const struct hfi1_devdata *dd, int ctxt,
u32 offset0)
{ … }
static inline void write_uctxt_csr(struct hfi1_devdata *dd, int ctxt,
u32 offset0, u64 value)
{ … }
static inline u32 chip_rcv_contexts(struct hfi1_devdata *dd)
{ … }
static inline u32 chip_send_contexts(struct hfi1_devdata *dd)
{ … }
static inline u32 chip_sdma_engines(struct hfi1_devdata *dd)
{ … }
static inline u32 chip_pio_mem_size(struct hfi1_devdata *dd)
{ … }
static inline u32 chip_sdma_mem_size(struct hfi1_devdata *dd)
{ … }
static inline u32 chip_rcv_array_count(struct hfi1_devdata *dd)
{ … }
u8 encode_rcv_header_entry_size(u8 size);
int hfi1_validate_rcvhdrcnt(struct hfi1_devdata *dd, uint thecnt);
void set_hdrq_regs(struct hfi1_devdata *dd, u8 ctxt, u8 entsize, u16 hdrcnt);
u64 create_pbc(struct hfi1_pportdata *ppd, u64 flags, int srate_mbs, u32 vl,
u32 dw_len);
#define SBUS_MASTER_BROADCAST …
#define NUM_PCIE_SERDES …
extern const u8 pcie_serdes_broadcast[];
extern const u8 pcie_pcs_addrs[2][NUM_PCIE_SERDES];
#define RESET_SBUS_RECEIVER …
#define WRITE_SBUS_RECEIVER …
#define READ_SBUS_RECEIVER …
void sbus_request(struct hfi1_devdata *dd,
u8 receiver_addr, u8 data_addr, u8 command, u32 data_in);
int sbus_request_slow(struct hfi1_devdata *dd,
u8 receiver_addr, u8 data_addr, u8 command, u32 data_in);
void set_sbus_fast_mode(struct hfi1_devdata *dd);
void clear_sbus_fast_mode(struct hfi1_devdata *dd);
int hfi1_firmware_init(struct hfi1_devdata *dd);
int load_pcie_firmware(struct hfi1_devdata *dd);
int load_firmware(struct hfi1_devdata *dd);
void dispose_firmware(void);
int acquire_hw_mutex(struct hfi1_devdata *dd);
void release_hw_mutex(struct hfi1_devdata *dd);
#define CR_SBUS …
#define CR_EPROM …
#define CR_I2C1 …
#define CR_I2C2 …
#define CR_DYN_SHIFT …
#define CR_DYN_MASK …
#define CR_THERM_INIT …
int acquire_chip_resource(struct hfi1_devdata *dd, u32 resource, u32 mswait);
void release_chip_resource(struct hfi1_devdata *dd, u32 resource);
bool check_chip_resource(struct hfi1_devdata *dd, u32 resource,
const char *func);
void init_chip_resources(struct hfi1_devdata *dd);
void finish_chip_resources(struct hfi1_devdata *dd);
#define SBUS_TIMEOUT …
#define QSFP_WAIT …
void fabric_serdes_reset(struct hfi1_devdata *dd);
int read_8051_data(struct hfi1_devdata *dd, u32 addr, u32 len, u64 *result);
void read_misc_status(struct hfi1_devdata *dd, u8 *ver_major, u8 *ver_minor,
u8 *ver_patch);
int write_host_interface_version(struct hfi1_devdata *dd, u8 version);
void read_guid(struct hfi1_devdata *dd);
int wait_fm_ready(struct hfi1_devdata *dd, u32 mstimeout);
void set_link_down_reason(struct hfi1_pportdata *ppd, u8 lcl_reason,
u8 neigh_reason, u8 rem_reason);
int set_link_state(struct hfi1_pportdata *, u32 state);
int port_ltp_to_cap(int port_ltp);
void handle_verify_cap(struct work_struct *work);
void handle_freeze(struct work_struct *work);
void handle_link_up(struct work_struct *work);
void handle_link_down(struct work_struct *work);
void handle_link_downgrade(struct work_struct *work);
void handle_link_bounce(struct work_struct *work);
void handle_start_link(struct work_struct *work);
void handle_sma_message(struct work_struct *work);
int reset_qsfp(struct hfi1_pportdata *ppd);
void qsfp_event(struct work_struct *work);
void start_freeze_handling(struct hfi1_pportdata *ppd, int flags);
int send_idle_sma(struct hfi1_devdata *dd, u64 message);
int load_8051_config(struct hfi1_devdata *, u8, u8, u32);
int read_8051_config(struct hfi1_devdata *, u8, u8, u32 *);
int start_link(struct hfi1_pportdata *ppd);
int bringup_serdes(struct hfi1_pportdata *ppd);
void set_intr_state(struct hfi1_devdata *dd, u32 enable);
bool apply_link_downgrade_policy(struct hfi1_pportdata *ppd,
bool refresh_widths);
void update_usrhead(struct hfi1_ctxtdata *rcd, u32 hd, u32 updegr, u32 egrhd,
u32 intr_adjust, u32 npkts);
int stop_drain_data_vls(struct hfi1_devdata *dd);
int open_fill_data_vls(struct hfi1_devdata *dd);
u32 ns_to_cclock(struct hfi1_devdata *dd, u32 ns);
u32 cclock_to_ns(struct hfi1_devdata *dd, u32 cclock);
void get_linkup_link_widths(struct hfi1_pportdata *ppd);
void read_ltp_rtt(struct hfi1_devdata *dd);
void clear_linkup_counters(struct hfi1_devdata *dd);
u32 hdrqempty(struct hfi1_ctxtdata *rcd);
int is_ax(struct hfi1_devdata *dd);
int is_bx(struct hfi1_devdata *dd);
bool is_urg_masked(struct hfi1_ctxtdata *rcd);
u32 read_physical_state(struct hfi1_devdata *dd);
u32 chip_to_opa_pstate(struct hfi1_devdata *dd, u32 chip_pstate);
const char *opa_lstate_name(u32 lstate);
const char *opa_pstate_name(u32 pstate);
u32 driver_pstate(struct hfi1_pportdata *ppd);
u32 driver_lstate(struct hfi1_pportdata *ppd);
int acquire_lcb_access(struct hfi1_devdata *dd, int sleep_ok);
int release_lcb_access(struct hfi1_devdata *dd, int sleep_ok);
#define LCB_START …
#define LCB_END …
extern uint num_vls;
extern uint disable_integrity;
u64 read_dev_cntr(struct hfi1_devdata *dd, int index, int vl);
u64 write_dev_cntr(struct hfi1_devdata *dd, int index, int vl, u64 data);
u64 read_port_cntr(struct hfi1_pportdata *ppd, int index, int vl);
u64 write_port_cntr(struct hfi1_pportdata *ppd, int index, int vl, u64 data);
u32 read_logical_state(struct hfi1_devdata *dd);
void force_recv_intr(struct hfi1_ctxtdata *rcd);
enum { … };
static inline int vl_from_idx(int idx)
{ … }
static inline int idx_from_vl(int vl)
{ … }
enum { … };
enum { … };
u64 get_all_cpu_total(u64 __percpu *cntr);
void hfi1_start_cleanup(struct hfi1_devdata *dd);
void hfi1_clear_tids(struct hfi1_ctxtdata *rcd);
void hfi1_init_ctxt(struct send_context *sc);
void hfi1_put_tid(struct hfi1_devdata *dd, u32 index,
u32 type, unsigned long pa, u16 order);
void hfi1_quiet_serdes(struct hfi1_pportdata *ppd);
void hfi1_rcvctrl(struct hfi1_devdata *dd, unsigned int op,
struct hfi1_ctxtdata *rcd);
u32 hfi1_read_cntrs(struct hfi1_devdata *dd, char **namep, u64 **cntrp);
u32 hfi1_read_portcntrs(struct hfi1_pportdata *ppd, char **namep, u64 **cntrp);
int hfi1_get_ib_cfg(struct hfi1_pportdata *ppd, int which);
int hfi1_set_ib_cfg(struct hfi1_pportdata *ppd, int which, u32 val);
int hfi1_set_ctxt_jkey(struct hfi1_devdata *dd, struct hfi1_ctxtdata *rcd,
u16 jkey);
int hfi1_clear_ctxt_jkey(struct hfi1_devdata *dd, struct hfi1_ctxtdata *ctxt);
int hfi1_set_ctxt_pkey(struct hfi1_devdata *dd, struct hfi1_ctxtdata *ctxt,
u16 pkey);
int hfi1_clear_ctxt_pkey(struct hfi1_devdata *dd, struct hfi1_ctxtdata *ctxt);
void hfi1_read_link_quality(struct hfi1_devdata *dd, u8 *link_quality);
void hfi1_init_vnic_rsm(struct hfi1_devdata *dd);
void hfi1_deinit_vnic_rsm(struct hfi1_devdata *dd);
irqreturn_t general_interrupt(int irq, void *data);
irqreturn_t sdma_interrupt(int irq, void *data);
irqreturn_t receive_context_interrupt(int irq, void *data);
irqreturn_t receive_context_thread(int irq, void *data);
irqreturn_t receive_context_interrupt_napi(int irq, void *data);
int set_intr_bits(struct hfi1_devdata *dd, u16 first, u16 last, bool set);
void init_qsfp_int(struct hfi1_devdata *dd);
void clear_all_interrupts(struct hfi1_devdata *dd);
void remap_intr(struct hfi1_devdata *dd, int isrc, int msix_intr);
void remap_sdma_interrupts(struct hfi1_devdata *dd, int engine, int msix_intr);
void reset_interrupts(struct hfi1_devdata *dd);
u8 hfi1_get_qp_map(struct hfi1_devdata *dd, u8 idx);
void hfi1_init_aip_rsm(struct hfi1_devdata *dd);
void hfi1_deinit_aip_rsm(struct hfi1_devdata *dd);
struct is_table { … };
#endif