函数逻辑报告

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

Source Code:kernel\resource.c Create Date:2022-07-27 10:04:59
Last Modify:2022-05-22 11:14:39 Copyright©Brick
首页 函数Tree
注解内核,赢得工具下载SCCTEnglish

函数名称:Find empty slot in the resource tree with the given range and* alignment constraints

函数原型:static int __find_resource(struct resource *root, struct resource *old, struct resource *new, resource_size_t size, struct resource_constraint *constraint)

返回类型:int

参数:

类型参数名称
struct resource *root
struct resource *old
struct resource *new
resource_size_tsize
struct resource_constraint *constraint
597  this等于child
598  tmp等于new
600  start等于start
605  如果thisstart恒等于start
606  start等于如果this恒等于oldstart否则end加1
607  this等于sibling
609  循环
610  如果(this)则end等于如果this恒等于oldend否则start减1
612  否则end等于end
615  如果end小于start则转到:next
618  resource_clip( & tmp, min, max)
619  arch_remove_reservations( & tmp)
622  start等于@a is a power of 2 value (start, align)
623  end等于end
624  flags等于flags按位与No address assigned yet 的反
625  如果start大于等于start
626  flags等于flags
627  start等于alignf(alignf_data, & avail, size, align)
629  end等于startsize减1
630  如果start小于等于endTrue iff r1 completely contains r2
632  start等于start
633  end等于end
634  返回:0
638  :
638  如果非thisend恒等于end退出
641  如果this不等于oldstart等于end加1
643  this等于sibling
645  返回:负EBUSY
调用者
名称描述
find_resourceFind empty slot in the resource tree given range and alignment.
reallocate_resourceallocate_resource - allocate a slot in the resource tree given range & alignment