Lines Matching refs:arc_id

2205 static bool gaudi2_is_arc_enabled(struct hl_device *hdev, u64 arc_id);
2206 static void gaudi2_clr_arc_id_cap(struct hl_device *hdev, u64 arc_id);
2207 static void gaudi2_set_arc_id_cap(struct hl_device *hdev, u64 arc_id);
3184 static bool gaudi2_is_arc_nic_owned(u64 arc_id) in gaudi2_is_arc_nic_owned() argument
3186 switch (arc_id) { in gaudi2_is_arc_nic_owned()
3194 static bool gaudi2_is_arc_tpc_owned(u64 arc_id) in gaudi2_is_arc_tpc_owned() argument
3196 switch (arc_id) { in gaudi2_is_arc_tpc_owned()
3208 u64 arc_id; in gaudi2_init_arcs() local
3222 arc_id = gaudi2_queue_id_to_arc_id[i]; in gaudi2_init_arcs()
3223 if (gaudi2_is_arc_enabled(hdev, arc_id)) in gaudi2_init_arcs()
3226 if (gaudi2_is_arc_nic_owned(arc_id) && in gaudi2_init_arcs()
3227 !(hdev->nic_ports_mask & BIT_ULL(arc_id - CPU_ID_NIC_QMAN_ARC0))) in gaudi2_init_arcs()
3230 if (gaudi2_is_arc_tpc_owned(arc_id) && !(gaudi2->tpc_hw_cap_initialized & in gaudi2_init_arcs()
3231 BIT_ULL(arc_id - CPU_ID_TPC_QMAN_ARC0))) in gaudi2_init_arcs()
3234 gaudi2_set_arc_id_cap(hdev, arc_id); in gaudi2_init_arcs()
3293 u16 arc_id; in gaudi2_scrub_arcs_dccm() local
3296 for (arc_id = CPU_ID_SCHED_ARC0 ; arc_id < CPU_ID_MAX ; arc_id++) { in gaudi2_scrub_arcs_dccm()
3297 if (!gaudi2_is_arc_enabled(hdev, arc_id)) in gaudi2_scrub_arcs_dccm()
3300 rc = gaudi2_scrub_arc_dccm(hdev, arc_id); in gaudi2_scrub_arcs_dccm()
4604 u16 arc_id; in gaudi2_halt_arcs() local
4606 for (arc_id = CPU_ID_SCHED_ARC0; arc_id < CPU_ID_MAX; arc_id++) { in gaudi2_halt_arcs()
4607 if (gaudi2_is_arc_enabled(hdev, arc_id)) in gaudi2_halt_arcs()
4608 gaudi2_set_arc_running_mode(hdev, arc_id, HL_ENGINE_CORE_HALT); in gaudi2_halt_arcs()
4642 u16 arc_id; in gaudi2_reset_arcs() local
4647 for (arc_id = CPU_ID_SCHED_ARC0; arc_id < CPU_ID_MAX; arc_id++) in gaudi2_reset_arcs()
4648 if (gaudi2_is_arc_enabled(hdev, arc_id)) in gaudi2_reset_arcs()
4649 gaudi2_clr_arc_id_cap(hdev, arc_id); in gaudi2_reset_arcs()
6611 static bool gaudi2_is_arc_enabled(struct hl_device *hdev, u64 arc_id) in gaudi2_is_arc_enabled() argument
6615 switch (arc_id) { in gaudi2_is_arc_enabled()
6618 return !!(gaudi2->active_hw_arc & BIT_ULL(arc_id)); in gaudi2_is_arc_enabled()
6621 return !!(gaudi2->active_tpc_arc & BIT_ULL(arc_id - CPU_ID_TPC_QMAN_ARC0)); in gaudi2_is_arc_enabled()
6624 return !!(gaudi2->active_nic_arc & BIT_ULL(arc_id - CPU_ID_NIC_QMAN_ARC0)); in gaudi2_is_arc_enabled()
6631 static void gaudi2_clr_arc_id_cap(struct hl_device *hdev, u64 arc_id) in gaudi2_clr_arc_id_cap() argument
6635 switch (arc_id) { in gaudi2_clr_arc_id_cap()
6638 gaudi2->active_hw_arc &= ~(BIT_ULL(arc_id)); in gaudi2_clr_arc_id_cap()
6642 gaudi2->active_tpc_arc &= ~(BIT_ULL(arc_id - CPU_ID_TPC_QMAN_ARC0)); in gaudi2_clr_arc_id_cap()
6646 gaudi2->active_nic_arc &= ~(BIT_ULL(arc_id - CPU_ID_NIC_QMAN_ARC0)); in gaudi2_clr_arc_id_cap()
6654 static void gaudi2_set_arc_id_cap(struct hl_device *hdev, u64 arc_id) in gaudi2_set_arc_id_cap() argument
6658 switch (arc_id) { in gaudi2_set_arc_id_cap()
6661 gaudi2->active_hw_arc |= BIT_ULL(arc_id); in gaudi2_set_arc_id_cap()
6665 gaudi2->active_tpc_arc |= BIT_ULL(arc_id - CPU_ID_TPC_QMAN_ARC0); in gaudi2_set_arc_id_cap()
6669 gaudi2->active_nic_arc |= BIT_ULL(arc_id - CPU_ID_NIC_QMAN_ARC0); in gaudi2_set_arc_id_cap()