lkml.org 
[lkml]   [2020]   [Jan]   [24]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
    Patch in this message
    /
    From
    Subject[PATCH 4.19 045/639] of: Fix property name in of_node_get_device_type
    Date
    From: Rob Herring <robh@kernel.org>

    [ Upstream commit 5d5a0ab1a7918fce5ca5c0fb1871a3e2000f85de ]

    Commit 0413bedabc88 ("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: 0413bedabc88 ("of: Add device_type access helper functions")
    Cc: Frank Rowand <frowand.list@gmail.com>
    Signed-off-by: Rob Herring <robh@kernel.org>
    Signed-off-by: Sasha Levin <sashal@kernel.org>
    ---
    include/linux/of.h | 2 +-
    1 file changed, 1 insertion(+), 1 deletion(-)

    diff --git a/include/linux/of.h b/include/linux/of.h
    index d5a863c1ee390..dac0201eacef7 100644
    --- a/include/linux/of.h
    +++ b/include/linux/of.h
    @@ -1001,7 +1001,7 @@ static inline struct device_node *of_find_matching_node(

    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)
    --
    2.20.1


    \
     
     \ /
      Last update: 2020-01-24 12:01    [W:2.020 / U:1.392 seconds]
    ©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site