* Iterator break-free ?
@ 2014-09-12 5:21 Jay Bhukhanwala
[not found] ` <CAB8QsTBF5V8JJeEkkUXN30fnUoDxVWR_ufGkXaEHRGeZCc6ozw-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
0 siblings, 1 reply; 2+ messages in thread
From: Jay Bhukhanwala @ 2014-09-12 5:21 UTC (permalink / raw)
To: devicetree-compiler-u79uwXL29TY76Z2rM5mHXA
When traversing the entire tree using fdt_next_node, will the iterator
break if I change the blob structure, due to, say, addition/deletion
of a node/property or changing a property ?
--
To unsubscribe from this list: send the line "unsubscribe devicetree-compiler" in
the body of a message to majordomo-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
^ permalink raw reply [flat|nested] 2+ messages in thread
* Re: Iterator break-free ?
[not found] ` <CAB8QsTBF5V8JJeEkkUXN30fnUoDxVWR_ufGkXaEHRGeZCc6ozw-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
@ 2014-09-12 5:56 ` David Gibson
0 siblings, 0 replies; 2+ messages in thread
From: David Gibson @ 2014-09-12 5:56 UTC (permalink / raw)
To: Jay Bhukhanwala; +Cc: devicetree-compiler-u79uwXL29TY76Z2rM5mHXA
[-- Attachment #1: Type: text/plain, Size: 783 bytes --]
On Thu, Sep 11, 2014 at 10:21:11PM -0700, Jay Bhukhanwala wrote:
> When traversing the entire tree using fdt_next_node, will the iterator
> break if I change the blob structure, due to, say, addition/deletion
> of a node/property or changing a property ?
In general yes, it will break.
however there's one very common special case where the iteration will
keep working:
if between one call to fdt_next_node() and the next, the *only*
insertions or deletions are of nodes or properties within the node
returned by the first call to fdt_next_node(), then you're ok.
--
David Gibson | I'll have my music baroque, and my code
david AT gibson.dropbear.id.au | minimalist, thank you. NOT _the_ _other_
| _way_ _around_!
http://www.ozlabs.org/~dgibson
[-- Attachment #2: Type: application/pgp-signature, Size: 819 bytes --]
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2014-09-12 5:56 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2014-09-12 5:21 Iterator break-free ? Jay Bhukhanwala
[not found] ` <CAB8QsTBF5V8JJeEkkUXN30fnUoDxVWR_ufGkXaEHRGeZCc6ozw-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
2014-09-12 5:56 ` David Gibson
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.