User manual
52
3.The CHAPI communication context descriptors
The part covers the details of the communication context descriptors and the component
initialization process.
3.1 The CHAPI_IN communication context descriptor
The chapi_in descriptor contains entry points to routines provided by the CHARON core,
as well as base address of control and status registers (CSRs) and base interrupt vector,
which might be specified in the configuration file (see below). The chapi_in descriptor
structure is defined basically as follows:
typedef struct __chapi_in {
__chapi_in_context_p context;
unsigned int base_b_address;
unsigned int base_i_vector;
// Synchronization calls
__chapi_put_ast_procedure_p put_ast;
__chapi_put_sst_procedure_p put_sst;
// Old way of IRQ processing calls
__chapi_put_irq_procedure_p put_irq;
__chapi_clear_irq_procedure_p clear_irq;
// New way of IRQ processing calls
__chapi_connect_bus_request_p connect_bus_request;
__chapi_set_bus_request_p set_bus_request;
__chapi_clear_bus_request_p clear_bus_request;
__chapi_enable_bus_request_p enable_bus_request;
__chapi_set_bus_request_affinity_p set_bus_request_affinity;
__chapi_set_affinity_callback_p set_affinity_callback;
__chapi_get_vector_p get_vector;
// IRQ processing support for hardware replacement boards
// NOTE: THIS IS CHARON DEEP INTEGRATION
__chapi_get_bus_server_mask_p get_bus_server_mask;
__chapi_get_attention_objects_p get_attention_objects;
__chapi_get_brq_objects_p get_brq_objects;
// Emulated DMA calls
__chapi_read_mem_procedure_p read_mem;
__chapi_write_mem_procedure_p write_mem;
// Address spaces handling calls
__chapi_create_io_space_procedure_p create_io_space;
__chapi_move_io_space_procedure_p move_io_space;
__chapi_destroy_io_space_procedure_p destroy_io_space;
// Licensing calls
__chapi_get_license_no_procedure_p get_license_no;
__chapi_encrypt_data_block_procedure_p encrypt_data_block;
__chapi_decrypt_data_block_procedure_p decrypt_data_block;
// Message logging calls
__chapi_log_message_procedure_p log_message;
__chapi_log_message_ex_procedure_p log_message_ex;
__chapi_debug_trace_procedure_p debug_trace;










