Lines Matching refs:z3fold_header
62 #define ZHDR_SIZE_ALIGNED round_up(sizeof(struct z3fold_header), CHUNK_SIZE)
99 * struct z3fold_header - z3fold page metadata occupying first chunks of each
115 struct z3fold_header {
194 static struct z3fold_header *__z3fold_alloc(struct z3fold_pool *, size_t, bool);
239 static inline void z3fold_page_lock(struct z3fold_header *zhdr)
245 static inline int z3fold_page_trylock(struct z3fold_header *zhdr)
251 static inline void z3fold_page_unlock(struct z3fold_header *zhdr)
257 static inline struct z3fold_header *__get_z3fold_header(unsigned long handle,
261 struct z3fold_header *zhdr;
271 zhdr = (struct z3fold_header *)(addr & PAGE_MASK);
280 zhdr = (struct z3fold_header *)(handle & PAGE_MASK);
287 static inline struct z3fold_header *handle_to_z3fold_header(unsigned long h)
293 static inline struct z3fold_header *get_z3fold_header(unsigned long h)
298 static inline void put_z3fold_header(struct z3fold_header *zhdr)
306 static inline void free_handle(unsigned long handle, struct z3fold_header *zhdr)
397 static struct z3fold_header *init_z3fold_page(struct page *page, bool headless,
400 struct z3fold_header *zhdr = page_address(page);
446 static inline int __idx(struct z3fold_header *zhdr, enum buddy bud)
455 static unsigned long __encode_handle(struct z3fold_header *zhdr,
481 static unsigned long encode_handle(struct z3fold_header *zhdr, enum buddy bud)
505 struct z3fold_header *zhdr;
513 zhdr = (struct z3fold_header *)(addr & PAGE_MASK);
517 static inline struct z3fold_pool *zhdr_to_pool(struct z3fold_header *zhdr)
522 static void __release_z3fold_page(struct z3fold_header *zhdr, bool locked)
547 struct z3fold_header *zhdr = container_of(ref, struct z3fold_header,
554 struct z3fold_header *zhdr = container_of(ref, struct z3fold_header,
562 struct z3fold_header *zhdr = container_of(ref, struct z3fold_header,
580 struct z3fold_header *zhdr = list_first_entry(&pool->stale,
581 struct z3fold_header, buddy);
600 static int num_free_chunks(struct z3fold_header *zhdr)
622 struct z3fold_header *zhdr)
637 static inline enum buddy get_free_buddy(struct z3fold_header *zhdr, int chunks)
659 static inline void *mchunk_memmove(struct z3fold_header *zhdr,
668 static inline bool buddy_single(struct z3fold_header *zhdr)
675 static struct z3fold_header *compact_single_buddy(struct z3fold_header *zhdr)
681 struct z3fold_header *new_zhdr = NULL;
772 static int z3fold_compact_page(struct z3fold_header *zhdr)
819 static void do_compact_page(struct z3fold_header *zhdr, bool locked)
867 struct z3fold_header *zhdr = container_of(w, struct z3fold_header,
874 static inline struct z3fold_header *__z3fold_alloc(struct z3fold_pool *pool,
877 struct z3fold_header *zhdr = NULL;
889 struct z3fold_header, buddy);
898 struct z3fold_header, buddy)) ||
945 struct z3fold_header, buddy);
1093 struct z3fold_header *zhdr = NULL;
1131 struct z3fold_header, buddy);
1214 struct z3fold_header *zhdr;
1331 struct z3fold_header *zhdr = NULL;
1504 struct z3fold_header *zhdr;
1549 struct z3fold_header *zhdr;
1579 struct z3fold_header *zhdr;
1619 struct z3fold_header *zhdr, *new_zhdr;
1684 struct z3fold_header *zhdr;