Thread (3 messages) flat view 3 messages, 2 authors, 2018-08-06

Re: is there any continuing value in node "chosen@0"?

From: Rob Herring <robh@kernel.org>
Date: 2018-08-06 15:57:21

On Mon, Aug 6, 2018 at 6:34 AM Robert P. J. Day [off-list ref] wrote:

  while the current DTSpec says nothing about the chosen node possibly
having a unit-address, if i search the current linux kernel code base,
there are a few examples of just that:

$ git grep chosen@
arch/mips/generic/yamon-dt.c:           chosen_off = fdt_path_offset(fdt, "/chosen@0");
arch/mips/generic/yamon-dt.c:           chosen_off = fdt_path_offset(fdt, "/chosen@0");
Nothing MIPS based should need this I think.
arch/powerpc/boot/oflib.c:              chosen = of_finddevice("/chosen@0");
drivers/of/base.c:              of_chosen = of_find_node_by_path("/chosen@0");
drivers/of/fdt.c:               offset = fdt_path_offset(fdt, "/chosen@0");
drivers/of/fdt.c:           (strcmp(uname, "chosen") != 0 && strcmp(uname, "chosen@0") != 0))

  is there some lingering value to the node name "chosen@0"? or should
this all be simplified to just "chosen"?
These are needed for some PPC system(s) though I don't have any clue
which ones specifically.

Rob
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help