Add a function to retrieve a writeable property only by the first
characters of its name.
Reviewed-by: David Gibson <redacted>
Signed-off-by: Maxime Ripard <maxime.ripard-wi1+55ScJUtKEb57/3fJTNBPR1lH4CV8@public.gmane.org>
---
libfdt/libfdt.h | 7 +++++++
1 file changed, 7 insertions(+)
diff --git a/libfdt/libfdt.h b/libfdt/libfdt.h
index 1a14bc16b3d7..e504467a6249 100644
--- a/libfdt/libfdt.h
+++ b/libfdt/libfdt.h
@@ -627,6 +627,13 @@ const void *fdt_getprop_by_offset(const void *fdt, int offset,
*/
const void *fdt_getprop_namelen(const void *fdt, int nodeoffset,
const char *name, int namelen, int *lenp);
+static inline void *fdt_getprop_namelen_w(void *fdt, int nodeoffset,
+ const char *name, int namelen,
+ int *lenp)
+{
+ return (void *)(uintptr_t)fdt_getprop_namelen(fdt, nodeoffset, name,
+ namelen, lenp);
+}
/**
* fdt_getprop - retrieve the value of a given property--
2.9.0
--
To unsubscribe from this list: send the line "unsubscribe devicetree" in
the body of a message to majordomo-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
More majordomo info at http://vger.kernel.org/majordomo-info.html