Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 1af4c7f1 authored by Alexandre Courbot's avatar Alexandre Courbot Committed by Rob Herring
Browse files

of: return -ENOENT when no property



Make of_parse_phandle_with_args return -ENOENT instead of -EINVAL when
no matching property is found, which allows to discriminate between
absence of property and parsing error.

Signed-off-by: default avatarAlexandre Courbot <acourbot@nvidia.com>
Signed-off-by: default avatarRob Herring <rob.herring@calxeda.com>
parent 5d781108
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -902,7 +902,7 @@ int of_parse_phandle_with_args(struct device_node *np, const char *list_name,
	/* Retrieve the phandle list property */
	list = of_get_property(np, list_name, &size);
	if (!list)
		return -EINVAL;
		return -ENOENT;
	list_end = list + size / sizeof(*list);

	/* Loop over the phandles until all the requested entry is found */