From 8c1a66d6bdc6de725348782508dbe5242a81e230 Mon Sep 17 00:00:00 2001 From: Jeykumar Sankaran Date: Thu, 7 Oct 2021 21:35:35 -0700 Subject: [PATCH] disp: msm: dsi: add const qualifer for device node in get_named_gpio Add const qualifier for the device_node param in get_named_gpio function pointer hook to adapt msm-5.15 kernel. Change-Id: I0129efeff5aeb85b567bf6f2b5d2e45312fab024 Signed-off-by: Jeykumar Sankaran --- msm/dsi/dsi_parser.c | 2 +- msm/dsi/dsi_parser.h | 6 +++--- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/msm/dsi/dsi_parser.c b/msm/dsi/dsi_parser.c index b4c737d24a..5e830e0621 100644 --- a/msm/dsi/dsi_parser.c +++ b/msm/dsi/dsi_parser.c @@ -897,7 +897,7 @@ end: return -EINVAL; } -int dsi_parser_get_named_gpio(struct device_node *np, +int dsi_parser_get_named_gpio(const struct device_node *np, const char *propname, int index) { int gpio = -EINVAL; diff --git a/msm/dsi/dsi_parser.h b/msm/dsi/dsi_parser.h index bdb93b80a9..4b163fc373 100644 --- a/msm/dsi/dsi_parser.h +++ b/msm/dsi/dsi_parser.h @@ -45,7 +45,7 @@ int dsi_parser_count_strings(const struct device_node *np, int dsi_parser_read_string_index(const struct device_node *np, const char *propname, int index, const char **output); -int dsi_parser_get_named_gpio(struct device_node *np, +int dsi_parser_get_named_gpio(const struct device_node *np, const char *propname, int index); #else /* CONFIG_DSI_PARSER */ static inline void *dsi_parser_get(struct device *dev) @@ -155,7 +155,7 @@ static inline int dsi_parser_read_string_index(const struct device_node *np, return -ENODEV; } -static inline int dsi_parser_get_named_gpio(struct device_node *np, +static inline int dsi_parser_get_named_gpio(const struct device_node *np, const char *propname, int index) { return -ENODEV; @@ -201,7 +201,7 @@ struct dsi_parser_utils { const char *propname); int (*count_strings)(const struct device_node *np, const char *propname); - int (*get_named_gpio)(struct device_node *np, + int (*get_named_gpio)(const struct device_node *np, const char *propname, int index); int (*get_available_child_count)(const struct device_node *np); };