]> git.karo-electronics.de Git - karo-tx-linux.git/commitdiff
drm/panel: Constify device node argument to of_drm_find_panel()
authorLaurent Pinchart <laurent.pinchart+renesas@ideasonboard.com>
Sat, 19 Nov 2016 03:28:05 +0000 (05:28 +0200)
committerThierry Reding <treding@nvidia.com>
Wed, 4 Jan 2017 07:30:37 +0000 (08:30 +0100)
The argument is never modified by the function, make it const.

Signed-off-by: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com>
Signed-off-by: Thierry Reding <treding@nvidia.com>
drivers/gpu/drm/drm_panel.c
include/drm/drm_panel.h

index 3dfe3c886502d8b9abac5492075aded558f26b3e..308d442a531b2dda2145dd296ee309ccda88e214 100644 (file)
@@ -137,7 +137,7 @@ EXPORT_SYMBOL(drm_panel_detach);
  * Return: A pointer to the panel registered for the specified device tree
  * node or NULL if no panel matching the device tree node can be found.
  */
-struct drm_panel *of_drm_find_panel(struct device_node *np)
+struct drm_panel *of_drm_find_panel(const struct device_node *np)
 {
        struct drm_panel *panel;
 
index 220d1e2b3db17cc80010ce3305933b37a523f673..4b76cf2d5a7bf7e2a6d9fe993068187f16a6d710 100644 (file)
@@ -193,9 +193,9 @@ int drm_panel_attach(struct drm_panel *panel, struct drm_connector *connector);
 int drm_panel_detach(struct drm_panel *panel);
 
 #ifdef CONFIG_OF
-struct drm_panel *of_drm_find_panel(struct device_node *np);
+struct drm_panel *of_drm_find_panel(const struct device_node *np);
 #else
-static inline struct drm_panel *of_drm_find_panel(struct device_node *np)
+static inline struct drm_panel *of_drm_find_panel(const struct device_node *np)
 {
        return NULL;
 }