@@ -539,7 +539,7 @@ struct fb_info *fbtft_framebuffer_alloc(struct fbtft_display *display,
{
struct fb_info *info;
struct fbtft_par *par;
- struct fb_ops *fbops = NULL;
+ const struct fb_ops *fbops = NULL;
struct fb_deferred_io *fbdefio = NULL;
u8 *vmem = NULL;
void *txbuf = NULL;
@@ -614,7 +614,7 @@ struct fb_info *fbtft_framebuffer_alloc(struct fbtft_display *display,
if (!vmem)
goto alloc_fail;
- fbops = devm_kzalloc(dev, sizeof(struct fb_ops), GFP_KERNEL);
+ const fbops = devm_kzalloc(dev, sizeof(struct fb_ops), GFP_KERNEL);
if (!fbops)
goto alloc_fail;
This simple patch fixes a checkpatch.pl warning in `fbtft/fbtft-core.c`. Reported by Checkpatch: WARNING: struct fb_ops should normally be const Signed-off-by: Uri Arev <me@wantyapps.xyz> --- drivers/staging/fbtft/fbtft-core.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-)