dt-bindings: panel: Add Sitronix ST7701 panel documentation
Subsystems (5)
Jagan Teki
maintainerPATCH v8 1/2 dt-bindings: panel: Add Sitronix ST7701 panel documentation
Techstar TS8550B MIPI DSI panel is 480x854, 2-lane MIPI DSI LCD panel with inbuilt ST7701 chip.
The default regulator names in ST7701 chip is renamed in Techstar TS8550B so, add specific binding names for them.
---
Changes for v8, v7:
- collect Rob Ack
Changes for v6:
- none
.../display/panel/sitronix,st7701.txt | 30 +++++++++++++++++++ 1 file changed, 30 insertions(+) create mode 100644 Documentation/devicetree/bindings/display/panel/sitronix,st7701.txt
Documentation/devicetree/bindings/display/panel/sitronix,st7701.txt new file +30 -0
@@ -0,0 +1,30 @@ +Sitronix ST7701 based LCD panels + +ST7701 designed for small and medium sizes of TFT LCD display, is +capable of supporting up to 480RGBX864 in resolution. It provides +several system interfaces like MIPI/RGB/SPI. + +Techstar TS8550B is 480x854, 2-lane MIPI DSI LCD panel which has +inbuilt ST7701 chip. + +Required properties: +- compatible: must be "sitronix,st7701" and one of + * "techstar,ts8550b" +- reset-gpios: a GPIO phandle for the reset pin + +Required properties for techstar,ts8550b: +- reg: DSI virtual channel used by that screen +- VCC-supply: analog regulator for MIPI circuit +- IOVCC-supply: I/O system regulator + +Optional properties: +- backlight: phandle for the backlight control. + +panel@0 { + compatible = "techstar,ts8550b", "sitronix,st7701"; + reg = <0>; + VCC-supply = <®_dldo2>; + IOVCC-supply = <®_dldo2>; + reset-gpios = <&pio 3 24 GPIO_ACTIVE_HIGH>; /* LCD-RST: PD24 */ + backlight = <&backlight>; +};
Signature · 6 lines
2.18.0.321.gffc6fa0e3 _______________________________________________ dri-devel mailing list [email protected] https://lists.freedesktop.org/mailman/listinfo/dri-devel
Jagan Teki
maintainerPATCH v8 2/2 drm/panel: Add Sitronix ST7701 panel driver
ST7701 designed for small and medium sizes of TFT LCD display, is capable of supporting up to 480RGBX864 in resolution. It provides several system interfaces like MIPI/RGB/SPI.
Currently added support for Techstar TS8550B which is ST7701 based 480x854, 2-lane MIPI DSI LCD panel.
Driver now registering mipi_dsi device, but indeed it can extendable for RGB if any requirement trigger in future.
---
Changes for v8:
- use DRM_DEV_ERROR instead of dev_err
- use devm_of_find_backlight() instead of of_parse_phandle()
- remove unneeded 'num_supplies' from struct st7701
- add proper comments about panel sepecific sleep mode delay as per st7701 datasheet
- update msleep delay values in .prepare as per datasheet and as per discussion in v7, thanks to 'Sam Ravnborg'
- update msleep delay values in .unprepare as per datasheet and as per discussion in v7, thanks to 'Sam Ravnborg'
- add proper comments on msleep delay values as per st7701 datasheet
- use MIPI_DCS_ENTER_SLEEP_MODE in .unprepare
- drop unneeded gpio set in .prepare and .unprepare as per panel-simple
- remove unneeded include files
- rebase on master
Changes for v7:
- rebase on master
Changes for v6:
- use sleep delay value as per datasheet
- add panel_sleep_delay variable for panel specific delay
- use command sequnce display on and off instead panel functions
- add proper comments on the delays
- remove delays from command switch
- move mode type on struct display mode
- drop refresh rate value, let drm compute
Changes for v5:
- found the chip from vendor, so added new panel driver
- here is v4: https://patchwork.kernel.org/patch/10680335/
MAINTAINERS | 6 + drivers/gpu/drm/panel/Kconfig | 10 + drivers/gpu/drm/panel/Makefile | 1 + drivers/gpu/drm/panel/panel-sitronix-st7701.c | 429 ++++++++++++++++++ 4 files changed, 446 insertions(+) create mode 100644 drivers/gpu/drm/panel/panel-sitronix-st7701.c
MAINTAINERS +6 -0
@@ -4937,6 +4937,12 @@ S: Orphan / Obsolete F: drivers/gpu/drm/sis/ F: include/uapi/drm/sis_drm.h +DRM DRIVER FOR SITRONIX ST7701 PANELS +M: Jagan Teki <[email protected]> +S: Maintained +F: drivers/gpu/drm/panel/panel-sitronix-st7701.c +F: Documentation/devicetree/bindings/display/panel/sitronix,st7701.txt + DRM DRIVER FOR SITRONIX ST7586 PANELS M: David Lechner <[email protected]> S: Maintained
drivers/gpu/drm/panel/Kconfig +10 -0
@@ -214,6 +214,16 @@ config DRM_PANEL_SHARP_LS043T1LE01 Say Y here if you want to enable support for Sharp LS043T1LE01 qHD (540x960) DSI panel as found on the Qualcomm APQ8074 Dragonboard +config DRM_PANEL_SITRONIX_ST7701 + tristate "Sitronix ST7701 panel driver" + depends on OF + depends on DRM_MIPI_DSI + depends on BACKLIGHT_CLASS_DEVICE + help + Say Y here if you want to enable support for the Sitronix + ST7701 controller for 480X864 LCD panels with MIPI/RGB/SPI + system interfaces. + config DRM_PANEL_SITRONIX_ST7789V tristate "Sitronix ST7789V panel" depends on OF && SPI
drivers/gpu/drm/panel/Makefile +1 -0
@@ -22,6 +22,7 @@ obj-$(CONFIG_DRM_PANEL_SAMSUNG_S6E8AA0) += panel-samsung-s6e8aa0.o obj-$(CONFIG_DRM_PANEL_SEIKO_43WVF1G) += panel-seiko-43wvf1g.o obj-$(CONFIG_DRM_PANEL_SHARP_LQ101R1SX01) += panel-sharp-lq101r1sx01.o obj-$(CONFIG_DRM_PANEL_SHARP_LS043T1LE01) += panel-sharp-ls043t1le01.o +obj-$(CONFIG_DRM_PANEL_SITRONIX_ST7701) += panel-sitronix-st7701.o obj-$(CONFIG_DRM_PANEL_SITRONIX_ST7789V) += panel-sitronix-st7789v.o obj-$(CONFIG_DRM_PANEL_TPO_TPG110) += panel-tpo-tpg110.o obj-$(CONFIG_DRM_PANEL_TRULY_NT35597_WQXGA) += panel-truly-nt35597.o
drivers/gpu/drm/panel/panel-sitronix-st7701.c new file +429 -0
429 lines not on this page · raw message
Signature · 1 line
2.18.0.321.gffc6fa0e3
Re: [PATCH v8 2/2] drm/panel: Add Sitronix ST7701 panel driver
Hi Jagan.
Thanks for being persistent and keep follow-up on this driver.
Quoted 24 lines · Jagan Teki
ST7701 designed for small and medium sizes of TFT LCD display, is capable of supporting up to 480RGBX864 in resolution. It provides several system interfaces like MIPI/RGB/SPI.
Currently added support for Techstar TS8550B which is ST7701 based 480x854, 2-lane MIPI DSI LCD panel.
Driver now registering
mipi_dsidevice, but indeed it can extendable for RGB if any requirement trigger in future.Signed-off-by Jagan Teki <[email protected]>---
drivers/gpu/drm/panel/panel-sitronix-st7701.c new file +5
-0@@ -0,0 +1,429 @@ +// SPDX-License-Identifier: GPL-2.0+ +/* +* Copyright (C) 2019, Amarula Solutions. +* Author: Jagan Teki <[email protected]> +*/
drivers/gpu/drm/panel/panel-sitronix-st7701.c line 15
Quoted 10 lines
drivers/gpu/drm/panel/panel-sitronix-st7701.c new file +10
-0+ +#include <linux/backlight.h> +#include <linux/delay.h> +#include <linux/module.h> +#include <linux/of_device.h> + +#include <linux/gpio/consumer.h> +#include <linux/regulator/consumer.h> + +#include <drm/drmP.h>
For new drivers please do not use drmP.h.
We are slowly going away from this and in drm-misc.git the drmP.h file is no longer needed for anything.
Quoted 6 lines
drivers/gpu/drm/panel/panel-sitronix-st7701.c new file +5
-0+ st7701->backlight =devm_of_find_backlight (&dsi->dev); +if (IS_ERR (st7701->backlight)) +return PTR_ERR (st7701->backlight); +static int st7701_dsi_remove (struct mipi_dsi_device *dsi) +{
drivers/gpu/drm/panel/panel-sitronix-st7701.c line 409
Quoted 10 lines
drivers/gpu/drm/panel/panel-sitronix-st7701.c new file +10
-0+struct st7701 *st7701 =mipi_dsi_get_drvdata (dsi); + +mipi_dsi_detach (dsi); +drm_panel_remove (&st7701->panel); + +if (st7701->backlight) +put_device (&st7701->backlight->dev); + +return 0 ; +}
Please address this comment from Noralf:
"This happens automatically on driver detach if devm_of_find_backlight() is used"
In other words, no need to do anything with backlight in st7701_dsi_remove()
With these details fixed you can add back my:
_______________________________________________
dri-devel mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/dri-devel