Lines Matching refs:collection
144 struct its_collection *collection;
158 * @cte_esz: collection table entry size
256 * Finds and returns a collection in the ITS collection table.
261 struct its_collection *collection;
263 list_for_each_entry(collection, &its->collection_list, coll_list) {
264 if (coll_id == collection->collection_id)
265 return collection;
384 * Needs to be called whenever either the collection for a LPIs has
385 * changed or the collection itself got retargeted.
391 if (!its_is_collection_mapped(ite->collection))
394 vcpu = kvm_get_vcpu(kvm, ite->collection->target_addr);
399 * Updates the target VCPU for every LPI targeting this collection.
409 if (!ite->collection || coll != ite->collection)
683 if (!ite || !its_is_collection_mapped(ite->collection))
686 vcpu = kvm_get_vcpu(kvm, ite->collection->target_addr);
854 if (ite && its_is_collection_mapped(ite->collection)) {
870 * The MOVI command moves an ITTE to a different collection.
881 struct its_collection *collection;
887 if (!its_is_collection_mapped(ite->collection))
890 collection = find_collection(its, coll_id);
891 if (!its_is_collection_mapped(collection))
894 ite->collection = collection;
895 vcpu = kvm_get_vcpu(kvm, collection->target_addr);
926 /* as GITS_TYPER.CIL == 0, ITS supports 16-bit collection ID */
988 struct its_collection *collection;
993 collection = kzalloc(sizeof(*collection), GFP_KERNEL);
994 if (!collection)
997 collection->collection_id = coll_id;
998 collection->target_addr = COLLECTION_NOT_MAPPED;
1000 list_add_tail(&collection->coll_list, &its->collection_list);
1001 *colp = collection;
1008 struct its_collection *collection;
1013 * Clearing the mapping for that collection ID removes the
1017 collection = find_collection(its, coll_id);
1018 if (!collection)
1022 if (ite->collection &&
1023 ite->collection->collection_id == coll_id)
1024 ite->collection = NULL;
1026 list_del(&collection->coll_list);
1027 kfree(collection);
1032 struct its_collection *collection,
1042 ite->collection = collection;
1061 struct its_collection *collection, *new_coll = NULL;
1084 collection = find_collection(its, coll_id);
1085 if (!collection) {
1086 int ret = vgic_its_alloc_collection(its, &collection, coll_id);
1089 new_coll = collection;
1092 ite = vgic_its_alloc_ite(device, collection, event_id);
1099 if (its_is_collection_mapped(collection))
1100 vcpu = kvm_get_vcpu(kvm, collection->target_addr);
1214 * The MAPC command maps collection IDs to redistributors.
1222 struct its_collection *collection;
1236 collection = find_collection(its, coll_id);
1238 if (!collection) {
1241 ret = vgic_its_alloc_collection(its, &collection,
1245 collection->target_addr = target_addr;
1247 collection->target_addr = target_addr;
1248 update_affinity_collection(kvm, its, collection);
1300 * The INVALL command requests flushing of all IRQ data in this collection.
1301 * Find the VCPU mapped to that collection, then iterate over the VM's list
1311 struct its_collection *collection;
1317 collection = find_collection(its, coll_id);
1318 if (!its_is_collection_mapped(collection))
1321 vcpu = kvm_get_vcpu(kvm, collection->target_addr);
1726 * device/collection BASER are invalid
2140 ite->collection->collection_id;
2155 struct its_collection *collection;
2182 collection = find_collection(its, coll_id);
2183 if (!collection)
2186 ite = vgic_its_alloc_ite(dev, collection, event_id);
2190 if (its_is_collection_mapped(collection))
2191 vcpu = kvm_get_vcpu(kvm, collection->target_addr);
2460 struct its_collection *collection,
2466 ((u64)collection->target_addr << KVM_ITS_CTE_RDBASE_SHIFT) |
2467 collection->collection_id);
2474 struct its_collection *collection;
2495 collection = find_collection(its, coll_id);
2496 if (collection)
2498 ret = vgic_its_alloc_collection(its, &collection, coll_id);
2501 collection->target_addr = target_addr;
2506 * vgic_its_save_collection_table - Save the collection table into
2514 struct its_collection *collection;
2524 list_for_each_entry(collection, &its->collection_list, coll_list) {
2525 ret = vgic_its_save_cte(its, collection, gpa, cte_esz);
2546 * vgic_its_restore_collection_table - reads the collection table