Lines Matching defs:obj

25 static inline bool is_omap_iommu_detached(struct omap_iommu *obj)
27 return !obj->domain;
38 iommu_read_reg(obj, MMU_##name)); \
44 omap2_iommu_dump_ctx(struct omap_iommu *obj, char *buf, ssize_t len)
68 static ssize_t omap_iommu_dump_ctx(struct omap_iommu *obj, char *buf,
71 if (!obj || !buf)
74 pm_runtime_get_sync(obj->dev);
76 bytes = omap2_iommu_dump_ctx(obj, buf, bytes);
78 pm_runtime_put_sync(obj->dev);
86 struct omap_iommu *obj = file->private_data;
90 if (is_omap_iommu_detached(obj))
100 bytes = omap_iommu_dump_ctx(obj, p, count);
113 __dump_tlb_entries(struct omap_iommu *obj, struct cr_regs *crs, int num)
120 pm_runtime_get_sync(obj->dev);
121 iotlb_lock_get(obj, &saved);
123 for_each_iotlb_cr(obj, num, i, tmp) {
129 iotlb_lock_set(obj, &saved);
130 pm_runtime_put_sync(obj->dev);
135 static ssize_t iotlb_dump_cr(struct omap_iommu *obj, struct cr_regs *cr,
143 static size_t omap_dump_tlb_entries(struct omap_iommu *obj, struct seq_file *s)
148 num = obj->nr_tlb_entries;
154 num = __dump_tlb_entries(obj, cr, num);
156 iotlb_dump_cr(obj, cr + i, s);
164 struct omap_iommu *obj = s->private;
166 if (is_omap_iommu_detached(obj))
173 omap_dump_tlb_entries(obj, s);
185 struct omap_iommu *obj = s->private;
187 spin_lock(&obj->page_table_lock);
189 iopgd = iopgd_offset(obj, 0);
210 spin_unlock(&obj->page_table_lock);
215 struct omap_iommu *obj = s->private;
217 if (is_omap_iommu_detached(obj))
242 void omap_iommu_debugfs_add(struct omap_iommu *obj)
249 d = debugfs_create_dir(obj->name, iommu_debug_root);
250 obj->debug_dir = d;
252 debugfs_create_u32("nr_tlb_entries", 0400, d, &obj->nr_tlb_entries);
253 debugfs_create_file("regs", 0400, d, obj, &regs_fops);
254 debugfs_create_file("tlb", 0400, d, obj, &tlb_fops);
255 debugfs_create_file("pagetable", 0400, d, obj, &pagetable_fops);
258 void omap_iommu_debugfs_remove(struct omap_iommu *obj)
260 if (!obj->debug_dir)
263 debugfs_remove_recursive(obj->debug_dir);