2019-06-04 10:11:33 +02:00
|
|
|
|
2012-11-15 21:28:22 +00:00
|
|
|
|
|
|
|
|
|
2013-03-22 16:34:09 +02:00
|
|
|
|
2012-11-15 21:28:22 +00:00
|
|
|
|
|
|
|
|
|
2013-03-22 16:34:05 +02:00
|
|
|
|
|
|
|
|
|
2012-11-15 21:28:22 +00:00
|
|
|
|
2013-09-24 13:59:01 +02:00
|
|
|
|
2016-12-14 13:16:11 +02:00
|
|
|
|
2020-04-15 14:24:27 +02:00
|
|
|
|
2013-09-24 13:59:01 +02:00
|
|
|
|
2017-11-13 11:08:13 +01:00
|
|
|
|
2020-08-14 01:06:54 +03:00
|
|
|
|
2016-11-28 20:51:09 +02:00
|
|
|
|
2012-11-15 21:28:22 +00:00
|
|
|
|
2019-01-17 22:03:34 +01:00
|
|
|
|
2019-08-04 11:41:30 +02:00
|
|
|
|
2012-11-15 21:28:22 +00:00
|
|
|
|
2014-06-03 14:48:12 +02:00
|
|
|
|
2017-11-13 11:08:13 +01:00
|
|
|
|
2017-08-15 15:41:10 +02:00
|
|
|
|
2014-06-03 14:48:12 +02:00
|
|
|
|
2021-03-26 15:51:39 +01:00
|
|
|
|
2021-05-30 22:55:06 +03:00
|
|
|
|
2021-03-26 15:51:39 +01:00
|
|
|
|
2024-09-24 09:13:16 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2023-12-13 12:19:51 +02:00
|
|
|
|
2013-11-06 16:20:54 -07:00
|
|
|
|
|
|
|
|
|
2013-09-24 13:22:17 +02:00
|
|
|
|
2012-11-15 21:28:22 +00:00
|
|
|
|
|
|
|
|
|
2014-06-26 21:41:53 +02:00
|
|
|
|
2019-10-28 13:37:18 +01:00
|
|
|
|
2017-03-09 20:04:56 +01:00
|
|
|
|
2014-06-26 21:41:53 +02:00
|
|
|
|
|
|
|
|
|
2016-12-14 13:16:11 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2012-11-15 21:28:22 +00:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2021-03-26 15:51:33 +01:00
|
|
|
|
2014-07-11 08:29:14 +02:00
|
|
|
|
2021-03-26 15:51:38 +01:00
|
|
|
|
2014-11-24 17:41:23 +01:00
|
|
|
|
2017-11-13 11:08:13 +01:00
|
|
|
|
2012-11-15 21:28:22 +00:00
|
|
|
|
|
|
|
|
|
2021-06-10 14:04:51 +03:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2013-09-24 15:35:40 +02:00
|
|
|
|
2012-11-15 21:28:22 +00:00
|
|
|
|
2013-09-26 16:08:22 +02:00
|
|
|
|
2013-09-24 15:35:40 +02:00
|
|
|
|
2013-03-22 16:34:09 +02:00
|
|
|
|
2021-06-10 14:04:51 +03:00
|
|
|
|
|
|
|
|
|
2017-03-09 20:04:55 +01:00
|
|
|
|
2021-06-10 14:04:51 +03:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2022-06-27 17:19:53 +03:00
|
|
|
|
2013-03-22 16:34:09 +02:00
|
|
|
|
|
|
|
|
|
2013-09-24 15:35:40 +02:00
|
|
|
|
|
|
|
|
|
2013-09-26 16:08:22 +02:00
|
|
|
|
|
|
|
|
|
2013-10-10 11:00:33 +02:00
|
|
|
|
2017-06-15 02:18:37 +03:00
|
|
|
|
2013-09-26 16:08:22 +02:00
|
|
|
|
2013-03-22 16:34:09 +02:00
|
|
|
|
|
|
|
|
|
2022-06-27 17:19:53 +03:00
|
|
|
|
|
|
|
|
|
2013-03-22 16:34:09 +02:00
|
|
|
|
|
|
|
|
|
2013-10-10 11:00:33 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2022-06-27 17:19:54 +03:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2013-09-24 15:35:40 +02:00
|
|
|
|
|
|
|
|
|
2013-10-14 14:43:22 +02:00
|
|
|
|
2019-02-01 14:28:31 +01:00
|
|
|
|
2021-06-10 14:04:50 +03:00
|
|
|
|
2012-11-15 21:28:22 +00:00
|
|
|
|
2021-06-10 14:04:50 +03:00
|
|
|
|
2018-05-16 17:05:04 +02:00
|
|
|
|
2013-09-24 15:35:40 +02:00
|
|
|
|
2012-11-15 21:28:22 +00:00
|
|
|
|
|
|
|
|
|
2013-09-24 15:35:40 +02:00
|
|
|
|
2013-10-14 14:43:22 +02:00
|
|
|
|
2013-09-24 15:35:40 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2014-04-16 09:54:21 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2019-10-28 13:37:08 +01:00
|
|
|
|
2019-02-08 14:35:13 +01:00
|
|
|
|
2013-10-14 14:43:22 +02:00
|
|
|
|
2016-12-14 13:16:11 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2017-09-11 14:29:52 +02:00
|
|
|
|
|
|
|
|
|
2012-11-15 21:28:22 +00:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2020-08-14 01:06:54 +03:00
|
|
|
|
2013-08-30 15:22:36 +02:00
|
|
|
|
2012-11-15 21:28:22 +00:00
|
|
|
|
2024-08-22 20:42:50 +03:00
|
|
|
|
2018-12-10 17:34:54 +01:00
|
|
|
|
2012-11-15 21:28:22 +00:00
|
|
|
|
2019-06-05 10:46:46 +02:00
|
|
|
|
2012-11-15 21:28:22 +00:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2014-04-16 09:54:21 +02:00
|
|
|
|
2014-12-19 15:55:08 +01:00
|
|
|
|
2014-04-16 09:54:21 +02:00
|
|
|
|
2014-12-19 15:55:08 +01:00
|
|
|
|
2017-10-12 19:12:57 +02:00
|
|
|
|
|
|
|
|
|
2019-12-02 15:29:03 +01:00
|
|
|
|
|
|
|
|
|
2012-11-15 21:28:22 +00:00
|
|
|
|
2014-11-28 15:38:40 +01:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2013-11-15 16:06:05 +01:00
|
|
|
|
2015-07-08 13:39:09 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2013-11-15 16:06:05 +01:00
|
|
|
|
2012-11-15 21:28:22 +00:00
|
|
|
|
2013-03-22 16:34:08 +02:00
|
|
|
|
|
|
|
|
|
2013-10-07 09:47:58 +02:00
|
|
|
|
2014-06-03 14:48:12 +02:00
|
|
|
|
|
|
|
|
|
2023-03-30 10:36:05 +02:00
|
|
|
|
2025-07-01 12:07:19 +03:00
|
|
|
|
2023-03-30 10:36:05 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2014-11-26 13:03:57 +01:00
|
|
|
|
|
|
|
|
|
drm: Pass the format info to .fb_create()
Pass along the format information from the top to .fb_create()
so that we can avoid redundant (and somewhat expensive) lookups
in the drivers.
Done with cocci (with some manual fixups):
@@
identifier func =~ ".*create.*";
identifier dev, file, mode_cmd;
@@
struct drm_framebuffer *func(
struct drm_device *dev,
struct drm_file *file,
+ const struct drm_format_info *info,
const struct drm_mode_fb_cmd2 *mode_cmd)
{
...
(
- const struct drm_format_info *info = drm_get_format_info(...);
|
- const struct drm_format_info *info;
...
- info = drm_get_format_info(...);
)
<...
- if (!info)
- return ...;
...>
}
@@
identifier func =~ ".*create.*";
identifier dev, file, mode_cmd;
@@
struct drm_framebuffer *func(
struct drm_device *dev,
struct drm_file *file,
+ const struct drm_format_info *info,
const struct drm_mode_fb_cmd2 *mode_cmd)
{
...
}
@find@
identifier fb_create_func =~ ".*create.*";
identifier dev, file, mode_cmd;
@@
struct drm_framebuffer *fb_create_func(
struct drm_device *dev,
struct drm_file *file,
+ const struct drm_format_info *info,
const struct drm_mode_fb_cmd2 *mode_cmd);
@@
identifier find.fb_create_func;
expression dev, file, mode_cmd;
@@
fb_create_func(dev, file
+ ,info
,mode_cmd)
@@
expression dev, file, mode_cmd;
@@
drm_gem_fb_create(dev, file
+ ,info
,mode_cmd)
@@
expression dev, file, mode_cmd;
@@
drm_gem_fb_create_with_dirty(dev, file
+ ,info
,mode_cmd)
@@
expression dev, file_priv, mode_cmd;
identifier info, fb;
@@
info = drm_get_format_info(...);
...
fb = dev->mode_config.funcs->fb_create(dev, file_priv
+ ,info
,mode_cmd);
@@
identifier dev, file_priv, mode_cmd;
@@
struct drm_mode_config_funcs {
...
struct drm_framebuffer *(*fb_create)(struct drm_device *dev,
struct drm_file *file_priv,
+ const struct drm_format_info *info,
const struct drm_mode_fb_cmd2 *mode_cmd);
...
};
v2: Fix kernel docs (Laurent)
Fix commit msg (Geert)
Cc: Alex Deucher <alexander.deucher@amd.com>
Cc: Liviu Dudau <liviu.dudau@arm.com>
Cc: Maxime Ripard <mripard@kernel.org>
Cc: Russell King <linux@armlinux.org.uk>
Cc: Inki Dae <inki.dae@samsung.com>
Cc: Seung-Woo Kim <sw0312.kim@samsung.com>
Cc: Kyungmin Park <kyungmin.park@samsung.com>
Cc: Patrik Jakobsson <patrik.r.jakobsson@gmail.com>
Cc: Chun-Kuang Hu <chunkuang.hu@kernel.org>
Cc: Philipp Zabel <p.zabel@pengutronix.de>
Cc: Rob Clark <robdclark@gmail.com>
Cc: Abhinav Kumar <quic_abhinavk@quicinc.com>
Cc: Dmitry Baryshkov <lumag@kernel.org>
Cc: Sean Paul <sean@poorly.run>
Cc: Marijn Suijten <marijn.suijten@somainline.org>
Cc: Marek Vasut <marex@denx.de>
Cc: Stefan Agner <stefan@agner.ch>
Cc: Lyude Paul <lyude@redhat.com>
Cc: Danilo Krummrich <dakr@kernel.org>
Cc: Tomi Valkeinen <tomi.valkeinen@ideasonboard.com>
Cc: Dave Airlie <airlied@redhat.com>
Cc: Gerd Hoffmann <kraxel@redhat.com>
Cc: Kieran Bingham <kieran.bingham+renesas@ideasonboard.com>
Cc: Biju Das <biju.das.jz@bp.renesas.com>
Cc: Sandy Huang <hjc@rock-chips.com>
Cc: "Heiko Stübner" <heiko@sntech.de>
Cc: Andy Yan <andy.yan@rock-chips.com>
Cc: Thierry Reding <thierry.reding@gmail.com>
Cc: Mikko Perttunen <mperttunen@nvidia.com>
Cc: Dave Stevenson <dave.stevenson@raspberrypi.com>
Cc: "Maíra Canal" <mcanal@igalia.com>
Cc: Raspberry Pi Kernel Maintenance <kernel-list@raspberrypi.com>
Cc: Dmitry Osipenko <dmitry.osipenko@collabora.com>
Cc: Gurchetan Singh <gurchetansingh@chromium.org>
Cc: Chia-I Wu <olvaffe@gmail.com>
Cc: Zack Rusin <zack.rusin@broadcom.com>
Cc: Broadcom internal kernel review list <bcm-kernel-feedback-list@broadcom.com>
Cc: Oleksandr Andrushchenko <oleksandr_andrushchenko@epam.com>
Cc: amd-gfx@lists.freedesktop.org
Cc: linux-arm-msm@vger.kernel.org
Cc: freedreno@lists.freedesktop.org
Cc: nouveau@lists.freedesktop.org
Cc: virtualization@lists.linux.dev
Cc: spice-devel@lists.freedesktop.org
Cc: linux-renesas-soc@vger.kernel.org
Cc: linux-tegra@vger.kernel.org
Cc: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com>
Reviewed-by: Geert Uytterhoeven <geert+renesas@glider.be>
Reviewed-by: Thomas Zimmermann <tzimmermann@suse.de>
Reviewed-by: Dmitry Baryshkov <dmitry.baryshkov@oss.qualcomm.com>
Acked-by: Liviu Dudau <liviu.dudau@arm.com>
Reviewed-by: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com>
Acked-by: Alex Deucher <alexander.deucher@amd.com>
Acked-by: Rodrigo Vivi <rodrigo.vivi@intel.com>
Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com>
Link: https://patchwork.freedesktop.org/patch/msgid/20250701090722.13645-5-ville.syrjala@linux.intel.com
2025-07-01 12:07:07 +03:00
|
|
|
|
2015-11-11 19:11:29 +02:00
|
|
|
|
2023-03-30 10:36:05 +02:00
|
|
|
|
|
|
|
|
|
2024-09-24 09:13:16 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2023-03-30 10:36:05 +02:00
|
|
|
|
2024-09-24 09:13:16 +02:00
|
|
|
|
|
|
|
|
|
2023-03-30 10:36:05 +02:00
|
|
|
|
2012-11-15 21:28:22 +00:00
|
|
|
|
2017-11-13 11:08:13 +01:00
|
|
|
|
2013-10-14 14:43:22 +02:00
|
|
|
|
|
|
|
|
|
2015-09-10 16:07:14 +02:00
|
|
|
|
2013-11-15 16:06:05 +01:00
|
|
|
|
2015-09-10 16:07:14 +02:00
|
|
|
|
2013-10-14 14:43:22 +02:00
|
|
|
|
2013-02-28 08:08:01 +01:00
|
|
|
|
2016-12-14 13:16:13 +02:00
|
|
|
|
2021-09-16 17:55:17 +03:00
|
|
|
|
2025-06-30 09:48:42 +01:00
|
|
|
|
2012-11-15 21:28:22 +00:00
|
|
|
|
2013-03-22 16:34:05 +02:00
|
|
|
|