| 342 | } |
| 343 | |
| 344 | bool |
| 345 | of_device_is_available(const struct device_node *dev_node) |
| 346 | { |
| 347 | const struct dt_dir *d; |
| 348 | |
| 349 | DPAAX_HWWARN(!alive, "Device-tree driver not initialised!"); |
| 350 | d = node2dir(dev_node); |
| 351 | if (!d->status) |
| 352 | return true; |
| 353 | if (!strcmp((char *)d->status->buf, "okay")) |
| 354 | return true; |
| 355 | if (!strcmp((char *)d->status->buf, "ok")) |
| 356 | return true; |
| 357 | return false; |
| 358 | } |
| 359 | |
| 360 | const struct device_node * |
| 361 | of_find_node_by_phandle(uint64_t ph) |
no test coverage detected