Lines Matching refs:fd
69 int opt, i, fd;
116 fd = ofw_open(O_RDONLY);
120 ofw_dump(fd, NULL, rflag, pflag, Parg, Rflag, Sflag);
127 ofw_dump(fd, argv[i], rflag, pflag, Parg, Rflag, Sflag);
129 ofw_close(fd);
143 ofw_dump_properties(int fd, phandle_t n, int level, const char *pmatch, int raw,
153 for (nlen = ofw_firstprop(fd, n, prop, sizeof(prop)); nlen != 0;
154 nlen = ofw_nextprop(fd, n, prop, prop, sizeof(prop))) {
157 len = ofw_getprop_alloc(fd, n, prop, &pbuf, &pblen, 1);
205 ofw_dump_node(int fd, phandle_t n, int level, int rec, int prop,
216 plen = ofw_getprop_alloc(fd, n, "name", &nbuf, &nblen, 1);
223 ofw_dump_properties(fd, n, level, pmatch, raw, str);
225 for (c = ofw_child(fd, n); c != 0; c = ofw_peer(fd, c)) {
226 ofw_dump_node(fd, c, level + 1, rec, prop, pmatch,
233 ofw_dump(int fd, const char *start, int rec, int prop, const char *pmatch,
238 n = start == NULL ? ofw_root(fd) : ofw_finddevice(fd, start);
239 ofw_dump_node(fd, n, 0, rec, prop, pmatch, raw, str);