提交 4e3cc0cf 编写于 作者: R Rob Herring 提交者: Xie XiuQi

of: Fix property name in of_node_get_device_type

mainline inclusion
from mainline-4.20-rc1
commit 5d5a0ab1
category: bugfix
bugzilla: 5547
CVE: NA

---------------------------

Commit 0413beda ("of: Add device_type access helper functions")
added a new helper not yet used in preparation for some treewide clean
up of accesses to 'device_type' properties. Unfortunately, there's an
error and 'type' was used for the property name. Fix this.

Fixes: 0413beda ("of: Add device_type access helper functions")
Cc: Frank Rowand <frowand.list@gmail.com>
Signed-off-by: NRob Herring <robh@kernel.org>
Signed-off-by: NJason Yan <yanaijie@huawei.com>
Reviewed-by: Nzhengbin <zhengbin13@huawei.com>
Signed-off-by: NYang Yingliang <yangyingliang@huawei.com>
上级 7c7db3d1
...@@ -995,7 +995,7 @@ static inline struct device_node *of_find_matching_node( ...@@ -995,7 +995,7 @@ static inline struct device_node *of_find_matching_node(
static inline const char *of_node_get_device_type(const struct device_node *np) static inline const char *of_node_get_device_type(const struct device_node *np)
{ {
return of_get_property(np, "type", NULL); return of_get_property(np, "device_type", NULL);
} }
static inline bool of_node_is_type(const struct device_node *np, const char *type) static inline bool of_node_is_type(const struct device_node *np, const char *type)
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册