Lines Matching full:asid

54 	struct qcom_iommu_ctx	*ctxs[];   /* indexed by asid */
62 u8 asid; /* asid and ctx bank # are 1:1 */ member
82 static struct qcom_iommu_ctx * to_ctx(struct qcom_iommu_domain *d, unsigned asid) in to_ctx() argument
87 return qcom_iommu->ctxs[asid]; in to_ctx()
141 iommu_writel(ctx, ARM_SMMU_CB_S1_TLBIASID, ctx->asid); in qcom_iommu_tlb_inv_context()
161 iova |= ctx->asid; in qcom_iommu_tlb_inv_range_nosync()
207 fsr, iova, fsynr, ctx->asid); in qcom_iommu_fault()
258 ret = qcom_scm_restore_sec_cfg(qcom_iommu->sec_id, ctx->asid); in qcom_iommu_init_domain()
282 FIELD_PREP(ARM_SMMU_TTBRn_ASID, ctx->asid)); in qcom_iommu_init_domain()
553 unsigned asid = args->args[0]; in qcom_iommu_of_xlate() local
568 /* make sure the asid specified in dt is valid, so we don't have in qcom_iommu_of_xlate()
571 if (WARN_ON(asid > qcom_iommu->max_asid) || in qcom_iommu_of_xlate()
572 WARN_ON(qcom_iommu->ctxs[asid] == NULL)) { in qcom_iommu_of_xlate()
590 return iommu_fwspec_add_ids(dev, &asid, 1); in qcom_iommu_of_xlate()
660 int asid; in get_asid() local
663 * of the context bank, and calculate the asid from that: in get_asid()
669 * Context banks are 0x1000 apart but, in some cases, the ASID in get_asid()
673 if (!of_property_read_u32(np, "qcom,ctx-asid", &val)) in get_asid()
674 asid = val; in get_asid()
676 asid = reg / 0x1000; in get_asid()
678 return asid; in get_asid()
728 ctx->asid = ret; in qcom_iommu_ctx_probe()
730 dev_dbg(dev, "found asid %u\n", ctx->asid); in qcom_iommu_ctx_probe()
732 qcom_iommu->ctxs[ctx->asid] = ctx; in qcom_iommu_ctx_probe()
744 qcom_iommu->ctxs[ctx->asid] = NULL; in qcom_iommu_ctx_remove()
788 /* find the max asid (which is 1:1 to ctx bank idx), so we know how in qcom_iommu_device_probe()