drm/fb_helper: set info->par in fill_info()
authorDaniel Vetter <daniel.vetter@ffwll.ch>
Tue, 26 Mar 2019 13:19:50 +0000 (14:19 +0100)
committerDaniel Vetter <daniel.vetter@ffwll.ch>
Wed, 27 Mar 2019 08:55:46 +0000 (09:55 +0100)
The fbdev emulation helpers pretty much assume that this is set.
Let's do it for everyone.

Reviewed-by: Sam Ravnborg <sam@ravnborg.org>
Cc: Sam Ravnborg <sam@ravnborg.org>
Reviewed-by: Noralf Trønnes <noralf@tronnes.org>
Reviewed-by: Alex Deucher <alexander.deucher@amd.com>
Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
Link: https://patchwork.freedesktop.org/patch/msgid/20190326132008.11781-3-daniel.vetter@ffwll.ch
drivers/gpu/drm/drm_fb_helper.c

index 6f51629..821a255 100644 (file)
@@ -2128,6 +2128,7 @@ void drm_fb_helper_fill_info(struct fb_info *info,
        drm_fb_helper_fill_var(info, fb_helper,
                               sizes->fb_width, sizes->fb_height);
 
+       info->par = fb_helper;
        snprintf(info->fix.id, sizeof(info->fix.id), "%sdrmfb",
                 fb_helper->dev->driver->name);
 
@@ -3181,7 +3182,6 @@ int drm_fb_helper_generic_probe(struct drm_fb_helper *fb_helper,
        if (IS_ERR(fbi))
                return PTR_ERR(fbi);
 
-       fbi->par = fb_helper;
        fbi->fbops = &drm_fbdev_fb_ops;
        fbi->screen_size = fb->height * fb->pitches[0];
        fbi->fix.smem_len = fbi->screen_size;