Lines Matching refs:mm
144 tee_mm_entry_t *mm = NULL; in rwp_paged_iv_alloc() local
155 mm = tee_mm_alloc(&tee_mm_sec_ddr, size); in rwp_paged_iv_alloc()
156 if (!mm) in rwp_paged_iv_alloc()
158 rwp->idx = (tee_mm_get_smem(mm) - tee_mm_sec_ddr.lo) / SMALL_PAGE_SIZE; in rwp_paged_iv_alloc()
167 tee_mm_free(mm); in rwp_paged_iv_alloc()
220 tee_mm_entry_t *mm = tee_mm_find(&tee_mm_sec_ddr, pa); in rwp_paged_iv_free() local
222 assert(mm); in rwp_paged_iv_free()
225 tee_mm_free(mm); in rwp_paged_iv_free()
255 tee_mm_entry_t *mm = NULL; in rwp_unpaged_iv_alloc() local
268 mm = tee_mm_alloc(&tee_mm_sec_ddr, size); in rwp_unpaged_iv_alloc()
269 if (!mm) in rwp_unpaged_iv_alloc()
271 rwp->store = phys_to_virt(tee_mm_get_smem(mm), MEM_AREA_TA_RAM, size); in rwp_unpaged_iv_alloc()
330 tee_mm_entry_t *mm = NULL; in rwp_unpaged_iv_free() local
336 mm = tee_mm_find(&tee_mm_sec_ddr, virt_to_phys(rwp->store)); in rwp_unpaged_iv_free()
338 assert(mm); in rwp_unpaged_iv_free()
341 tee_mm_free(mm); in rwp_unpaged_iv_free()
744 tee_mm_entry_t *mm; member
762 f->mm = tee_mm_alloc(&tee_mm_sec_ddr, size); in fobj_sec_mem_alloc()
763 if (!f->mm) in fobj_sec_mem_alloc()
766 va = phys_to_virt(tee_mm_get_smem(f->mm), MEM_AREA_TA_RAM, size); in fobj_sec_mem_alloc()
777 tee_mm_free(f->mm); in fobj_sec_mem_alloc()
795 tee_mm_free(f->mm); in sec_mem_free()
806 return tee_mm_get_smem(f->mm) + page_idx * SMALL_PAGE_SIZE; in sec_mem_get_pa()