Lines Matching refs:rte
180 struct iosapic_rte_info *rte; in __gsi_to_irq() local
184 list_for_each_entry(rte, &info->rtes, rte_list) in __gsi_to_irq()
185 if (rte->iosapic->gsi_base + rte->rte_index == gsi) in __gsi_to_irq()
205 struct iosapic_rte_info *rte; in find_rte() local
207 list_for_each_entry(rte, &iosapic_intr_info[irq].rtes, rte_list) in find_rte()
208 if (rte->iosapic->gsi_base + rte->rte_index == gsi) in find_rte()
209 return rte; in find_rte()
220 struct iosapic_rte_info *rte; in set_rte() local
225 rte = find_rte(irq, gsi); in set_rte()
226 if (!rte) in set_rte()
229 rte_index = rte->rte_index; in set_rte()
249 iosapic_write(rte->iosapic, IOSAPIC_RTE_HIGH(rte_index), high32); in set_rte()
250 iosapic_write(rte->iosapic, IOSAPIC_RTE_LOW(rte_index), low32); in set_rte()
267 struct iosapic_rte_info *rte; in kexec_disable_iosapic() local
274 list_for_each_entry(rte, &info->rtes, in kexec_disable_iosapic()
276 iosapic_write(rte->iosapic, in kexec_disable_iosapic()
277 IOSAPIC_RTE_LOW(rte->rte_index), in kexec_disable_iosapic()
279 iosapic_eoi(rte->iosapic->addr, vec); in kexec_disable_iosapic()
291 struct iosapic_rte_info *rte; in mask_irq() local
298 list_for_each_entry(rte, &iosapic_intr_info[irq].rtes, rte_list) { in mask_irq()
299 rte_index = rte->rte_index; in mask_irq()
300 iosapic_write(rte->iosapic, IOSAPIC_RTE_LOW(rte_index), low32); in mask_irq()
310 struct iosapic_rte_info *rte; in unmask_irq() local
316 list_for_each_entry(rte, &iosapic_intr_info[irq].rtes, rte_list) { in unmask_irq()
317 rte_index = rte->rte_index; in unmask_irq()
318 iosapic_write(rte->iosapic, IOSAPIC_RTE_LOW(rte_index), low32); in unmask_irq()
332 struct iosapic_rte_info *rte; in iosapic_set_affinity() local
366 list_for_each_entry(rte, &iosapic_intr_info[irq].rtes, rte_list) { in iosapic_set_affinity()
367 iosapic = rte->iosapic; in iosapic_set_affinity()
368 rte_index = rte->rte_index; in iosapic_set_affinity()
393 struct iosapic_rte_info *rte; in iosapic_unmask_level_irq() local
403 list_for_each_entry(rte, &iosapic_intr_info[irq].rtes, rte_list) in iosapic_unmask_level_irq()
404 iosapic_eoi(rte->iosapic->addr, vec); in iosapic_unmask_level_irq()
556 struct iosapic_rte_info *rte; in register_intr() local
565 rte = find_rte(irq, gsi); in register_intr()
566 if (!rte) { in register_intr()
567 rte = kzalloc(sizeof (*rte), GFP_ATOMIC); in register_intr()
568 if (!rte) { in register_intr()
574 rte->iosapic = &iosapic_lists[index]; in register_intr()
575 rte->rte_index = gsi - rte->iosapic->gsi_base; in register_intr()
576 rte->refcnt++; in register_intr()
577 list_add_tail(&rte->rte_list, &iosapic_intr_info[irq].rtes); in register_intr()
581 else if (rte->refcnt == NO_REF_RTE) { in register_intr()
590 rte->refcnt++; in register_intr()
717 struct iosapic_rte_info *rte; in iosapic_register_intr() local
730 rte = find_rte(irq, gsi); in iosapic_register_intr()
734 } else if (rte->refcnt != NO_REF_RTE) { in iosapic_register_intr()
735 rte->refcnt++; in iosapic_register_intr()
787 struct iosapic_rte_info *rte; in iosapic_unregister_intr() local
803 if ((rte = find_rte(irq, gsi)) == NULL) { in iosapic_unregister_intr()
810 if (--rte->refcnt > 0) in iosapic_unregister_intr()
813 rte->refcnt = NO_REF_RTE; in iosapic_unregister_intr()
817 iosapic_write(rte->iosapic, IOSAPIC_RTE_LOW(rte->rte_index), low32); in iosapic_unregister_intr()
1011 struct iosapic_rte_info *rte, *temp; in iosapic_delete_rte() local
1013 list_for_each_entry_safe(rte, temp, &iosapic_intr_info[irq].rtes, in iosapic_delete_rte()
1015 if (rte->iosapic->gsi_base + rte->rte_index == gsi) { in iosapic_delete_rte()
1016 if (rte->refcnt) in iosapic_delete_rte()
1019 list_del(&rte->rte_list); in iosapic_delete_rte()
1020 kfree(rte); in iosapic_delete_rte()