Function report

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

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

Name:devm_request_resource() - request and reserve an I/O or memory resource*@dev: device for which to request the resource*@root: root of the resource tree from which to request the resource*@new: descriptor of the resource to request

Proto:int devm_request_resource(struct device *dev, struct resource *root, struct resource *new)

Type:int

Parameter:

TypeParameterName
struct device *dev
struct resource *root
struct resource *new
1384  ptr = devres_alloc(Managed region resource, size of ptr , GFP_KERNEL)
1385  If Not ptr Then Return -ENOMEM
1388  ptr = new
1390  conflict = quest_resource_conflict - request and reserve an I/O or memory resource*@root: root resource descriptor*@new: resource descriptor desired by caller* Returns 0 for success, conflict resource on error.
1391  If conflict Then
1392  dev_err(dev, "resource collision: %pR conflicts with %s %pR\n", new, name, conflict)
1394  devres_free(ptr)
1395  Return -EBUSY
1398  devres_add(dev, ptr)
1399  Return 0