Change some global variables 63/208263/1
authorlsj119 <lsj119@samsung.com>
Fri, 21 Jun 2019 01:44:00 +0000 (10:44 +0900)
committerlsj119 <lsj119@samsung.com>
Fri, 21 Jun 2019 01:45:15 +0000 (10:45 +0900)
Change-Id: I4841a803db39ed94d4909d64337e28aee9b91625

src/tbm_bufmgr_exynos.c

index 8576b8e..004088e 100644 (file)
@@ -185,7 +185,7 @@ struct _tbm_bufmgr_exynos {
        tbm_bufmgr bufmgr;
 };
 
-char *STR_DEVICE[] = {
+const static char *STR_DEVICE[] = {
        "DEF",
        "CPU",
        "2D",
@@ -193,7 +193,7 @@ char *STR_DEVICE[] = {
        "MM"
 };
 
-char *STR_OPT[] = {
+const static char *STR_OPT[] = {
        "NONE",
        "RD",
        "WR",
@@ -201,13 +201,6 @@ char *STR_OPT[] = {
 };
 
 
-uint32_t tbm_exynos_color_format_list[TBM_COLOR_FORMAT_COUNT] = {
-                                                                               TBM_FORMAT_ARGB8888,
-                                                                               TBM_FORMAT_XRGB8888,
-                                                                               TBM_FORMAT_NV12,
-                                                                               TBM_FORMAT_YUV420
-                                                                       };
-
 #ifdef TGL_GET_VERSION
 static inline int
 _tgl_get_version(int fd)
@@ -1037,6 +1030,13 @@ static tbm_error_e
 tbm_exynos_bufmgr_get_supported_formats(tbm_backend_bufmgr_data *bufmgr_data,
                                                        uint32_t **formats, uint32_t *num)
 {
+       const static uint32_t tbm_exynos_color_format_list[TBM_COLOR_FORMAT_COUNT] = {
+                                                                                       TBM_FORMAT_ARGB8888,
+                                                                                       TBM_FORMAT_XRGB8888,
+                                                                                       TBM_FORMAT_NV12,
+                                                                                       TBM_FORMAT_YUV420
+                                                                               };
+
        tbm_bufmgr_exynos bufmgr_exynos = (tbm_bufmgr_exynos)bufmgr_data;
        uint32_t *color_formats;