Function report

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

Source Code:kernel\power\snapshot.c Create Date:2022-07-28 10:00:33
Last Modify:2020-03-12 14:18:49 Copyright©Brick
home page Tree
Annotation kernel can get tool activityDownload SCCTChinese

Name:memory_bm_create - Allocate memory for a memory bitmap.

Proto:static int memory_bm_create(struct memory_bitmap *bm, gfp_t gfp_mask, int safe_needed)

Type:int

Parameter:

TypeParameterName
struct memory_bitmap *bm
gfp_tgfp_mask
intsafe_needed
651  chain_init( & ca, gfp_mask, safe_needed)
652  Initialization list head
654  error = reate_mem_extents - Create a list of memory extents.*@list: List to put the extents into.*@gfp_mask: Mask to use for memory allocations.* The extents represent contiguous ranges of PFNs.
655  If error Then Return error
661  zone = reate_zone_bm_rtree - Create a radix tree for one zone.* Allocated the mem_zone_bm_rtree structure and initializes it.* This function also allocated and builds the radix tree for the* zone.
663  If Not zone Then
664  error = -ENOMEM
665  Go to Error
667  list_add_tail - add a new entry*@new: new entry to be added*@head: list head to add it before* Insert a new entry before the specified head.* This is useful for implementing queues.
670  list of pages used to store zone bitmap objects and bitmap block objects = he chain
671  memory_bm_position_reset(bm)
672  Exit :
673  _mem_extents - Free a list of memory extents.*@list: List of extents to free.
674  Return error
676  Error :
677  list of pages used to store zone bitmap objects and bitmap block objects = he chain
678  memory_bm_free(bm, PG_UNSAFE_CLEAR)
679  Go to Exit
Caller
NameDescribe
create_basic_memory_bitmapsreate_basic_memory_bitmaps - Create bitmaps to hold basic page information
hibernate_preallocate_memoryhibernate_preallocate_memory - Preallocate memory for hibernation image
prepare_imageprepare_image - Make room for loading hibernation image
snapshot_write_nextsnapshot_write_next - Get the address to store the next image page.*@handle: Snapshot handle structure to guide the writing.* On the first call, @handle should point to a zeroed snapshot_handle* structure