Home
last modified time | relevance | path

Searched refs:hpio (Results 1 – 5 of 5) sorted by relevance

/kernel/linux/linux-5.10/drivers/hyperhold/
Dhp_iotab.c36 static struct hpio *__iotab_search_get(struct hp_iotab *iotab, u32 eid) in __iotab_search_get()
38 struct hpio *hpio = NULL; in __iotab_search_get() local
40 list_for_each_entry(hpio, &iotab->io_list, list) in __iotab_search_get()
41 if (hpio->eid == eid && kref_get_unless_zero(&hpio->refcnt)) in __iotab_search_get()
42 return hpio; in __iotab_search_get()
47 static struct hpio *iotab_search_get(struct hp_iotab *iotab, u32 eid) in iotab_search_get()
49 struct hpio *hpio = NULL; in iotab_search_get() local
53 hpio = __iotab_search_get(iotab, eid); in iotab_search_get()
56 pr_info("find hpio %p for eid %u.\n", hpio, eid); in iotab_search_get()
58 return hpio; in iotab_search_get()
[all …]
Dhyperhold.h13 struct hpio;
15 typedef void (*hp_endio)(struct hpio *);
31 struct hpio *hyperhold_io_alloc(u32 eid, gfp_t gfp, unsigned int op, bool new_page);
32 void hyperhold_io_free(struct hpio *hpio);
34 struct hpio *hyperhold_io_get(u32 eid, gfp_t gfp, unsigned int op);
35 bool hyperhold_io_put(struct hpio *hpio);
37 void hyperhold_io_complete(struct hpio *hpio);
38 void hyperhold_io_wait(struct hpio *hpio);
40 bool hyperhold_io_success(struct hpio *hpio);
42 int hyperhold_io_extent(struct hpio *hpio);
[all …]
Dhp_core.c412 struct hpio *hpio = NULL; in hyperhold_should_free_extent() local
421 hpio = hpio_get(eid); in hyperhold_should_free_extent()
422 if (!hpio) { in hyperhold_should_free_extent()
426 hpio->free_extent = hyperhold_free_extent; in hyperhold_should_free_extent()
427 hpio_put(hpio); in hyperhold_should_free_extent()
435 struct hpio *hyperhold_io_alloc(u32 eid, gfp_t gfp, unsigned int op, bool new_page) in hyperhold_io_alloc()
437 struct hpio *hpio = NULL; in hyperhold_io_alloc() local
448 hpio = hpio_alloc(nr_page, gfp, op, new_page); in hyperhold_io_alloc()
449 if (!hpio) in hyperhold_io_alloc()
451 hpio->eid = eid; in hyperhold_io_alloc()
[all …]
Dhp_iotab.h23 struct hpio;
25 typedef void (*hp_endio)(struct hpio *);
27 struct hpio { struct
46 struct hpio *hpio_alloc(u32 nr_page, gfp_t gfp, unsigned int op, bool new_page); argument
47 void hpio_free(struct hpio *hpio);
49 struct hpio *hpio_get(u32 eid);
50 bool hpio_put(struct hpio *hpio);
51 struct hpio *hpio_get_alloc(u32 eid, u32 nr_page, gfp_t gfp, unsigned int op);
53 void hpio_complete(struct hpio *hpio);
54 void hpio_wait(struct hpio *hpio);
[all …]
/kernel/linux/linux-5.10/drivers/block/zram/zram_group/
Dgroup_writeback.c79 static void copy_obj(struct hpio *hpio, u32 offset, char *obj, u32 size, bool to) in copy_obj() argument
87 buf = page_to_virt(hyperhold_io_page(hpio, page_id)); in copy_obj()
95 buf = page_to_virt(hyperhold_io_page(hpio, page_id)); in copy_obj()
100 buf = page_to_virt(hyperhold_io_page(hpio, page_id + 1)); in copy_obj()
108 struct hpio *hpio, u32 offset) in move_obj_to_hpio() argument
116 eid = hyperhold_io_extent(hpio); in move_obj_to_hpio()
133 copy_obj(hpio, offset, src, size, true); in move_obj_to_hpio()
142 index, gid, hpio, eid, size, offset); in move_obj_to_hpio()
149 static void move_obj_from_hpio(struct zram *zram, int index, struct hpio *hpio) in move_obj_from_hpio() argument
158 eid = hyperhold_io_extent(hpio); in move_obj_from_hpio()
[all …]