[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <20201026194110.3817470-4-arnd@kernel.org>
Date: Mon, 26 Oct 2020 20:41:04 +0100
From: Arnd Bergmann <arnd@...nel.org>
To: Patrik Jakobsson <patrik.r.jakobsson@...il.com>,
David Airlie <airlied@...ux.ie>,
Daniel Vetter <daniel@...ll.ch>,
Stefan Christ <contact@...fanchrist.eu>
Cc: Arnd Bergmann <arnd@...db.de>,
Daniel Vetter <daniel.vetter@...ll.ch>,
Thomas Zimmermann <tzimmermann@...e.de>,
Emil Velikov <emil.velikov@...labora.com>,
Pankaj Bharadiya <pankaj.laxminarayan.bharadiya@...el.com>,
Rikard Falkeborn <rikard.falkeborn@...il.com>,
Paul Kocialkowski <paul.kocialkowski@...tlin.com>,
Ville Syrjälä
<ville.syrjala@...ux.intel.com>, dri-devel@...ts.freedesktop.org,
linux-kernel@...r.kernel.org
Subject: [PATCH 4/4] drm/gma500: avoid Woverride-init warning
From: Arnd Bergmann <arnd@...db.de>
gcc -Wextra notices that one of the fields in psbfb_roll_ops has two
initializers:
drivers/gpu/drm/gma500/framebuffer.c:185:20: warning: initialized field overwritten [-Woverride-init]
Open-code this instead, leaving out the extraneous initializers for
.fb_pan_display.
Fixes: 3da6c2f3b730 ("drm/gma500: use DRM_FB_HELPER_DEFAULT_OPS for fb_ops")
Signed-off-by: Arnd Bergmann <arnd@...db.de>
---
drivers/gpu/drm/gma500/framebuffer.c | 9 ++++++++-
1 file changed, 8 insertions(+), 1 deletion(-)
diff --git a/drivers/gpu/drm/gma500/framebuffer.c b/drivers/gpu/drm/gma500/framebuffer.c
index 54d9876b5305..a56a6b53fac6 100644
--- a/drivers/gpu/drm/gma500/framebuffer.c
+++ b/drivers/gpu/drm/gma500/framebuffer.c
@@ -177,7 +177,14 @@ static const struct fb_ops psbfb_ops = {
static const struct fb_ops psbfb_roll_ops = {
.owner = THIS_MODULE,
- DRM_FB_HELPER_DEFAULT_OPS,
+ .fb_check_var = drm_fb_helper_check_var,
+ .fb_set_par = drm_fb_helper_set_par,
+ .fb_setcmap = drm_fb_helper_setcmap,
+ .fb_blank = drm_fb_helper_blank,
+ .fb_debug_enter = drm_fb_helper_debug_enter,
+ .fb_debug_leave = drm_fb_helper_debug_leave,
+ .fb_ioctl = drm_fb_helper_ioctl,
+
.fb_setcolreg = psbfb_setcolreg,
.fb_fillrect = drm_fb_helper_cfb_fillrect,
.fb_copyarea = drm_fb_helper_cfb_copyarea,
--
2.27.0
Powered by blists - more mailing lists