Lines Matching refs:encl_page
200 struct sgx_encl_page *encl_page = epc_page->owner; in sgx_encl_ewb() local
201 struct sgx_encl *encl = encl_page->encl; in sgx_encl_ewb()
207 encl_page->desc &= ~SGX_ENCL_PAGE_BEING_RECLAIMED; in sgx_encl_ewb()
245 encl_page->desc |= va_offset; in sgx_encl_ewb()
246 encl_page->va_page = va_page; in sgx_encl_ewb()
253 struct sgx_encl_page *encl_page = epc_page->owner; in sgx_reclaimer_write() local
254 struct sgx_encl *encl = encl_page->encl; in sgx_reclaimer_write()
261 encl_page->epc_page = NULL; in sgx_reclaimer_write()
300 struct sgx_encl_page *encl_page; in sgx_reclaim_pages() local
315 encl_page = epc_page->owner; in sgx_reclaim_pages()
317 if (kref_get_unless_zero(&encl_page->encl->refcount) != 0) in sgx_reclaim_pages()
329 encl_page = epc_page->owner; in sgx_reclaim_pages()
334 page_index = PFN_DOWN(encl_page->desc - encl_page->encl->base); in sgx_reclaim_pages()
336 mutex_lock(&encl_page->encl->lock); in sgx_reclaim_pages()
337 ret = sgx_encl_alloc_backing(encl_page->encl, page_index, &backing[i]); in sgx_reclaim_pages()
339 mutex_unlock(&encl_page->encl->lock); in sgx_reclaim_pages()
343 encl_page->desc |= SGX_ENCL_PAGE_BEING_RECLAIMED; in sgx_reclaim_pages()
344 mutex_unlock(&encl_page->encl->lock); in sgx_reclaim_pages()
352 kref_put(&encl_page->encl->refcount, sgx_encl_release); in sgx_reclaim_pages()
368 encl_page = epc_page->owner; in sgx_reclaim_pages()
371 kref_put(&encl_page->encl->refcount, sgx_encl_release); in sgx_reclaim_pages()