Commit 88269151 authored by Dmitry Torokhov's avatar Dmitry Torokhov Committed by Rob Herring

of: base: make of_device_compatible_match() accept const device node

of_device_is_compatible() accepts const device node pointer, there is
no reason why of_device_compatible_match() can't do the same.
Signed-off-by: default avatarDmitry Torokhov <dmitry.torokhov@gmail.com>
Link: https://lore.kernel.org/r/YzY5MaU5N4A2st5R@google.comSigned-off-by: default avatarRob Herring <robh@kernel.org>
parent f1ad5338
...@@ -561,7 +561,7 @@ EXPORT_SYMBOL(of_device_is_compatible); ...@@ -561,7 +561,7 @@ EXPORT_SYMBOL(of_device_is_compatible);
* a NULL terminated array of strings. Returns the best match * a NULL terminated array of strings. Returns the best match
* score or 0. * score or 0.
*/ */
int of_device_compatible_match(struct device_node *device, int of_device_compatible_match(const struct device_node *device,
const char *const *compat) const char *const *compat)
{ {
unsigned int tmp, score = 0; unsigned int tmp, score = 0;
......
...@@ -342,7 +342,7 @@ extern int of_property_read_string_helper(const struct device_node *np, ...@@ -342,7 +342,7 @@ extern int of_property_read_string_helper(const struct device_node *np,
const char **out_strs, size_t sz, int index); const char **out_strs, size_t sz, int index);
extern int of_device_is_compatible(const struct device_node *device, extern int of_device_is_compatible(const struct device_node *device,
const char *); const char *);
extern int of_device_compatible_match(struct device_node *device, extern int of_device_compatible_match(const struct device_node *device,
const char *const *compat); const char *const *compat);
extern bool of_device_is_available(const struct device_node *device); extern bool of_device_is_available(const struct device_node *device);
extern bool of_device_is_big_endian(const struct device_node *device); extern bool of_device_is_big_endian(const struct device_node *device);
...@@ -562,7 +562,7 @@ static inline int of_device_is_compatible(const struct device_node *device, ...@@ -562,7 +562,7 @@ static inline int of_device_is_compatible(const struct device_node *device,
return 0; return 0;
} }
static inline int of_device_compatible_match(struct device_node *device, static inline int of_device_compatible_match(const struct device_node *device,
const char *const *compat) const char *const *compat)
{ {
return 0; return 0;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment