#define SOURCEFILE_NAME …
#include "hpi_internal.h"
#include "hpimsginit.h"
#include "hpidebug.h"
#include "hpi6000.h"
#include "hpidspcd.h"
#include "hpicmn.h"
#define HPI_HIF_BASE …
#define HPI_HIF_ADDR(member) …
#define HPI_HIF_ERROR_MASK …
#define HPI6000_ERROR_BASE …
#define HPI6000_ERROR_MSG_RESP_IDLE_TIMEOUT …
#define HPI6000_ERROR_RESP_GET_LEN …
#define HPI6000_ERROR_MSG_RESP_GET_RESP_ACK …
#define HPI6000_ERROR_MSG_GET_ADR …
#define HPI6000_ERROR_RESP_GET_ADR …
#define HPI6000_ERROR_MSG_RESP_BLOCKWRITE32 …
#define HPI6000_ERROR_MSG_RESP_BLOCKREAD32 …
#define HPI6000_ERROR_CONTROL_CACHE_PARAMS …
#define HPI6000_ERROR_SEND_DATA_IDLE_TIMEOUT …
#define HPI6000_ERROR_SEND_DATA_ACK …
#define HPI6000_ERROR_SEND_DATA_ADR …
#define HPI6000_ERROR_SEND_DATA_TIMEOUT …
#define HPI6000_ERROR_SEND_DATA_CMD …
#define HPI6000_ERROR_SEND_DATA_WRITE …
#define HPI6000_ERROR_SEND_DATA_IDLECMD …
#define HPI6000_ERROR_GET_DATA_IDLE_TIMEOUT …
#define HPI6000_ERROR_GET_DATA_ACK …
#define HPI6000_ERROR_GET_DATA_CMD …
#define HPI6000_ERROR_GET_DATA_READ …
#define HPI6000_ERROR_GET_DATA_IDLECMD …
#define HPI6000_ERROR_CONTROL_CACHE_ADDRLEN …
#define HPI6000_ERROR_CONTROL_CACHE_READ …
#define HPI6000_ERROR_CONTROL_CACHE_FLUSH …
#define HPI6000_ERROR_MSG_RESP_GETRESPCMD …
#define HPI6000_ERROR_MSG_RESP_IDLECMD …
#define HPI6000_ERROR_UNHANDLED_SUBSYS_ID …
#define HPI6000_ERROR_INIT_PCI2040 …
#define HPI6000_ERROR_INIT_DSPHPI …
#define HPI6000_ERROR_INIT_DSPINTMEM …
#define HPI6000_ERROR_INIT_SDRAM1 …
#define HPI6000_ERROR_INIT_SDRAM2 …
#define HPI6000_ERROR_INIT_VERIFY …
#define HPI6000_ERROR_INIT_NOACK …
#define HPI6000_ERROR_INIT_PLDTEST1 …
#define HPI6000_ERROR_INIT_PLDTEST2 …
#define HIDE_PCI_ASSERTS
#define PROFILE_DSP2
#define INTERRUPT_EVENT_SET …
#define INTERRUPT_EVENT_CLEAR …
#define INTERRUPT_MASK_SET …
#define INTERRUPT_MASK_CLEAR …
#define HPI_ERROR_REPORT …
#define HPI_RESET …
#define HPI_DATA_WIDTH …
#define MAX_DSPS …
#define DSP_SPACING …
#define CONTROL …
#define ADDRESS …
#define DATA_AUTOINC …
#define DATA …
#define TIMEOUT …
struct dsp_obj { … };
struct hpi_hw_obj { … };
static u16 hpi6000_dsp_block_write32(struct hpi_adapter_obj *pao,
u16 dsp_index, u32 hpi_address, u32 *source, u32 count);
static u16 hpi6000_dsp_block_read32(struct hpi_adapter_obj *pao,
u16 dsp_index, u32 hpi_address, u32 *dest, u32 count);
static short hpi6000_adapter_boot_load_dsp(struct hpi_adapter_obj *pao,
u32 *pos_error_code);
static short hpi6000_check_PCI2040_error_flag(struct hpi_adapter_obj *pao,
u16 read_or_write);
#define H6READ …
#define H6WRITE …
static short hpi6000_update_control_cache(struct hpi_adapter_obj *pao,
struct hpi_message *phm);
static short hpi6000_message_response_sequence(struct hpi_adapter_obj *pao,
u16 dsp_index, struct hpi_message *phm, struct hpi_response *phr);
static void hw_message(struct hpi_adapter_obj *pao, struct hpi_message *phm,
struct hpi_response *phr);
static short hpi6000_wait_dsp_ack(struct hpi_adapter_obj *pao, u16 dsp_index,
u32 ack_value);
static short hpi6000_send_host_command(struct hpi_adapter_obj *pao,
u16 dsp_index, u32 host_cmd);
static void hpi6000_send_dsp_interrupt(struct dsp_obj *pdo);
static short hpi6000_send_data(struct hpi_adapter_obj *pao, u16 dsp_index,
struct hpi_message *phm, struct hpi_response *phr);
static short hpi6000_get_data(struct hpi_adapter_obj *pao, u16 dsp_index,
struct hpi_message *phm, struct hpi_response *phr);
static void hpi_write_word(struct dsp_obj *pdo, u32 address, u32 data);
static u32 hpi_read_word(struct dsp_obj *pdo, u32 address);
static void hpi_write_block(struct dsp_obj *pdo, u32 address, u32 *pdata,
u32 length);
static void hpi_read_block(struct dsp_obj *pdo, u32 address, u32 *pdata,
u32 length);
static void subsys_create_adapter(struct hpi_message *phm,
struct hpi_response *phr);
static void adapter_delete(struct hpi_adapter_obj *pao,
struct hpi_message *phm, struct hpi_response *phr);
static void adapter_get_asserts(struct hpi_adapter_obj *pao,
struct hpi_message *phm, struct hpi_response *phr);
static short create_adapter_obj(struct hpi_adapter_obj *pao,
u32 *pos_error_code);
static void delete_adapter_obj(struct hpi_adapter_obj *pao);
static u16 gw_pci_read_asserts;
static u16 gw_pci_write_asserts;
static void subsys_message(struct hpi_message *phm, struct hpi_response *phr)
{ … }
static void control_message(struct hpi_adapter_obj *pao,
struct hpi_message *phm, struct hpi_response *phr)
{ … }
static void adapter_message(struct hpi_adapter_obj *pao,
struct hpi_message *phm, struct hpi_response *phr)
{ … }
static void outstream_message(struct hpi_adapter_obj *pao,
struct hpi_message *phm, struct hpi_response *phr)
{ … }
static void instream_message(struct hpi_adapter_obj *pao,
struct hpi_message *phm, struct hpi_response *phr)
{ … }
void HPI_6000(struct hpi_message *phm, struct hpi_response *phr)
{ … }
static void subsys_create_adapter(struct hpi_message *phm,
struct hpi_response *phr)
{ … }
static void adapter_delete(struct hpi_adapter_obj *pao,
struct hpi_message *phm, struct hpi_response *phr)
{ … }
static short create_adapter_obj(struct hpi_adapter_obj *pao,
u32 *pos_error_code)
{ … }
static void delete_adapter_obj(struct hpi_adapter_obj *pao)
{ … }
static void adapter_get_asserts(struct hpi_adapter_obj *pao,
struct hpi_message *phm, struct hpi_response *phr)
{ … }
static short hpi6000_adapter_boot_load_dsp(struct hpi_adapter_obj *pao,
u32 *pos_error_code)
{ … }
#define PCI_TIMEOUT …
static int hpi_set_address(struct dsp_obj *pdo, u32 address)
{ … }
static void hpi_write_word(struct dsp_obj *pdo, u32 address, u32 data)
{ … }
static u32 hpi_read_word(struct dsp_obj *pdo, u32 address)
{ … }
static void hpi_write_block(struct dsp_obj *pdo, u32 address, u32 *pdata,
u32 length)
{ … }
static void hpi_read_block(struct dsp_obj *pdo, u32 address, u32 *pdata,
u32 length)
{ … }
static u16 hpi6000_dsp_block_write32(struct hpi_adapter_obj *pao,
u16 dsp_index, u32 hpi_address, u32 *source, u32 count)
{ … }
static u16 hpi6000_dsp_block_read32(struct hpi_adapter_obj *pao,
u16 dsp_index, u32 hpi_address, u32 *dest, u32 count)
{ … }
static short hpi6000_message_response_sequence(struct hpi_adapter_obj *pao,
u16 dsp_index, struct hpi_message *phm, struct hpi_response *phr)
{ … }
#define MSG_ADDRESS …
#define MSG_LENGTH …
#define RESP_ADDRESS …
#define RESP_LENGTH …
#define QUEUE_START …
#define QUEUE_SIZE …
static short hpi6000_send_data_check_adr(u32 address, u32 length_in_dwords)
{ … }
static short hpi6000_send_data(struct hpi_adapter_obj *pao, u16 dsp_index,
struct hpi_message *phm, struct hpi_response *phr)
{ … }
static short hpi6000_get_data(struct hpi_adapter_obj *pao, u16 dsp_index,
struct hpi_message *phm, struct hpi_response *phr)
{ … }
static void hpi6000_send_dsp_interrupt(struct dsp_obj *pdo)
{ … }
static short hpi6000_send_host_command(struct hpi_adapter_obj *pao,
u16 dsp_index, u32 host_cmd)
{ … }
static short hpi6000_check_PCI2040_error_flag(struct hpi_adapter_obj *pao,
u16 read_or_write)
{ … }
static short hpi6000_wait_dsp_ack(struct hpi_adapter_obj *pao, u16 dsp_index,
u32 ack_value)
{ … }
static short hpi6000_update_control_cache(struct hpi_adapter_obj *pao,
struct hpi_message *phm)
{ … }
static u16 get_dsp_index(struct hpi_adapter_obj *pao, struct hpi_message *phm)
{ … }
static void hw_message(struct hpi_adapter_obj *pao, struct hpi_message *phm,
struct hpi_response *phr)
{ … }