Function report

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

Source Code:kernel\resource.c Create Date:2022-07-28 09:04:55
Last Modify:2022-05-22 11:14:39 Copyright©Brick
home page Tree
Annotation kernel can get tool activityDownload SCCTChinese

Name:alloc_resource

Proto:static struct resource *alloc_resource(gfp_t flags)

Type:struct resource

Parameter:

TypeParameterName
gfp_tflags
167  struct resource * res = NULL
169  spin_lock( & bootmem_resource_lock)
170  If For memory hotplug, there is no way to free resource entries allocated* by boot mem after the system is up. So for reusing the resource entry* we need to remember the resource. Then
171  res = For memory hotplug, there is no way to free resource entries allocated* by boot mem after the system is up. So for reusing the resource entry* we need to remember the resource.
172  For memory hotplug, there is no way to free resource entries allocated* by boot mem after the system is up. So for reusing the resource entry* we need to remember the resource. = sibling
174  spin_unlock( & bootmem_resource_lock)
176  If res Then memset(res, 0, sizeof(structresource))
178  Else res = kzalloc - allocate memory. The memory is set to zero.*@size: how many bytes of memory are required.*@flags: the type of memory to allocate (see kmalloc).
181  Return res
Caller
NameDescribe
__reserve_region_with_split
__request_region__request_region - create a new busy resource region*@parent: parent resource descriptor*@start: resource start address*@n: resource region size*@name: reserving caller's ID string*@flags: IO resource flags