drm/exynos: Constify struct exynos_drm_ipp_funcs

'struct exynos_drm_ipp_funcs' are not modified in these drivers.

Constifying this structure moves some data to a read-only section, so
increase overall security.

On a x86_64, with allmodconfig, as an example:
Before:
======
   text	   data	    bss	    dec	    hex	filename
  20446	   1746	     16	  22208	   56c0	drivers/gpu/drm/exynos/exynos_drm_fimc.o

After:
=====
   text	   data	    bss	    dec	    hex	filename
  20446	   1714	     16	  22176	   56a0	drivers/gpu/drm/exynos/exynos_drm_fimc.o

Signed-off-by: Christophe JAILLET <christophe.jaillet@wanadoo.fr>
Signed-off-by: Inki Dae <inki.dae@samsung.com>
This commit is contained in:
Christophe JAILLET 2024-07-14 09:37:20 +02:00 committed by Inki Dae
parent fce4a2a95d
commit c50b7416fd
No known key found for this signature in database
GPG Key ID: C5601BECE83FF9B6
3 changed files with 3 additions and 3 deletions

View File

@ -1125,7 +1125,7 @@ static void fimc_abort(struct exynos_drm_ipp *ipp,
}
}
static struct exynos_drm_ipp_funcs ipp_funcs = {
static const struct exynos_drm_ipp_funcs ipp_funcs = {
.commit = fimc_commit,
.abort = fimc_abort,
};

View File

@ -1162,7 +1162,7 @@ static void gsc_abort(struct exynos_drm_ipp *ipp,
}
}
static struct exynos_drm_ipp_funcs ipp_funcs = {
static const struct exynos_drm_ipp_funcs ipp_funcs = {
.commit = gsc_commit,
.abort = gsc_abort,
};

View File

@ -403,7 +403,7 @@ static int scaler_commit(struct exynos_drm_ipp *ipp,
return 0;
}
static struct exynos_drm_ipp_funcs ipp_funcs = {
static const struct exynos_drm_ipp_funcs ipp_funcs = {
.commit = scaler_commit,
};