On Sun, Mar 08, 2026 at 04:52:42PM +0100, Cristian Cozzolino via B4 Relay wrote: > From: Cristian Cozzolino <[email protected]> > > Add support for Novatek NT35532-based 1080p video mode DSI panel. > > Signed-off-by: Cristian Cozzolino <[email protected]> > --- > MAINTAINERS | 1 + > drivers/gpu/drm/panel/Kconfig | 11 + > drivers/gpu/drm/panel/Makefile | 1 + > drivers/gpu/drm/panel/panel-novatek-nt35532.c | 767 > ++++++++++++++++++++++++++ > 4 files changed, 780 insertions(+) > > diff --git a/MAINTAINERS b/MAINTAINERS > index 12243feb0b27..d854804dc8cc 100644 > --- a/MAINTAINERS > +++ b/MAINTAINERS > @@ -8143,6 +8143,7 @@ DRM DRIVER FOR NOVATEK NT35532 PANELS > M: Cristian Cozzolino <[email protected]> > S: Maintained > F: Documentation/devicetree/bindings/display/panel/novatek,nt35532.yaml > +F: drivers/gpu/drm/panel/panel-novatek-nt35532.c > > DRM DRIVER FOR NOVATEK NT35560 PANELS > M: Linus Walleij <[email protected]> > diff --git a/drivers/gpu/drm/panel/Kconfig b/drivers/gpu/drm/panel/Kconfig > index 307152ad7759..4eb9691ab552 100644 > --- a/drivers/gpu/drm/panel/Kconfig > +++ b/drivers/gpu/drm/panel/Kconfig > @@ -500,6 +500,17 @@ config DRM_PANEL_NOVATEK_NT35510 > around the Novatek NT35510 display controller, such as some > Hydis panels. > > +config DRM_PANEL_NOVATEK_NT35532 > + tristate "Novatek NT35532-based DSI video mode panel" > + depends on OF > + depends on DRM_MIPI_DSI > + depends on BACKLIGHT_CLASS_DEVICE > + select VIDEOMODE_HELPERS > + select DRM_KMS_HELPER > + help > + Say Y or M here if you want to enable support for Novatek > + NT35532-based 1080p video mode DSI panels. > + > config DRM_PANEL_NOVATEK_NT35560 > tristate "Novatek NT35560 DSI command mode panel" > depends on OF > diff --git a/drivers/gpu/drm/panel/Makefile b/drivers/gpu/drm/panel/Makefile > index aeffaa95666d..f2b3d9b7abee 100644 > --- a/drivers/gpu/drm/panel/Makefile > +++ b/drivers/gpu/drm/panel/Makefile > @@ -49,6 +49,7 @@ obj-$(CONFIG_DRM_PANEL_NEC_NL8048HL11) += > panel-nec-nl8048hl11.o > obj-$(CONFIG_DRM_PANEL_NEWVISION_NV3051D) += panel-newvision-nv3051d.o > obj-$(CONFIG_DRM_PANEL_NEWVISION_NV3052C) += panel-newvision-nv3052c.o > obj-$(CONFIG_DRM_PANEL_NOVATEK_NT35510) += panel-novatek-nt35510.o > +obj-$(CONFIG_DRM_PANEL_NOVATEK_NT35532) += panel-novatek-nt35532.o > obj-$(CONFIG_DRM_PANEL_NOVATEK_NT35560) += panel-novatek-nt35560.o > obj-$(CONFIG_DRM_PANEL_NOVATEK_NT35950) += panel-novatek-nt35950.o > obj-$(CONFIG_DRM_PANEL_NOVATEK_NT36523) += panel-novatek-nt36523.o > diff --git a/drivers/gpu/drm/panel/panel-novatek-nt35532.c > b/drivers/gpu/drm/panel/panel-novatek-nt35532.c > new file mode 100644 > index 000000000000..51ba548d0a8b > --- /dev/null > +++ b/drivers/gpu/drm/panel/panel-novatek-nt35532.c > @@ -0,0 +1,767 @@ > +// SPDX-License-Identifier: GPL-2.0-only > +/* > + * Generated with linux-mdss-dsi-panel-driver-generator from vendor device > tree. > + * Copyright (c) 2026 Cristian Cozzolino <[email protected]> > + */ > + > +#include <linux/delay.h> > +#include <linux/gpio/consumer.h> > +#include <linux/mod_devicetable.h> > +#include <linux/module.h> > +#include <linux/regulator/consumer.h> > + > +#include <drm/drm_mipi_dsi.h> > +#include <drm/drm_modes.h> > +#include <drm/drm_panel.h> > +#include <drm/drm_probe_helper.h> > + > +struct novatek_nt35532 { > + struct drm_panel panel; > + struct mipi_dsi_device *dsi; > + struct regulator_bulk_data *supplies; > + struct gpio_desc *reset_gpio; > +}; > + > +static const struct regulator_bulk_data nt35532_supplies[] = { > + { .supply = "vsn" }, > + { .supply = "vsp" }, > +}; > + > +static inline struct novatek_nt35532 *to_novatek_nt35532(struct drm_panel > *panel) > +{ > + return container_of(panel, struct novatek_nt35532, panel); > +} > + > +static void nt35532_reset(struct novatek_nt35532 *ctx) > +{ > + gpiod_set_value_cansleep(ctx->reset_gpio, 0); > + usleep_range(10000, 11000); > + gpiod_set_value_cansleep(ctx->reset_gpio, 1); > + usleep_range(5000, 6000); > + gpiod_set_value_cansleep(ctx->reset_gpio, 0); > + usleep_range(10000, 11000); > +} > + > +static int nt35532_on(struct novatek_nt35532 *ctx) > +{ > + struct mipi_dsi_multi_context dsi_ctx = { .dsi = ctx->dsi }; > + > + mipi_dsi_generic_write_seq_multi(&dsi_ctx, 0xff, 0x01); > + mipi_dsi_generic_write_seq_multi(&dsi_ctx, 0x6e, 0x80); > + mipi_dsi_generic_write_seq_multi(&dsi_ctx, 0x68, 0x13); > + mipi_dsi_generic_write_seq_multi(&dsi_ctx, 0xfb, 0x01); > + mipi_dsi_generic_write_seq_multi(&dsi_ctx, 0xff, 0x02);
If this goes to be resent for any reason, could you please insert an empty line before 0xff, 0xNN wries? > + mipi_dsi_generic_write_seq_multi(&dsi_ctx, 0xfb, 0x01); [...] > + mipi_dsi_generic_write_seq_multi(&dsi_ctx, 0x11, 0x00); I suppose this is MIPI_DCS_EXIT_SLEEP_MODE, > + mipi_dsi_msleep(&dsi_ctx, 120); > + mipi_dsi_generic_write_seq_multi(&dsi_ctx, 0x29, 0x00); MIPI_DCS_SET_DISPLAY_ON > + mipi_dsi_msleep(&dsi_ctx, 50); > + > + return dsi_ctx.accum_err; > +} > + -- With best wishes Dmitry

