Lines Matching refs:ccq
3298 void irdma_sc_ccq_arm(struct irdma_sc_cq *ccq) in irdma_sc_ccq_arm() argument
3305 get_64bit_val(ccq->cq_uk.shadow_area, 32, &temp_val); in irdma_sc_ccq_arm()
3314 set_64bit_val(ccq->cq_uk.shadow_area, 32, temp_val); in irdma_sc_ccq_arm()
3318 writel(ccq->cq_uk.cq_id, ccq->dev->cq_arm_db); in irdma_sc_ccq_arm()
3326 int irdma_sc_ccq_get_cqe_info(struct irdma_sc_cq *ccq, in irdma_sc_ccq_get_cqe_info() argument
3337 if (ccq->cq_uk.avoid_mem_cflct) in irdma_sc_ccq_get_cqe_info()
3338 cqe = IRDMA_GET_CURRENT_EXTENDED_CQ_ELEM(&ccq->cq_uk); in irdma_sc_ccq_get_cqe_info()
3340 cqe = IRDMA_GET_CURRENT_CQ_ELEM(&ccq->cq_uk); in irdma_sc_ccq_get_cqe_info()
3344 if (polarity != ccq->cq_uk.polarity) in irdma_sc_ccq_get_cqe_info()
3369 IRDMA_RING_MOVE_HEAD(ccq->cq_uk.cq_ring, ret_code); in irdma_sc_ccq_get_cqe_info()
3370 if (!IRDMA_RING_CURRENT_HEAD(ccq->cq_uk.cq_ring)) in irdma_sc_ccq_get_cqe_info()
3371 ccq->cq_uk.polarity ^= 1; in irdma_sc_ccq_get_cqe_info()
3374 IRDMA_RING_MOVE_TAIL(ccq->cq_uk.cq_ring); in irdma_sc_ccq_get_cqe_info()
3375 set_64bit_val(ccq->cq_uk.shadow_area, 0, in irdma_sc_ccq_get_cqe_info()
3376 IRDMA_RING_CURRENT_HEAD(ccq->cq_uk.cq_ring)); in irdma_sc_ccq_get_cqe_info()
3381 ccq->dev->cqp_cmd_stats[IRDMA_OP_CMPL_CMDS]++; in irdma_sc_ccq_get_cqe_info()
3396 struct irdma_sc_cq *ccq; in irdma_sc_poll_for_cqp_op_done() local
3400 ccq = cqp->dev->ccq; in irdma_sc_poll_for_cqp_op_done()
3405 if (irdma_sc_ccq_get_cqe_info(ccq, &info)) { in irdma_sc_poll_for_cqp_op_done()
3703 irdma_sc_remove_cq_ctx(ceq, ceq->dev->ccq); in irdma_sc_cceq_destroy_done()
3722 dev->ccq->vsi = ceq->vsi; in irdma_sc_cceq_create()
3724 ret_code = irdma_sc_add_cq_ctx(ceq, ceq->dev->ccq); in irdma_sc_cceq_create()
4186 info->dev->ccq = cq; in irdma_sc_ccq_init()
4194 static inline int irdma_sc_ccq_create_done(struct irdma_sc_cq *ccq) in irdma_sc_ccq_create_done() argument
4198 cqp = ccq->dev->cqp; in irdma_sc_ccq_create_done()
4210 int irdma_sc_ccq_create(struct irdma_sc_cq *ccq, u64 scratch, in irdma_sc_ccq_create() argument
4215 ret_code = irdma_sc_cq_create(ccq, scratch, check_overflow, post_sq); in irdma_sc_ccq_create()
4220 ret_code = irdma_sc_ccq_create_done(ccq); in irdma_sc_ccq_create()
4224 ccq->dev->cqp->process_cqp_sds = irdma_cqp_sds_cmd; in irdma_sc_ccq_create()
4235 int irdma_sc_ccq_destroy(struct irdma_sc_cq *ccq, u64 scratch, bool post_sq) in irdma_sc_ccq_destroy() argument
4243 cqp = ccq->dev->cqp; in irdma_sc_ccq_destroy()
4248 set_64bit_val(wqe, 0, ccq->cq_uk.cq_size); in irdma_sc_ccq_destroy()
4249 set_64bit_val(wqe, 8, (uintptr_t)ccq >> 1); in irdma_sc_ccq_destroy()
4250 set_64bit_val(wqe, 40, ccq->shadow_area_pa); in irdma_sc_ccq_destroy()
4252 hdr = ccq->cq_uk.cq_id | in irdma_sc_ccq_destroy()
4253 FLD_LS_64(ccq->dev, (ccq->ceq_id_valid ? ccq->ceq_id : 0), in irdma_sc_ccq_destroy()
4256 FIELD_PREP(IRDMA_CQPSQ_CQ_ENCEQEMASK, ccq->ceqe_mask) | in irdma_sc_ccq_destroy()
4257 FIELD_PREP(IRDMA_CQPSQ_CQ_CEQIDVALID, ccq->ceq_id_valid) | in irdma_sc_ccq_destroy()
4258 FIELD_PREP(IRDMA_CQPSQ_TPHEN, ccq->tph_en) | in irdma_sc_ccq_destroy()
4259 FIELD_PREP(IRDMA_CQPSQ_CQ_AVOIDMEMCNFLCT, ccq->cq_uk.avoid_mem_cflct) | in irdma_sc_ccq_destroy()