]> git.ipfire.org Git - thirdparty/kernel/linux.git/commitdiff
drm: Make passing of format info to drm_helper_mode_fill_fb_struct() mandatory
authorVille Syrjälä <ville.syrjala@linux.intel.com>
Tue, 1 Jul 2025 09:07:22 +0000 (12:07 +0300)
committerVille Syrjälä <ville.syrjala@linux.intel.com>
Wed, 16 Jul 2025 17:12:35 +0000 (20:12 +0300)
Now that everyone passes along the format info to
drm_helper_mode_fill_fb_struct() we can make this behaviour
mandatory and drop the extra lookup.

Reviewed-by: Thomas Zimmermann <tzimmermann@suse.de>
Reviewed-by: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com>
Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com>
Link: https://patchwork.freedesktop.org/patch/msgid/20250701090722.13645-20-ville.syrjala@linux.intel.com
drivers/gpu/drm/drm_modeset_helper.c

index 89ba99970735469d5a4d3c8b3029c0f56f806dbd..988735560570063c3b98d99557326db2670744a9 100644 (file)
@@ -88,8 +88,7 @@ void drm_helper_mode_fill_fb_struct(struct drm_device *dev,
        int i;
 
        fb->dev = dev;
-       fb->format = info ? : drm_get_format_info(dev, mode_cmd->pixel_format,
-                                                 mode_cmd->modifier[0]);
+       fb->format = info;
        fb->width = mode_cmd->width;
        fb->height = mode_cmd->height;
        for (i = 0; i < 4; i++) {