| Main index | Section 9 | Options |
#include <dev/ofw/ofw_bus.h>
#include <dev/ofw/ofw_bus_subr.h>
OF_node_from_xref() returns the kernel phandle for the effective phandle xref. If one cannot be found or the OpenFirmware implementation does not support effective phandles, the function returns the input value.
OF_xref_from_node() returns the effective phandle for the kernel phandle node. If one cannot be found or the OpenFirmware implementation does not support effective phandles, the function returns the input value.
phandle_t panelnode, panelxref;
char *model;
if (OF_getencprop(node, "lcd-panel", &panelxref) <= 0)
return;
panelnode = OF_node_from_xref(panelxref);
if (OF_getprop_alloc(hdminode, "model", (void **)&model) <= 0)
return;
| OF_NODE_FROM_XREF (9) | April 9, 2018 |
| Main index | Section 9 | Options |
Please direct any comments about this manual page service to Ben Bullock. Privacy policy.
| “ | Ken Thompson was once asked by a reporter what he would have changed about Unix if he had it all to do over again. His answer: “I would spell creat with an ‘e.'” | ” |