Data Plane Development Kit Reference Manual: Intel FPGA Programmable Acceleration Card N3000

ID 683512
Date 12/06/2019
Public
Document Table of Contents

2.4.2. OPAE Manager

OPAE Data Structures

The $RTE_SDK/drivers/raw/ifpga_rawdev/base/opae_hw_api.h header file defines the following data structures.

struct opae_manager {
   const char *name;
   struct opae_adapter *adapter;
   struct opae_manager_ops *ops;
   struct opae_manager_networking_ops *network_ops;
   void *data;
Table 3.  opae_manager Struct Field Definitions
Data Structure Field Names Description
name A pointer to the name of the opae_manager.
adapter A pointer to the opae_adapter data structure.
ops A pointer to the opae_manager_ops data structure which defines the operations that the OPAE manager provides:
struct opae_manager_ops {
        int (*flash)(struct opae_manager *mgr, int id, 
		const char *buffer, u32 size, u64 *status);
        int (*get_eth_group_region_info)
			(struct opae_manager *mgr,
                struct opae_eth_group_region_info *info);
        int (*get_sensor_value)(struct opae_manager *mgr,
                struct opae_sensor_info *sensor,
                unsigned int *value);
        int (*get_board_info)(struct opae_manager *mgr,
                truct opae_board_info **info);
};
opae_manager_networking_ops A pointer to the opae_manager_networking_ops data structure which defines the networking functions required for networking on the Intel® FPGA PAC N3000:
struct opae_manager_networking_ops {
        int (*read_mac_rom)(struct opae_manager *mgr, int offset, 
					void *buf,int size);
        int (*write_mac_rom)(struct opae_manager *mgr, int offset, 
					void *buf, int size);
        int (*get_eth_group_nums)(struct opae_manager *mgr);
        int (*get_eth_group_info)(struct opae_manager *mgr,
                        u8 group_id, struct opae_eth_group_info *info);
        int (*eth_group_reg_read)(struct opae_manager *mgr, u8 group_id,
                        u8 type, u8 index, u16 addr, u32 *data);
        int (*eth_group_reg_write)(struct opae_manager *mgr, u8 group_id,
                        u8 type, u8 index, u16 addr, u32 data);
        int (*get_retimer_info)(struct opae_manager *mgr,
                        struct opae_retimer_info *info);
        int (*get_retimer_status)(struct opae_manager *mgr,
                        struct opae_retimer_status *status);
};
data A pointer to opae_manager private data.

The OPAE manager exports the following API functions: