Function report

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

Source Code:scripts\dtc\libfdt\fdt_ro.c Create Date:2022-07-28 06:18:38
Last Modify:2020-03-12 14:18:49 Copyright©Brick
home page Tree
Annotation kernel can get tool activityDownload SCCTChinese

Name:fdt_stringlist_search

Proto:int fdt_stringlist_search(const void *fdt, int nodeoffset, const char *property, const char *string)

Type:int

Parameter:

TypeParameterName
const void *fdt
intnodeoffset
const char *property
const char *string
726  idx = 0
729  list = fdt_getprop(fdt, nodeoffset, property, & length)
730  If Not list Then Return length
733  len = strlen(string) + 1
734  end = list + length
736  When list < end cycle
737  length = strnlen(list, end - list) + 1
740  If list + length > end Then Return -FDT_ERR_BADNCELLS: Device tree has a #address-cells, #size-cells* or similar property with a bad format or value
743  If length == len && memcmp(list, string, length) == 0 Then Return idx
746  list += length
747  idx++
750  Return -Error codes: informative error codes