public inbox for stable@vger.kernel.org
 help / color / mirror / Atom feed
From: Fabio Estevam <festevam@gmail.com>
To: stable@vger.kernel.org
Cc: tzimmermann@suse.de, javierm@redhat.com,
	gregkh@linuxfoundation.org, "Noralf Trønnes" <noralf@tronnes.org>,
	"Fabio Estevam" <festevam@denx.de>
Subject: [PATCH 6.12.y 2/3] drm/panel-mipi-dbi: Run DRM default client setup
Date: Mon, 19 May 2025 13:32:29 -0300	[thread overview]
Message-ID: <20250519163230.1303438-2-festevam@gmail.com> (raw)
In-Reply-To: <20250519163230.1303438-1-festevam@gmail.com>

From: Thomas Zimmermann <tzimmermann@suse.de>

commit 1b0caa5f5ac20bcaf82fc89a5c849b21ce3bfdf6 uptream.

Call drm_client_setup() to run the kernel's default client setup
for DRM. Set fbdev_probe in struct drm_driver, so that the client
setup can start the common fbdev client.

v5:
- select DRM_CLIENT_SELECTION

Signed-off-by: Thomas Zimmermann <tzimmermann@suse.de>
Cc: "Noralf Trønnes" <noralf@tronnes.org>
Acked-by: Noralf Trønnes <noralf@tronnes.org>
Link: https://patchwork.freedesktop.org/patch/msgid/20240924071734.98201-32-tzimmermann@suse.de
Signed-off-by: Fabio Estevam <festevam@denx.de>
---
 drivers/gpu/drm/tiny/Kconfig          | 1 +
 drivers/gpu/drm/tiny/panel-mipi-dbi.c | 4 +++-
 2 files changed, 4 insertions(+), 1 deletion(-)

diff --git a/drivers/gpu/drm/tiny/Kconfig b/drivers/gpu/drm/tiny/Kconfig
index f6889f649bc1..ce17143d47a8 100644
--- a/drivers/gpu/drm/tiny/Kconfig
+++ b/drivers/gpu/drm/tiny/Kconfig
@@ -67,6 +67,7 @@ config DRM_OFDRM
 config DRM_PANEL_MIPI_DBI
 	tristate "DRM support for MIPI DBI compatible panels"
 	depends on DRM && SPI
+	select DRM_CLIENT_SELECTION
 	select DRM_KMS_HELPER
 	select DRM_GEM_DMA_HELPER
 	select DRM_MIPI_DBI
diff --git a/drivers/gpu/drm/tiny/panel-mipi-dbi.c b/drivers/gpu/drm/tiny/panel-mipi-dbi.c
index f753cdffe6f8..e66729b31bd6 100644
--- a/drivers/gpu/drm/tiny/panel-mipi-dbi.c
+++ b/drivers/gpu/drm/tiny/panel-mipi-dbi.c
@@ -15,6 +15,7 @@
 #include <linux/spi/spi.h>
 
 #include <drm/drm_atomic_helper.h>
+#include <drm/drm_client_setup.h>
 #include <drm/drm_drv.h>
 #include <drm/drm_fbdev_dma.h>
 #include <drm/drm_gem_atomic_helper.h>
@@ -264,6 +265,7 @@ static const struct drm_driver panel_mipi_dbi_driver = {
 	.driver_features	= DRIVER_GEM | DRIVER_MODESET | DRIVER_ATOMIC,
 	.fops			= &panel_mipi_dbi_fops,
 	DRM_GEM_DMA_DRIVER_OPS_VMAP,
+	DRM_FBDEV_DMA_DRIVER_OPS,
 	.debugfs_init		= mipi_dbi_debugfs_init,
 	.name			= "panel-mipi-dbi",
 	.desc			= "MIPI DBI compatible display panel",
@@ -388,7 +390,7 @@ static int panel_mipi_dbi_spi_probe(struct spi_device *spi)
 
 	spi_set_drvdata(spi, drm);
 
-	drm_fbdev_dma_setup(drm, 0);
+	drm_client_setup(drm, NULL);
 
 	return 0;
 }
-- 
2.34.1


  reply	other threads:[~2025-05-19 16:32 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-05-19 16:32 [PATCH 6.12.y 1/3] drm/fbdev-dma: Support struct drm_driver.fbdev_probe Fabio Estevam
2025-05-19 16:32 ` Fabio Estevam [this message]
2025-05-20  8:19   ` [PATCH 6.12.y 2/3] drm/panel-mipi-dbi: Run DRM default client setup Sasha Levin
2025-05-19 16:32 ` [PATCH 6.12.y 3/3] drm/tiny: panel-mipi-dbi: Use drm_client_setup_with_fourcc() Fabio Estevam
2025-05-20  8:19   ` Sasha Levin
2025-05-20  7:52 ` [PATCH 6.12.y 1/3] drm/fbdev-dma: Support struct drm_driver.fbdev_probe Sasha Levin

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20250519163230.1303438-2-festevam@gmail.com \
    --to=festevam@gmail.com \
    --cc=festevam@denx.de \
    --cc=gregkh@linuxfoundation.org \
    --cc=javierm@redhat.com \
    --cc=noralf@tronnes.org \
    --cc=stable@vger.kernel.org \
    --cc=tzimmermann@suse.de \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox