Lines Matching refs:grp
554 struct otx2_cpt_eng_grp_info *grp) in release_engines() argument
559 if (!grp->engs[i].type) in release_engines()
562 if (grp->engs[i].count > 0) { in release_engines()
563 ret = update_engines_avail_count(dev, &grp->g->avail, in release_engines()
564 &grp->engs[i], in release_engines()
565 grp->engs[i].count); in release_engines()
570 grp->engs[i].type = 0; in release_engines()
571 grp->engs[i].count = 0; in release_engines()
572 grp->engs[i].offset = 0; in release_engines()
573 grp->engs[i].ucode = NULL; in release_engines()
574 bitmap_zero(grp->engs[i].bmap, grp->g->engs_num); in release_engines()
580 struct otx2_cpt_eng_grp_info *grp, in do_reserve_engines() argument
587 if (!grp->engs[i].type) { in do_reserve_engines()
588 engs = &grp->engs[i]; in do_reserve_engines()
599 ret = update_engines_offset(dev, &grp->g->avail, engs); in do_reserve_engines()
604 ret = update_engines_avail_count(dev, &grp->g->avail, engs, in do_reserve_engines()
614 struct otx2_cpt_eng_grp_info *grp, in check_engines_availability() argument
621 avail_cnt = grp->g->avail.se_cnt; in check_engines_availability()
625 avail_cnt = grp->g->avail.ie_cnt; in check_engines_availability()
629 avail_cnt = grp->g->avail.ae_cnt; in check_engines_availability()
648 struct otx2_cpt_eng_grp_info *grp, in reserve_engines() argument
655 ret = check_engines_availability(dev, grp, &req_engs[i]); in reserve_engines()
662 ret = do_reserve_engines(dev, grp, &req_engs[i]); in reserve_engines()
774 src_grp = &dst_grp->g->grp[dst_grp->mirror.idx]; in remove_eng_grp_mirroring()
813 struct otx2_cpt_eng_grp_info *grp) in find_mirrored_eng_grp() argument
815 struct otx2_cpt_eng_grps *eng_grps = grp->g; in find_mirrored_eng_grp()
819 if (!eng_grps->grp[i].is_enabled) in find_mirrored_eng_grp()
821 if (eng_grps->grp[i].ucode[0].type && in find_mirrored_eng_grp()
822 eng_grps->grp[i].ucode[1].type) in find_mirrored_eng_grp()
824 if (grp->idx == i) in find_mirrored_eng_grp()
826 if (!strncasecmp(eng_grps->grp[i].ucode[0].ver_str, in find_mirrored_eng_grp()
827 grp->ucode[0].ver_str, in find_mirrored_eng_grp()
829 return &eng_grps->grp[i]; in find_mirrored_eng_grp()
841 if (!eng_grps->grp[i].is_enabled) in find_unused_eng_grp()
842 return &eng_grps->grp[i]; in find_unused_eng_grp()
907 &eng_grp->g->grp[eng_grp->mirror.idx], in eng_grp_update_masks()
960 ucode = &eng_grp->g->grp[eng_grp->mirror.idx].ucode[0]; in update_ucode_ptrs()
1071 if (eng_grps->grp[i].mirror.is_ena) in delete_engine_grps()
1072 delete_engine_group(&pdev->dev, &eng_grps->grp[i]); in delete_engine_grps()
1076 delete_engine_group(&pdev->dev, &eng_grps->grp[i]); in delete_engine_grps()
1116 struct otx2_cpt_eng_grp_info *grp; in otx2_cpt_get_eng_grp() local
1120 grp = &eng_grps->grp[i]; in otx2_cpt_get_eng_grp()
1121 if (!grp->is_enabled) in otx2_cpt_get_eng_grp()
1125 if (eng_grp_has_eng_type(grp, eng_type) && in otx2_cpt_get_eng_grp()
1126 !eng_grp_has_eng_type(grp, OTX2_CPT_IE_TYPES)) { in otx2_cpt_get_eng_grp()
1131 if (eng_grp_has_eng_type(grp, eng_type)) { in otx2_cpt_get_eng_grp()
1345 struct otx2_cpt_eng_grp_info *grp; in otx2_cpt_cleanup_eng_grps() local
1352 grp = &eng_grps->grp[i]; in otx2_cpt_cleanup_eng_grps()
1354 kfree(grp->engs[j].bmap); in otx2_cpt_cleanup_eng_grps()
1355 grp->engs[j].bmap = NULL; in otx2_cpt_cleanup_eng_grps()
1364 struct otx2_cpt_eng_grp_info *grp; in otx2_cpt_init_eng_grps() local
1385 grp = &eng_grps->grp[i]; in otx2_cpt_init_eng_grps()
1386 grp->g = eng_grps; in otx2_cpt_init_eng_grps()
1387 grp->idx = i; in otx2_cpt_init_eng_grps()
1390 grp->engs[j].bmap = in otx2_cpt_init_eng_grps()
1393 if (!grp->engs[j].bmap) { in otx2_cpt_init_eng_grps()
1546 iq_cmd.cptr.s.grp = otx2_cpt_get_eng_grp(&cptpf->eng_grps, in otx2_cpt_discover_eng_capabilities()
1754 if (!eng_grps->grp[egrp].is_enabled) { in otx2_cpt_dl_custom_egrp_delete()
1759 ret = delete_engine_group(dev, &eng_grps->grp[egrp]); in otx2_cpt_dl_custom_egrp_delete()
1786 &eng_grp->g->grp[eng_grp->mirror.idx], in get_engs_info()
1815 struct otx2_cpt_eng_grp_info *grp; in otx2_cpt_print_uc_dbg_info() local
1827 grp = &eng_grps->grp[i]; in otx2_cpt_print_uc_dbg_info()
1829 grp->is_enabled ? "enabled" : "disabled"); in otx2_cpt_print_uc_dbg_info()
1830 if (grp->is_enabled) { in otx2_cpt_print_uc_dbg_info()
1831 mirrored_grp = &eng_grps->grp[grp->mirror.idx]; in otx2_cpt_print_uc_dbg_info()
1833 grp->mirror.is_ena ? in otx2_cpt_print_uc_dbg_info()
1835 grp->ucode[0].filename, in otx2_cpt_print_uc_dbg_info()
1836 grp->mirror.is_ena ? in otx2_cpt_print_uc_dbg_info()
1838 grp->ucode[0].ver_str); in otx2_cpt_print_uc_dbg_info()
1839 if (is_2nd_ucode_used(grp)) in otx2_cpt_print_uc_dbg_info()
1841 grp->ucode[1].filename, in otx2_cpt_print_uc_dbg_info()
1842 grp->ucode[1].ver_str); in otx2_cpt_print_uc_dbg_info()
1846 engs = &grp->engs[j]; in otx2_cpt_print_uc_dbg_info()
1850 get_engs_info(grp, engs_info, in otx2_cpt_print_uc_dbg_info()