Changeset View
Changeset View
Standalone View
Standalone View
sys/dev/ice/ice_controlq.h
Show All 37 Lines | |||||
/* Maximum buffer lengths for all control queue types */ | /* Maximum buffer lengths for all control queue types */ | ||||
#define ICE_AQ_MAX_BUF_LEN 4096 | #define ICE_AQ_MAX_BUF_LEN 4096 | ||||
#define ICE_MBXQ_MAX_BUF_LEN 4096 | #define ICE_MBXQ_MAX_BUF_LEN 4096 | ||||
#define ICE_CTL_Q_DESC(R, i) \ | #define ICE_CTL_Q_DESC(R, i) \ | ||||
(&(((struct ice_aq_desc *)((R).desc_buf.va))[i])) | (&(((struct ice_aq_desc *)((R).desc_buf.va))[i])) | ||||
#define ICE_CTL_Q_DESC_UNUSED(R) \ | #define ICE_CTL_Q_DESC_UNUSED(R) \ | ||||
(u16)((((R)->next_to_clean > (R)->next_to_use) ? 0 : (R)->count) + \ | ((u16)((((R)->next_to_clean > (R)->next_to_use) ? 0 : (R)->count) + \ | ||||
(R)->next_to_clean - (R)->next_to_use - 1) | (R)->next_to_clean - (R)->next_to_use - 1)) | ||||
/* Defines that help manage the driver vs FW API checks. | /* Defines that help manage the driver vs FW API checks. | ||||
* Take a look at ice_aq_ver_check in ice_controlq.c for actual usage. | * Take a look at ice_aq_ver_check in ice_controlq.c for actual usage. | ||||
*/ | */ | ||||
#define EXP_FW_API_VER_BRANCH 0x00 | #define EXP_FW_API_VER_BRANCH 0x00 | ||||
#define EXP_FW_API_VER_MAJOR 0x01 | #define EXP_FW_API_VER_MAJOR 0x01 | ||||
#define EXP_FW_API_VER_MINOR 0x05 | #define EXP_FW_API_VER_MINOR 0x05 | ||||
▲ Show 20 Lines • Show All 51 Lines • ▼ Show 20 Lines | struct ice_rq_event_info { | ||||
u16 msg_len; | u16 msg_len; | ||||
u16 buf_len; | u16 buf_len; | ||||
u8 *msg_buf; | u8 *msg_buf; | ||||
}; | }; | ||||
/* Control Queue information */ | /* Control Queue information */ | ||||
struct ice_ctl_q_info { | struct ice_ctl_q_info { | ||||
enum ice_ctl_q qtype; | enum ice_ctl_q qtype; | ||||
enum ice_aq_err rq_last_status; /* last status on receive queue */ | |||||
struct ice_ctl_q_ring rq; /* receive queue */ | struct ice_ctl_q_ring rq; /* receive queue */ | ||||
struct ice_ctl_q_ring sq; /* send queue */ | struct ice_ctl_q_ring sq; /* send queue */ | ||||
u32 sq_cmd_timeout; /* send queue cmd write back timeout */ | u32 sq_cmd_timeout; /* send queue cmd write back timeout */ | ||||
u16 num_rq_entries; /* receive queue depth */ | u16 num_rq_entries; /* receive queue depth */ | ||||
u16 num_sq_entries; /* send queue depth */ | u16 num_sq_entries; /* send queue depth */ | ||||
u16 rq_buf_size; /* receive queue buffer size */ | u16 rq_buf_size; /* receive queue buffer size */ | ||||
u16 sq_buf_size; /* send queue buffer size */ | u16 sq_buf_size; /* send queue buffer size */ | ||||
enum ice_aq_err sq_last_status; /* last status on send queue */ | enum ice_aq_err sq_last_status; /* last status on send queue */ | ||||
struct ice_lock sq_lock; /* Send queue lock */ | struct ice_lock sq_lock; /* Send queue lock */ | ||||
struct ice_lock rq_lock; /* Receive queue lock */ | struct ice_lock rq_lock; /* Receive queue lock */ | ||||
}; | }; | ||||
#endif /* _ICE_CONTROLQ_H_ */ | #endif /* _ICE_CONTROLQ_H_ */ |