Function report

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

Source Code:mm\swapfile.c Create Date:2022-07-28 15:18:51
Last Modify:2020-03-17 22:19:49 Copyright©Brick
home page Tree
Annotation kernel can get tool activityDownload SCCTChinese

Name:setup_swap_info

Proto:static void setup_swap_info(struct swap_info_struct *p, int prio, unsigned char *swap_map, struct swap_cluster_info *cluster_info)

Type:void

Parameter:

TypeParameterName
struct swap_info_struct *p
intprio
unsigned char *swap_map
struct swap_cluster_info *cluster_info
2427  If prio >= 0 Then swap priority of this type = prio
2429  Else swap priority of this type = --least_priority
2435  swap priority of this type = -swap priority of this type
2436  for_each_node(i)
2437  If swap priority of this type >= 0 Then prio = -swap priority of this type
2439  Else
2440  If swap_node(p) == i Then prio = 1
2446  vmalloc'ed array of usage counts = swap_map
2447  cluster info. Only for SSD = cluster_info
Caller
NameDescribe
enable_swap_info
reinsert_swap_info