Lines Matching defs:offset
56 const void *fdt_offset_ptr(const void *fdt, int offset, unsigned int len)
61 if (((offset + len) < offset)
62 || ((offset + len) > fdt_size_dt_struct(fdt)))
65 p = _fdt_offset_ptr(fdt, offset);
76 int offset = startoffset;
80 tagp = fdt_offset_ptr(fdt, offset, FDT_TAGSIZE);
84 offset += FDT_TAGSIZE;
91 p = fdt_offset_ptr(fdt, offset++, 1);
98 lenp = fdt_offset_ptr(fdt, offset, sizeof(*lenp));
101 /* skip-name offset, length and value */
102 offset += sizeof(struct fdt_property) - FDT_TAGSIZE
115 if (!fdt_offset_ptr(fdt, startoffset, offset - startoffset))
118 *nextoffset = FDT_TAGALIGN(offset);
122 int _fdt_check_node_offset(const void *fdt, int offset)
124 if ((offset < 0) || (offset % FDT_TAGSIZE)
125 || (fdt_next_tag(fdt, offset, &offset) != FDT_BEGIN_NODE))
128 return offset;
131 int _fdt_check_prop_offset(const void *fdt, int offset)
133 if ((offset < 0) || (offset % FDT_TAGSIZE)
134 || (fdt_next_tag(fdt, offset, &offset) != FDT_PROP))
137 return offset;
140 int fdt_next_node(const void *fdt, int offset, int *depth)
145 if (offset >= 0)
146 if ((nextoffset = _fdt_check_node_offset(fdt, offset)) < 0)
150 offset = nextoffset;
151 tag = fdt_next_tag(fdt, offset, &nextoffset);
177 return offset;