函数逻辑报告

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

Source Code:scripts\dtc\libfdt\fdt_ro.c Create Date:2022-07-27 07:15:42
Last Modify:2020-03-12 14:18:49 Copyright©Brick
首页 函数Tree
注解内核,赢得工具下载SCCTEnglish

函数名称:fdt_path_offset_namelen

函数原型:int fdt_path_offset_namelen(const void *fdt, const char *path, int namelen)

返回类型:int

参数:

类型参数名称
const void *fdt
const char *path
intnamelen
237  end等于pathnamelen
238  p等于path
239  offset等于0
244  如果path不等于'/'则
245  q等于memchr(path, '/', end - p)
247  如果非qq等于end
250  p等于dt_get_alias_namelen - get alias based on substring*@fdt: pointer to the device tree blob*@name: name of the alias th look up*@namelen: number of characters of name to consider* Identical to fdt_get_alias(), but only examine the first namelen
251  如果非p则返回:负FDT_ERR_BADOFFSET: Function was passed a structure block* offset which is out-of-bounds, or which points to an* unsuitable part of the structure for the operation.
253  offset等于dt_path_offset - find a tree node by its full path*@fdt: pointer to the device tree blob*@path: full path of the node to locate* fdt_path_offset() finds a node of a given path in the device tree
255  p等于q
258 p小于end循环
261 p恒等于'/'循环
262  p自加
263  如果p恒等于end则返回:offset
266  q等于memchr(p, '/', end - p)
267  如果非qq等于end
270  offset等于fdt_subnode_offset_namelen(fdt, offset, p, q - p)
271  如果offset小于0则返回:offset
274  p等于q
277  返回:offset
调用者
名称描述
fdt_path_offset