/* Convenience function to directly set a property given the path to the node.  */
int fdt_find_and_setprop(void *fdt, const char *node, const char *prop, const void *val, int len, int create)
/* Convenience function to directly set a property given the path to the node.  */
int fdt_find_and_setprop(void *fdt, const char *node, const char *prop, const void *val, int len, int create)
{
	int nodeoff = fdt_path_offset(fdt, node);
	if (nodeoff < 0)
		return nodeoff;
	if ((!create) && (fdt_get_property(fdt, nodeoff, prop, 0) == NULL))
		return 0;
	return fdt_setprop(fdt, nodeoff, prop, val, len);
}