Commit c08503ec authored by Rikard Falkeborn's avatar Rikard Falkeborn Committed by Daniel Vetter

drm/gma500: Constify static structs

The only usage of these is to assign their address to the fbops field in
the fb_info struct, which is a const pointer. Make them const to allow
the compiler to put them in read-only memory.
Signed-off-by: default avatarRikard Falkeborn <rikard.falkeborn@gmail.com>
Signed-off-by: default avatarDaniel Vetter <daniel.vetter@ffwll.ch>
Link: https://patchwork.freedesktop.org/patch/msgid/20200830211741.17326-1-rikard.falkeborn@gmail.com
parent 8445e2c5
...@@ -164,7 +164,7 @@ static int psbfb_mmap(struct fb_info *info, struct vm_area_struct *vma) ...@@ -164,7 +164,7 @@ static int psbfb_mmap(struct fb_info *info, struct vm_area_struct *vma)
return 0; return 0;
} }
static struct fb_ops psbfb_ops = { static const struct fb_ops psbfb_ops = {
.owner = THIS_MODULE, .owner = THIS_MODULE,
DRM_FB_HELPER_DEFAULT_OPS, DRM_FB_HELPER_DEFAULT_OPS,
.fb_setcolreg = psbfb_setcolreg, .fb_setcolreg = psbfb_setcolreg,
...@@ -175,7 +175,7 @@ static struct fb_ops psbfb_ops = { ...@@ -175,7 +175,7 @@ static struct fb_ops psbfb_ops = {
.fb_sync = psbfb_sync, .fb_sync = psbfb_sync,
}; };
static struct fb_ops psbfb_roll_ops = { static const struct fb_ops psbfb_roll_ops = {
.owner = THIS_MODULE, .owner = THIS_MODULE,
DRM_FB_HELPER_DEFAULT_OPS, DRM_FB_HELPER_DEFAULT_OPS,
.fb_setcolreg = psbfb_setcolreg, .fb_setcolreg = psbfb_setcolreg,
...@@ -186,7 +186,7 @@ static struct fb_ops psbfb_roll_ops = { ...@@ -186,7 +186,7 @@ static struct fb_ops psbfb_roll_ops = {
.fb_mmap = psbfb_mmap, .fb_mmap = psbfb_mmap,
}; };
static struct fb_ops psbfb_unaccel_ops = { static const struct fb_ops psbfb_unaccel_ops = {
.owner = THIS_MODULE, .owner = THIS_MODULE,
DRM_FB_HELPER_DEFAULT_OPS, DRM_FB_HELPER_DEFAULT_OPS,
.fb_setcolreg = psbfb_setcolreg, .fb_setcolreg = psbfb_setcolreg,
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment