函数逻辑报告

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

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

函数名称:fdt_create_with_flags

函数原型:int fdt_create_with_flags(void *buf, int bufsize, uint32_t flags)

返回类型:int

参数:

类型参数名称
void *buf
intbufsize
uint32_tflags
107  hdrsize等于FDT_ALIGN(sizeof(structfdt_header), sizeof(structfdt_reserve_entry))
109  fdt等于buf
111  如果bufsize小于hdrsize则返回:负FDT_ERR_EXISTS: Attempted to create a node or property which* already exists
114  如果flags按位与FDT_CREATE_FLAG_NO_NAME_DEDUP: Do not try to de-duplicate property* names in the fdt. This can result in faster creation times, but* a larger fdt. 的反则返回:负FDT_ERR_NOPHANDLES: The device tree doesn't have any* phandle available anymore without causing an overflow
117  memset(buf, 0, bufsize)
126  fdt_set_magic(fdt, FDT_SW_MAGIC)
127  fdt_set_version(fdt, FDT_LAST_SUPPORTED_VERSION)
128  fdt_set_last_comp_version(fdt, flags)
130  fdt_set_totalsize(fdt, bufsize)
132  fdt_set_off_mem_rsvmap(fdt, hdrsize)
133  fdt_set_off_dt_struct(fdt, fdt_off_mem_rsvmap(fdt))
134  fdt_set_off_dt_strings(fdt, 0)
136  返回:0
调用者
名称描述
fdt_create