Home
last modified time | relevance | path

Searched refs:swp_tb (Results 1 – 3 of 3) sorted by relevance

/linux/mm/ !
H A Dswap_table.h51 static inline bool swp_tb_is_null(unsigned long swp_tb) in swp_tb_is_null() argument
53 return !swp_tb; in swp_tb_is_null()
56 static inline bool swp_tb_is_folio(unsigned long swp_tb) in swp_tb_is_folio() argument
58 return !xa_is_value((void *)swp_tb) && !swp_tb_is_null(swp_tb); in swp_tb_is_folio()
61 static inline bool swp_tb_is_shadow(unsigned long swp_tb) in swp_tb_is_shadow() argument
63 return xa_is_value((void *)swp_tb); in swp_tb_is_shadow()
69 static inline struct folio *swp_tb_to_folio(unsigned long swp_tb) in swp_tb_to_folio() argument
71 VM_WARN_ON(!swp_tb_is_folio(swp_tb)); in swp_tb_to_folio()
72 return (void *)swp_tb; in swp_tb_to_folio()
75 static inline void *swp_tb_to_shadow(unsigned long swp_tb) in swp_tb_to_shadow() argument
[all …]
H A Dswap_state.c89 unsigned long swp_tb; in swap_cache_get_folio() local
93 swp_tb = swap_table_get(__swap_entry_to_cluster(entry), in swap_cache_get_folio()
95 if (!swp_tb_is_folio(swp_tb)) in swap_cache_get_folio()
97 folio = swp_tb_to_folio(swp_tb); in swap_cache_get_folio()
114 unsigned long swp_tb; in swap_cache_has_folio() local
116 swp_tb = swap_table_get(__swap_entry_to_cluster(entry), in swap_cache_has_folio()
118 return swp_tb_is_folio(swp_tb); in swap_cache_has_folio()
131 unsigned long swp_tb; in swap_cache_get_shadow() local
133 swp_tb = swap_table_get(__swap_entry_to_cluster(entry), in swap_cache_get_shadow()
135 if (swp_tb_is_shadow(swp_tb)) in swap_cache_get_shadow()
[all …]
H A Dswapfile.c184 unsigned long swp_tb; in swap_only_has_cache() local
187 swp_tb = __swap_table_get(ci, ci_off); in swap_only_has_cache()
188 VM_WARN_ON_ONCE(!swp_tb_is_folio(swp_tb)); in swap_only_has_cache()
773 unsigned long swp_tb; in cluster_reclaim_range() local
779 swp_tb = swap_table_get(ci, offset % SWAPFILE_CLUSTER); in cluster_reclaim_range()
780 if (swp_tb_is_folio(swp_tb)) { in cluster_reclaim_range()
806 swp_tb = __swap_table_get(ci, offset % SWAPFILE_CLUSTER); in cluster_reclaim_range()
807 if (map[offset] || !swp_tb_is_null(swp_tb)) in cluster_reclaim_range()
821 unsigned long swp_tb; in cluster_scan_range() local
829 swp_tb = __swap_table_get(ci, offset % SWAPFILE_CLUSTER); in cluster_scan_range()
[all …]