2 * Copyright (C) 2013, NVIDIA Corporation. All rights reserved.
4 * Permission is hereby granted, free of charge, to any person obtaining a
5 * copy of this software and associated documentation files (the "Software"),
6 * to deal in the Software without restriction, including without limitation
7 * the rights to use, copy, modify, merge, publish, distribute, sub license,
8 * and/or sell copies of the Software, and to permit persons to whom the
9 * Software is furnished to do so, subject to the following conditions:
11 * The above copyright notice and this permission notice (including the
12 * next paragraph) shall be included in all copies or substantial portions
15 * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16 * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17 * FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT. IN NO EVENT SHALL
18 * THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19 * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
20 * FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
21 * DEALINGS IN THE SOFTWARE.
24 #include <linux/delay.h>
25 #include <linux/gpio/consumer.h>
26 #include <linux/module.h>
27 #include <linux/of_platform.h>
28 #include <linux/platform_device.h>
29 #include <linux/regulator/consumer.h>
31 #include <video/display_timing.h>
32 #include <video/of_display_timing.h>
33 #include <video/videomode.h>
35 #include <drm/drm_crtc.h>
36 #include <drm/drm_device.h>
37 #include <drm/drm_mipi_dsi.h>
38 #include <drm/drm_panel.h>
41 * @modes: Pointer to array of fixed modes appropriate for this panel. If
42 * only one mode then this can just be the address of this the mode.
43 * NOTE: cannot be used with "timings" and also if this is specified
44 * then you cannot override the mode in the device tree.
45 * @num_modes: Number of elements in modes array.
46 * @timings: Pointer to array of display timings. NOTE: cannot be used with
47 * "modes" and also these will be used to validate a device tree
48 * override if one is present.
49 * @num_timings: Number of elements in timings array.
50 * @bpc: Bits per color.
51 * @size: Structure containing the physical size of this panel.
52 * @delay: Structure containing various delay values for this panel.
53 * @bus_format: See MEDIA_BUS_FMT_... defines.
54 * @bus_flags: See DRM_BUS_FLAG_... defines.
57 const struct drm_display_mode *modes;
58 unsigned int num_modes;
59 const struct display_timing *timings;
60 unsigned int num_timings;
65 * @width: width (in millimeters) of the panel's active display area
66 * @height: height (in millimeters) of the panel's active display area
74 * @prepare: the time (in milliseconds) that it takes for the panel to
75 * become ready and start receiving video data
76 * @hpd_absent_delay: Add this to the prepare delay if we know Hot
77 * Plug Detect isn't used.
78 * @enable: the time (in milliseconds) that it takes for the panel to
79 * display the first valid frame after starting to receive
81 * @disable: the time (in milliseconds) that it takes for the panel to
82 * turn the display off (no content is visible)
83 * @unprepare: the time (in milliseconds) that it takes for the panel
84 * to power itself down completely
88 unsigned int hpd_absent_delay;
91 unsigned int unprepare;
100 struct drm_panel base;
105 const struct panel_desc *desc;
107 struct regulator *supply;
108 struct i2c_adapter *ddc;
110 struct gpio_desc *enable_gpio;
112 struct drm_display_mode override_mode;
115 static inline struct panel_simple *to_panel_simple(struct drm_panel *panel)
117 return container_of(panel, struct panel_simple, base);
120 static unsigned int panel_simple_get_timings_modes(struct panel_simple *panel,
121 struct drm_connector *connector)
123 struct drm_display_mode *mode;
124 unsigned int i, num = 0;
126 for (i = 0; i < panel->desc->num_timings; i++) {
127 const struct display_timing *dt = &panel->desc->timings[i];
130 videomode_from_timing(dt, &vm);
131 mode = drm_mode_create(connector->dev);
133 dev_err(panel->base.dev, "failed to add mode %ux%u\n",
134 dt->hactive.typ, dt->vactive.typ);
138 drm_display_mode_from_videomode(&vm, mode);
140 mode->type |= DRM_MODE_TYPE_DRIVER;
142 if (panel->desc->num_timings == 1)
143 mode->type |= DRM_MODE_TYPE_PREFERRED;
145 drm_mode_probed_add(connector, mode);
152 static unsigned int panel_simple_get_display_modes(struct panel_simple *panel,
153 struct drm_connector *connector)
155 struct drm_display_mode *mode;
156 unsigned int i, num = 0;
158 for (i = 0; i < panel->desc->num_modes; i++) {
159 const struct drm_display_mode *m = &panel->desc->modes[i];
161 mode = drm_mode_duplicate(connector->dev, m);
163 dev_err(panel->base.dev, "failed to add mode %ux%u@%u\n",
164 m->hdisplay, m->vdisplay, m->vrefresh);
168 mode->type |= DRM_MODE_TYPE_DRIVER;
170 if (panel->desc->num_modes == 1)
171 mode->type |= DRM_MODE_TYPE_PREFERRED;
173 drm_mode_set_name(mode);
175 drm_mode_probed_add(connector, mode);
182 static int panel_simple_get_non_edid_modes(struct panel_simple *panel,
183 struct drm_connector *connector)
185 struct drm_display_mode *mode;
186 bool has_override = panel->override_mode.type;
187 unsigned int num = 0;
193 mode = drm_mode_duplicate(connector->dev,
194 &panel->override_mode);
196 drm_mode_probed_add(connector, mode);
199 dev_err(panel->base.dev, "failed to add override mode\n");
203 /* Only add timings if override was not there or failed to validate */
204 if (num == 0 && panel->desc->num_timings)
205 num = panel_simple_get_timings_modes(panel, connector);
208 * Only add fixed modes if timings/override added no mode.
210 * We should only ever have either the display timings specified
211 * or a fixed mode. Anything else is rather bogus.
213 WARN_ON(panel->desc->num_timings && panel->desc->num_modes);
215 num = panel_simple_get_display_modes(panel, connector);
217 connector->display_info.bpc = panel->desc->bpc;
218 connector->display_info.width_mm = panel->desc->size.width;
219 connector->display_info.height_mm = panel->desc->size.height;
220 if (panel->desc->bus_format)
221 drm_display_info_set_bus_formats(&connector->display_info,
222 &panel->desc->bus_format, 1);
223 connector->display_info.bus_flags = panel->desc->bus_flags;
228 static int panel_simple_disable(struct drm_panel *panel)
230 struct panel_simple *p = to_panel_simple(panel);
235 if (p->desc->delay.disable)
236 msleep(p->desc->delay.disable);
243 static int panel_simple_unprepare(struct drm_panel *panel)
245 struct panel_simple *p = to_panel_simple(panel);
250 gpiod_set_value_cansleep(p->enable_gpio, 0);
252 regulator_disable(p->supply);
254 if (p->desc->delay.unprepare)
255 msleep(p->desc->delay.unprepare);
262 static int panel_simple_prepare(struct drm_panel *panel)
264 struct panel_simple *p = to_panel_simple(panel);
271 err = regulator_enable(p->supply);
273 dev_err(panel->dev, "failed to enable supply: %d\n", err);
277 gpiod_set_value_cansleep(p->enable_gpio, 1);
279 delay = p->desc->delay.prepare;
281 delay += p->desc->delay.hpd_absent_delay;
290 static int panel_simple_enable(struct drm_panel *panel)
292 struct panel_simple *p = to_panel_simple(panel);
297 if (p->desc->delay.enable)
298 msleep(p->desc->delay.enable);
305 static int panel_simple_get_modes(struct drm_panel *panel,
306 struct drm_connector *connector)
308 struct panel_simple *p = to_panel_simple(panel);
311 /* probe EDID if a DDC bus is available */
313 struct edid *edid = drm_get_edid(connector, p->ddc);
315 drm_connector_update_edid_property(connector, edid);
317 num += drm_add_edid_modes(connector, edid);
322 /* add hard-coded panel modes */
323 num += panel_simple_get_non_edid_modes(p, connector);
328 static int panel_simple_get_timings(struct drm_panel *panel,
329 unsigned int num_timings,
330 struct display_timing *timings)
332 struct panel_simple *p = to_panel_simple(panel);
335 if (p->desc->num_timings < num_timings)
336 num_timings = p->desc->num_timings;
339 for (i = 0; i < num_timings; i++)
340 timings[i] = p->desc->timings[i];
342 return p->desc->num_timings;
345 static const struct drm_panel_funcs panel_simple_funcs = {
346 .disable = panel_simple_disable,
347 .unprepare = panel_simple_unprepare,
348 .prepare = panel_simple_prepare,
349 .enable = panel_simple_enable,
350 .get_modes = panel_simple_get_modes,
351 .get_timings = panel_simple_get_timings,
354 static struct panel_desc panel_dpi;
356 static int panel_dpi_probe(struct device *dev,
357 struct panel_simple *panel)
359 struct display_timing *timing;
360 const struct device_node *np;
361 struct panel_desc *desc;
362 unsigned int bus_flags;
367 desc = devm_kzalloc(dev, sizeof(*desc), GFP_KERNEL);
371 timing = devm_kzalloc(dev, sizeof(*timing), GFP_KERNEL);
375 ret = of_get_display_timing(np, "panel-timing", timing);
377 dev_err(dev, "%pOF: no panel-timing node found for \"panel-dpi\" binding\n",
382 desc->timings = timing;
383 desc->num_timings = 1;
385 of_property_read_u32(np, "width-mm", &desc->size.width);
386 of_property_read_u32(np, "height-mm", &desc->size.height);
388 /* Extract bus_flags from display_timing */
390 vm.flags = timing->flags;
391 drm_bus_flags_from_videomode(&vm, &bus_flags);
392 desc->bus_flags = bus_flags;
394 /* We do not know the connector for the DT node, so guess it */
395 desc->connector_type = DRM_MODE_CONNECTOR_DPI;
402 #define PANEL_SIMPLE_BOUNDS_CHECK(to_check, bounds, field) \
403 (to_check->field.typ >= bounds->field.min && \
404 to_check->field.typ <= bounds->field.max)
405 static void panel_simple_parse_panel_timing_node(struct device *dev,
406 struct panel_simple *panel,
407 const struct display_timing *ot)
409 const struct panel_desc *desc = panel->desc;
413 if (WARN_ON(desc->num_modes)) {
414 dev_err(dev, "Reject override mode: panel has a fixed mode\n");
417 if (WARN_ON(!desc->num_timings)) {
418 dev_err(dev, "Reject override mode: no timings specified\n");
422 for (i = 0; i < panel->desc->num_timings; i++) {
423 const struct display_timing *dt = &panel->desc->timings[i];
425 if (!PANEL_SIMPLE_BOUNDS_CHECK(ot, dt, hactive) ||
426 !PANEL_SIMPLE_BOUNDS_CHECK(ot, dt, hfront_porch) ||
427 !PANEL_SIMPLE_BOUNDS_CHECK(ot, dt, hback_porch) ||
428 !PANEL_SIMPLE_BOUNDS_CHECK(ot, dt, hsync_len) ||
429 !PANEL_SIMPLE_BOUNDS_CHECK(ot, dt, vactive) ||
430 !PANEL_SIMPLE_BOUNDS_CHECK(ot, dt, vfront_porch) ||
431 !PANEL_SIMPLE_BOUNDS_CHECK(ot, dt, vback_porch) ||
432 !PANEL_SIMPLE_BOUNDS_CHECK(ot, dt, vsync_len))
435 if (ot->flags != dt->flags)
438 videomode_from_timing(ot, &vm);
439 drm_display_mode_from_videomode(&vm, &panel->override_mode);
440 panel->override_mode.type |= DRM_MODE_TYPE_DRIVER |
441 DRM_MODE_TYPE_PREFERRED;
445 if (WARN_ON(!panel->override_mode.type))
446 dev_err(dev, "Reject override mode: No display_timing found\n");
449 static int panel_simple_probe(struct device *dev, const struct panel_desc *desc)
451 struct panel_simple *panel;
452 struct display_timing dt;
453 struct device_node *ddc;
456 panel = devm_kzalloc(dev, sizeof(*panel), GFP_KERNEL);
460 panel->enabled = false;
461 panel->prepared = false;
464 panel->no_hpd = of_property_read_bool(dev->of_node, "no-hpd");
466 panel->supply = devm_regulator_get(dev, "power");
467 if (IS_ERR(panel->supply))
468 return PTR_ERR(panel->supply);
470 panel->enable_gpio = devm_gpiod_get_optional(dev, "enable",
472 if (IS_ERR(panel->enable_gpio)) {
473 err = PTR_ERR(panel->enable_gpio);
474 if (err != -EPROBE_DEFER)
475 dev_err(dev, "failed to request GPIO: %d\n", err);
479 ddc = of_parse_phandle(dev->of_node, "ddc-i2c-bus", 0);
481 panel->ddc = of_find_i2c_adapter_by_node(ddc);
485 return -EPROBE_DEFER;
488 if (desc == &panel_dpi) {
489 /* Handle the generic panel-dpi binding */
490 err = panel_dpi_probe(dev, panel);
494 if (!of_get_display_timing(dev->of_node, "panel-timing", &dt))
495 panel_simple_parse_panel_timing_node(dev, panel, &dt);
498 drm_panel_init(&panel->base, dev, &panel_simple_funcs,
499 desc->connector_type);
501 err = drm_panel_of_backlight(&panel->base);
505 err = drm_panel_add(&panel->base);
509 dev_set_drvdata(dev, panel);
515 put_device(&panel->ddc->dev);
520 static int panel_simple_remove(struct device *dev)
522 struct panel_simple *panel = dev_get_drvdata(dev);
524 drm_panel_remove(&panel->base);
525 drm_panel_disable(&panel->base);
526 drm_panel_unprepare(&panel->base);
529 put_device(&panel->ddc->dev);
534 static void panel_simple_shutdown(struct device *dev)
536 struct panel_simple *panel = dev_get_drvdata(dev);
538 drm_panel_disable(&panel->base);
539 drm_panel_unprepare(&panel->base);
542 static const struct drm_display_mode ampire_am_480272h3tmqw_t01h_mode = {
545 .hsync_start = 480 + 2,
546 .hsync_end = 480 + 2 + 41,
547 .htotal = 480 + 2 + 41 + 2,
549 .vsync_start = 272 + 2,
550 .vsync_end = 272 + 2 + 10,
551 .vtotal = 272 + 2 + 10 + 2,
553 .flags = DRM_MODE_FLAG_PHSYNC | DRM_MODE_FLAG_PVSYNC,
556 static const struct panel_desc ampire_am_480272h3tmqw_t01h = {
557 .modes = &ire_am_480272h3tmqw_t01h_mode,
564 .bus_format = MEDIA_BUS_FMT_RGB888_1X24,
567 static const struct drm_display_mode ampire_am800480r3tmqwa1h_mode = {
570 .hsync_start = 800 + 0,
571 .hsync_end = 800 + 0 + 255,
572 .htotal = 800 + 0 + 255 + 0,
574 .vsync_start = 480 + 2,
575 .vsync_end = 480 + 2 + 45,
576 .vtotal = 480 + 2 + 45 + 0,
578 .flags = DRM_MODE_FLAG_PHSYNC | DRM_MODE_FLAG_PVSYNC,
581 static const struct panel_desc ampire_am800480r3tmqwa1h = {
582 .modes = &ire_am800480r3tmqwa1h_mode,
589 .bus_format = MEDIA_BUS_FMT_RGB666_1X18,
592 static const struct display_timing santek_st0700i5y_rbslw_f_timing = {
593 .pixelclock = { 26400000, 33300000, 46800000 },
594 .hactive = { 800, 800, 800 },
595 .hfront_porch = { 16, 210, 354 },
596 .hback_porch = { 45, 36, 6 },
597 .hsync_len = { 1, 10, 40 },
598 .vactive = { 480, 480, 480 },
599 .vfront_porch = { 7, 22, 147 },
600 .vback_porch = { 22, 13, 3 },
601 .vsync_len = { 1, 10, 20 },
602 .flags = DISPLAY_FLAGS_HSYNC_LOW | DISPLAY_FLAGS_VSYNC_LOW |
603 DISPLAY_FLAGS_DE_HIGH | DISPLAY_FLAGS_PIXDATA_POSEDGE
606 static const struct panel_desc armadeus_st0700_adapt = {
607 .timings = &santek_st0700i5y_rbslw_f_timing,
614 .bus_format = MEDIA_BUS_FMT_RGB666_1X18,
615 .bus_flags = DRM_BUS_FLAG_DE_HIGH | DRM_BUS_FLAG_PIXDATA_POSEDGE,
618 static const struct drm_display_mode auo_b101aw03_mode = {
621 .hsync_start = 1024 + 156,
622 .hsync_end = 1024 + 156 + 8,
623 .htotal = 1024 + 156 + 8 + 156,
625 .vsync_start = 600 + 16,
626 .vsync_end = 600 + 16 + 6,
627 .vtotal = 600 + 16 + 6 + 16,
631 static const struct panel_desc auo_b101aw03 = {
632 .modes = &auo_b101aw03_mode,
641 static const struct display_timing auo_b101ean01_timing = {
642 .pixelclock = { 65300000, 72500000, 75000000 },
643 .hactive = { 1280, 1280, 1280 },
644 .hfront_porch = { 18, 119, 119 },
645 .hback_porch = { 21, 21, 21 },
646 .hsync_len = { 32, 32, 32 },
647 .vactive = { 800, 800, 800 },
648 .vfront_porch = { 4, 4, 4 },
649 .vback_porch = { 8, 8, 8 },
650 .vsync_len = { 18, 20, 20 },
653 static const struct panel_desc auo_b101ean01 = {
654 .timings = &auo_b101ean01_timing,
663 static const struct drm_display_mode auo_b101xtn01_mode = {
666 .hsync_start = 1366 + 20,
667 .hsync_end = 1366 + 20 + 70,
668 .htotal = 1366 + 20 + 70,
670 .vsync_start = 768 + 14,
671 .vsync_end = 768 + 14 + 42,
672 .vtotal = 768 + 14 + 42,
674 .flags = DRM_MODE_FLAG_NVSYNC | DRM_MODE_FLAG_NHSYNC,
677 static const struct panel_desc auo_b101xtn01 = {
678 .modes = &auo_b101xtn01_mode,
687 static const struct drm_display_mode auo_b116xak01_mode = {
690 .hsync_start = 1366 + 48,
691 .hsync_end = 1366 + 48 + 32,
692 .htotal = 1366 + 48 + 32 + 10,
694 .vsync_start = 768 + 4,
695 .vsync_end = 768 + 4 + 6,
696 .vtotal = 768 + 4 + 6 + 15,
698 .flags = DRM_MODE_FLAG_NVSYNC | DRM_MODE_FLAG_NHSYNC,
701 static const struct panel_desc auo_b116xak01 = {
702 .modes = &auo_b116xak01_mode,
710 .hpd_absent_delay = 200,
712 .bus_format = MEDIA_BUS_FMT_RGB666_1X18,
713 .connector_type = DRM_MODE_CONNECTOR_eDP,
716 static const struct drm_display_mode auo_b116xw03_mode = {
719 .hsync_start = 1366 + 40,
720 .hsync_end = 1366 + 40 + 40,
721 .htotal = 1366 + 40 + 40 + 32,
723 .vsync_start = 768 + 10,
724 .vsync_end = 768 + 10 + 12,
725 .vtotal = 768 + 10 + 12 + 6,
729 static const struct panel_desc auo_b116xw03 = {
730 .modes = &auo_b116xw03_mode,
739 static const struct drm_display_mode auo_b133xtn01_mode = {
742 .hsync_start = 1366 + 48,
743 .hsync_end = 1366 + 48 + 32,
744 .htotal = 1366 + 48 + 32 + 20,
746 .vsync_start = 768 + 3,
747 .vsync_end = 768 + 3 + 6,
748 .vtotal = 768 + 3 + 6 + 13,
752 static const struct panel_desc auo_b133xtn01 = {
753 .modes = &auo_b133xtn01_mode,
762 static const struct drm_display_mode auo_b133htn01_mode = {
765 .hsync_start = 1920 + 172,
766 .hsync_end = 1920 + 172 + 80,
767 .htotal = 1920 + 172 + 80 + 60,
769 .vsync_start = 1080 + 25,
770 .vsync_end = 1080 + 25 + 10,
771 .vtotal = 1080 + 25 + 10 + 10,
775 static const struct panel_desc auo_b133htn01 = {
776 .modes = &auo_b133htn01_mode,
790 static const struct display_timing auo_g070vvn01_timings = {
791 .pixelclock = { 33300000, 34209000, 45000000 },
792 .hactive = { 800, 800, 800 },
793 .hfront_porch = { 20, 40, 200 },
794 .hback_porch = { 87, 40, 1 },
795 .hsync_len = { 1, 48, 87 },
796 .vactive = { 480, 480, 480 },
797 .vfront_porch = { 5, 13, 200 },
798 .vback_porch = { 31, 31, 29 },
799 .vsync_len = { 1, 1, 3 },
802 static const struct panel_desc auo_g070vvn01 = {
803 .timings = &auo_g070vvn01_timings,
818 static const struct drm_display_mode auo_g101evn010_mode = {
821 .hsync_start = 1280 + 82,
822 .hsync_end = 1280 + 82 + 2,
823 .htotal = 1280 + 82 + 2 + 84,
825 .vsync_start = 800 + 8,
826 .vsync_end = 800 + 8 + 2,
827 .vtotal = 800 + 8 + 2 + 6,
831 static const struct panel_desc auo_g101evn010 = {
832 .modes = &auo_g101evn010_mode,
839 .bus_format = MEDIA_BUS_FMT_RGB666_1X18,
842 static const struct drm_display_mode auo_g104sn02_mode = {
845 .hsync_start = 800 + 40,
846 .hsync_end = 800 + 40 + 216,
847 .htotal = 800 + 40 + 216 + 128,
849 .vsync_start = 600 + 10,
850 .vsync_end = 600 + 10 + 35,
851 .vtotal = 600 + 10 + 35 + 2,
855 static const struct panel_desc auo_g104sn02 = {
856 .modes = &auo_g104sn02_mode,
865 static const struct display_timing auo_g133han01_timings = {
866 .pixelclock = { 134000000, 141200000, 149000000 },
867 .hactive = { 1920, 1920, 1920 },
868 .hfront_porch = { 39, 58, 77 },
869 .hback_porch = { 59, 88, 117 },
870 .hsync_len = { 28, 42, 56 },
871 .vactive = { 1080, 1080, 1080 },
872 .vfront_porch = { 3, 8, 11 },
873 .vback_porch = { 5, 14, 19 },
874 .vsync_len = { 4, 14, 19 },
877 static const struct panel_desc auo_g133han01 = {
878 .timings = &auo_g133han01_timings,
891 .bus_format = MEDIA_BUS_FMT_RGB888_1X7X4_JEIDA,
892 .connector_type = DRM_MODE_CONNECTOR_LVDS,
895 static const struct display_timing auo_g185han01_timings = {
896 .pixelclock = { 120000000, 144000000, 175000000 },
897 .hactive = { 1920, 1920, 1920 },
898 .hfront_porch = { 36, 120, 148 },
899 .hback_porch = { 24, 88, 108 },
900 .hsync_len = { 20, 48, 64 },
901 .vactive = { 1080, 1080, 1080 },
902 .vfront_porch = { 6, 10, 40 },
903 .vback_porch = { 2, 5, 20 },
904 .vsync_len = { 2, 5, 20 },
907 static const struct panel_desc auo_g185han01 = {
908 .timings = &auo_g185han01_timings,
921 .bus_format = MEDIA_BUS_FMT_RGB888_1X7X4_SPWG,
922 .connector_type = DRM_MODE_CONNECTOR_LVDS,
925 static const struct display_timing auo_p320hvn03_timings = {
926 .pixelclock = { 106000000, 148500000, 164000000 },
927 .hactive = { 1920, 1920, 1920 },
928 .hfront_porch = { 25, 50, 130 },
929 .hback_porch = { 25, 50, 130 },
930 .hsync_len = { 20, 40, 105 },
931 .vactive = { 1080, 1080, 1080 },
932 .vfront_porch = { 8, 17, 150 },
933 .vback_porch = { 8, 17, 150 },
934 .vsync_len = { 4, 11, 100 },
937 static const struct panel_desc auo_p320hvn03 = {
938 .timings = &auo_p320hvn03_timings,
950 .bus_format = MEDIA_BUS_FMT_RGB888_1X7X4_SPWG,
951 .connector_type = DRM_MODE_CONNECTOR_LVDS,
954 static const struct drm_display_mode auo_t215hvn01_mode = {
957 .hsync_start = 1920 + 88,
958 .hsync_end = 1920 + 88 + 44,
959 .htotal = 1920 + 88 + 44 + 148,
961 .vsync_start = 1080 + 4,
962 .vsync_end = 1080 + 4 + 5,
963 .vtotal = 1080 + 4 + 5 + 36,
967 static const struct panel_desc auo_t215hvn01 = {
968 .modes = &auo_t215hvn01_mode,
981 static const struct drm_display_mode avic_tm070ddh03_mode = {
984 .hsync_start = 1024 + 160,
985 .hsync_end = 1024 + 160 + 4,
986 .htotal = 1024 + 160 + 4 + 156,
988 .vsync_start = 600 + 17,
989 .vsync_end = 600 + 17 + 1,
990 .vtotal = 600 + 17 + 1 + 17,
994 static const struct panel_desc avic_tm070ddh03 = {
995 .modes = &avic_tm070ddh03_mode,
1009 static const struct drm_display_mode bananapi_s070wv20_ct16_mode = {
1012 .hsync_start = 800 + 40,
1013 .hsync_end = 800 + 40 + 48,
1014 .htotal = 800 + 40 + 48 + 40,
1016 .vsync_start = 480 + 13,
1017 .vsync_end = 480 + 13 + 3,
1018 .vtotal = 480 + 13 + 3 + 29,
1021 static const struct panel_desc bananapi_s070wv20_ct16 = {
1022 .modes = &bananapi_s070wv20_ct16_mode,
1031 static const struct drm_display_mode boe_hv070wsa_mode = {
1034 .hsync_start = 1024 + 30,
1035 .hsync_end = 1024 + 30 + 30,
1036 .htotal = 1024 + 30 + 30 + 30,
1038 .vsync_start = 600 + 10,
1039 .vsync_end = 600 + 10 + 10,
1040 .vtotal = 600 + 10 + 10 + 10,
1044 static const struct panel_desc boe_hv070wsa = {
1045 .modes = &boe_hv070wsa_mode,
1053 static const struct drm_display_mode boe_nv101wxmn51_modes[] = {
1057 .hsync_start = 1280 + 48,
1058 .hsync_end = 1280 + 48 + 32,
1059 .htotal = 1280 + 48 + 32 + 80,
1061 .vsync_start = 800 + 3,
1062 .vsync_end = 800 + 3 + 5,
1063 .vtotal = 800 + 3 + 5 + 24,
1069 .hsync_start = 1280 + 48,
1070 .hsync_end = 1280 + 48 + 32,
1071 .htotal = 1280 + 48 + 32 + 80,
1073 .vsync_start = 800 + 3,
1074 .vsync_end = 800 + 3 + 5,
1075 .vtotal = 800 + 3 + 5 + 24,
1080 static const struct panel_desc boe_nv101wxmn51 = {
1081 .modes = boe_nv101wxmn51_modes,
1082 .num_modes = ARRAY_SIZE(boe_nv101wxmn51_modes),
1095 static const struct drm_display_mode boe_nv140fhmn49_modes[] = {
1099 .hsync_start = 1920 + 48,
1100 .hsync_end = 1920 + 48 + 32,
1103 .vsync_start = 1080 + 3,
1104 .vsync_end = 1080 + 3 + 5,
1110 static const struct panel_desc boe_nv140fhmn49 = {
1111 .modes = boe_nv140fhmn49_modes,
1112 .num_modes = ARRAY_SIZE(boe_nv140fhmn49_modes),
1123 .bus_format = MEDIA_BUS_FMT_RGB666_1X18,
1124 .connector_type = DRM_MODE_CONNECTOR_eDP,
1127 static const struct drm_display_mode cdtech_s043wq26h_ct7_mode = {
1130 .hsync_start = 480 + 5,
1131 .hsync_end = 480 + 5 + 5,
1132 .htotal = 480 + 5 + 5 + 40,
1134 .vsync_start = 272 + 8,
1135 .vsync_end = 272 + 8 + 8,
1136 .vtotal = 272 + 8 + 8 + 8,
1138 .flags = DRM_MODE_FLAG_NHSYNC | DRM_MODE_FLAG_NVSYNC,
1141 static const struct panel_desc cdtech_s043wq26h_ct7 = {
1142 .modes = &cdtech_s043wq26h_ct7_mode,
1149 .bus_flags = DRM_BUS_FLAG_PIXDATA_DRIVE_POSEDGE,
1152 static const struct drm_display_mode cdtech_s070wv95_ct16_mode = {
1155 .hsync_start = 800 + 40,
1156 .hsync_end = 800 + 40 + 40,
1157 .htotal = 800 + 40 + 40 + 48,
1159 .vsync_start = 480 + 29,
1160 .vsync_end = 480 + 29 + 13,
1161 .vtotal = 480 + 29 + 13 + 3,
1163 .flags = DRM_MODE_FLAG_NHSYNC | DRM_MODE_FLAG_NVSYNC,
1166 static const struct panel_desc cdtech_s070wv95_ct16 = {
1167 .modes = &cdtech_s070wv95_ct16_mode,
1176 static const struct drm_display_mode chunghwa_claa070wp03xg_mode = {
1179 .hsync_start = 800 + 49,
1180 .hsync_end = 800 + 49 + 33,
1181 .htotal = 800 + 49 + 33 + 17,
1183 .vsync_start = 1280 + 1,
1184 .vsync_end = 1280 + 1 + 7,
1185 .vtotal = 1280 + 1 + 7 + 15,
1187 .flags = DRM_MODE_FLAG_NVSYNC | DRM_MODE_FLAG_NHSYNC,
1190 static const struct panel_desc chunghwa_claa070wp03xg = {
1191 .modes = &chunghwa_claa070wp03xg_mode,
1200 static const struct drm_display_mode chunghwa_claa101wa01a_mode = {
1203 .hsync_start = 1366 + 58,
1204 .hsync_end = 1366 + 58 + 58,
1205 .htotal = 1366 + 58 + 58 + 58,
1207 .vsync_start = 768 + 4,
1208 .vsync_end = 768 + 4 + 4,
1209 .vtotal = 768 + 4 + 4 + 4,
1213 static const struct panel_desc chunghwa_claa101wa01a = {
1214 .modes = &chunghwa_claa101wa01a_mode,
1223 static const struct drm_display_mode chunghwa_claa101wb01_mode = {
1226 .hsync_start = 1366 + 48,
1227 .hsync_end = 1366 + 48 + 32,
1228 .htotal = 1366 + 48 + 32 + 20,
1230 .vsync_start = 768 + 16,
1231 .vsync_end = 768 + 16 + 8,
1232 .vtotal = 768 + 16 + 8 + 16,
1236 static const struct panel_desc chunghwa_claa101wb01 = {
1237 .modes = &chunghwa_claa101wb01_mode,
1246 static const struct drm_display_mode dataimage_scf0700c48ggu18_mode = {
1249 .hsync_start = 800 + 40,
1250 .hsync_end = 800 + 40 + 128,
1251 .htotal = 800 + 40 + 128 + 88,
1253 .vsync_start = 480 + 10,
1254 .vsync_end = 480 + 10 + 2,
1255 .vtotal = 480 + 10 + 2 + 33,
1257 .flags = DRM_MODE_FLAG_NVSYNC | DRM_MODE_FLAG_NHSYNC,
1260 static const struct panel_desc dataimage_scf0700c48ggu18 = {
1261 .modes = &dataimage_scf0700c48ggu18_mode,
1268 .bus_format = MEDIA_BUS_FMT_RGB888_1X24,
1269 .bus_flags = DRM_BUS_FLAG_DE_HIGH | DRM_BUS_FLAG_PIXDATA_DRIVE_POSEDGE,
1272 static const struct display_timing dlc_dlc0700yzg_1_timing = {
1273 .pixelclock = { 45000000, 51200000, 57000000 },
1274 .hactive = { 1024, 1024, 1024 },
1275 .hfront_porch = { 100, 106, 113 },
1276 .hback_porch = { 100, 106, 113 },
1277 .hsync_len = { 100, 108, 114 },
1278 .vactive = { 600, 600, 600 },
1279 .vfront_porch = { 8, 11, 15 },
1280 .vback_porch = { 8, 11, 15 },
1281 .vsync_len = { 9, 13, 15 },
1282 .flags = DISPLAY_FLAGS_DE_HIGH,
1285 static const struct panel_desc dlc_dlc0700yzg_1 = {
1286 .timings = &dlc_dlc0700yzg_1_timing,
1298 .bus_format = MEDIA_BUS_FMT_RGB666_1X7X3_SPWG,
1299 .connector_type = DRM_MODE_CONNECTOR_LVDS,
1302 static const struct display_timing dlc_dlc1010gig_timing = {
1303 .pixelclock = { 68900000, 71100000, 73400000 },
1304 .hactive = { 1280, 1280, 1280 },
1305 .hfront_porch = { 43, 53, 63 },
1306 .hback_porch = { 43, 53, 63 },
1307 .hsync_len = { 44, 54, 64 },
1308 .vactive = { 800, 800, 800 },
1309 .vfront_porch = { 5, 8, 11 },
1310 .vback_porch = { 5, 8, 11 },
1311 .vsync_len = { 5, 7, 11 },
1312 .flags = DISPLAY_FLAGS_DE_HIGH,
1315 static const struct panel_desc dlc_dlc1010gig = {
1316 .timings = &dlc_dlc1010gig_timing,
1329 .bus_format = MEDIA_BUS_FMT_RGB888_1X7X4_SPWG,
1330 .connector_type = DRM_MODE_CONNECTOR_LVDS,
1333 static const struct drm_display_mode edt_et035012dm6_mode = {
1336 .hsync_start = 320 + 20,
1337 .hsync_end = 320 + 20 + 30,
1338 .htotal = 320 + 20 + 68,
1340 .vsync_start = 240 + 4,
1341 .vsync_end = 240 + 4 + 4,
1342 .vtotal = 240 + 4 + 4 + 14,
1344 .flags = DRM_MODE_FLAG_NVSYNC | DRM_MODE_FLAG_NHSYNC,
1347 static const struct panel_desc edt_et035012dm6 = {
1348 .modes = &edt_et035012dm6_mode,
1355 .bus_format = MEDIA_BUS_FMT_RGB888_1X24,
1356 .bus_flags = DRM_BUS_FLAG_DE_LOW | DRM_BUS_FLAG_PIXDATA_NEGEDGE,
1359 static const struct drm_display_mode edt_etm043080dh6gp_mode = {
1362 .hsync_start = 480 + 8,
1363 .hsync_end = 480 + 8 + 4,
1364 .htotal = 480 + 8 + 4 + 41,
1367 * IWG22M: Y resolution changed for "dc_linuxfb" module crashing while
1372 .vsync_start = 288 + 2,
1373 .vsync_end = 288 + 2 + 4,
1374 .vtotal = 288 + 2 + 4 + 10,
1378 static const struct panel_desc edt_etm043080dh6gp = {
1379 .modes = &edt_etm043080dh6gp_mode,
1386 .bus_format = MEDIA_BUS_FMT_RGB666_1X18,
1387 .connector_type = DRM_MODE_CONNECTOR_DPI,
1390 static const struct drm_display_mode edt_etm0430g0dh6_mode = {
1393 .hsync_start = 480 + 2,
1394 .hsync_end = 480 + 2 + 41,
1395 .htotal = 480 + 2 + 41 + 2,
1397 .vsync_start = 272 + 2,
1398 .vsync_end = 272 + 2 + 10,
1399 .vtotal = 272 + 2 + 10 + 2,
1401 .flags = DRM_MODE_FLAG_NHSYNC | DRM_MODE_FLAG_NVSYNC,
1404 static const struct panel_desc edt_etm0430g0dh6 = {
1405 .modes = &edt_etm0430g0dh6_mode,
1414 static const struct drm_display_mode edt_et057090dhu_mode = {
1417 .hsync_start = 640 + 16,
1418 .hsync_end = 640 + 16 + 30,
1419 .htotal = 640 + 16 + 30 + 114,
1421 .vsync_start = 480 + 10,
1422 .vsync_end = 480 + 10 + 3,
1423 .vtotal = 480 + 10 + 3 + 32,
1425 .flags = DRM_MODE_FLAG_NVSYNC | DRM_MODE_FLAG_NHSYNC,
1428 static const struct panel_desc edt_et057090dhu = {
1429 .modes = &edt_et057090dhu_mode,
1436 .bus_format = MEDIA_BUS_FMT_RGB666_1X18,
1437 .bus_flags = DRM_BUS_FLAG_DE_HIGH | DRM_BUS_FLAG_PIXDATA_DRIVE_NEGEDGE,
1440 static const struct drm_display_mode edt_etm0700g0dh6_mode = {
1443 .hsync_start = 800 + 40,
1444 .hsync_end = 800 + 40 + 128,
1445 .htotal = 800 + 40 + 128 + 88,
1447 .vsync_start = 480 + 10,
1448 .vsync_end = 480 + 10 + 2,
1449 .vtotal = 480 + 10 + 2 + 33,
1451 .flags = DRM_MODE_FLAG_NHSYNC | DRM_MODE_FLAG_NVSYNC,
1454 static const struct panel_desc edt_etm0700g0dh6 = {
1455 .modes = &edt_etm0700g0dh6_mode,
1462 .bus_format = MEDIA_BUS_FMT_RGB666_1X18,
1463 .bus_flags = DRM_BUS_FLAG_DE_HIGH | DRM_BUS_FLAG_PIXDATA_DRIVE_NEGEDGE,
1466 static const struct panel_desc edt_etm0700g0bdh6 = {
1467 .modes = &edt_etm0700g0dh6_mode,
1474 .bus_format = MEDIA_BUS_FMT_RGB666_1X18,
1475 .bus_flags = DRM_BUS_FLAG_DE_HIGH | DRM_BUS_FLAG_PIXDATA_DRIVE_POSEDGE,
1478 static const struct display_timing evervision_vgg804821_timing = {
1479 .pixelclock = { 27600000, 33300000, 50000000 },
1480 .hactive = { 800, 800, 800 },
1481 .hfront_porch = { 40, 66, 70 },
1482 .hback_porch = { 40, 67, 70 },
1483 .hsync_len = { 40, 67, 70 },
1484 .vactive = { 480, 480, 480 },
1485 .vfront_porch = { 6, 10, 10 },
1486 .vback_porch = { 7, 11, 11 },
1487 .vsync_len = { 7, 11, 11 },
1488 .flags = DISPLAY_FLAGS_HSYNC_HIGH | DISPLAY_FLAGS_VSYNC_HIGH |
1489 DISPLAY_FLAGS_DE_HIGH | DISPLAY_FLAGS_PIXDATA_NEGEDGE |
1490 DISPLAY_FLAGS_SYNC_NEGEDGE,
1493 static const struct panel_desc evervision_vgg804821 = {
1494 .timings = &evervision_vgg804821_timing,
1501 .bus_format = MEDIA_BUS_FMT_RGB888_1X24,
1502 .bus_flags = DRM_BUS_FLAG_DE_HIGH | DRM_BUS_FLAG_PIXDATA_NEGEDGE,
1505 static const struct drm_display_mode foxlink_fl500wvr00_a0t_mode = {
1508 .hsync_start = 800 + 168,
1509 .hsync_end = 800 + 168 + 64,
1510 .htotal = 800 + 168 + 64 + 88,
1512 .vsync_start = 480 + 37,
1513 .vsync_end = 480 + 37 + 2,
1514 .vtotal = 480 + 37 + 2 + 8,
1518 static const struct panel_desc foxlink_fl500wvr00_a0t = {
1519 .modes = &foxlink_fl500wvr00_a0t_mode,
1526 .bus_format = MEDIA_BUS_FMT_RGB888_1X24,
1529 static const struct drm_display_mode frida_frd350h54004_mode = {
1532 .hsync_start = 320 + 44,
1533 .hsync_end = 320 + 44 + 16,
1534 .htotal = 320 + 44 + 16 + 20,
1536 .vsync_start = 240 + 2,
1537 .vsync_end = 240 + 2 + 6,
1538 .vtotal = 240 + 2 + 6 + 2,
1540 .flags = DRM_MODE_FLAG_PHSYNC | DRM_MODE_FLAG_PVSYNC,
1543 static const struct panel_desc frida_frd350h54004 = {
1544 .modes = &frida_frd350h54004_mode,
1551 .bus_format = MEDIA_BUS_FMT_RGB888_1X24,
1552 .bus_flags = DRM_BUS_FLAG_DE_HIGH | DRM_BUS_FLAG_PIXDATA_POSEDGE,
1553 .connector_type = DRM_MODE_CONNECTOR_DPI,
1556 static const struct drm_display_mode friendlyarm_hd702e_mode = {
1559 .hsync_start = 800 + 20,
1560 .hsync_end = 800 + 20 + 24,
1561 .htotal = 800 + 20 + 24 + 20,
1563 .vsync_start = 1280 + 4,
1564 .vsync_end = 1280 + 4 + 8,
1565 .vtotal = 1280 + 4 + 8 + 4,
1567 .flags = DRM_MODE_FLAG_NVSYNC | DRM_MODE_FLAG_NHSYNC,
1570 static const struct panel_desc friendlyarm_hd702e = {
1571 .modes = &friendlyarm_hd702e_mode,
1579 static const struct drm_display_mode giantplus_gpg482739qs5_mode = {
1582 .hsync_start = 480 + 5,
1583 .hsync_end = 480 + 5 + 1,
1584 .htotal = 480 + 5 + 1 + 40,
1586 .vsync_start = 272 + 8,
1587 .vsync_end = 272 + 8 + 1,
1588 .vtotal = 272 + 8 + 1 + 8,
1592 static const struct panel_desc giantplus_gpg482739qs5 = {
1593 .modes = &giantplus_gpg482739qs5_mode,
1600 .bus_format = MEDIA_BUS_FMT_RGB888_1X24,
1603 static const struct display_timing giantplus_gpm940b0_timing = {
1604 .pixelclock = { 13500000, 27000000, 27500000 },
1605 .hactive = { 320, 320, 320 },
1606 .hfront_porch = { 14, 686, 718 },
1607 .hback_porch = { 50, 70, 255 },
1608 .hsync_len = { 1, 1, 1 },
1609 .vactive = { 240, 240, 240 },
1610 .vfront_porch = { 1, 1, 179 },
1611 .vback_porch = { 1, 21, 31 },
1612 .vsync_len = { 1, 1, 6 },
1613 .flags = DISPLAY_FLAGS_HSYNC_LOW | DISPLAY_FLAGS_VSYNC_LOW,
1616 static const struct panel_desc giantplus_gpm940b0 = {
1617 .timings = &giantplus_gpm940b0_timing,
1624 .bus_format = MEDIA_BUS_FMT_RGB888_3X8,
1625 .bus_flags = DRM_BUS_FLAG_DE_HIGH | DRM_BUS_FLAG_PIXDATA_NEGEDGE,
1628 static const struct display_timing hannstar_hsd070pww1_timing = {
1629 .pixelclock = { 64300000, 71100000, 82000000 },
1630 .hactive = { 1280, 1280, 1280 },
1631 .hfront_porch = { 1, 1, 10 },
1632 .hback_porch = { 1, 1, 10 },
1634 * According to the data sheet, the minimum horizontal blanking interval
1635 * is 54 clocks (1 + 52 + 1), but tests with a Nitrogen6X have shown the
1636 * minimum working horizontal blanking interval to be 60 clocks.
1638 .hsync_len = { 58, 158, 661 },
1639 .vactive = { 800, 800, 800 },
1640 .vfront_porch = { 1, 1, 10 },
1641 .vback_porch = { 1, 1, 10 },
1642 .vsync_len = { 1, 21, 203 },
1643 .flags = DISPLAY_FLAGS_DE_HIGH,
1646 static const struct panel_desc hannstar_hsd070pww1 = {
1647 .timings = &hannstar_hsd070pww1_timing,
1654 .bus_format = MEDIA_BUS_FMT_RGB666_1X7X3_SPWG,
1655 .connector_type = DRM_MODE_CONNECTOR_LVDS,
1658 static const struct display_timing hannstar_hsd100pxn1_timing = {
1659 .pixelclock = { 55000000, 65000000, 75000000 },
1660 .hactive = { 1024, 1024, 1024 },
1661 .hfront_porch = { 40, 40, 40 },
1662 .hback_porch = { 220, 220, 220 },
1663 .hsync_len = { 20, 60, 100 },
1664 .vactive = { 768, 768, 768 },
1665 .vfront_porch = { 7, 7, 7 },
1666 .vback_porch = { 21, 21, 21 },
1667 .vsync_len = { 10, 10, 10 },
1668 .flags = DISPLAY_FLAGS_DE_HIGH,
1671 static const struct panel_desc hannstar_hsd100pxn1 = {
1672 .timings = &hannstar_hsd100pxn1_timing,
1679 .bus_format = MEDIA_BUS_FMT_RGB666_1X7X3_SPWG,
1680 .connector_type = DRM_MODE_CONNECTOR_LVDS,
1683 static const struct drm_display_mode hitachi_tx23d38vm0caa_mode = {
1686 .hsync_start = 800 + 85,
1687 .hsync_end = 800 + 85 + 86,
1688 .htotal = 800 + 85 + 86 + 85,
1690 .vsync_start = 480 + 16,
1691 .vsync_end = 480 + 16 + 13,
1692 .vtotal = 480 + 16 + 13 + 16,
1696 static const struct panel_desc hitachi_tx23d38vm0caa = {
1697 .modes = &hitachi_tx23d38vm0caa_mode,
1710 static const struct drm_display_mode innolux_at043tn24_mode = {
1713 .hsync_start = 480 + 2,
1714 .hsync_end = 480 + 2 + 41,
1715 .htotal = 480 + 2 + 41 + 2,
1717 .vsync_start = 272 + 2,
1718 .vsync_end = 272 + 2 + 10,
1719 .vtotal = 272 + 2 + 10 + 2,
1721 .flags = DRM_MODE_FLAG_NHSYNC | DRM_MODE_FLAG_NVSYNC,
1724 static const struct panel_desc innolux_at043tn24 = {
1725 .modes = &innolux_at043tn24_mode,
1732 .bus_format = MEDIA_BUS_FMT_RGB888_1X24,
1733 .bus_flags = DRM_BUS_FLAG_DE_HIGH | DRM_BUS_FLAG_PIXDATA_DRIVE_POSEDGE,
1736 static const struct drm_display_mode innolux_at070tn92_mode = {
1739 .hsync_start = 800 + 210,
1740 .hsync_end = 800 + 210 + 20,
1741 .htotal = 800 + 210 + 20 + 46,
1743 .vsync_start = 480 + 22,
1744 .vsync_end = 480 + 22 + 10,
1745 .vtotal = 480 + 22 + 23 + 10,
1749 static const struct panel_desc innolux_at070tn92 = {
1750 .modes = &innolux_at070tn92_mode,
1756 .bus_format = MEDIA_BUS_FMT_RGB888_1X24,
1759 static const struct display_timing innolux_g070y2_l01_timing = {
1760 .pixelclock = { 28000000, 29500000, 32000000 },
1761 .hactive = { 800, 800, 800 },
1762 .hfront_porch = { 61, 91, 141 },
1763 .hback_porch = { 60, 90, 140 },
1764 .hsync_len = { 12, 12, 12 },
1765 .vactive = { 480, 480, 480 },
1766 .vfront_porch = { 4, 9, 30 },
1767 .vback_porch = { 4, 8, 28 },
1768 .vsync_len = { 2, 2, 2 },
1769 .flags = DISPLAY_FLAGS_DE_HIGH,
1772 static const struct panel_desc innolux_g070y2_l01 = {
1773 .timings = &innolux_g070y2_l01_timing,
1786 .bus_format = MEDIA_BUS_FMT_RGB888_1X7X4_SPWG,
1787 .connector_type = DRM_MODE_CONNECTOR_LVDS,
1790 static const struct display_timing innolux_g101ice_l01_timing = {
1791 .pixelclock = { 60400000, 71100000, 74700000 },
1792 .hactive = { 1280, 1280, 1280 },
1793 .hfront_porch = { 41, 80, 100 },
1794 .hback_porch = { 40, 79, 99 },
1795 .hsync_len = { 1, 1, 1 },
1796 .vactive = { 800, 800, 800 },
1797 .vfront_porch = { 5, 11, 14 },
1798 .vback_porch = { 4, 11, 14 },
1799 .vsync_len = { 1, 1, 1 },
1800 .flags = DISPLAY_FLAGS_DE_HIGH,
1803 static const struct panel_desc innolux_g101ice_l01 = {
1804 .timings = &innolux_g101ice_l01_timing,
1815 .bus_format = MEDIA_BUS_FMT_RGB888_1X7X4_SPWG,
1816 .connector_type = DRM_MODE_CONNECTOR_LVDS,
1819 static const struct display_timing innolux_g121i1_l01_timing = {
1820 .pixelclock = { 67450000, 71000000, 74550000 },
1821 .hactive = { 1280, 1280, 1280 },
1822 .hfront_porch = { 40, 80, 160 },
1823 .hback_porch = { 39, 79, 159 },
1824 .hsync_len = { 1, 1, 1 },
1825 .vactive = { 800, 800, 800 },
1826 .vfront_porch = { 5, 11, 100 },
1827 .vback_porch = { 4, 11, 99 },
1828 .vsync_len = { 1, 1, 1 },
1831 static const struct panel_desc innolux_g121i1_l01 = {
1832 .timings = &innolux_g121i1_l01_timing,
1843 .bus_format = MEDIA_BUS_FMT_RGB888_1X7X4_SPWG,
1844 .connector_type = DRM_MODE_CONNECTOR_LVDS,
1847 static const struct drm_display_mode innolux_g121x1_l03_mode = {
1850 .hsync_start = 1024 + 0,
1851 .hsync_end = 1024 + 1,
1852 .htotal = 1024 + 0 + 1 + 320,
1854 .vsync_start = 768 + 38,
1855 .vsync_end = 768 + 38 + 1,
1856 .vtotal = 768 + 38 + 1 + 0,
1858 .flags = DRM_MODE_FLAG_NHSYNC | DRM_MODE_FLAG_NVSYNC,
1861 static const struct panel_desc innolux_g121x1_l03 = {
1862 .modes = &innolux_g121x1_l03_mode,
1877 * Datasheet specifies that at 60 Hz refresh rate:
1878 * - total horizontal time: { 1506, 1592, 1716 }
1879 * - total vertical time: { 788, 800, 868 }
1881 * ...but doesn't go into exactly how that should be split into a front
1882 * porch, back porch, or sync length. For now we'll leave a single setting
1883 * here which allows a bit of tweaking of the pixel clock at the expense of
1886 static const struct display_timing innolux_n116bge_timing = {
1887 .pixelclock = { 72600000, 76420000, 80240000 },
1888 .hactive = { 1366, 1366, 1366 },
1889 .hfront_porch = { 136, 136, 136 },
1890 .hback_porch = { 60, 60, 60 },
1891 .hsync_len = { 30, 30, 30 },
1892 .vactive = { 768, 768, 768 },
1893 .vfront_porch = { 8, 8, 8 },
1894 .vback_porch = { 12, 12, 12 },
1895 .vsync_len = { 12, 12, 12 },
1896 .flags = DISPLAY_FLAGS_VSYNC_LOW | DISPLAY_FLAGS_HSYNC_LOW,
1899 static const struct panel_desc innolux_n116bge = {
1900 .timings = &innolux_n116bge_timing,
1909 static const struct drm_display_mode innolux_n156bge_l21_mode = {
1912 .hsync_start = 1366 + 16,
1913 .hsync_end = 1366 + 16 + 34,
1914 .htotal = 1366 + 16 + 34 + 50,
1916 .vsync_start = 768 + 2,
1917 .vsync_end = 768 + 2 + 6,
1918 .vtotal = 768 + 2 + 6 + 12,
1922 static const struct panel_desc innolux_n156bge_l21 = {
1923 .modes = &innolux_n156bge_l21_mode,
1932 static const struct drm_display_mode innolux_p120zdg_bf1_mode = {
1935 .hsync_start = 2160 + 48,
1936 .hsync_end = 2160 + 48 + 32,
1937 .htotal = 2160 + 48 + 32 + 80,
1939 .vsync_start = 1440 + 3,
1940 .vsync_end = 1440 + 3 + 10,
1941 .vtotal = 1440 + 3 + 10 + 27,
1943 .flags = DRM_MODE_FLAG_PHSYNC | DRM_MODE_FLAG_PVSYNC,
1946 static const struct panel_desc innolux_p120zdg_bf1 = {
1947 .modes = &innolux_p120zdg_bf1_mode,
1955 .hpd_absent_delay = 200,
1960 static const struct drm_display_mode innolux_zj070na_01p_mode = {
1963 .hsync_start = 1024 + 128,
1964 .hsync_end = 1024 + 128 + 64,
1965 .htotal = 1024 + 128 + 64 + 128,
1967 .vsync_start = 600 + 16,
1968 .vsync_end = 600 + 16 + 4,
1969 .vtotal = 600 + 16 + 4 + 16,
1973 static const struct panel_desc innolux_zj070na_01p = {
1974 .modes = &innolux_zj070na_01p_mode,
1983 static const struct display_timing koe_tx14d24vm1bpa_timing = {
1984 .pixelclock = { 5580000, 5850000, 6200000 },
1985 .hactive = { 320, 320, 320 },
1986 .hfront_porch = { 30, 30, 30 },
1987 .hback_porch = { 30, 30, 30 },
1988 .hsync_len = { 1, 5, 17 },
1989 .vactive = { 240, 240, 240 },
1990 .vfront_porch = { 6, 6, 6 },
1991 .vback_porch = { 5, 5, 5 },
1992 .vsync_len = { 1, 2, 11 },
1993 .flags = DISPLAY_FLAGS_DE_HIGH,
1996 static const struct panel_desc koe_tx14d24vm1bpa = {
1997 .timings = &koe_tx14d24vm1bpa_timing,
2006 static const struct display_timing koe_tx31d200vm0baa_timing = {
2007 .pixelclock = { 39600000, 43200000, 48000000 },
2008 .hactive = { 1280, 1280, 1280 },
2009 .hfront_porch = { 16, 36, 56 },
2010 .hback_porch = { 16, 36, 56 },
2011 .hsync_len = { 8, 8, 8 },
2012 .vactive = { 480, 480, 480 },
2013 .vfront_porch = { 6, 21, 33 },
2014 .vback_porch = { 6, 21, 33 },
2015 .vsync_len = { 8, 8, 8 },
2016 .flags = DISPLAY_FLAGS_DE_HIGH,
2019 static const struct panel_desc koe_tx31d200vm0baa = {
2020 .timings = &koe_tx31d200vm0baa_timing,
2027 .bus_format = MEDIA_BUS_FMT_RGB666_1X7X3_SPWG,
2028 .connector_type = DRM_MODE_CONNECTOR_LVDS,
2031 static const struct display_timing kyo_tcg121xglp_timing = {
2032 .pixelclock = { 52000000, 65000000, 71000000 },
2033 .hactive = { 1024, 1024, 1024 },
2034 .hfront_porch = { 2, 2, 2 },
2035 .hback_porch = { 2, 2, 2 },
2036 .hsync_len = { 86, 124, 244 },
2037 .vactive = { 768, 768, 768 },
2038 .vfront_porch = { 2, 2, 2 },
2039 .vback_porch = { 2, 2, 2 },
2040 .vsync_len = { 6, 34, 73 },
2041 .flags = DISPLAY_FLAGS_DE_HIGH,
2044 static const struct panel_desc kyo_tcg121xglp = {
2045 .timings = &kyo_tcg121xglp_timing,
2052 .bus_format = MEDIA_BUS_FMT_RGB888_1X7X4_SPWG,
2053 .connector_type = DRM_MODE_CONNECTOR_LVDS,
2056 static const struct drm_display_mode lemaker_bl035_rgb_002_mode = {
2059 .hsync_start = 320 + 20,
2060 .hsync_end = 320 + 20 + 30,
2061 .htotal = 320 + 20 + 30 + 38,
2063 .vsync_start = 240 + 4,
2064 .vsync_end = 240 + 4 + 3,
2065 .vtotal = 240 + 4 + 3 + 15,
2069 static const struct panel_desc lemaker_bl035_rgb_002 = {
2070 .modes = &lemaker_bl035_rgb_002_mode,
2076 .bus_format = MEDIA_BUS_FMT_RGB888_1X24,
2077 .bus_flags = DRM_BUS_FLAG_DE_LOW,
2080 static const struct drm_display_mode lg_lb070wv8_mode = {
2083 .hsync_start = 800 + 88,
2084 .hsync_end = 800 + 88 + 80,
2085 .htotal = 800 + 88 + 80 + 88,
2087 .vsync_start = 480 + 10,
2088 .vsync_end = 480 + 10 + 25,
2089 .vtotal = 480 + 10 + 25 + 10,
2093 static const struct panel_desc lg_lb070wv8 = {
2094 .modes = &lg_lb070wv8_mode,
2101 .bus_format = MEDIA_BUS_FMT_RGB888_1X7X4_SPWG,
2102 .connector_type = DRM_MODE_CONNECTOR_LVDS,
2105 static const struct drm_display_mode lg_lp079qx1_sp0v_mode = {
2108 .hsync_start = 1536 + 12,
2109 .hsync_end = 1536 + 12 + 16,
2110 .htotal = 1536 + 12 + 16 + 48,
2112 .vsync_start = 2048 + 8,
2113 .vsync_end = 2048 + 8 + 4,
2114 .vtotal = 2048 + 8 + 4 + 8,
2116 .flags = DRM_MODE_FLAG_NVSYNC | DRM_MODE_FLAG_NHSYNC,
2119 static const struct panel_desc lg_lp079qx1_sp0v = {
2120 .modes = &lg_lp079qx1_sp0v_mode,
2128 static const struct drm_display_mode lg_lp097qx1_spa1_mode = {
2131 .hsync_start = 2048 + 150,
2132 .hsync_end = 2048 + 150 + 5,
2133 .htotal = 2048 + 150 + 5 + 5,
2135 .vsync_start = 1536 + 3,
2136 .vsync_end = 1536 + 3 + 1,
2137 .vtotal = 1536 + 3 + 1 + 9,
2141 static const struct panel_desc lg_lp097qx1_spa1 = {
2142 .modes = &lg_lp097qx1_spa1_mode,
2150 static const struct drm_display_mode lg_lp120up1_mode = {
2153 .hsync_start = 1920 + 40,
2154 .hsync_end = 1920 + 40 + 40,
2155 .htotal = 1920 + 40 + 40+ 80,
2157 .vsync_start = 1280 + 4,
2158 .vsync_end = 1280 + 4 + 4,
2159 .vtotal = 1280 + 4 + 4 + 12,
2163 static const struct panel_desc lg_lp120up1 = {
2164 .modes = &lg_lp120up1_mode,
2173 static const struct drm_display_mode lg_lp129qe_mode = {
2176 .hsync_start = 2560 + 48,
2177 .hsync_end = 2560 + 48 + 32,
2178 .htotal = 2560 + 48 + 32 + 80,
2180 .vsync_start = 1700 + 3,
2181 .vsync_end = 1700 + 3 + 10,
2182 .vtotal = 1700 + 3 + 10 + 36,
2186 static const struct panel_desc lg_lp129qe = {
2187 .modes = &lg_lp129qe_mode,
2196 static const struct display_timing logictechno_lt161010_2nh_timing = {
2197 .pixelclock = { 26400000, 33300000, 46800000 },
2198 .hactive = { 800, 800, 800 },
2199 .hfront_porch = { 16, 210, 354 },
2200 .hback_porch = { 46, 46, 46 },
2201 .hsync_len = { 1, 20, 40 },
2202 .vactive = { 480, 480, 480 },
2203 .vfront_porch = { 7, 22, 147 },
2204 .vback_porch = { 23, 23, 23 },
2205 .vsync_len = { 1, 10, 20 },
2206 .flags = DISPLAY_FLAGS_HSYNC_LOW | DISPLAY_FLAGS_VSYNC_LOW |
2207 DISPLAY_FLAGS_DE_HIGH | DISPLAY_FLAGS_PIXDATA_POSEDGE |
2208 DISPLAY_FLAGS_SYNC_POSEDGE,
2211 static const struct panel_desc logictechno_lt161010_2nh = {
2212 .timings = &logictechno_lt161010_2nh_timing,
2218 .bus_format = MEDIA_BUS_FMT_RGB666_1X18,
2219 .bus_flags = DRM_BUS_FLAG_DE_HIGH |
2220 DRM_BUS_FLAG_PIXDATA_SAMPLE_NEGEDGE |
2221 DRM_BUS_FLAG_SYNC_SAMPLE_NEGEDGE,
2222 .connector_type = DRM_MODE_CONNECTOR_DPI,
2225 static const struct display_timing logictechno_lt170410_2whc_timing = {
2226 .pixelclock = { 68900000, 71100000, 73400000 },
2227 .hactive = { 1280, 1280, 1280 },
2228 .hfront_porch = { 23, 60, 71 },
2229 .hback_porch = { 23, 60, 71 },
2230 .hsync_len = { 15, 40, 47 },
2231 .vactive = { 800, 800, 800 },
2232 .vfront_porch = { 5, 7, 10 },
2233 .vback_porch = { 5, 7, 10 },
2234 .vsync_len = { 6, 9, 12 },
2235 .flags = DISPLAY_FLAGS_HSYNC_LOW | DISPLAY_FLAGS_VSYNC_LOW |
2236 DISPLAY_FLAGS_DE_HIGH | DISPLAY_FLAGS_PIXDATA_POSEDGE |
2237 DISPLAY_FLAGS_SYNC_POSEDGE,
2240 static const struct panel_desc logictechno_lt170410_2whc = {
2241 .timings = &logictechno_lt170410_2whc_timing,
2247 .bus_format = MEDIA_BUS_FMT_RGB888_1X7X4_SPWG,
2248 .bus_flags = DRM_BUS_FLAG_DE_HIGH |
2249 DRM_BUS_FLAG_PIXDATA_SAMPLE_NEGEDGE |
2250 DRM_BUS_FLAG_SYNC_SAMPLE_NEGEDGE,
2251 .connector_type = DRM_MODE_CONNECTOR_LVDS,
2254 static const struct drm_display_mode mitsubishi_aa070mc01_mode = {
2257 .hsync_start = 800 + 0,
2258 .hsync_end = 800 + 1,
2259 .htotal = 800 + 0 + 1 + 160,
2261 .vsync_start = 480 + 0,
2262 .vsync_end = 480 + 48 + 1,
2263 .vtotal = 480 + 48 + 1 + 0,
2265 .flags = DRM_MODE_FLAG_NHSYNC | DRM_MODE_FLAG_NVSYNC,
2268 static const struct drm_display_mode logicpd_type_28_mode = {
2271 .hsync_start = 480 + 3,
2272 .hsync_end = 480 + 3 + 42,
2273 .htotal = 480 + 3 + 42 + 2,
2276 .vsync_start = 272 + 2,
2277 .vsync_end = 272 + 2 + 11,
2278 .vtotal = 272 + 2 + 11 + 3,
2280 .flags = DRM_MODE_FLAG_PHSYNC | DRM_MODE_FLAG_PVSYNC,
2283 static const struct panel_desc logicpd_type_28 = {
2284 .modes = &logicpd_type_28_mode,
2297 .bus_format = MEDIA_BUS_FMT_RGB888_1X24,
2298 .bus_flags = DRM_BUS_FLAG_DE_HIGH | DRM_BUS_FLAG_PIXDATA_DRIVE_POSEDGE |
2299 DRM_BUS_FLAG_SYNC_DRIVE_NEGEDGE,
2302 static const struct panel_desc mitsubishi_aa070mc01 = {
2303 .modes = &mitsubishi_aa070mc01_mode,
2316 .bus_format = MEDIA_BUS_FMT_RGB888_1X7X4_SPWG,
2317 .connector_type = DRM_MODE_CONNECTOR_LVDS,
2318 .bus_flags = DRM_BUS_FLAG_DE_HIGH,
2321 static const struct display_timing nec_nl12880bc20_05_timing = {
2322 .pixelclock = { 67000000, 71000000, 75000000 },
2323 .hactive = { 1280, 1280, 1280 },
2324 .hfront_porch = { 2, 30, 30 },
2325 .hback_porch = { 6, 100, 100 },
2326 .hsync_len = { 2, 30, 30 },
2327 .vactive = { 800, 800, 800 },
2328 .vfront_porch = { 5, 5, 5 },
2329 .vback_porch = { 11, 11, 11 },
2330 .vsync_len = { 7, 7, 7 },
2333 static const struct panel_desc nec_nl12880bc20_05 = {
2334 .timings = &nec_nl12880bc20_05_timing,
2345 .bus_format = MEDIA_BUS_FMT_RGB888_1X7X4_SPWG,
2346 .connector_type = DRM_MODE_CONNECTOR_LVDS,
2349 static const struct drm_display_mode nec_nl4827hc19_05b_mode = {
2352 .hsync_start = 480 + 2,
2353 .hsync_end = 480 + 2 + 41,
2354 .htotal = 480 + 2 + 41 + 2,
2356 .vsync_start = 272 + 2,
2357 .vsync_end = 272 + 2 + 4,
2358 .vtotal = 272 + 2 + 4 + 2,
2360 .flags = DRM_MODE_FLAG_NVSYNC | DRM_MODE_FLAG_NHSYNC,
2363 static const struct panel_desc nec_nl4827hc19_05b = {
2364 .modes = &nec_nl4827hc19_05b_mode,
2371 .bus_format = MEDIA_BUS_FMT_RGB888_1X24,
2372 .bus_flags = DRM_BUS_FLAG_PIXDATA_DRIVE_POSEDGE,
2375 static const struct drm_display_mode netron_dy_e231732_mode = {
2378 .hsync_start = 1024 + 160,
2379 .hsync_end = 1024 + 160 + 70,
2380 .htotal = 1024 + 160 + 70 + 90,
2382 .vsync_start = 600 + 127,
2383 .vsync_end = 600 + 127 + 20,
2384 .vtotal = 600 + 127 + 20 + 3,
2388 static const struct panel_desc netron_dy_e231732 = {
2389 .modes = &netron_dy_e231732_mode,
2395 .bus_format = MEDIA_BUS_FMT_RGB666_1X18,
2398 static const struct drm_display_mode neweast_wjfh116008a_modes[] = {
2402 .hsync_start = 1920 + 48,
2403 .hsync_end = 1920 + 48 + 32,
2404 .htotal = 1920 + 48 + 32 + 80,
2406 .vsync_start = 1080 + 3,
2407 .vsync_end = 1080 + 3 + 5,
2408 .vtotal = 1080 + 3 + 5 + 23,
2410 .flags = DRM_MODE_FLAG_NVSYNC | DRM_MODE_FLAG_NHSYNC,
2414 .hsync_start = 1920 + 48,
2415 .hsync_end = 1920 + 48 + 32,
2416 .htotal = 1920 + 48 + 32 + 80,
2418 .vsync_start = 1080 + 3,
2419 .vsync_end = 1080 + 3 + 5,
2420 .vtotal = 1080 + 3 + 5 + 23,
2422 .flags = DRM_MODE_FLAG_NVSYNC | DRM_MODE_FLAG_NHSYNC,
2426 static const struct panel_desc neweast_wjfh116008a = {
2427 .modes = neweast_wjfh116008a_modes,
2439 .bus_format = MEDIA_BUS_FMT_RGB666_1X18,
2440 .connector_type = DRM_MODE_CONNECTOR_eDP,
2443 static const struct drm_display_mode newhaven_nhd_43_480272ef_atxl_mode = {
2446 .hsync_start = 480 + 2,
2447 .hsync_end = 480 + 2 + 41,
2448 .htotal = 480 + 2 + 41 + 2,
2450 .vsync_start = 272 + 2,
2451 .vsync_end = 272 + 2 + 10,
2452 .vtotal = 272 + 2 + 10 + 2,
2454 .flags = DRM_MODE_FLAG_NVSYNC | DRM_MODE_FLAG_NHSYNC,
2457 static const struct panel_desc newhaven_nhd_43_480272ef_atxl = {
2458 .modes = &newhaven_nhd_43_480272ef_atxl_mode,
2465 .bus_format = MEDIA_BUS_FMT_RGB888_1X24,
2466 .bus_flags = DRM_BUS_FLAG_DE_HIGH | DRM_BUS_FLAG_PIXDATA_DRIVE_POSEDGE |
2467 DRM_BUS_FLAG_SYNC_DRIVE_POSEDGE,
2470 static const struct display_timing nlt_nl192108ac18_02d_timing = {
2471 .pixelclock = { 130000000, 148350000, 163000000 },
2472 .hactive = { 1920, 1920, 1920 },
2473 .hfront_porch = { 80, 100, 100 },
2474 .hback_porch = { 100, 120, 120 },
2475 .hsync_len = { 50, 60, 60 },
2476 .vactive = { 1080, 1080, 1080 },
2477 .vfront_porch = { 12, 30, 30 },
2478 .vback_porch = { 4, 10, 10 },
2479 .vsync_len = { 4, 5, 5 },
2482 static const struct panel_desc nlt_nl192108ac18_02d = {
2483 .timings = &nlt_nl192108ac18_02d_timing,
2493 .bus_format = MEDIA_BUS_FMT_RGB888_1X7X4_SPWG,
2494 .connector_type = DRM_MODE_CONNECTOR_LVDS,
2497 static const struct drm_display_mode nvd_9128_mode = {
2500 .hsync_start = 800 + 130,
2501 .hsync_end = 800 + 130 + 98,
2502 .htotal = 800 + 0 + 130 + 98,
2504 .vsync_start = 480 + 10,
2505 .vsync_end = 480 + 10 + 50,
2506 .vtotal = 480 + 0 + 10 + 50,
2509 static const struct panel_desc nvd_9128 = {
2510 .modes = &nvd_9128_mode,
2517 .bus_format = MEDIA_BUS_FMT_RGB888_1X7X4_SPWG,
2518 .connector_type = DRM_MODE_CONNECTOR_LVDS,
2521 static const struct display_timing okaya_rs800480t_7x0gp_timing = {
2522 .pixelclock = { 30000000, 30000000, 40000000 },
2523 .hactive = { 800, 800, 800 },
2524 .hfront_porch = { 40, 40, 40 },
2525 .hback_porch = { 40, 40, 40 },
2526 .hsync_len = { 1, 48, 48 },
2527 .vactive = { 480, 480, 480 },
2528 .vfront_porch = { 13, 13, 13 },
2529 .vback_porch = { 29, 29, 29 },
2530 .vsync_len = { 3, 3, 3 },
2531 .flags = DISPLAY_FLAGS_DE_HIGH,
2534 static const struct panel_desc okaya_rs800480t_7x0gp = {
2535 .timings = &okaya_rs800480t_7x0gp_timing,
2548 .bus_format = MEDIA_BUS_FMT_RGB666_1X18,
2551 static const struct drm_display_mode olimex_lcd_olinuxino_43ts_mode = {
2554 .hsync_start = 480 + 5,
2555 .hsync_end = 480 + 5 + 30,
2556 .htotal = 480 + 5 + 30 + 10,
2558 .vsync_start = 272 + 8,
2559 .vsync_end = 272 + 8 + 5,
2560 .vtotal = 272 + 8 + 5 + 3,
2564 static const struct panel_desc olimex_lcd_olinuxino_43ts = {
2565 .modes = &olimex_lcd_olinuxino_43ts_mode,
2571 .bus_format = MEDIA_BUS_FMT_RGB888_1X24,
2575 * 800x480 CVT. The panel appears to be quite accepting, at least as far as
2576 * pixel clocks, but this is the timing that was being used in the Adafruit
2577 * installation instructions.
2579 static const struct drm_display_mode ontat_yx700wv03_mode = {
2590 .flags = DRM_MODE_FLAG_NVSYNC | DRM_MODE_FLAG_NHSYNC,
2595 * https://www.adafruit.com/images/product-files/2406/c3163.pdf
2597 static const struct panel_desc ontat_yx700wv03 = {
2598 .modes = &ontat_yx700wv03_mode,
2605 .bus_format = MEDIA_BUS_FMT_RGB666_1X18,
2608 static const struct drm_display_mode ortustech_com37h3m_mode = {
2611 .hsync_start = 480 + 40,
2612 .hsync_end = 480 + 40 + 10,
2613 .htotal = 480 + 40 + 10 + 40,
2615 .vsync_start = 640 + 4,
2616 .vsync_end = 640 + 4 + 2,
2617 .vtotal = 640 + 4 + 2 + 4,
2619 .flags = DRM_MODE_FLAG_NVSYNC | DRM_MODE_FLAG_NHSYNC,
2622 static const struct panel_desc ortustech_com37h3m = {
2623 .modes = &ortustech_com37h3m_mode,
2627 .width = 56, /* 56.16mm */
2628 .height = 75, /* 74.88mm */
2630 .bus_format = MEDIA_BUS_FMT_RGB888_1X24,
2631 .bus_flags = DRM_BUS_FLAG_DE_HIGH | DRM_BUS_FLAG_PIXDATA_POSEDGE |
2632 DRM_BUS_FLAG_SYNC_DRIVE_POSEDGE,
2635 static const struct drm_display_mode ortustech_com43h4m85ulc_mode = {
2638 .hsync_start = 480 + 10,
2639 .hsync_end = 480 + 10 + 10,
2640 .htotal = 480 + 10 + 10 + 15,
2642 .vsync_start = 800 + 3,
2643 .vsync_end = 800 + 3 + 3,
2644 .vtotal = 800 + 3 + 3 + 3,
2648 static const struct panel_desc ortustech_com43h4m85ulc = {
2649 .modes = &ortustech_com43h4m85ulc_mode,
2656 .bus_format = MEDIA_BUS_FMT_RGB888_1X24,
2657 .bus_flags = DRM_BUS_FLAG_DE_HIGH | DRM_BUS_FLAG_PIXDATA_DRIVE_POSEDGE,
2658 .connector_type = DRM_MODE_CONNECTOR_DPI,
2661 static const struct drm_display_mode osddisplays_osd070t1718_19ts_mode = {
2664 .hsync_start = 800 + 210,
2665 .hsync_end = 800 + 210 + 30,
2666 .htotal = 800 + 210 + 30 + 16,
2668 .vsync_start = 480 + 22,
2669 .vsync_end = 480 + 22 + 13,
2670 .vtotal = 480 + 22 + 13 + 10,
2672 .flags = DRM_MODE_FLAG_NVSYNC | DRM_MODE_FLAG_NHSYNC,
2675 static const struct panel_desc osddisplays_osd070t1718_19ts = {
2676 .modes = &osddisplays_osd070t1718_19ts_mode,
2683 .bus_format = MEDIA_BUS_FMT_RGB888_1X24,
2684 .bus_flags = DRM_BUS_FLAG_DE_HIGH | DRM_BUS_FLAG_PIXDATA_DRIVE_POSEDGE |
2685 DRM_BUS_FLAG_SYNC_DRIVE_POSEDGE,
2686 .connector_type = DRM_MODE_CONNECTOR_DPI,
2689 static const struct drm_display_mode pda_91_00156_a0_mode = {
2692 .hsync_start = 800 + 1,
2693 .hsync_end = 800 + 1 + 64,
2694 .htotal = 800 + 1 + 64 + 64,
2696 .vsync_start = 480 + 1,
2697 .vsync_end = 480 + 1 + 23,
2698 .vtotal = 480 + 1 + 23 + 22,
2702 static const struct panel_desc pda_91_00156_a0 = {
2703 .modes = &pda_91_00156_a0_mode,
2709 .bus_format = MEDIA_BUS_FMT_RGB888_1X24,
2713 static const struct drm_display_mode qd43003c0_40_mode = {
2716 .hsync_start = 480 + 8,
2717 .hsync_end = 480 + 8 + 4,
2718 .htotal = 480 + 8 + 4 + 39,
2720 .vsync_start = 272 + 4,
2721 .vsync_end = 272 + 4 + 10,
2722 .vtotal = 272 + 4 + 10 + 2,
2726 static const struct panel_desc qd43003c0_40 = {
2727 .modes = &qd43003c0_40_mode,
2734 .bus_format = MEDIA_BUS_FMT_RGB888_1X24,
2737 static const struct display_timing rocktech_rk070er9427_timing = {
2738 .pixelclock = { 26400000, 33300000, 46800000 },
2739 .hactive = { 800, 800, 800 },
2740 .hfront_porch = { 16, 210, 354 },
2741 .hback_porch = { 46, 46, 46 },
2742 .hsync_len = { 1, 1, 1 },
2743 .vactive = { 480, 480, 480 },
2744 .vfront_porch = { 7, 22, 147 },
2745 .vback_porch = { 23, 23, 23 },
2746 .vsync_len = { 1, 1, 1 },
2747 .flags = DISPLAY_FLAGS_DE_HIGH,
2750 static const struct panel_desc rocktech_rk070er9427 = {
2751 .timings = &rocktech_rk070er9427_timing,
2764 .bus_format = MEDIA_BUS_FMT_RGB666_1X18,
2767 static const struct drm_display_mode rocktech_rk101ii01d_ct_mode = {
2770 .hsync_start = 1280 + 48,
2771 .hsync_end = 1280 + 48 + 32,
2772 .htotal = 1280 + 48 + 32 + 80,
2774 .vsync_start = 800 + 2,
2775 .vsync_end = 800 + 2 + 5,
2776 .vtotal = 800 + 2 + 5 + 16,
2780 static const struct panel_desc rocktech_rk101ii01d_ct = {
2781 .modes = &rocktech_rk101ii01d_ct_mode,
2791 .bus_flags = DRM_BUS_FLAG_DE_HIGH,
2792 .bus_format = MEDIA_BUS_FMT_RGB888_1X7X4_SPWG,
2793 .connector_type = DRM_MODE_CONNECTOR_LVDS,
2796 static const struct drm_display_mode samsung_lsn122dl01_c01_mode = {
2799 .hsync_start = 2560 + 48,
2800 .hsync_end = 2560 + 48 + 32,
2801 .htotal = 2560 + 48 + 32 + 80,
2803 .vsync_start = 1600 + 2,
2804 .vsync_end = 1600 + 2 + 5,
2805 .vtotal = 1600 + 2 + 5 + 57,
2809 static const struct panel_desc samsung_lsn122dl01_c01 = {
2810 .modes = &samsung_lsn122dl01_c01_mode,
2818 static const struct drm_display_mode samsung_ltn101nt05_mode = {
2821 .hsync_start = 1024 + 24,
2822 .hsync_end = 1024 + 24 + 136,
2823 .htotal = 1024 + 24 + 136 + 160,
2825 .vsync_start = 600 + 3,
2826 .vsync_end = 600 + 3 + 6,
2827 .vtotal = 600 + 3 + 6 + 61,
2831 static const struct panel_desc samsung_ltn101nt05 = {
2832 .modes = &samsung_ltn101nt05_mode,
2841 static const struct drm_display_mode samsung_ltn140at29_301_mode = {
2844 .hsync_start = 1366 + 64,
2845 .hsync_end = 1366 + 64 + 48,
2846 .htotal = 1366 + 64 + 48 + 128,
2848 .vsync_start = 768 + 2,
2849 .vsync_end = 768 + 2 + 5,
2850 .vtotal = 768 + 2 + 5 + 17,
2854 static const struct panel_desc samsung_ltn140at29_301 = {
2855 .modes = &samsung_ltn140at29_301_mode,
2864 static const struct display_timing satoz_sat050at40h12r2_timing = {
2865 .pixelclock = {33300000, 33300000, 50000000},
2866 .hactive = {800, 800, 800},
2867 .hfront_porch = {16, 210, 354},
2868 .hback_porch = {46, 46, 46},
2869 .hsync_len = {1, 1, 40},
2870 .vactive = {480, 480, 480},
2871 .vfront_porch = {7, 22, 147},
2872 .vback_porch = {23, 23, 23},
2873 .vsync_len = {1, 1, 20},
2876 static const struct panel_desc satoz_sat050at40h12r2 = {
2877 .timings = &satoz_sat050at40h12r2_timing,
2884 .bus_format = MEDIA_BUS_FMT_RGB888_1X24,
2885 .connector_type = DRM_MODE_CONNECTOR_LVDS,
2888 static const struct drm_display_mode sharp_ld_d5116z01b_mode = {
2891 .hsync_start = 1920 + 48,
2892 .hsync_end = 1920 + 48 + 32,
2893 .htotal = 1920 + 48 + 32 + 80,
2895 .vsync_start = 1280 + 3,
2896 .vsync_end = 1280 + 3 + 10,
2897 .vtotal = 1280 + 3 + 10 + 57,
2899 .flags = DRM_MODE_FLAG_PHSYNC | DRM_MODE_FLAG_PVSYNC,
2902 static const struct panel_desc sharp_ld_d5116z01b = {
2903 .modes = &sharp_ld_d5116z01b_mode,
2910 .bus_format = MEDIA_BUS_FMT_RGB888_1X24,
2911 .bus_flags = DRM_BUS_FLAG_DATA_MSB_TO_LSB,
2914 static const struct drm_display_mode sharp_lq070y3dg3b_mode = {
2917 .hsync_start = 800 + 64,
2918 .hsync_end = 800 + 64 + 128,
2919 .htotal = 800 + 64 + 128 + 64,
2921 .vsync_start = 480 + 8,
2922 .vsync_end = 480 + 8 + 2,
2923 .vtotal = 480 + 8 + 2 + 35,
2925 .flags = DISPLAY_FLAGS_PIXDATA_POSEDGE,
2928 static const struct panel_desc sharp_lq070y3dg3b = {
2929 .modes = &sharp_lq070y3dg3b_mode,
2933 .width = 152, /* 152.4mm */
2934 .height = 91, /* 91.4mm */
2936 .bus_format = MEDIA_BUS_FMT_RGB888_1X24,
2937 .bus_flags = DRM_BUS_FLAG_DE_HIGH | DRM_BUS_FLAG_PIXDATA_POSEDGE |
2938 DRM_BUS_FLAG_SYNC_DRIVE_POSEDGE,
2941 static const struct drm_display_mode sharp_lq035q7db03_mode = {
2944 .hsync_start = 240 + 16,
2945 .hsync_end = 240 + 16 + 7,
2946 .htotal = 240 + 16 + 7 + 5,
2948 .vsync_start = 320 + 9,
2949 .vsync_end = 320 + 9 + 1,
2950 .vtotal = 320 + 9 + 1 + 7,
2954 static const struct panel_desc sharp_lq035q7db03 = {
2955 .modes = &sharp_lq035q7db03_mode,
2962 .bus_format = MEDIA_BUS_FMT_RGB666_1X18,
2965 static const struct display_timing sharp_lq101k1ly04_timing = {
2966 .pixelclock = { 60000000, 65000000, 80000000 },
2967 .hactive = { 1280, 1280, 1280 },
2968 .hfront_porch = { 20, 20, 20 },
2969 .hback_porch = { 20, 20, 20 },
2970 .hsync_len = { 10, 10, 10 },
2971 .vactive = { 800, 800, 800 },
2972 .vfront_porch = { 4, 4, 4 },
2973 .vback_porch = { 4, 4, 4 },
2974 .vsync_len = { 4, 4, 4 },
2975 .flags = DISPLAY_FLAGS_PIXDATA_POSEDGE,
2978 static const struct panel_desc sharp_lq101k1ly04 = {
2979 .timings = &sharp_lq101k1ly04_timing,
2986 .bus_format = MEDIA_BUS_FMT_RGB888_1X7X4_JEIDA,
2987 .connector_type = DRM_MODE_CONNECTOR_LVDS,
2990 static const struct display_timing sharp_lq123p1jx31_timing = {
2991 .pixelclock = { 252750000, 252750000, 266604720 },
2992 .hactive = { 2400, 2400, 2400 },
2993 .hfront_porch = { 48, 48, 48 },
2994 .hback_porch = { 80, 80, 84 },
2995 .hsync_len = { 32, 32, 32 },
2996 .vactive = { 1600, 1600, 1600 },
2997 .vfront_porch = { 3, 3, 3 },
2998 .vback_porch = { 33, 33, 120 },
2999 .vsync_len = { 10, 10, 10 },
3000 .flags = DISPLAY_FLAGS_VSYNC_LOW | DISPLAY_FLAGS_HSYNC_LOW,
3003 static const struct panel_desc sharp_lq123p1jx31 = {
3004 .timings = &sharp_lq123p1jx31_timing,
3018 static const struct display_timing sharp_ls020b1dd01d_timing = {
3019 .pixelclock = { 2000000, 4200000, 5000000 },
3020 .hactive = { 240, 240, 240 },
3021 .hfront_porch = { 66, 66, 66 },
3022 .hback_porch = { 1, 1, 1 },
3023 .hsync_len = { 1, 1, 1 },
3024 .vactive = { 160, 160, 160 },
3025 .vfront_porch = { 52, 52, 52 },
3026 .vback_porch = { 6, 6, 6 },
3027 .vsync_len = { 10, 10, 10 },
3028 .flags = DISPLAY_FLAGS_HSYNC_HIGH | DISPLAY_FLAGS_VSYNC_LOW,
3031 static const struct panel_desc sharp_ls020b1dd01d = {
3032 .timings = &sharp_ls020b1dd01d_timing,
3039 .bus_format = MEDIA_BUS_FMT_RGB565_1X16,
3040 .bus_flags = DRM_BUS_FLAG_DE_HIGH
3041 | DRM_BUS_FLAG_PIXDATA_NEGEDGE
3042 | DRM_BUS_FLAG_SHARP_SIGNALS,
3045 static const struct drm_display_mode shelly_sca07010_bfn_lnn_mode = {
3048 .hsync_start = 800 + 1,
3049 .hsync_end = 800 + 1 + 64,
3050 .htotal = 800 + 1 + 64 + 64,
3052 .vsync_start = 480 + 1,
3053 .vsync_end = 480 + 1 + 23,
3054 .vtotal = 480 + 1 + 23 + 22,
3058 static const struct panel_desc shelly_sca07010_bfn_lnn = {
3059 .modes = &shelly_sca07010_bfn_lnn_mode,
3065 .bus_format = MEDIA_BUS_FMT_RGB666_1X18,
3068 static const struct drm_display_mode starry_kr070pe2t_mode = {
3071 .hsync_start = 800 + 209,
3072 .hsync_end = 800 + 209 + 1,
3073 .htotal = 800 + 209 + 1 + 45,
3075 .vsync_start = 480 + 22,
3076 .vsync_end = 480 + 22 + 1,
3077 .vtotal = 480 + 22 + 1 + 22,
3081 static const struct panel_desc starry_kr070pe2t = {
3082 .modes = &starry_kr070pe2t_mode,
3089 .bus_format = MEDIA_BUS_FMT_RGB888_1X24,
3090 .bus_flags = DRM_BUS_FLAG_DE_HIGH | DRM_BUS_FLAG_PIXDATA_DRIVE_NEGEDGE,
3091 .connector_type = DRM_MODE_CONNECTOR_LVDS,
3094 static const struct drm_display_mode starry_kr122ea0sra_mode = {
3097 .hsync_start = 1920 + 16,
3098 .hsync_end = 1920 + 16 + 16,
3099 .htotal = 1920 + 16 + 16 + 32,
3101 .vsync_start = 1200 + 15,
3102 .vsync_end = 1200 + 15 + 2,
3103 .vtotal = 1200 + 15 + 2 + 18,
3105 .flags = DRM_MODE_FLAG_NVSYNC | DRM_MODE_FLAG_NHSYNC,
3108 static const struct panel_desc starry_kr122ea0sra = {
3109 .modes = &starry_kr122ea0sra_mode,
3116 .prepare = 10 + 200,
3118 .unprepare = 10 + 500,
3122 static const struct drm_display_mode tfc_s9700rtwv43tr_01b_mode = {
3125 .hsync_start = 800 + 39,
3126 .hsync_end = 800 + 39 + 47,
3127 .htotal = 800 + 39 + 47 + 39,
3129 .vsync_start = 480 + 13,
3130 .vsync_end = 480 + 13 + 2,
3131 .vtotal = 480 + 13 + 2 + 29,
3135 static const struct panel_desc tfc_s9700rtwv43tr_01b = {
3136 .modes = &tfc_s9700rtwv43tr_01b_mode,
3143 .bus_format = MEDIA_BUS_FMT_RGB888_1X24,
3144 .bus_flags = DRM_BUS_FLAG_DE_HIGH | DRM_BUS_FLAG_PIXDATA_POSEDGE,
3147 static const struct display_timing tianma_tm070jdhg30_timing = {
3148 .pixelclock = { 62600000, 68200000, 78100000 },
3149 .hactive = { 1280, 1280, 1280 },
3150 .hfront_porch = { 15, 64, 159 },
3151 .hback_porch = { 5, 5, 5 },
3152 .hsync_len = { 1, 1, 256 },
3153 .vactive = { 800, 800, 800 },
3154 .vfront_porch = { 3, 40, 99 },
3155 .vback_porch = { 2, 2, 2 },
3156 .vsync_len = { 1, 1, 128 },
3157 .flags = DISPLAY_FLAGS_DE_HIGH,
3160 static const struct panel_desc tianma_tm070jdhg30 = {
3161 .timings = &tianma_tm070jdhg30_timing,
3168 .bus_format = MEDIA_BUS_FMT_RGB888_1X7X4_SPWG,
3169 .connector_type = DRM_MODE_CONNECTOR_LVDS,
3172 static const struct display_timing tianma_tm070rvhg71_timing = {
3173 .pixelclock = { 27700000, 29200000, 39600000 },
3174 .hactive = { 800, 800, 800 },
3175 .hfront_porch = { 12, 40, 212 },
3176 .hback_porch = { 88, 88, 88 },
3177 .hsync_len = { 1, 1, 40 },
3178 .vactive = { 480, 480, 480 },
3179 .vfront_porch = { 1, 13, 88 },
3180 .vback_porch = { 32, 32, 32 },
3181 .vsync_len = { 1, 1, 3 },
3182 .flags = DISPLAY_FLAGS_DE_HIGH,
3185 static const struct panel_desc tianma_tm070rvhg71 = {
3186 .timings = &tianma_tm070rvhg71_timing,
3193 .bus_format = MEDIA_BUS_FMT_RGB888_1X7X4_SPWG,
3194 .connector_type = DRM_MODE_CONNECTOR_LVDS,
3197 static const struct drm_display_mode ti_nspire_cx_lcd_mode[] = {
3201 .hsync_start = 320 + 50,
3202 .hsync_end = 320 + 50 + 6,
3203 .htotal = 320 + 50 + 6 + 38,
3205 .vsync_start = 240 + 3,
3206 .vsync_end = 240 + 3 + 1,
3207 .vtotal = 240 + 3 + 1 + 17,
3209 .flags = DRM_MODE_FLAG_NVSYNC | DRM_MODE_FLAG_NHSYNC,
3213 static const struct panel_desc ti_nspire_cx_lcd_panel = {
3214 .modes = ti_nspire_cx_lcd_mode,
3221 .bus_format = MEDIA_BUS_FMT_RGB888_1X24,
3222 .bus_flags = DRM_BUS_FLAG_PIXDATA_NEGEDGE,
3225 static const struct drm_display_mode ti_nspire_classic_lcd_mode[] = {
3229 .hsync_start = 320 + 6,
3230 .hsync_end = 320 + 6 + 6,
3231 .htotal = 320 + 6 + 6 + 6,
3233 .vsync_start = 240 + 0,
3234 .vsync_end = 240 + 0 + 1,
3235 .vtotal = 240 + 0 + 1 + 0,
3237 .flags = DRM_MODE_FLAG_PHSYNC | DRM_MODE_FLAG_PVSYNC,
3241 static const struct panel_desc ti_nspire_classic_lcd_panel = {
3242 .modes = ti_nspire_classic_lcd_mode,
3244 /* The grayscale panel has 8 bit for the color .. Y (black) */
3250 /* This is the grayscale bus format */
3251 .bus_format = MEDIA_BUS_FMT_Y8_1X8,
3252 .bus_flags = DRM_BUS_FLAG_PIXDATA_POSEDGE,
3255 static const struct drm_display_mode toshiba_lt089ac29000_mode = {
3258 .hsync_start = 1280 + 192,
3259 .hsync_end = 1280 + 192 + 128,
3260 .htotal = 1280 + 192 + 128 + 64,
3262 .vsync_start = 768 + 20,
3263 .vsync_end = 768 + 20 + 7,
3264 .vtotal = 768 + 20 + 7 + 3,
3268 static const struct panel_desc toshiba_lt089ac29000 = {
3269 .modes = &toshiba_lt089ac29000_mode,
3275 .bus_format = MEDIA_BUS_FMT_RGB888_1X7X4_JEIDA,
3276 .bus_flags = DRM_BUS_FLAG_DE_HIGH | DRM_BUS_FLAG_PIXDATA_DRIVE_POSEDGE,
3277 .connector_type = DRM_MODE_CONNECTOR_LVDS,
3280 static const struct drm_display_mode tpk_f07a_0102_mode = {
3283 .hsync_start = 800 + 40,
3284 .hsync_end = 800 + 40 + 128,
3285 .htotal = 800 + 40 + 128 + 88,
3287 .vsync_start = 480 + 10,
3288 .vsync_end = 480 + 10 + 2,
3289 .vtotal = 480 + 10 + 2 + 33,
3293 static const struct panel_desc tpk_f07a_0102 = {
3294 .modes = &tpk_f07a_0102_mode,
3300 .bus_flags = DRM_BUS_FLAG_PIXDATA_DRIVE_POSEDGE,
3303 static const struct drm_display_mode tpk_f10a_0102_mode = {
3306 .hsync_start = 1024 + 176,
3307 .hsync_end = 1024 + 176 + 5,
3308 .htotal = 1024 + 176 + 5 + 88,
3310 .vsync_start = 600 + 20,
3311 .vsync_end = 600 + 20 + 5,
3312 .vtotal = 600 + 20 + 5 + 25,
3316 static const struct panel_desc tpk_f10a_0102 = {
3317 .modes = &tpk_f10a_0102_mode,
3325 static const struct display_timing urt_umsh_8596md_timing = {
3326 .pixelclock = { 33260000, 33260000, 33260000 },
3327 .hactive = { 800, 800, 800 },
3328 .hfront_porch = { 41, 41, 41 },
3329 .hback_porch = { 216 - 128, 216 - 128, 216 - 128 },
3330 .hsync_len = { 71, 128, 128 },
3331 .vactive = { 480, 480, 480 },
3332 .vfront_porch = { 10, 10, 10 },
3333 .vback_porch = { 35 - 2, 35 - 2, 35 - 2 },
3334 .vsync_len = { 2, 2, 2 },
3335 .flags = DISPLAY_FLAGS_DE_HIGH | DISPLAY_FLAGS_PIXDATA_NEGEDGE |
3336 DISPLAY_FLAGS_HSYNC_LOW | DISPLAY_FLAGS_VSYNC_LOW,
3339 static const struct panel_desc urt_umsh_8596md_lvds = {
3340 .timings = &urt_umsh_8596md_timing,
3347 .bus_format = MEDIA_BUS_FMT_RGB666_1X7X3_SPWG,
3348 .connector_type = DRM_MODE_CONNECTOR_LVDS,
3351 static const struct panel_desc urt_umsh_8596md_parallel = {
3352 .timings = &urt_umsh_8596md_timing,
3359 .bus_format = MEDIA_BUS_FMT_RGB666_1X18,
3362 static const struct drm_display_mode vl050_8048nt_c01_mode = {
3365 .hsync_start = 800 + 210,
3366 .hsync_end = 800 + 210 + 20,
3367 .htotal = 800 + 210 + 20 + 46,
3369 .vsync_start = 480 + 22,
3370 .vsync_end = 480 + 22 + 10,
3371 .vtotal = 480 + 22 + 10 + 23,
3373 .flags = DRM_MODE_FLAG_NHSYNC | DRM_MODE_FLAG_NVSYNC,
3376 static const struct panel_desc vl050_8048nt_c01 = {
3377 .modes = &vl050_8048nt_c01_mode,
3384 .bus_format = MEDIA_BUS_FMT_RGB888_1X24,
3385 .bus_flags = DRM_BUS_FLAG_DE_HIGH | DRM_BUS_FLAG_PIXDATA_POSEDGE,
3388 static const struct drm_display_mode winstar_wf35ltiacd_mode = {
3391 .hsync_start = 320 + 20,
3392 .hsync_end = 320 + 20 + 30,
3393 .htotal = 320 + 20 + 30 + 38,
3395 .vsync_start = 240 + 4,
3396 .vsync_end = 240 + 4 + 3,
3397 .vtotal = 240 + 4 + 3 + 15,
3399 .flags = DRM_MODE_FLAG_NVSYNC | DRM_MODE_FLAG_NHSYNC,
3402 static const struct panel_desc winstar_wf35ltiacd = {
3403 .modes = &winstar_wf35ltiacd_mode,
3410 .bus_format = MEDIA_BUS_FMT_RGB888_1X24,
3413 static const struct drm_display_mode arm_rtsm_mode[] = {
3417 .hsync_start = 1024 + 24,
3418 .hsync_end = 1024 + 24 + 136,
3419 .htotal = 1024 + 24 + 136 + 160,
3421 .vsync_start = 768 + 3,
3422 .vsync_end = 768 + 3 + 6,
3423 .vtotal = 768 + 3 + 6 + 29,
3425 .flags = DRM_MODE_FLAG_NVSYNC | DRM_MODE_FLAG_NHSYNC,
3429 static const struct panel_desc arm_rtsm = {
3430 .modes = arm_rtsm_mode,
3437 .bus_format = MEDIA_BUS_FMT_RGB888_1X24,
3440 static const struct of_device_id platform_of_match[] = {
3442 .compatible = "ampire,am-480272h3tmqw-t01h",
3443 .data = &ire_am_480272h3tmqw_t01h,
3445 .compatible = "ampire,am800480r3tmqwa1h",
3446 .data = &ire_am800480r3tmqwa1h,
3448 .compatible = "arm,rtsm-display",
3451 .compatible = "armadeus,st0700-adapt",
3452 .data = &armadeus_st0700_adapt,
3454 .compatible = "auo,b101aw03",
3455 .data = &auo_b101aw03,
3457 .compatible = "auo,b101ean01",
3458 .data = &auo_b101ean01,
3460 .compatible = "auo,b101xtn01",
3461 .data = &auo_b101xtn01,
3463 .compatible = "auo,b116xa01",
3464 .data = &auo_b116xak01,
3466 .compatible = "auo,b116xw03",
3467 .data = &auo_b116xw03,
3469 .compatible = "auo,b133htn01",
3470 .data = &auo_b133htn01,
3472 .compatible = "auo,b133xtn01",
3473 .data = &auo_b133xtn01,
3475 .compatible = "auo,g070vvn01",
3476 .data = &auo_g070vvn01,
3478 .compatible = "auo,g101evn010",
3479 .data = &auo_g101evn010,
3481 .compatible = "auo,g104sn02",
3482 .data = &auo_g104sn02,
3484 .compatible = "auo,g133han01",
3485 .data = &auo_g133han01,
3487 .compatible = "auo,g185han01",
3488 .data = &auo_g185han01,
3490 .compatible = "auo,p320hvn03",
3491 .data = &auo_p320hvn03,
3493 .compatible = "auo,t215hvn01",
3494 .data = &auo_t215hvn01,
3496 .compatible = "avic,tm070ddh03",
3497 .data = &avic_tm070ddh03,
3499 .compatible = "bananapi,s070wv20-ct16",
3500 .data = &bananapi_s070wv20_ct16,
3502 .compatible = "boe,hv070wsa-100",
3503 .data = &boe_hv070wsa
3505 .compatible = "boe,nv101wxmn51",
3506 .data = &boe_nv101wxmn51,
3508 .compatible = "boe,nv140fhmn49",
3509 .data = &boe_nv140fhmn49,
3511 .compatible = "cdtech,s043wq26h-ct7",
3512 .data = &cdtech_s043wq26h_ct7,
3514 .compatible = "cdtech,s070wv95-ct16",
3515 .data = &cdtech_s070wv95_ct16,
3517 .compatible = "chunghwa,claa070wp03xg",
3518 .data = &chunghwa_claa070wp03xg,
3520 .compatible = "chunghwa,claa101wa01a",
3521 .data = &chunghwa_claa101wa01a
3523 .compatible = "chunghwa,claa101wb01",
3524 .data = &chunghwa_claa101wb01
3526 .compatible = "dataimage,scf0700c48ggu18",
3527 .data = &dataimage_scf0700c48ggu18,
3529 .compatible = "dlc,dlc0700yzg-1",
3530 .data = &dlc_dlc0700yzg_1,
3532 .compatible = "dlc,dlc1010gig",
3533 .data = &dlc_dlc1010gig,
3535 .compatible = "edt,et035012dm6",
3536 .data = &edt_et035012dm6,
3538 .compatible = "edt,etm043080dh6gp",
3539 .data = &edt_etm043080dh6gp,
3541 .compatible = "edt,etm0430g0dh6",
3542 .data = &edt_etm0430g0dh6,
3544 .compatible = "edt,et057090dhu",
3545 .data = &edt_et057090dhu,
3547 .compatible = "edt,et070080dh6",
3548 .data = &edt_etm0700g0dh6,
3550 .compatible = "edt,etm0700g0dh6",
3551 .data = &edt_etm0700g0dh6,
3553 .compatible = "edt,etm0700g0bdh6",
3554 .data = &edt_etm0700g0bdh6,
3556 .compatible = "edt,etm0700g0edh6",
3557 .data = &edt_etm0700g0bdh6,
3559 .compatible = "evervision,vgg804821",
3560 .data = &evervision_vgg804821,
3562 .compatible = "foxlink,fl500wvr00-a0t",
3563 .data = &foxlink_fl500wvr00_a0t,
3565 .compatible = "frida,frd350h54004",
3566 .data = &frida_frd350h54004,
3568 .compatible = "friendlyarm,hd702e",
3569 .data = &friendlyarm_hd702e,
3571 .compatible = "giantplus,gpg482739qs5",
3572 .data = &giantplus_gpg482739qs5
3574 .compatible = "giantplus,gpm940b0",
3575 .data = &giantplus_gpm940b0,
3577 .compatible = "hannstar,hsd070pww1",
3578 .data = &hannstar_hsd070pww1,
3580 .compatible = "hannstar,hsd100pxn1",
3581 .data = &hannstar_hsd100pxn1,
3583 .compatible = "hit,tx23d38vm0caa",
3584 .data = &hitachi_tx23d38vm0caa
3586 .compatible = "innolux,at043tn24",
3587 .data = &innolux_at043tn24,
3589 .compatible = "innolux,at070tn92",
3590 .data = &innolux_at070tn92,
3592 .compatible = "innolux,g070y2-l01",
3593 .data = &innolux_g070y2_l01,
3595 .compatible = "innolux,g101ice-l01",
3596 .data = &innolux_g101ice_l01
3598 .compatible = "innolux,g121i1-l01",
3599 .data = &innolux_g121i1_l01
3601 .compatible = "innolux,g121x1-l03",
3602 .data = &innolux_g121x1_l03,
3604 .compatible = "innolux,n116bge",
3605 .data = &innolux_n116bge,
3607 .compatible = "innolux,n156bge-l21",
3608 .data = &innolux_n156bge_l21,
3610 .compatible = "innolux,p120zdg-bf1",
3611 .data = &innolux_p120zdg_bf1,
3613 .compatible = "innolux,zj070na-01p",
3614 .data = &innolux_zj070na_01p,
3616 .compatible = "koe,tx14d24vm1bpa",
3617 .data = &koe_tx14d24vm1bpa,
3619 .compatible = "koe,tx31d200vm0baa",
3620 .data = &koe_tx31d200vm0baa,
3622 .compatible = "kyo,tcg121xglp",
3623 .data = &kyo_tcg121xglp,
3625 .compatible = "lemaker,bl035-rgb-002",
3626 .data = &lemaker_bl035_rgb_002,
3628 .compatible = "lg,lb070wv8",
3629 .data = &lg_lb070wv8,
3631 .compatible = "lg,lp079qx1-sp0v",
3632 .data = &lg_lp079qx1_sp0v,
3634 .compatible = "lg,lp097qx1-spa1",
3635 .data = &lg_lp097qx1_spa1,
3637 .compatible = "lg,lp120up1",
3638 .data = &lg_lp120up1,
3640 .compatible = "lg,lp129qe",
3641 .data = &lg_lp129qe,
3643 .compatible = "logicpd,type28",
3644 .data = &logicpd_type_28,
3646 .compatible = "logictechno,lt161010-2nhc",
3647 .data = &logictechno_lt161010_2nh,
3649 .compatible = "logictechno,lt161010-2nhr",
3650 .data = &logictechno_lt161010_2nh,
3652 .compatible = "logictechno,lt170410-2whc",
3653 .data = &logictechno_lt170410_2whc,
3655 .compatible = "mitsubishi,aa070mc01-ca1",
3656 .data = &mitsubishi_aa070mc01,
3658 .compatible = "nec,nl12880bc20-05",
3659 .data = &nec_nl12880bc20_05,
3661 .compatible = "nec,nl4827hc19-05b",
3662 .data = &nec_nl4827hc19_05b,
3664 .compatible = "netron-dy,e231732",
3665 .data = &netron_dy_e231732,
3667 .compatible = "neweast,wjfh116008a",
3668 .data = &neweast_wjfh116008a,
3670 .compatible = "newhaven,nhd-4.3-480272ef-atxl",
3671 .data = &newhaven_nhd_43_480272ef_atxl,
3673 .compatible = "nlt,nl192108ac18-02d",
3674 .data = &nlt_nl192108ac18_02d,
3676 .compatible = "nvd,9128",
3679 .compatible = "okaya,rs800480t-7x0gp",
3680 .data = &okaya_rs800480t_7x0gp,
3682 .compatible = "olimex,lcd-olinuxino-43-ts",
3683 .data = &olimex_lcd_olinuxino_43ts,
3685 .compatible = "ontat,yx700wv03",
3686 .data = &ontat_yx700wv03,
3688 .compatible = "ortustech,com37h3m05dtc",
3689 .data = &ortustech_com37h3m,
3691 .compatible = "ortustech,com37h3m99dtc",
3692 .data = &ortustech_com37h3m,
3694 .compatible = "ortustech,com43h4m85ulc",
3695 .data = &ortustech_com43h4m85ulc,
3697 .compatible = "osddisplays,osd070t1718-19ts",
3698 .data = &osddisplays_osd070t1718_19ts,
3700 .compatible = "pda,91-00156-a0",
3701 .data = &pda_91_00156_a0,
3703 .compatible = "qiaodian,qd43003c0-40",
3704 .data = &qd43003c0_40,
3706 .compatible = "rocktech,rk070er9427",
3707 .data = &rocktech_rk070er9427,
3709 .compatible = "rocktech,rk101ii01d-ct",
3710 .data = &rocktech_rk101ii01d_ct,
3712 .compatible = "samsung,lsn122dl01-c01",
3713 .data = &samsung_lsn122dl01_c01,
3715 .compatible = "samsung,ltn101nt05",
3716 .data = &samsung_ltn101nt05,
3718 .compatible = "samsung,ltn140at29-301",
3719 .data = &samsung_ltn140at29_301,
3721 .compatible = "satoz,sat050at40h12r2",
3722 .data = &satoz_sat050at40h12r2,
3724 .compatible = "sharp,ld-d5116z01b",
3725 .data = &sharp_ld_d5116z01b,
3727 .compatible = "sharp,lq035q7db03",
3728 .data = &sharp_lq035q7db03,
3730 .compatible = "sharp,lq070y3dg3b",
3731 .data = &sharp_lq070y3dg3b,
3733 .compatible = "sharp,lq101k1ly04",
3734 .data = &sharp_lq101k1ly04,
3736 .compatible = "sharp,lq123p1jx31",
3737 .data = &sharp_lq123p1jx31,
3739 .compatible = "sharp,ls020b1dd01d",
3740 .data = &sharp_ls020b1dd01d,
3742 .compatible = "shelly,sca07010-bfn-lnn",
3743 .data = &shelly_sca07010_bfn_lnn,
3745 .compatible = "starry,kr070pe2t",
3746 .data = &starry_kr070pe2t,
3748 .compatible = "starry,kr122ea0sra",
3749 .data = &starry_kr122ea0sra,
3751 .compatible = "tfc,s9700rtwv43tr-01b",
3752 .data = &tfc_s9700rtwv43tr_01b,
3754 .compatible = "tianma,tm070jdhg30",
3755 .data = &tianma_tm070jdhg30,
3757 .compatible = "tianma,tm070rvhg71",
3758 .data = &tianma_tm070rvhg71,
3760 .compatible = "ti,nspire-cx-lcd-panel",
3761 .data = &ti_nspire_cx_lcd_panel,
3763 .compatible = "ti,nspire-classic-lcd-panel",
3764 .data = &ti_nspire_classic_lcd_panel,
3766 .compatible = "toshiba,lt089ac29000",
3767 .data = &toshiba_lt089ac29000,
3769 .compatible = "tpk,f07a-0102",
3770 .data = &tpk_f07a_0102,
3772 .compatible = "tpk,f10a-0102",
3773 .data = &tpk_f10a_0102,
3775 .compatible = "urt,umsh-8596md-t",
3776 .data = &urt_umsh_8596md_parallel,
3778 .compatible = "urt,umsh-8596md-1t",
3779 .data = &urt_umsh_8596md_parallel,
3781 .compatible = "urt,umsh-8596md-7t",
3782 .data = &urt_umsh_8596md_parallel,
3784 .compatible = "urt,umsh-8596md-11t",
3785 .data = &urt_umsh_8596md_lvds,
3787 .compatible = "urt,umsh-8596md-19t",
3788 .data = &urt_umsh_8596md_lvds,
3790 .compatible = "urt,umsh-8596md-20t",
3791 .data = &urt_umsh_8596md_parallel,
3793 .compatible = "vxt,vl050-8048nt-c01",
3794 .data = &vl050_8048nt_c01,
3796 .compatible = "winstar,wf35ltiacd",
3797 .data = &winstar_wf35ltiacd,
3799 /* Must be the last entry */
3800 .compatible = "panel-dpi",
3806 MODULE_DEVICE_TABLE(of, platform_of_match);
3808 static int panel_simple_platform_probe(struct platform_device *pdev)
3810 const struct of_device_id *id;
3812 id = of_match_node(platform_of_match, pdev->dev.of_node);
3816 return panel_simple_probe(&pdev->dev, id->data);
3819 static int panel_simple_platform_remove(struct platform_device *pdev)
3821 return panel_simple_remove(&pdev->dev);
3824 static void panel_simple_platform_shutdown(struct platform_device *pdev)
3826 panel_simple_shutdown(&pdev->dev);
3829 static struct platform_driver panel_simple_platform_driver = {
3831 .name = "panel-simple",
3832 .of_match_table = platform_of_match,
3834 .probe = panel_simple_platform_probe,
3835 .remove = panel_simple_platform_remove,
3836 .shutdown = panel_simple_platform_shutdown,
3839 struct panel_desc_dsi {
3840 struct panel_desc desc;
3842 unsigned long flags;
3843 enum mipi_dsi_pixel_format format;
3847 static const struct drm_display_mode auo_b080uan01_mode = {
3850 .hsync_start = 1200 + 62,
3851 .hsync_end = 1200 + 62 + 4,
3852 .htotal = 1200 + 62 + 4 + 62,
3854 .vsync_start = 1920 + 9,
3855 .vsync_end = 1920 + 9 + 2,
3856 .vtotal = 1920 + 9 + 2 + 8,
3860 static const struct panel_desc_dsi auo_b080uan01 = {
3862 .modes = &auo_b080uan01_mode,
3870 .flags = MIPI_DSI_MODE_VIDEO | MIPI_DSI_CLOCK_NON_CONTINUOUS,
3871 .format = MIPI_DSI_FMT_RGB888,
3875 static const struct drm_display_mode boe_tv080wum_nl0_mode = {
3878 .hsync_start = 1200 + 120,
3879 .hsync_end = 1200 + 120 + 20,
3880 .htotal = 1200 + 120 + 20 + 21,
3882 .vsync_start = 1920 + 21,
3883 .vsync_end = 1920 + 21 + 3,
3884 .vtotal = 1920 + 21 + 3 + 18,
3886 .flags = DRM_MODE_FLAG_NVSYNC | DRM_MODE_FLAG_NHSYNC,
3889 static const struct panel_desc_dsi boe_tv080wum_nl0 = {
3891 .modes = &boe_tv080wum_nl0_mode,
3898 .flags = MIPI_DSI_MODE_VIDEO |
3899 MIPI_DSI_MODE_VIDEO_BURST |
3900 MIPI_DSI_MODE_VIDEO_SYNC_PULSE,
3901 .format = MIPI_DSI_FMT_RGB888,
3905 static const struct drm_display_mode lg_ld070wx3_sl01_mode = {
3908 .hsync_start = 800 + 32,
3909 .hsync_end = 800 + 32 + 1,
3910 .htotal = 800 + 32 + 1 + 57,
3912 .vsync_start = 1280 + 28,
3913 .vsync_end = 1280 + 28 + 1,
3914 .vtotal = 1280 + 28 + 1 + 14,
3918 static const struct panel_desc_dsi lg_ld070wx3_sl01 = {
3920 .modes = &lg_ld070wx3_sl01_mode,
3928 .flags = MIPI_DSI_MODE_VIDEO | MIPI_DSI_CLOCK_NON_CONTINUOUS,
3929 .format = MIPI_DSI_FMT_RGB888,
3933 static const struct drm_display_mode lg_lh500wx1_sd03_mode = {
3936 .hsync_start = 720 + 12,
3937 .hsync_end = 720 + 12 + 4,
3938 .htotal = 720 + 12 + 4 + 112,
3940 .vsync_start = 1280 + 8,
3941 .vsync_end = 1280 + 8 + 4,
3942 .vtotal = 1280 + 8 + 4 + 12,
3946 static const struct panel_desc_dsi lg_lh500wx1_sd03 = {
3948 .modes = &lg_lh500wx1_sd03_mode,
3956 .flags = MIPI_DSI_MODE_VIDEO,
3957 .format = MIPI_DSI_FMT_RGB888,
3961 static const struct drm_display_mode panasonic_vvx10f004b00_mode = {
3964 .hsync_start = 1920 + 154,
3965 .hsync_end = 1920 + 154 + 16,
3966 .htotal = 1920 + 154 + 16 + 32,
3968 .vsync_start = 1200 + 17,
3969 .vsync_end = 1200 + 17 + 2,
3970 .vtotal = 1200 + 17 + 2 + 16,
3974 static const struct panel_desc_dsi panasonic_vvx10f004b00 = {
3976 .modes = &panasonic_vvx10f004b00_mode,
3984 .flags = MIPI_DSI_MODE_VIDEO | MIPI_DSI_MODE_VIDEO_SYNC_PULSE |
3985 MIPI_DSI_CLOCK_NON_CONTINUOUS,
3986 .format = MIPI_DSI_FMT_RGB888,
3990 static const struct drm_display_mode lg_acx467akm_7_mode = {
3993 .hsync_start = 1080 + 2,
3994 .hsync_end = 1080 + 2 + 2,
3995 .htotal = 1080 + 2 + 2 + 2,
3997 .vsync_start = 1920 + 2,
3998 .vsync_end = 1920 + 2 + 2,
3999 .vtotal = 1920 + 2 + 2 + 2,
4003 static const struct panel_desc_dsi lg_acx467akm_7 = {
4005 .modes = &lg_acx467akm_7_mode,
4014 .format = MIPI_DSI_FMT_RGB888,
4018 static const struct drm_display_mode osd101t2045_53ts_mode = {
4021 .hsync_start = 1920 + 112,
4022 .hsync_end = 1920 + 112 + 16,
4023 .htotal = 1920 + 112 + 16 + 32,
4025 .vsync_start = 1200 + 16,
4026 .vsync_end = 1200 + 16 + 2,
4027 .vtotal = 1200 + 16 + 2 + 16,
4029 .flags = DRM_MODE_FLAG_NHSYNC | DRM_MODE_FLAG_NVSYNC,
4032 static const struct panel_desc_dsi osd101t2045_53ts = {
4034 .modes = &osd101t2045_53ts_mode,
4042 .flags = MIPI_DSI_MODE_VIDEO | MIPI_DSI_MODE_VIDEO_BURST |
4043 MIPI_DSI_MODE_VIDEO_SYNC_PULSE |
4044 MIPI_DSI_MODE_EOT_PACKET,
4045 .format = MIPI_DSI_FMT_RGB888,
4049 static const struct of_device_id dsi_of_match[] = {
4051 .compatible = "auo,b080uan01",
4052 .data = &auo_b080uan01
4054 .compatible = "boe,tv080wum-nl0",
4055 .data = &boe_tv080wum_nl0
4057 .compatible = "lg,ld070wx3-sl01",
4058 .data = &lg_ld070wx3_sl01
4060 .compatible = "lg,lh500wx1-sd03",
4061 .data = &lg_lh500wx1_sd03
4063 .compatible = "panasonic,vvx10f004b00",
4064 .data = &panasonic_vvx10f004b00
4066 .compatible = "lg,acx467akm-7",
4067 .data = &lg_acx467akm_7
4069 .compatible = "osddisplays,osd101t2045-53ts",
4070 .data = &osd101t2045_53ts
4075 MODULE_DEVICE_TABLE(of, dsi_of_match);
4077 static int panel_simple_dsi_probe(struct mipi_dsi_device *dsi)
4079 const struct panel_desc_dsi *desc;
4080 const struct of_device_id *id;
4083 id = of_match_node(dsi_of_match, dsi->dev.of_node);
4089 err = panel_simple_probe(&dsi->dev, &desc->desc);
4093 dsi->mode_flags = desc->flags;
4094 dsi->format = desc->format;
4095 dsi->lanes = desc->lanes;
4097 err = mipi_dsi_attach(dsi);
4099 struct panel_simple *panel = dev_get_drvdata(&dsi->dev);
4101 drm_panel_remove(&panel->base);
4107 static int panel_simple_dsi_remove(struct mipi_dsi_device *dsi)
4111 err = mipi_dsi_detach(dsi);
4113 dev_err(&dsi->dev, "failed to detach from DSI host: %d\n", err);
4115 return panel_simple_remove(&dsi->dev);
4118 static void panel_simple_dsi_shutdown(struct mipi_dsi_device *dsi)
4120 panel_simple_shutdown(&dsi->dev);
4123 static struct mipi_dsi_driver panel_simple_dsi_driver = {
4125 .name = "panel-simple-dsi",
4126 .of_match_table = dsi_of_match,
4128 .probe = panel_simple_dsi_probe,
4129 .remove = panel_simple_dsi_remove,
4130 .shutdown = panel_simple_dsi_shutdown,
4133 static int __init panel_simple_init(void)
4137 err = platform_driver_register(&panel_simple_platform_driver);
4141 if (IS_ENABLED(CONFIG_DRM_MIPI_DSI)) {
4142 err = mipi_dsi_driver_register(&panel_simple_dsi_driver);
4149 module_init(panel_simple_init);
4151 static void __exit panel_simple_exit(void)
4153 if (IS_ENABLED(CONFIG_DRM_MIPI_DSI))
4154 mipi_dsi_driver_unregister(&panel_simple_dsi_driver);
4156 platform_driver_unregister(&panel_simple_platform_driver);
4158 module_exit(panel_simple_exit);
4161 MODULE_DESCRIPTION("DRM Driver for Simple Panels");
4162 MODULE_LICENSE("GPL and additional rights");