public inbox for linux-doc@vger.kernel.org
 help / color / mirror / Atom feed
* [PATCH 00/20] drm/panel: Move to using mipi_dsi_*_multi() variants when available
@ 2025-02-13 20:44 Anusha Srivatsa
  2025-02-13 20:44 ` [PATCH 01/20] drm/panel/xpp055c272: Move to using mipi_dsi_*_multi() variants Anusha Srivatsa
                   ` (20 more replies)
  0 siblings, 21 replies; 32+ messages in thread
From: Anusha Srivatsa @ 2025-02-13 20:44 UTC (permalink / raw)
  To: Neil Armstrong, Jessica Zhang, Maarten Lankhorst, Maxime Ripard,
	Thomas Zimmermann, David Airlie, Simona Vetter, Joel Selvaraj,
	Ondrej Jirman, Javier Martinez Canillas, Jianhua Lu,
	Robert Chiras, Artur Weber, Jonathan Corbet
  Cc: dri-devel, linux-kernel, linux-doc, Anusha Srivatsa,
	Douglas Anderson

A lot of mipi API are deprecated and have a _multi() variant
which is the preferred way forward. This covers  TODO in the
gpu Documentation:[1]

An incomplete effort was made in the previous version
to address this[2]. It removed on the mipi_dsi_dcs_write_seq()
and mipi_dsi_generic_write_seq_multi() with the respective
replacemts and not the rest of the API.

The Coccinelle patch used to mkae changes:
@rule_1@
expression dsi_var;
expression list es;
identifier jdi;
@@
static int jdi_write_dcdc_registers(struct jdi_panel *jdi)
{
+struct mipi_dsi_multi_context dsi_ctx1 = { .dsi = jdi->link1 };
+struct mipi_dsi_multi_context dsi_ctx2 = { .dsi = jdi->link2 };
<+...
-mipi_dsi_generic_write_seq(jdi->link1,es);
+mipi_dsi_generic_write_seq_multi(&dsi_ctx1,es);
-mipi_dsi_generic_write_seq(jdi->link2,es);
+mipi_dsi_generic_write_seq_multi(&dsi_ctx2,es);
...+>
}

@rule_2@
expression dsi_var;
expression list es;
identifier jdi;
@@
struct mipi_dsi_device *dsi0 = pinfo->dsi[0];
struct mipi_dsi_device *dsi1 = pinfo->dsi[1];
+struct mipi_dsi_multi_context dsi_ctx0 = { .dsi = dsi0 };
+struct mipi_dsi_multi_context dsi_ctx1 = { .dsi = dsi1 };
<+...
-mipi_dsi_dual_dcs_write_seq(dsi0, dsi1, es);
+mipi_dsi_dual_dcs_write_seq(dsi_ctx0, dsi_ctx1, es);
...+>

@rule_3@
identifier func;
identifier r;
type t;
expression list es;
position p;
@@
t func(...) {
<+...
(
-mipi_dsi_dcs_write_seq(dsi_var,es);
+mipi_dsi_dcs_write_seq_multi(&dsi_ctx,es);
|
-r = mipi_dsi_dcs_exit_sleep_mode(jdi->link1)@p;
+mipi_dsi_dcs_exit_sleep_mode_multi(&dsi_ctx1);
|
-r = mipi_dsi_dcs_enter_sleep_mode(jdi->link1)@p;
+mipi_dsi_dcs_enter_sleep_mode_multi(&dsi_ctx1);
|
-r = mipi_dsi_dcs_set_display_off(jdi->link1)@p;
+mipi_dsi_dcs_set_display_off_multi(&dsi_ctx1);
|
.....//rest of the mipi APIs with _multi variant
)
<+...
-if(r < 0) {
-...
-}
...+>

[1] -> https://docs.kernel.org/gpu/todo.html#transition-away-from-using-mipi-dsi-write-seq
[2] -> https://patchwork.freedesktop.org/series/144446/

Signed-off-by: Anusha Srivatsa <asrivats@redhat.com>
---
Anusha Srivatsa (20):
      drm/panel/xpp055c272: Move to using mipi_dsi_*_multi() variants
      drm/panel/visionox-r66451: Move to using mipi_dsi_*_multi() variants
      drm/panel/asus-tm5p5-n35596: Move to using mipi_dsi_*_multi() variants
      drm/panel/boe-bf060y8m-aj0: Move to using mipi_dsi_*_multi() variants
      drm/panel/dsi-cm: Move to using mipi_dsi_*_multi() variants
      drm/panel/sony-nt35521: Move to using mipi_dsi_*_multi() variants
      drm/panel/ebbg-ft8719: Move to using mipi_dsi_*_multi() variants
      drm/panel/himax-hx8394: Move to using mipi_dsi_*_multi() variants
      drm/panel/jdi-lpm102a188a: Move to using mipi_dsi_*_multi() variants
      drm/panel/jdi-lt070me05000: Move to using mipi_dsi_*_multi() variants
      drm/panel/novatek-nt36523: Move to using mipi_dsi_*_multi() variants
      drm/panel/raydium-rm67191: Move to using mipi_dsi_*_multi() variants
      drm/panel/samsung-s6d7aa0:Move to using mipi_dsi_*_multi() variants
      drm/panel/s6e88a0-ams452ef01: Move to using mipi_dsi_*_multi() variants
      drm/panel/samsung-sofef00: Move to using mipi_dsi_*_multi() variants
      drm/panel/ls043t1le01: Move to using mipi_dsi_*_multi() variants
      drm/panel/ls060t1sx01: Move to using mipi_dsi_*_multi() variants
      drm/panel/sony-td4353-jdi: Move to using mipi_dsi_*_multi() variants
      drm/panel: Remove deprecated functions
      Documentation: Update the documentation

 Documentation/gpu/todo.rst                         |   19 -
 drivers/gpu/drm/drm_mipi_dsi.c                     |   56 -
 .../gpu/drm/panel/panel-asus-z00t-tm5p5-n35596.c   |    6 +-
 drivers/gpu/drm/panel/panel-boe-bf060y8m-aj0.c     |   75 +-
 drivers/gpu/drm/panel/panel-dsi-cm.c               |   44 +-
 drivers/gpu/drm/panel/panel-ebbg-ft8719.c          |   45 +-
 drivers/gpu/drm/panel/panel-himax-hx8394.c         |  389 +++--
 drivers/gpu/drm/panel/panel-jdi-lpm102a188a.c      |  141 +-
 drivers/gpu/drm/panel/panel-jdi-lt070me05000.c     |   81 +-
 drivers/gpu/drm/panel/panel-novatek-nt36523.c      | 1678 ++++++++++----------
 drivers/gpu/drm/panel/panel-raydium-rm67191.c      |   60 +-
 drivers/gpu/drm/panel/panel-samsung-s6d7aa0.c      |  101 +-
 .../drm/panel/panel-samsung-s6e88a0-ams452ef01.c   |   63 +-
 drivers/gpu/drm/panel/panel-samsung-sofef00.c      |   54 +-
 drivers/gpu/drm/panel/panel-sharp-ls043t1le01.c    |   28 +-
 drivers/gpu/drm/panel/panel-sharp-ls060t1sx01.c    |   34 +-
 drivers/gpu/drm/panel/panel-sony-td4353-jdi.c      |   71 +-
 .../gpu/drm/panel/panel-sony-tulip-truly-nt35521.c |    6 +-
 drivers/gpu/drm/panel/panel-visionox-r66451.c      |  156 +-
 drivers/gpu/drm/panel/panel-xinpeng-xpp055c272.c   |  138 +-
 include/drm/drm_mipi_dsi.h                         |   47 -
 21 files changed, 1432 insertions(+), 1860 deletions(-)
---
base-commit: febbc555cf0fff895546ddb8ba2c9a523692fb55
change-id: 20250211-mipi_cocci_multi-440af15236c2

Best regards,
-- 
Anusha Srivatsa <asrivats@redhat.com>


^ permalink raw reply	[flat|nested] 32+ messages in thread

end of thread, other threads:[~2025-02-24 18:40 UTC | newest]

Thread overview: 32+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2025-02-13 20:44 [PATCH 00/20] drm/panel: Move to using mipi_dsi_*_multi() variants when available Anusha Srivatsa
2025-02-13 20:44 ` [PATCH 01/20] drm/panel/xpp055c272: Move to using mipi_dsi_*_multi() variants Anusha Srivatsa
2025-02-13 21:06   ` Dmitry Baryshkov
2025-02-13 20:44 ` [PATCH 02/20] drm/panel/visionox-r66451: " Anusha Srivatsa
2025-02-13 21:07   ` Dmitry Baryshkov
2025-02-13 20:44 ` [PATCH 03/20] drm/panel/asus-tm5p5-n35596: " Anusha Srivatsa
2025-02-13 21:08   ` Dmitry Baryshkov
2025-02-13 20:44 ` [PATCH 04/20] drm/panel/boe-bf060y8m-aj0: " Anusha Srivatsa
2025-02-13 21:27   ` Dmitry Baryshkov
2025-02-13 20:44 ` [PATCH 05/20] drm/panel/dsi-cm: " Anusha Srivatsa
2025-02-13 20:44 ` [PATCH 06/20] drm/panel/sony-nt35521: " Anusha Srivatsa
2025-02-13 20:44 ` [PATCH 07/20] drm/panel/ebbg-ft8719: " Anusha Srivatsa
2025-02-13 20:44 ` [PATCH 08/20] drm/panel/himax-hx8394: " Anusha Srivatsa
2025-02-13 20:44 ` [PATCH 09/20] drm/panel/jdi-lpm102a188a: " Anusha Srivatsa
2025-02-13 20:44 ` [PATCH 10/20] drm/panel/jdi-lt070me05000: " Anusha Srivatsa
2025-02-13 20:44 ` [PATCH 11/20] drm/panel/novatek-nt36523: " Anusha Srivatsa
2025-02-13 20:44 ` [PATCH 12/20] drm/panel/raydium-rm67191: " Anusha Srivatsa
2025-02-13 20:44 ` [PATCH 13/20] drm/panel/samsung-s6d7aa0:Move " Anusha Srivatsa
2025-02-13 20:44 ` [PATCH 14/20] drm/panel/s6e88a0-ams452ef01: Move " Anusha Srivatsa
2025-02-13 20:44 ` [PATCH 15/20] drm/panel/samsung-sofef00: " Anusha Srivatsa
2025-02-13 20:44 ` [PATCH 16/20] drm/panel/ls043t1le01: " Anusha Srivatsa
2025-02-13 20:44 ` [PATCH 17/20] drm/panel/ls060t1sx01: " Anusha Srivatsa
2025-02-13 20:44 ` [PATCH 18/20] drm/panel/sony-td4353-jdi: " Anusha Srivatsa
2025-02-13 20:44 ` [PATCH 19/20] drm/panel: Remove deprecated functions Anusha Srivatsa
2025-02-13 20:44 ` [PATCH 20/20] Documentation: Update the documentation Anusha Srivatsa
2025-02-14 16:26 ` [PATCH 00/20] drm/panel: Move to using mipi_dsi_*_multi() variants when available Doug Anderson
2025-02-18  9:55   ` Maxime Ripard
2025-02-18 12:14     ` Dmitry Baryshkov
2025-02-18 15:52       ` Maxime Ripard
2025-02-19  9:11         ` Dmitry Baryshkov
2025-02-19 13:35           ` Maxime Ripard
2025-02-24 18:40     ` Doug Anderson

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox