NVIDIA DOCA SDK Data Center on a Chip Framework Documentation
doca_pcc.h File Reference
#include <stdbool.h>
#include <doca_compat.h>
#include <doca_error.h>
Include dependency graph for doca_pcc.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Typedefs

typedef int(* doca_pcc_trace_callback_t) (void *ctx, struct doca_pcc_bin_report *reps, int reps_size)
 Tracer user callback, to be defined by user and called when traces are sent by DPA. More...
 

Enumerations

enum  doca_pcc_ccmad_custom_header_loc_t { DOCA_PCC_CCMAD_CUSTOM_HEADER_LOCATION_MAD_PAYLOAD = 1 }
 CCMAD custom header location. More...
 
enum  doca_pcc_process_state_t { DOCA_PCC_PS_ACTIVE = 0 , DOCA_PCC_PS_STANDBY = 1 , DOCA_PCC_PS_DEACTIVATED = 2 , DOCA_PCC_PS_ERROR = 3 }
 Process states. More...
 

Functions

DOCA_STABLE doca_error_t doca_devinfo_get_is_pcc_supported (const struct doca_devinfo *devinfo)
 Get whether the DOCA device supports PCC reaction point. More...
 
DOCA_EXPERIMENTAL doca_error_t doca_pcc_np_cap_is_supported (const struct doca_devinfo *devinfo)
 Get whether the DOCA device supports PCC notification point. More...
 
DOCA_STABLE doca_error_t doca_pcc_create (struct doca_dev *doca_dev, struct doca_pcc **pcc)
 Create programmable CC Reaction Point context. More...
 
DOCA_EXPERIMENTAL doca_error_t doca_pcc_np_create (struct doca_dev *doca_dev, struct doca_pcc **pcc)
 Create programmable CC Notification Point context. More...
 
DOCA_STABLE doca_error_t doca_pcc_destroy (struct doca_pcc *pcc)
 Destroy a DOCA PCC context. More...
 
DOCA_STABLE doca_error_t doca_pcc_start (struct doca_pcc *pcc)
 Start a PCC context Register the pcc process in the NIC hw. More...
 
DOCA_STABLE doca_error_t doca_pcc_stop (struct doca_pcc *pcc)
 Stop a PCC context. More...
 
DOCA_STABLE doca_error_t doca_pcc_get_min_num_threads (struct doca_pcc *pcc, uint32_t *min_num_threads)
 Get a minimal required number of threads handling CC events. More...
 
DOCA_STABLE doca_error_t doca_pcc_get_max_num_threads (struct doca_pcc *pcc, uint32_t *max_num_threads)
 Get a maximal allowed number of threads handling CC events. More...
 
DOCA_STABLE doca_error_t doca_pcc_set_app (struct doca_pcc *pcc, struct doca_pcc_app *app)
 Set program app for PCC context. More...
 
DOCA_EXPERIMENTAL doca_error_t doca_pcc_cap_get_num_probe_format_slots (struct doca_pcc *pcc, uint32_t *num_probe_format_slots)
 Get number of available probe format slots. More...
 
DOCA_EXPERIMENTAL doca_error_t doca_pcc_set_ccmad_probe_packet_format (struct doca_pcc *pcc, uint32_t probe_format_slot)
 Set CCMAD probe packet format for the pcc process. More...
 
DOCA_EXPERIMENTAL doca_error_t doca_pcc_set_ifa1_probe_packet_format (struct doca_pcc *pcc, uint32_t probe_format_slot)
 Set ifa1 probe packet format for the pcc process. More...
 
DOCA_EXPERIMENTAL doca_error_t doca_pcc_set_ifa2_probe_packet_format (struct doca_pcc *pcc, uint32_t probe_format_slot)
 Set ifa2 probe packet format for the pcc process. More...
 
DOCA_EXPERIMENTAL doca_error_t doca_pcc_rp_set_ccmad_remote_sw_handler (struct doca_pcc *pcc, uint32_t probe_format_slot, bool sw_handler)
 Set sw remote handler for CCMAD probe type. More...
 
DOCA_EXPERIMENTAL doca_error_t doca_pcc_cap_is_ccmad_custom_header_supported (const struct doca_devinfo *devinfo)
 Get whether the DOCA device supports PCC ccmad customized header in reaction point. More...
 
DOCA_EXPERIMENTAL doca_error_t doca_pcc_rp_set_ccmad_custom_header_size (struct doca_pcc *pcc, uint32_t probe_format_slot, uint8_t header_size)
 Set customized header of CCMAD probe packet in RP. More...
 
DOCA_EXPERIMENTAL doca_error_t doca_pcc_rp_set_ccmad_custom_header_location (struct doca_pcc *pcc, uint32_t probe_format_slot, doca_pcc_ccmad_custom_header_loc_t header_loc)
 Set customized header of CCMAD probe packet in RP. More...
 
DOCA_EXPERIMENTAL doca_error_t doca_pcc_set_ifa1_probe_marker (struct doca_pcc *pcc, uint32_t probe_format_slot, uint64_t probe_marker)
 Set probe marker value for IFA1 probe. More...
 
DOCA_EXPERIMENTAL doca_error_t doca_pcc_rp_set_ifa2_gns (struct doca_pcc *pcc, uint32_t probe_format_slot, uint8_t gns)
 Set GNS value for IFA2 packets. More...
 
DOCA_EXPERIMENTAL doca_error_t doca_pcc_np_set_ifa2_gns_ignore (struct doca_pcc *pcc, uint32_t probe_format_slot, uint8_t ignore_mask, uint8_t ignore_value)
 Set GNS ignore for IFA2 packets. More...
 
DOCA_EXPERIMENTAL doca_error_t doca_pcc_rp_set_ifa2_hop_limit (struct doca_pcc *pcc, uint32_t probe_format_slot, uint8_t hop_limit)
 Set hop_limit field in the metadata header for IFA2 packets. More...
 
DOCA_STABLE doca_error_t doca_pcc_set_thread_affinity (struct doca_pcc *pcc, uint32_t num_threads, uint32_t *affinity_configs)
 Configure affinity of threads handling CC events. More...
 
DOCA_STABLE doca_error_t doca_pcc_set_trace_message (struct doca_pcc *pcc, char **trace_message)
 Set message for trace printing. More...
 
DOCA_EXPERIMENTAL doca_error_t doca_pcc_activate_tracer (struct doca_pcc *pcc)
 Enable trace printing. More...
 
DOCA_EXPERIMENTAL doca_error_t doca_pcc_deactivate_tracer (struct doca_pcc *pcc)
 Disable trace printing. More...
 
DOCA_EXPERIMENTAL doca_error_t doca_pcc_trace_buf_set (struct doca_pcc *pcc, void *buf_addr, uint32_t buf_size)
 Set trace buffer address to write trace into. More...
 
DOCA_EXPERIMENTAL doca_error_t doca_pcc_trace_buf_get (struct doca_pcc *pcc, void **buf_addr, uint32_t *buf_size)
 Get trace buffer address to write trace into. More...
 
DOCA_EXPERIMENTAL doca_error_t doca_pcc_trace_file_set (struct doca_pcc *pcc, const char *file_path)
 Set trace file path to write trace into. More...
 
DOCA_EXPERIMENTAL doca_error_t doca_pcc_trace_file_get (struct doca_pcc *pcc, char **file_path, uint32_t *file_path_len)
 Get trace file path to write trace into. More...
 
DOCA_EXPERIMENTAL doca_error_t doca_pcc_register_trace_handler (struct doca_pcc *pcc, doca_pcc_trace_callback_t trace_callback, void *user_ctx)
 Register a user callback that is triggered when traces arrive from the device. More...
 
DOCA_STABLE doca_error_t doca_pcc_set_print_buffer_size (struct doca_pcc *pcc, size_t buffer_size)
 Set buffer size of DPA print message. More...
 
DOCA_STABLE doca_error_t doca_pcc_set_dev_coredump_file (struct doca_pcc *pcc, const char *file_name)
 Set output file to write crash data and coredump in case of unrecoverable error on the device. More...
 
DOCA_EXPERIMENTAL doca_error_t doca_pcc_set_mailbox (struct doca_pcc *pcc, uint32_t max_request_size, uint32_t max_response_size)
 Set mailbox attributes to obtain and pass data from and to the device. More...
 
DOCA_EXPERIMENTAL doca_error_t doca_pcc_mailbox_get_request_buffer (struct doca_pcc *pcc, void **request_buffer)
 Get mailbox request data buffer address to fill and transfer to device. More...
 
DOCA_EXPERIMENTAL doca_error_t doca_pcc_mailbox_get_response_buffer (struct doca_pcc *pcc, void **response_buffer)
 Get mailbox response data buffer address that contains data transferred from device. More...
 
DOCA_EXPERIMENTAL doca_error_t doca_pcc_mailbox_send (struct doca_pcc *pcc, uint32_t request_size, uint32_t *response_size, uint32_t *cb_ret_val)
 Send mailbox request data to device. More...
 
DOCA_STABLE doca_error_t doca_pcc_wait (struct doca_pcc *pcc, int wait_time)
 Wait on events or timeout from device for given time in seconds. More...
 
DOCA_STABLE doca_error_t doca_pcc_get_process_state (const struct doca_pcc *pcc, doca_pcc_process_state_t *process_state)
 Return the state of the process. More...
 
DOCA_EXPERIMENTAL doca_error_t doca_pcc_dump_debug (const struct doca_pcc *pcc)
 Dump device side debug info. More...
 
DOCA_EXPERIMENTAL doca_error_t doca_pcc_enable_debug (const struct doca_pcc *pcc, bool enable)
 Enable or disable device side debug. More...