Lines Matching defs:offset
77 const void *fdt_offset_ptr(const void *fdt, int offset, unsigned int len)
82 if (((offset + len) < offset)
83 || ((offset + len) > fdt_size_dt_struct(fdt)))
86 p = _fdt_offset_ptr(fdt, offset);
97 int offset = startoffset;
101 tagp = fdt_offset_ptr(fdt, offset, FDT_TAGSIZE);
105 offset += FDT_TAGSIZE;
112 p = fdt_offset_ptr(fdt, offset++, 1);
119 lenp = fdt_offset_ptr(fdt, offset, sizeof(*lenp));
122 /* skip-name offset, length and value */
123 offset += sizeof(struct fdt_property) - FDT_TAGSIZE
136 if (!fdt_offset_ptr(fdt, startoffset, offset - startoffset))
139 *nextoffset = FDT_TAGALIGN(offset);
143 int _fdt_check_node_offset(const void *fdt, int offset)
145 if ((offset < 0) || (offset % FDT_TAGSIZE)
146 || (fdt_next_tag(fdt, offset, &offset) != FDT_BEGIN_NODE))
149 return offset;
152 int _fdt_check_prop_offset(const void *fdt, int offset)
154 if ((offset < 0) || (offset % FDT_TAGSIZE)
155 || (fdt_next_tag(fdt, offset, &offset) != FDT_PROP))
158 return offset;
161 int fdt_next_node(const void *fdt, int offset, int *depth)
166 if (offset >= 0)
167 if ((nextoffset = _fdt_check_node_offset(fdt, offset)) < 0)
171 offset = nextoffset;
172 tag = fdt_next_tag(fdt, offset, &nextoffset);
198 return offset;