Lines Matching refs:handle

87 	return zram->table[index].handle;  in zram_get_handle()
90 static void zram_set_handle(struct zram *zram, u32 index, unsigned long handle) in zram_set_handle() argument
92 zram->table[index].handle = handle; in zram_set_handle()
1258 unsigned long handle; in zram_free_page() local
1292 handle = zram_get_handle(zram, index); in zram_free_page()
1293 if (!handle) in zram_free_page()
1296 zs_free(zram->mem_pool, handle); in zram_free_page()
1316 unsigned long handle; in zram_read_from_zspool() local
1322 handle = zram_get_handle(zram, index); in zram_read_from_zspool()
1323 if (!handle || zram_test_flag(zram, index, ZRAM_SAME)) { in zram_read_from_zspool()
1327 value = handle ? zram_get_element(zram, index) : 0; in zram_read_from_zspool()
1341 src = zs_map_object(zram->mem_pool, handle, ZS_MM_RO); in zram_read_from_zspool()
1353 zs_unmap_object(zram->mem_pool, handle); in zram_read_from_zspool()
1416 unsigned long handle = -ENOMEM; in zram_write_page() local
1442 zs_free(zram->mem_pool, handle); in zram_write_page()
1461 if (IS_ERR_VALUE(handle)) in zram_write_page()
1462 handle = zs_malloc(zram->mem_pool, comp_len, in zram_write_page()
1467 if (IS_ERR_VALUE(handle)) { in zram_write_page()
1470 handle = zs_malloc(zram->mem_pool, comp_len, in zram_write_page()
1473 if (IS_ERR_VALUE(handle)) in zram_write_page()
1474 return PTR_ERR((void *)handle); in zram_write_page()
1493 zs_free(zram->mem_pool, handle); in zram_write_page()
1497 dst = zs_map_object(zram->mem_pool, handle, ZS_MM_WO); in zram_write_page()
1507 zs_unmap_object(zram->mem_pool, handle); in zram_write_page()
1527 zram_set_handle(zram, index, handle); in zram_write_page()