drm/dsi: Constify mipi_dsi_msg
authorThierry Reding <treding@nvidia.com>
Tue, 5 Aug 2014 09:27:56 +0000 (11:27 +0200)
committerThierry Reding <treding@nvidia.com>
Thu, 13 Nov 2014 12:55:41 +0000 (13:55 +0100)
struct mipi_dsi_msg is a read-only structure, drivers should never need
to modify it. Make this explicit by making all references to the struct
const.

Acked-by: Andrzej Hajda <a.hajda@samsung.com>
Reviewed-by: Sean Paul <seanpaul@chromium.org>
Signed-off-by: Thierry Reding <treding@nvidia.com>
drivers/gpu/drm/exynos/exynos_drm_dsi.c
include/drm/drm_mipi_dsi.h

index 24741d8..c5f3c76 100644 (file)
@@ -1236,7 +1236,7 @@ static bool exynos_dsi_is_short_dsi_type(u8 type)
 }
 
 static ssize_t exynos_dsi_host_transfer(struct mipi_dsi_host *host,
-                                      struct mipi_dsi_msg *msg)
+                                       const struct mipi_dsi_msg *msg)
 {
        struct exynos_dsi *dsi = host_to_dsi(host);
        struct exynos_dsi_transfer xfer;
index 44cece9..4eeb4a5 100644 (file)
@@ -77,7 +77,7 @@ struct mipi_dsi_host_ops {
        int (*detach)(struct mipi_dsi_host *host,
                      struct mipi_dsi_device *dsi);
        ssize_t (*transfer)(struct mipi_dsi_host *host,
-                           struct mipi_dsi_msg *msg);
+                           const struct mipi_dsi_msg *msg);
 };
 
 /**