summaryrefslogtreecommitdiffstats
path: root/drivers
diff options
context:
space:
mode:
authorZhaoxiong Lv <lvzhaoxiong@huaqin.corp-partner.google.com>2024-07-23 08:26:14 +0200
committerNeil Armstrong <neil.armstrong@linaro.org>2024-07-24 09:55:36 +0200
commitc60ca14bfd2d399a66f7164e044b63991c6a5a82 (patch)
tree69be3e9a0bfee6d481c8b776e6d1722bebd89185 /drivers
parentdrm: panel: boe-bf060y8m-aj0: Enable prepare_prev_first (diff)
downloadlinux-c60ca14bfd2d399a66f7164e044b63991c6a5a82.tar.xz
linux-c60ca14bfd2d399a66f7164e044b63991c6a5a82.zip
drm/panel: boe-th101mb31ig002 : Fix the way to get porch parameters
The current driver can only obtain the porch parameters of boe-th101mb31ig002. Modify it to obtain the porch parameters of the panel currently being used. Reviewed-by: Douglas Anderson <dianders@chromium.org> Signed-off-by: Zhaoxiong Lv <lvzhaoxiong@huaqin.corp-partner.google.com> Link: https://lore.kernel.org/r/20240723062615.14796-2-lvzhaoxiong@huaqin.corp-partner.google.com Signed-off-by: Neil Armstrong <neil.armstrong@linaro.org> Link: https://patchwork.freedesktop.org/patch/msgid/20240723062615.14796-2-lvzhaoxiong@huaqin.corp-partner.google.com
Diffstat (limited to 'drivers')
-rw-r--r--drivers/gpu/drm/panel/panel-boe-th101mb31ig002-28a.c9
1 files changed, 4 insertions, 5 deletions
diff --git a/drivers/gpu/drm/panel/panel-boe-th101mb31ig002-28a.c b/drivers/gpu/drm/panel/panel-boe-th101mb31ig002-28a.c
index b55cf80c5522..d4e4abd103bb 100644
--- a/drivers/gpu/drm/panel/panel-boe-th101mb31ig002-28a.c
+++ b/drivers/gpu/drm/panel/panel-boe-th101mb31ig002-28a.c
@@ -312,15 +312,14 @@ static int boe_th101mb31ig002_get_modes(struct drm_panel *panel,
struct boe_th101mb31ig002 *ctx = container_of(panel,
struct boe_th101mb31ig002,
panel);
+ const struct drm_display_mode *desc_mode = ctx->desc->modes;
struct drm_display_mode *mode;
- mode = drm_mode_duplicate(connector->dev,
- &boe_th101mb31ig002_default_mode);
+ mode = drm_mode_duplicate(connector->dev, desc_mode);
if (!mode) {
dev_err(panel->dev, "Failed to add mode %ux%u@%u\n",
- boe_th101mb31ig002_default_mode.hdisplay,
- boe_th101mb31ig002_default_mode.vdisplay,
- drm_mode_vrefresh(&boe_th101mb31ig002_default_mode));
+ desc_mode->hdisplay, desc_mode->vdisplay,
+ drm_mode_vrefresh(desc_mode));
return -ENOMEM;
}