Blame view

drivers/gpu/drm/panel/panel-simple.c 115 KB
280921de7   Thierry Reding   drm/panel: Add si...
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
  /*
   * Copyright (C) 2013, NVIDIA Corporation.  All rights reserved.
   *
   * Permission is hereby granted, free of charge, to any person obtaining a
   * copy of this software and associated documentation files (the "Software"),
   * to deal in the Software without restriction, including without limitation
   * the rights to use, copy, modify, merge, publish, distribute, sub license,
   * and/or sell copies of the Software, and to permit persons to whom the
   * Software is furnished to do so, subject to the following conditions:
   *
   * The above copyright notice and this permission notice (including the
   * next paragraph) shall be included in all copies or substantial portions
   * of the Software.
   *
   * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
   * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
   * FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT. IN NO EVENT SHALL
   * THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
   * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
   * FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
   * DEALINGS IN THE SOFTWARE.
   */
cb23eae3e   Sam Ravnborg   drm/panel: drop d...
23
  #include <linux/delay.h>
cfdf0549f   Alexandre Courbot   drm/panel: use gp...
24
  #include <linux/gpio/consumer.h>
48834e608   Douglas Anderson   drm/panel-simple:...
25
  #include <linux/iopoll.h>
280921de7   Thierry Reding   drm/panel: Add si...
26
  #include <linux/module.h>
280921de7   Thierry Reding   drm/panel: Add si...
27
28
29
  #include <linux/of_platform.h>
  #include <linux/platform_device.h>
  #include <linux/regulator/consumer.h>
cb23eae3e   Sam Ravnborg   drm/panel: drop d...
30
  #include <video/display_timing.h>
b8a2948fa   Sean Paul   drm/panel: simple...
31
  #include <video/of_display_timing.h>
cb23eae3e   Sam Ravnborg   drm/panel: drop d...
32
  #include <video/videomode.h>
280921de7   Thierry Reding   drm/panel: Add si...
33
  #include <drm/drm_crtc.h>
cb23eae3e   Sam Ravnborg   drm/panel: drop d...
34
  #include <drm/drm_device.h>
210fcd9d9   Thierry Reding   drm/panel: Add su...
35
  #include <drm/drm_mipi_dsi.h>
280921de7   Thierry Reding   drm/panel: Add si...
36
  #include <drm/drm_panel.h>
e362cc6a2   Douglas Anderson   drm/panel: simple...
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
  /**
   * @modes: Pointer to array of fixed modes appropriate for this panel.  If
   *         only one mode then this can just be the address of this the mode.
   *         NOTE: cannot be used with "timings" and also if this is specified
   *         then you cannot override the mode in the device tree.
   * @num_modes: Number of elements in modes array.
   * @timings: Pointer to array of display timings.  NOTE: cannot be used with
   *           "modes" and also these will be used to validate a device tree
   *           override if one is present.
   * @num_timings: Number of elements in timings array.
   * @bpc: Bits per color.
   * @size: Structure containing the physical size of this panel.
   * @delay: Structure containing various delay values for this panel.
   * @bus_format: See MEDIA_BUS_FMT_... defines.
   * @bus_flags: See DRM_BUS_FLAG_... defines.
   */
280921de7   Thierry Reding   drm/panel: Add si...
53
54
55
  struct panel_desc {
  	const struct drm_display_mode *modes;
  	unsigned int num_modes;
a5d3e6251   Philipp Zabel   drm/panel: simple...
56
57
  	const struct display_timing *timings;
  	unsigned int num_timings;
280921de7   Thierry Reding   drm/panel: Add si...
58

0208d5111   Stéphane Marchesin   drm/panel: simple...
59
  	unsigned int bpc;
85533e3b3   Ulrich Ölmann   drm/panel: add ke...
60
61
62
63
  	/**
  	 * @width: width (in millimeters) of the panel's active display area
  	 * @height: height (in millimeters) of the panel's active display area
  	 */
280921de7   Thierry Reding   drm/panel: Add si...
64
65
66
67
  	struct {
  		unsigned int width;
  		unsigned int height;
  	} size;
f673c37ec   Ajay Kumar   drm/panel: simple...
68
69
70
71
  
  	/**
  	 * @prepare: the time (in milliseconds) that it takes for the panel to
  	 *           become ready and start receiving video data
2ed3e9510   Douglas Anderson   drm/panel: simple...
72
73
  	 * @hpd_absent_delay: Add this to the prepare delay if we know Hot
  	 *                    Plug Detect isn't used.
f673c37ec   Ajay Kumar   drm/panel: simple...
74
75
76
77
78
79
80
81
82
83
  	 * @enable: the time (in milliseconds) that it takes for the panel to
  	 *          display the first valid frame after starting to receive
  	 *          video data
  	 * @disable: the time (in milliseconds) that it takes for the panel to
  	 *           turn the display off (no content is visible)
  	 * @unprepare: the time (in milliseconds) that it takes for the panel
  	 *             to power itself down completely
  	 */
  	struct {
  		unsigned int prepare;
2ed3e9510   Douglas Anderson   drm/panel: simple...
84
  		unsigned int hpd_absent_delay;
f673c37ec   Ajay Kumar   drm/panel: simple...
85
86
87
88
  		unsigned int enable;
  		unsigned int disable;
  		unsigned int unprepare;
  	} delay;
795f7ab3a   Boris Brezillon   drm: panel: simpl...
89
90
  
  	u32 bus_format;
f0aa08387   Stefan Agner   drm: introduce bu...
91
  	u32 bus_flags;
9a2654c0f   Laurent Pinchart   drm/panel: Add an...
92
  	int connector_type;
280921de7   Thierry Reding   drm/panel: Add si...
93
  };
280921de7   Thierry Reding   drm/panel: Add si...
94
95
  struct panel_simple {
  	struct drm_panel base;
613a633e7   Ajay Kumar   drm/panel: simple...
96
  	bool prepared;
280921de7   Thierry Reding   drm/panel: Add si...
97
  	bool enabled;
2ed3e9510   Douglas Anderson   drm/panel: simple...
98
  	bool no_hpd;
280921de7   Thierry Reding   drm/panel: Add si...
99
100
  
  	const struct panel_desc *desc;
280921de7   Thierry Reding   drm/panel: Add si...
101
102
  	struct regulator *supply;
  	struct i2c_adapter *ddc;
cfdf0549f   Alexandre Courbot   drm/panel: use gp...
103
  	struct gpio_desc *enable_gpio;
48834e608   Douglas Anderson   drm/panel-simple:...
104
  	struct gpio_desc *hpd_gpio;
b8a2948fa   Sean Paul   drm/panel: simple...
105
106
  
  	struct drm_display_mode override_mode;
5759c9674   Dmitry Osipenko   drm/panel-simple:...
107
108
  
  	enum drm_panel_orientation orientation;
280921de7   Thierry Reding   drm/panel: Add si...
109
110
111
112
113
114
  };
  
  static inline struct panel_simple *to_panel_simple(struct drm_panel *panel)
  {
  	return container_of(panel, struct panel_simple, base);
  }
0ce8ddd8e   Sam Ravnborg   drm/panel: add dr...
115
116
  static unsigned int panel_simple_get_timings_modes(struct panel_simple *panel,
  						   struct drm_connector *connector)
280921de7   Thierry Reding   drm/panel: Add si...
117
  {
280921de7   Thierry Reding   drm/panel: Add si...
118
119
  	struct drm_display_mode *mode;
  	unsigned int i, num = 0;
a5d3e6251   Philipp Zabel   drm/panel: simple...
120
121
122
123
124
  	for (i = 0; i < panel->desc->num_timings; i++) {
  		const struct display_timing *dt = &panel->desc->timings[i];
  		struct videomode vm;
  
  		videomode_from_timing(dt, &vm);
aa6c43644   Sam Ravnborg   drm/panel: drop d...
125
  		mode = drm_mode_create(connector->dev);
a5d3e6251   Philipp Zabel   drm/panel: simple...
126
  		if (!mode) {
aa6c43644   Sam Ravnborg   drm/panel: drop d...
127
128
  			dev_err(panel->base.dev, "failed to add mode %ux%u
  ",
a5d3e6251   Philipp Zabel   drm/panel: simple...
129
130
131
132
133
  				dt->hactive.typ, dt->vactive.typ);
  			continue;
  		}
  
  		drm_display_mode_from_videomode(&vm, mode);
cda553725   Boris Brezillon   drm/panel: simple...
134
135
  
  		mode->type |= DRM_MODE_TYPE_DRIVER;
230c5b442   Chen-Yu Tsai   drm/panel: simple...
136
  		if (panel->desc->num_timings == 1)
cda553725   Boris Brezillon   drm/panel: simple...
137
  			mode->type |= DRM_MODE_TYPE_PREFERRED;
a5d3e6251   Philipp Zabel   drm/panel: simple...
138
139
140
  		drm_mode_probed_add(connector, mode);
  		num++;
  	}
b8a2948fa   Sean Paul   drm/panel: simple...
141
142
  	return num;
  }
0ce8ddd8e   Sam Ravnborg   drm/panel: add dr...
143
144
  static unsigned int panel_simple_get_display_modes(struct panel_simple *panel,
  						   struct drm_connector *connector)
b8a2948fa   Sean Paul   drm/panel: simple...
145
  {
b8a2948fa   Sean Paul   drm/panel: simple...
146
147
  	struct drm_display_mode *mode;
  	unsigned int i, num = 0;
280921de7   Thierry Reding   drm/panel: Add si...
148
149
  	for (i = 0; i < panel->desc->num_modes; i++) {
  		const struct drm_display_mode *m = &panel->desc->modes[i];
aa6c43644   Sam Ravnborg   drm/panel: drop d...
150
  		mode = drm_mode_duplicate(connector->dev, m);
280921de7   Thierry Reding   drm/panel: Add si...
151
  		if (!mode) {
aa6c43644   Sam Ravnborg   drm/panel: drop d...
152
153
  			dev_err(panel->base.dev, "failed to add mode %ux%u@%u
  ",
0425662fd   Ville Syrjälä   drm: Nuke mode->v...
154
155
  				m->hdisplay, m->vdisplay,
  				drm_mode_vrefresh(m));
280921de7   Thierry Reding   drm/panel: Add si...
156
157
  			continue;
  		}
cda553725   Boris Brezillon   drm/panel: simple...
158
159
160
161
  		mode->type |= DRM_MODE_TYPE_DRIVER;
  
  		if (panel->desc->num_modes == 1)
  			mode->type |= DRM_MODE_TYPE_PREFERRED;
280921de7   Thierry Reding   drm/panel: Add si...
162
163
164
165
166
  		drm_mode_set_name(mode);
  
  		drm_mode_probed_add(connector, mode);
  		num++;
  	}
b8a2948fa   Sean Paul   drm/panel: simple...
167
168
  	return num;
  }
0ce8ddd8e   Sam Ravnborg   drm/panel: add dr...
169
170
  static int panel_simple_get_non_edid_modes(struct panel_simple *panel,
  					   struct drm_connector *connector)
b8a2948fa   Sean Paul   drm/panel: simple...
171
  {
b8a2948fa   Sean Paul   drm/panel: simple...
172
173
174
175
176
177
178
179
  	struct drm_display_mode *mode;
  	bool has_override = panel->override_mode.type;
  	unsigned int num = 0;
  
  	if (!panel->desc)
  		return 0;
  
  	if (has_override) {
aa6c43644   Sam Ravnborg   drm/panel: drop d...
180
181
  		mode = drm_mode_duplicate(connector->dev,
  					  &panel->override_mode);
b8a2948fa   Sean Paul   drm/panel: simple...
182
183
184
185
  		if (mode) {
  			drm_mode_probed_add(connector, mode);
  			num = 1;
  		} else {
aa6c43644   Sam Ravnborg   drm/panel: drop d...
186
187
  			dev_err(panel->base.dev, "failed to add override mode
  ");
b8a2948fa   Sean Paul   drm/panel: simple...
188
189
190
191
192
  		}
  	}
  
  	/* Only add timings if override was not there or failed to validate */
  	if (num == 0 && panel->desc->num_timings)
0ce8ddd8e   Sam Ravnborg   drm/panel: add dr...
193
  		num = panel_simple_get_timings_modes(panel, connector);
b8a2948fa   Sean Paul   drm/panel: simple...
194
195
196
197
198
199
200
201
202
  
  	/*
  	 * Only add fixed modes if timings/override added no mode.
  	 *
  	 * We should only ever have either the display timings specified
  	 * or a fixed mode. Anything else is rather bogus.
  	 */
  	WARN_ON(panel->desc->num_timings && panel->desc->num_modes);
  	if (num == 0)
0ce8ddd8e   Sam Ravnborg   drm/panel: add dr...
203
  		num = panel_simple_get_display_modes(panel, connector);
b8a2948fa   Sean Paul   drm/panel: simple...
204

0208d5111   Stéphane Marchesin   drm/panel: simple...
205
  	connector->display_info.bpc = panel->desc->bpc;
280921de7   Thierry Reding   drm/panel: Add si...
206
207
  	connector->display_info.width_mm = panel->desc->size.width;
  	connector->display_info.height_mm = panel->desc->size.height;
795f7ab3a   Boris Brezillon   drm: panel: simpl...
208
209
210
  	if (panel->desc->bus_format)
  		drm_display_info_set_bus_formats(&connector->display_info,
  						 &panel->desc->bus_format, 1);
f0aa08387   Stefan Agner   drm: introduce bu...
211
  	connector->display_info.bus_flags = panel->desc->bus_flags;
280921de7   Thierry Reding   drm/panel: Add si...
212
213
214
215
216
217
218
219
220
221
  
  	return num;
  }
  
  static int panel_simple_disable(struct drm_panel *panel)
  {
  	struct panel_simple *p = to_panel_simple(panel);
  
  	if (!p->enabled)
  		return 0;
f673c37ec   Ajay Kumar   drm/panel: simple...
222
223
  	if (p->desc->delay.disable)
  		msleep(p->desc->delay.disable);
280921de7   Thierry Reding   drm/panel: Add si...
224
225
226
227
  	p->enabled = false;
  
  	return 0;
  }
c0e1d1706   Ajay Kumar   drm/panel: simple...
228
229
  static int panel_simple_unprepare(struct drm_panel *panel)
  {
613a633e7   Ajay Kumar   drm/panel: simple...
230
231
232
233
  	struct panel_simple *p = to_panel_simple(panel);
  
  	if (!p->prepared)
  		return 0;
756b918d0   Fabio Estevam   drm/panel: simple...
234
  	gpiod_set_value_cansleep(p->enable_gpio, 0);
613a633e7   Ajay Kumar   drm/panel: simple...
235
236
  
  	regulator_disable(p->supply);
f673c37ec   Ajay Kumar   drm/panel: simple...
237
238
  	if (p->desc->delay.unprepare)
  		msleep(p->desc->delay.unprepare);
613a633e7   Ajay Kumar   drm/panel: simple...
239
  	p->prepared = false;
c0e1d1706   Ajay Kumar   drm/panel: simple...
240

c0e1d1706   Ajay Kumar   drm/panel: simple...
241
242
  	return 0;
  }
48834e608   Douglas Anderson   drm/panel-simple:...
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
  static int panel_simple_get_hpd_gpio(struct device *dev,
  				     struct panel_simple *p, bool from_probe)
  {
  	int err;
  
  	p->hpd_gpio = devm_gpiod_get_optional(dev, "hpd", GPIOD_IN);
  	if (IS_ERR(p->hpd_gpio)) {
  		err = PTR_ERR(p->hpd_gpio);
  
  		/*
  		 * If we're called from probe we won't consider '-EPROBE_DEFER'
  		 * to be an error--we'll leave the error code in "hpd_gpio".
  		 * When we try to use it we'll try again.  This allows for
  		 * circular dependencies where the component providing the
  		 * hpd gpio needs the panel to init before probing.
  		 */
  		if (err != -EPROBE_DEFER || !from_probe) {
  			dev_err(dev, "failed to get 'hpd' GPIO: %d
  ", err);
  			return err;
  		}
  	}
  
  	return 0;
  }
613a633e7   Ajay Kumar   drm/panel: simple...
268
  static int panel_simple_prepare(struct drm_panel *panel)
280921de7   Thierry Reding   drm/panel: Add si...
269
270
  {
  	struct panel_simple *p = to_panel_simple(panel);
2ed3e9510   Douglas Anderson   drm/panel: simple...
271
  	unsigned int delay;
280921de7   Thierry Reding   drm/panel: Add si...
272
  	int err;
48834e608   Douglas Anderson   drm/panel-simple:...
273
  	int hpd_asserted;
280921de7   Thierry Reding   drm/panel: Add si...
274

613a633e7   Ajay Kumar   drm/panel: simple...
275
  	if (p->prepared)
280921de7   Thierry Reding   drm/panel: Add si...
276
277
278
279
280
281
282
283
  		return 0;
  
  	err = regulator_enable(p->supply);
  	if (err < 0) {
  		dev_err(panel->dev, "failed to enable supply: %d
  ", err);
  		return err;
  	}
756b918d0   Fabio Estevam   drm/panel: simple...
284
  	gpiod_set_value_cansleep(p->enable_gpio, 1);
280921de7   Thierry Reding   drm/panel: Add si...
285

2ed3e9510   Douglas Anderson   drm/panel: simple...
286
287
288
289
290
  	delay = p->desc->delay.prepare;
  	if (p->no_hpd)
  		delay += p->desc->delay.hpd_absent_delay;
  	if (delay)
  		msleep(delay);
f673c37ec   Ajay Kumar   drm/panel: simple...
291

48834e608   Douglas Anderson   drm/panel-simple:...
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
  	if (p->hpd_gpio) {
  		if (IS_ERR(p->hpd_gpio)) {
  			err = panel_simple_get_hpd_gpio(panel->dev, p, false);
  			if (err)
  				return err;
  		}
  
  		err = readx_poll_timeout(gpiod_get_value_cansleep, p->hpd_gpio,
  					 hpd_asserted, hpd_asserted,
  					 1000, 2000000);
  		if (hpd_asserted < 0)
  			err = hpd_asserted;
  
  		if (err) {
  			dev_err(panel->dev,
  				"error waiting for hpd GPIO: %d
  ", err);
  			return err;
  		}
  	}
613a633e7   Ajay Kumar   drm/panel: simple...
312
313
314
315
316
317
318
319
320
321
322
  	p->prepared = true;
  
  	return 0;
  }
  
  static int panel_simple_enable(struct drm_panel *panel)
  {
  	struct panel_simple *p = to_panel_simple(panel);
  
  	if (p->enabled)
  		return 0;
f673c37ec   Ajay Kumar   drm/panel: simple...
323
324
  	if (p->desc->delay.enable)
  		msleep(p->desc->delay.enable);
280921de7   Thierry Reding   drm/panel: Add si...
325
326
327
328
  	p->enabled = true;
  
  	return 0;
  }
0ce8ddd8e   Sam Ravnborg   drm/panel: add dr...
329
330
  static int panel_simple_get_modes(struct drm_panel *panel,
  				  struct drm_connector *connector)
280921de7   Thierry Reding   drm/panel: Add si...
331
332
333
334
335
336
  {
  	struct panel_simple *p = to_panel_simple(panel);
  	int num = 0;
  
  	/* probe EDID if a DDC bus is available */
  	if (p->ddc) {
0ce8ddd8e   Sam Ravnborg   drm/panel: add dr...
337
338
339
  		struct edid *edid = drm_get_edid(connector, p->ddc);
  
  		drm_connector_update_edid_property(connector, edid);
280921de7   Thierry Reding   drm/panel: Add si...
340
  		if (edid) {
0ce8ddd8e   Sam Ravnborg   drm/panel: add dr...
341
  			num += drm_add_edid_modes(connector, edid);
280921de7   Thierry Reding   drm/panel: Add si...
342
343
344
345
346
  			kfree(edid);
  		}
  	}
  
  	/* add hard-coded panel modes */
0ce8ddd8e   Sam Ravnborg   drm/panel: add dr...
347
  	num += panel_simple_get_non_edid_modes(p, connector);
280921de7   Thierry Reding   drm/panel: Add si...
348

5759c9674   Dmitry Osipenko   drm/panel-simple:...
349
350
  	/* set up connector's "panel orientation" property */
  	drm_connector_set_panel_orientation(connector, p->orientation);
280921de7   Thierry Reding   drm/panel: Add si...
351
352
  	return num;
  }
a5d3e6251   Philipp Zabel   drm/panel: simple...
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
  static int panel_simple_get_timings(struct drm_panel *panel,
  				    unsigned int num_timings,
  				    struct display_timing *timings)
  {
  	struct panel_simple *p = to_panel_simple(panel);
  	unsigned int i;
  
  	if (p->desc->num_timings < num_timings)
  		num_timings = p->desc->num_timings;
  
  	if (timings)
  		for (i = 0; i < num_timings; i++)
  			timings[i] = p->desc->timings[i];
  
  	return p->desc->num_timings;
  }
280921de7   Thierry Reding   drm/panel: Add si...
369
370
  static const struct drm_panel_funcs panel_simple_funcs = {
  	.disable = panel_simple_disable,
c0e1d1706   Ajay Kumar   drm/panel: simple...
371
372
  	.unprepare = panel_simple_unprepare,
  	.prepare = panel_simple_prepare,
280921de7   Thierry Reding   drm/panel: Add si...
373
374
  	.enable = panel_simple_enable,
  	.get_modes = panel_simple_get_modes,
a5d3e6251   Philipp Zabel   drm/panel: simple...
375
  	.get_timings = panel_simple_get_timings,
280921de7   Thierry Reding   drm/panel: Add si...
376
  };
4a1d0dbc8   Sam Ravnborg   drm/panel: simple...
377
378
379
380
381
382
383
384
385
386
  static struct panel_desc panel_dpi;
  
  static int panel_dpi_probe(struct device *dev,
  			   struct panel_simple *panel)
  {
  	struct display_timing *timing;
  	const struct device_node *np;
  	struct panel_desc *desc;
  	unsigned int bus_flags;
  	struct videomode vm;
4a1d0dbc8   Sam Ravnborg   drm/panel: simple...
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
  	int ret;
  
  	np = dev->of_node;
  	desc = devm_kzalloc(dev, sizeof(*desc), GFP_KERNEL);
  	if (!desc)
  		return -ENOMEM;
  
  	timing = devm_kzalloc(dev, sizeof(*timing), GFP_KERNEL);
  	if (!timing)
  		return -ENOMEM;
  
  	ret = of_get_display_timing(np, "panel-timing", timing);
  	if (ret < 0) {
  		dev_err(dev, "%pOF: no panel-timing node found for \"panel-dpi\" binding
  ",
  			np);
  		return ret;
  	}
  
  	desc->timings = timing;
  	desc->num_timings = 1;
  
  	of_property_read_u32(np, "width-mm", &desc->size.width);
  	of_property_read_u32(np, "height-mm", &desc->size.height);
4a1d0dbc8   Sam Ravnborg   drm/panel: simple...
411
412
413
414
415
416
417
418
419
420
421
422
423
  	/* Extract bus_flags from display_timing */
  	bus_flags = 0;
  	vm.flags = timing->flags;
  	drm_bus_flags_from_videomode(&vm, &bus_flags);
  	desc->bus_flags = bus_flags;
  
  	/* We do not know the connector for the DT node, so guess it */
  	desc->connector_type = DRM_MODE_CONNECTOR_DPI;
  
  	panel->desc = desc;
  
  	return 0;
  }
b8a2948fa   Sean Paul   drm/panel: simple...
424
425
426
  #define PANEL_SIMPLE_BOUNDS_CHECK(to_check, bounds, field) \
  	(to_check->field.typ >= bounds->field.min && \
  	 to_check->field.typ <= bounds->field.max)
e362cc6a2   Douglas Anderson   drm/panel: simple...
427
428
429
  static void panel_simple_parse_panel_timing_node(struct device *dev,
  						 struct panel_simple *panel,
  						 const struct display_timing *ot)
b8a2948fa   Sean Paul   drm/panel: simple...
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
  {
  	const struct panel_desc *desc = panel->desc;
  	struct videomode vm;
  	unsigned int i;
  
  	if (WARN_ON(desc->num_modes)) {
  		dev_err(dev, "Reject override mode: panel has a fixed mode
  ");
  		return;
  	}
  	if (WARN_ON(!desc->num_timings)) {
  		dev_err(dev, "Reject override mode: no timings specified
  ");
  		return;
  	}
  
  	for (i = 0; i < panel->desc->num_timings; i++) {
  		const struct display_timing *dt = &panel->desc->timings[i];
  
  		if (!PANEL_SIMPLE_BOUNDS_CHECK(ot, dt, hactive) ||
  		    !PANEL_SIMPLE_BOUNDS_CHECK(ot, dt, hfront_porch) ||
  		    !PANEL_SIMPLE_BOUNDS_CHECK(ot, dt, hback_porch) ||
  		    !PANEL_SIMPLE_BOUNDS_CHECK(ot, dt, hsync_len) ||
  		    !PANEL_SIMPLE_BOUNDS_CHECK(ot, dt, vactive) ||
  		    !PANEL_SIMPLE_BOUNDS_CHECK(ot, dt, vfront_porch) ||
  		    !PANEL_SIMPLE_BOUNDS_CHECK(ot, dt, vback_porch) ||
  		    !PANEL_SIMPLE_BOUNDS_CHECK(ot, dt, vsync_len))
  			continue;
  
  		if (ot->flags != dt->flags)
  			continue;
  
  		videomode_from_timing(ot, &vm);
  		drm_display_mode_from_videomode(&vm, &panel->override_mode);
  		panel->override_mode.type |= DRM_MODE_TYPE_DRIVER |
  					     DRM_MODE_TYPE_PREFERRED;
  		break;
  	}
  
  	if (WARN_ON(!panel->override_mode.type))
  		dev_err(dev, "Reject override mode: No display_timing found
  ");
  }
280921de7   Thierry Reding   drm/panel: Add si...
473
474
  static int panel_simple_probe(struct device *dev, const struct panel_desc *desc)
  {
280921de7   Thierry Reding   drm/panel: Add si...
475
  	struct panel_simple *panel;
b8a2948fa   Sean Paul   drm/panel: simple...
476
  	struct display_timing dt;
0fe1564bd   Sam Ravnborg   drm/panel: simple...
477
  	struct device_node *ddc;
9f069c6fb   Sam Ravnborg   drm/panel: panel-...
478
  	int connector_type;
ddb8e853d   Sam Ravnborg   drm/panel: panel-...
479
  	u32 bus_flags;
280921de7   Thierry Reding   drm/panel: Add si...
480
481
482
483
484
485
486
  	int err;
  
  	panel = devm_kzalloc(dev, sizeof(*panel), GFP_KERNEL);
  	if (!panel)
  		return -ENOMEM;
  
  	panel->enabled = false;
613a633e7   Ajay Kumar   drm/panel: simple...
487
  	panel->prepared = false;
280921de7   Thierry Reding   drm/panel: Add si...
488
  	panel->desc = desc;
2ed3e9510   Douglas Anderson   drm/panel: simple...
489
  	panel->no_hpd = of_property_read_bool(dev->of_node, "no-hpd");
48834e608   Douglas Anderson   drm/panel-simple:...
490
491
492
493
494
  	if (!panel->no_hpd) {
  		err = panel_simple_get_hpd_gpio(dev, panel, true);
  		if (err)
  			return err;
  	}
2ed3e9510   Douglas Anderson   drm/panel: simple...
495

280921de7   Thierry Reding   drm/panel: Add si...
496
497
498
  	panel->supply = devm_regulator_get(dev, "power");
  	if (IS_ERR(panel->supply))
  		return PTR_ERR(panel->supply);
a61400d85   Alexandre Courbot   drm/panel: simple...
499
500
  	panel->enable_gpio = devm_gpiod_get_optional(dev, "enable",
  						     GPIOD_OUT_LOW);
cfdf0549f   Alexandre Courbot   drm/panel: use gp...
501
502
  	if (IS_ERR(panel->enable_gpio)) {
  		err = PTR_ERR(panel->enable_gpio);
b8e938079   Fabio Estevam   drm/panel: simple...
503
504
505
  		if (err != -EPROBE_DEFER)
  			dev_err(dev, "failed to request GPIO: %d
  ", err);
9746c6196   Alexandre Courbot   drm/panel: simple...
506
507
  		return err;
  	}
280921de7   Thierry Reding   drm/panel: Add si...
508

5759c9674   Dmitry Osipenko   drm/panel-simple:...
509
510
511
512
513
514
  	err = of_drm_get_panel_orientation(dev->of_node, &panel->orientation);
  	if (err) {
  		dev_err(dev, "%pOF: failed to get orientation %d
  ", dev->of_node, err);
  		return err;
  	}
280921de7   Thierry Reding   drm/panel: Add si...
515
516
517
518
  	ddc = of_parse_phandle(dev->of_node, "ddc-i2c-bus", 0);
  	if (ddc) {
  		panel->ddc = of_find_i2c_adapter_by_node(ddc);
  		of_node_put(ddc);
0fe1564bd   Sam Ravnborg   drm/panel: simple...
519
520
  		if (!panel->ddc)
  			return -EPROBE_DEFER;
280921de7   Thierry Reding   drm/panel: Add si...
521
  	}
4a1d0dbc8   Sam Ravnborg   drm/panel: simple...
522
523
524
525
526
527
528
529
530
  	if (desc == &panel_dpi) {
  		/* Handle the generic panel-dpi binding */
  		err = panel_dpi_probe(dev, panel);
  		if (err)
  			goto free_ddc;
  	} else {
  		if (!of_get_display_timing(dev->of_node, "panel-timing", &dt))
  			panel_simple_parse_panel_timing_node(dev, panel, &dt);
  	}
b8a2948fa   Sean Paul   drm/panel: simple...
531

9f069c6fb   Sam Ravnborg   drm/panel: panel-...
532
  	connector_type = desc->connector_type;
ddb8e853d   Sam Ravnborg   drm/panel: panel-...
533
  	/* Catch common mistakes for panels. */
9f069c6fb   Sam Ravnborg   drm/panel: panel-...
534
  	switch (connector_type) {
ddb8e853d   Sam Ravnborg   drm/panel: panel-...
535
536
537
  	case 0:
  		dev_warn(dev, "Specify missing connector_type
  ");
9f069c6fb   Sam Ravnborg   drm/panel: panel-...
538
  		connector_type = DRM_MODE_CONNECTOR_DPI;
ddb8e853d   Sam Ravnborg   drm/panel: panel-...
539
540
  		break;
  	case DRM_MODE_CONNECTOR_LVDS:
c4715837b   Laurent Pinchart   drm: panel: simpl...
541
542
543
544
545
  		WARN_ON(desc->bus_flags &
  			~(DRM_BUS_FLAG_DE_LOW |
  			  DRM_BUS_FLAG_DE_HIGH |
  			  DRM_BUS_FLAG_DATA_MSB_TO_LSB |
  			  DRM_BUS_FLAG_DATA_LSB_TO_MSB));
1185c406f   Laurent Pinchart   drm: panel: simpl...
546
547
548
549
550
551
552
553
  		WARN_ON(desc->bus_format != MEDIA_BUS_FMT_RGB666_1X7X3_SPWG &&
  			desc->bus_format != MEDIA_BUS_FMT_RGB888_1X7X4_SPWG &&
  			desc->bus_format != MEDIA_BUS_FMT_RGB888_1X7X4_JEIDA);
  		WARN_ON(desc->bus_format == MEDIA_BUS_FMT_RGB666_1X7X3_SPWG &&
  			desc->bpc != 6);
  		WARN_ON((desc->bus_format == MEDIA_BUS_FMT_RGB888_1X7X4_SPWG ||
  			 desc->bus_format == MEDIA_BUS_FMT_RGB888_1X7X4_JEIDA) &&
  			desc->bpc != 8);
ddb8e853d   Sam Ravnborg   drm/panel: panel-...
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
  		break;
  	case DRM_MODE_CONNECTOR_eDP:
  		if (desc->bus_format == 0)
  			dev_warn(dev, "Specify missing bus_format
  ");
  		if (desc->bpc != 6 && desc->bpc != 8)
  			dev_warn(dev, "Expected bpc in {6,8} but got: %u
  ", desc->bpc);
  		break;
  	case DRM_MODE_CONNECTOR_DSI:
  		if (desc->bpc != 6 && desc->bpc != 8)
  			dev_warn(dev, "Expected bpc in {6,8} but got: %u
  ", desc->bpc);
  		break;
  	case DRM_MODE_CONNECTOR_DPI:
  		bus_flags = DRM_BUS_FLAG_DE_LOW |
  			    DRM_BUS_FLAG_DE_HIGH |
  			    DRM_BUS_FLAG_PIXDATA_SAMPLE_POSEDGE |
  			    DRM_BUS_FLAG_PIXDATA_SAMPLE_NEGEDGE |
  			    DRM_BUS_FLAG_DATA_MSB_TO_LSB |
  			    DRM_BUS_FLAG_DATA_LSB_TO_MSB |
  			    DRM_BUS_FLAG_SYNC_SAMPLE_POSEDGE |
  			    DRM_BUS_FLAG_SYNC_SAMPLE_NEGEDGE;
  		if (desc->bus_flags & ~bus_flags)
  			dev_warn(dev, "Unexpected bus_flags(%d)
  ", desc->bus_flags & ~bus_flags);
  		if (!(desc->bus_flags & bus_flags))
  			dev_warn(dev, "Specify missing bus_flags
  ");
  		if (desc->bus_format == 0)
  			dev_warn(dev, "Specify missing bus_format
  ");
  		if (desc->bpc != 6 && desc->bpc != 8)
  			dev_warn(dev, "Expected bpc in {6,8} but got: %u
  ", desc->bpc);
  		break;
  	default:
  		dev_warn(dev, "Specify a valid connector_type: %d
  ", desc->connector_type);
9f069c6fb   Sam Ravnborg   drm/panel: panel-...
593
  		connector_type = DRM_MODE_CONNECTOR_DPI;
ddb8e853d   Sam Ravnborg   drm/panel: panel-...
594
  		break;
1185c406f   Laurent Pinchart   drm: panel: simpl...
595
  	}
c4715837b   Laurent Pinchart   drm: panel: simpl...
596

9f069c6fb   Sam Ravnborg   drm/panel: panel-...
597
  	drm_panel_init(&panel->base, dev, &panel_simple_funcs, connector_type);
280921de7   Thierry Reding   drm/panel: Add si...
598

0fe1564bd   Sam Ravnborg   drm/panel: simple...
599
600
601
  	err = drm_panel_of_backlight(&panel->base);
  	if (err)
  		goto free_ddc;
c3ee8c65f   Bernard Zhao   drm/panel: remove...
602
  	drm_panel_add(&panel->base);
280921de7   Thierry Reding   drm/panel: Add si...
603
604
605
606
607
608
609
610
  
  	dev_set_drvdata(dev, panel);
  
  	return 0;
  
  free_ddc:
  	if (panel->ddc)
  		put_device(&panel->ddc->dev);
280921de7   Thierry Reding   drm/panel: Add si...
611
612
613
614
615
616
617
  
  	return err;
  }
  
  static int panel_simple_remove(struct device *dev)
  {
  	struct panel_simple *panel = dev_get_drvdata(dev);
280921de7   Thierry Reding   drm/panel: Add si...
618
  	drm_panel_remove(&panel->base);
0fe1564bd   Sam Ravnborg   drm/panel: simple...
619
620
  	drm_panel_disable(&panel->base);
  	drm_panel_unprepare(&panel->base);
280921de7   Thierry Reding   drm/panel: Add si...
621
622
623
  
  	if (panel->ddc)
  		put_device(&panel->ddc->dev);
280921de7   Thierry Reding   drm/panel: Add si...
624
625
  	return 0;
  }
d02fd93e2   Thierry Reding   drm/panel: simple...
626
627
628
  static void panel_simple_shutdown(struct device *dev)
  {
  	struct panel_simple *panel = dev_get_drvdata(dev);
0fe1564bd   Sam Ravnborg   drm/panel: simple...
629
630
  	drm_panel_disable(&panel->base);
  	drm_panel_unprepare(&panel->base);
d02fd93e2   Thierry Reding   drm/panel: simple...
631
  }
bca684e69   Jagan Teki   drm/panel: simple...
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
  static const struct drm_display_mode ampire_am_1280800n3tzqw_t00h_mode = {
  	.clock = 71100,
  	.hdisplay = 1280,
  	.hsync_start = 1280 + 40,
  	.hsync_end = 1280 + 40 + 80,
  	.htotal = 1280 + 40 + 80 + 40,
  	.vdisplay = 800,
  	.vsync_start = 800 + 3,
  	.vsync_end = 800 + 3 + 10,
  	.vtotal = 800 + 3 + 10 + 10,
  	.flags = DRM_MODE_FLAG_PHSYNC | DRM_MODE_FLAG_PVSYNC,
  };
  
  static const struct panel_desc ampire_am_1280800n3tzqw_t00h = {
  	.modes = &ampire_am_1280800n3tzqw_t00h_mode,
  	.num_modes = 1,
  	.bpc = 6,
  	.size = {
  		.width = 217,
  		.height = 136,
  	},
  	.bus_flags = DRM_BUS_FLAG_DE_HIGH,
  	.bus_format = MEDIA_BUS_FMT_RGB888_1X7X4_SPWG,
  	.connector_type = DRM_MODE_CONNECTOR_LVDS,
  };
966fea78a   Yannick Fertre   drm/panel: simple...
657
658
659
660
661
662
663
664
665
666
  static const struct drm_display_mode ampire_am_480272h3tmqw_t01h_mode = {
  	.clock = 9000,
  	.hdisplay = 480,
  	.hsync_start = 480 + 2,
  	.hsync_end = 480 + 2 + 41,
  	.htotal = 480 + 2 + 41 + 2,
  	.vdisplay = 272,
  	.vsync_start = 272 + 2,
  	.vsync_end = 272 + 2 + 10,
  	.vtotal = 272 + 2 + 10 + 2,
966fea78a   Yannick Fertre   drm/panel: simple...
667
668
669
670
671
672
673
674
675
676
677
678
679
  	.flags = DRM_MODE_FLAG_PHSYNC | DRM_MODE_FLAG_PVSYNC,
  };
  
  static const struct panel_desc ampire_am_480272h3tmqw_t01h = {
  	.modes = &ampire_am_480272h3tmqw_t01h_mode,
  	.num_modes = 1,
  	.bpc = 8,
  	.size = {
  		.width = 105,
  		.height = 67,
  	},
  	.bus_format = MEDIA_BUS_FMT_RGB888_1X24,
  };
1c550fa19   Philipp Zabel   drm/panel: Add su...
680
681
682
683
684
685
686
687
688
689
  static const struct drm_display_mode ampire_am800480r3tmqwa1h_mode = {
  	.clock = 33333,
  	.hdisplay = 800,
  	.hsync_start = 800 + 0,
  	.hsync_end = 800 + 0 + 255,
  	.htotal = 800 + 0 + 255 + 0,
  	.vdisplay = 480,
  	.vsync_start = 480 + 2,
  	.vsync_end = 480 + 2 + 45,
  	.vtotal = 480 + 2 + 45 + 0,
1c550fa19   Philipp Zabel   drm/panel: Add su...
690
691
692
693
694
695
696
697
698
699
700
701
702
  	.flags = DRM_MODE_FLAG_PHSYNC | DRM_MODE_FLAG_PVSYNC,
  };
  
  static const struct panel_desc ampire_am800480r3tmqwa1h = {
  	.modes = &ampire_am800480r3tmqwa1h_mode,
  	.num_modes = 1,
  	.bpc = 6,
  	.size = {
  		.width = 152,
  		.height = 91,
  	},
  	.bus_format = MEDIA_BUS_FMT_RGB666_1X18,
  };
c479450f6   Sébastien Szymanski   drm/panel: Add su...
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
  static const struct display_timing santek_st0700i5y_rbslw_f_timing = {
  	.pixelclock = { 26400000, 33300000, 46800000 },
  	.hactive = { 800, 800, 800 },
  	.hfront_porch = { 16, 210, 354 },
  	.hback_porch = { 45, 36, 6 },
  	.hsync_len = { 1, 10, 40 },
  	.vactive = { 480, 480, 480 },
  	.vfront_porch = { 7, 22, 147 },
  	.vback_porch = { 22, 13, 3 },
  	.vsync_len = { 1, 10, 20 },
  	.flags = DISPLAY_FLAGS_HSYNC_LOW | DISPLAY_FLAGS_VSYNC_LOW |
  		DISPLAY_FLAGS_DE_HIGH | DISPLAY_FLAGS_PIXDATA_POSEDGE
  };
  
  static const struct panel_desc armadeus_st0700_adapt = {
  	.timings = &santek_st0700i5y_rbslw_f_timing,
  	.num_timings = 1,
  	.bpc = 6,
  	.size = {
  		.width = 154,
  		.height = 86,
  	},
  	.bus_format = MEDIA_BUS_FMT_RGB666_1X18,
f5436f774   Sam Ravnborg   drm/panel: panel-...
726
  	.bus_flags = DRM_BUS_FLAG_DE_HIGH | DRM_BUS_FLAG_PIXDATA_SAMPLE_NEGEDGE,
c479450f6   Sébastien Szymanski   drm/panel: Add su...
727
  };
280921de7   Thierry Reding   drm/panel: Add si...
728
729
730
731
732
733
734
735
736
737
  static const struct drm_display_mode auo_b101aw03_mode = {
  	.clock = 51450,
  	.hdisplay = 1024,
  	.hsync_start = 1024 + 156,
  	.hsync_end = 1024 + 156 + 8,
  	.htotal = 1024 + 156 + 8 + 156,
  	.vdisplay = 600,
  	.vsync_start = 600 + 16,
  	.vsync_end = 600 + 16 + 6,
  	.vtotal = 600 + 16 + 6 + 16,
280921de7   Thierry Reding   drm/panel: Add si...
738
739
740
741
742
  };
  
  static const struct panel_desc auo_b101aw03 = {
  	.modes = &auo_b101aw03_mode,
  	.num_modes = 1,
0208d5111   Stéphane Marchesin   drm/panel: simple...
743
  	.bpc = 6,
280921de7   Thierry Reding   drm/panel: Add si...
744
745
746
747
  	.size = {
  		.width = 223,
  		.height = 125,
  	},
855608296   Dmitry Osipenko   drm/panel-simple:...
748
  	.bus_format = MEDIA_BUS_FMT_RGB666_1X7X3_SPWG,
c4715837b   Laurent Pinchart   drm: panel: simpl...
749
  	.bus_flags = DRM_BUS_FLAG_DE_HIGH,
94f07917e   Dmitry Osipenko   drm/panel-simple:...
750
  	.connector_type = DRM_MODE_CONNECTOR_LVDS,
280921de7   Thierry Reding   drm/panel: Add si...
751
  };
374bf825e   Douglas Anderson   drm/panel: simple...
752
753
754
755
756
757
758
759
760
761
  static const struct display_timing auo_b101ean01_timing = {
  	.pixelclock = { 65300000, 72500000, 75000000 },
  	.hactive = { 1280, 1280, 1280 },
  	.hfront_porch = { 18, 119, 119 },
  	.hback_porch = { 21, 21, 21 },
  	.hsync_len = { 32, 32, 32 },
  	.vactive = { 800, 800, 800 },
  	.vfront_porch = { 4, 4, 4 },
  	.vback_porch = { 8, 8, 8 },
  	.vsync_len = { 18, 20, 20 },
a531bc3d9   Huang Lin   drm/panel: simple...
762
763
764
  };
  
  static const struct panel_desc auo_b101ean01 = {
374bf825e   Douglas Anderson   drm/panel: simple...
765
766
  	.timings = &auo_b101ean01_timing,
  	.num_timings = 1,
a531bc3d9   Huang Lin   drm/panel: simple...
767
768
769
770
771
772
  	.bpc = 6,
  	.size = {
  		.width = 217,
  		.height = 136,
  	},
  };
dac746e04   Rob Clark   drm/panel/simple:...
773
774
775
776
777
778
779
780
781
782
  static const struct drm_display_mode auo_b101xtn01_mode = {
  	.clock = 72000,
  	.hdisplay = 1366,
  	.hsync_start = 1366 + 20,
  	.hsync_end = 1366 + 20 + 70,
  	.htotal = 1366 + 20 + 70,
  	.vdisplay = 768,
  	.vsync_start = 768 + 14,
  	.vsync_end = 768 + 14 + 42,
  	.vtotal = 768 + 14 + 42,
dac746e04   Rob Clark   drm/panel/simple:...
783
784
785
786
787
788
789
790
791
792
793
794
  	.flags = DRM_MODE_FLAG_NVSYNC | DRM_MODE_FLAG_NHSYNC,
  };
  
  static const struct panel_desc auo_b101xtn01 = {
  	.modes = &auo_b101xtn01_mode,
  	.num_modes = 1,
  	.bpc = 6,
  	.size = {
  		.width = 223,
  		.height = 125,
  	},
  };
da458286a   Rob Clark   drm/panel: Add su...
795
796
797
798
799
800
801
802
803
804
  static const struct drm_display_mode auo_b116xak01_mode = {
  	.clock = 69300,
  	.hdisplay = 1366,
  	.hsync_start = 1366 + 48,
  	.hsync_end = 1366 + 48 + 32,
  	.htotal = 1366 + 48 + 32 + 10,
  	.vdisplay = 768,
  	.vsync_start = 768 + 4,
  	.vsync_end = 768 + 4 + 6,
  	.vtotal = 768 + 4 + 6 + 15,
da458286a   Rob Clark   drm/panel: Add su...
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
  	.flags = DRM_MODE_FLAG_NVSYNC | DRM_MODE_FLAG_NHSYNC,
  };
  
  static const struct panel_desc auo_b116xak01 = {
  	.modes = &auo_b116xak01_mode,
  	.num_modes = 1,
  	.bpc = 6,
  	.size = {
  		.width = 256,
  		.height = 144,
  	},
  	.delay = {
  		.hpd_absent_delay = 200,
  	},
  	.bus_format = MEDIA_BUS_FMT_RGB666_1X18,
  	.connector_type = DRM_MODE_CONNECTOR_eDP,
  };
e35e305ef   Ajay Kumar   drm/panel: simple...
822
823
824
825
826
827
828
829
830
831
  static const struct drm_display_mode auo_b116xw03_mode = {
  	.clock = 70589,
  	.hdisplay = 1366,
  	.hsync_start = 1366 + 40,
  	.hsync_end = 1366 + 40 + 40,
  	.htotal = 1366 + 40 + 40 + 32,
  	.vdisplay = 768,
  	.vsync_start = 768 + 10,
  	.vsync_end = 768 + 10 + 12,
  	.vtotal = 768 + 10 + 12 + 6,
88d3457ce   Jitao Shi   drm/panel: auo,b1...
832
  	.flags = DRM_MODE_FLAG_NVSYNC | DRM_MODE_FLAG_NHSYNC,
e35e305ef   Ajay Kumar   drm/panel: simple...
833
834
835
836
837
838
839
840
841
842
  };
  
  static const struct panel_desc auo_b116xw03 = {
  	.modes = &auo_b116xw03_mode,
  	.num_modes = 1,
  	.bpc = 6,
  	.size = {
  		.width = 256,
  		.height = 144,
  	},
88d3457ce   Jitao Shi   drm/panel: auo,b1...
843
844
845
846
847
848
  	.delay = {
  		.enable = 400,
  	},
  	.bus_flags = DRM_BUS_FLAG_SYNC_DRIVE_NEGEDGE,
  	.bus_format = MEDIA_BUS_FMT_RGB666_1X18,
  	.connector_type = DRM_MODE_CONNECTOR_eDP,
e35e305ef   Ajay Kumar   drm/panel: simple...
849
  };
a333f7ad1   Stéphane Marchesin   drm/panel: simple...
850
851
852
853
854
855
856
857
858
859
  static const struct drm_display_mode auo_b133xtn01_mode = {
  	.clock = 69500,
  	.hdisplay = 1366,
  	.hsync_start = 1366 + 48,
  	.hsync_end = 1366 + 48 + 32,
  	.htotal = 1366 + 48 + 32 + 20,
  	.vdisplay = 768,
  	.vsync_start = 768 + 3,
  	.vsync_end = 768 + 3 + 6,
  	.vtotal = 768 + 3 + 6 + 13,
a333f7ad1   Stéphane Marchesin   drm/panel: simple...
860
861
862
863
864
  };
  
  static const struct panel_desc auo_b133xtn01 = {
  	.modes = &auo_b133xtn01_mode,
  	.num_modes = 1,
0208d5111   Stéphane Marchesin   drm/panel: simple...
865
  	.bpc = 6,
a333f7ad1   Stéphane Marchesin   drm/panel: simple...
866
867
868
869
870
  	.size = {
  		.width = 293,
  		.height = 165,
  	},
  };
3e51d6093   Ajay Kumar   drm/panel: simple...
871
872
873
874
875
876
877
878
879
880
  static const struct drm_display_mode auo_b133htn01_mode = {
  	.clock = 150660,
  	.hdisplay = 1920,
  	.hsync_start = 1920 + 172,
  	.hsync_end = 1920 + 172 + 80,
  	.htotal = 1920 + 172 + 80 + 60,
  	.vdisplay = 1080,
  	.vsync_start = 1080 + 25,
  	.vsync_end = 1080 + 25 + 10,
  	.vtotal = 1080 + 25 + 10 + 10,
3e51d6093   Ajay Kumar   drm/panel: simple...
881
882
883
884
885
  };
  
  static const struct panel_desc auo_b133htn01 = {
  	.modes = &auo_b133htn01_mode,
  	.num_modes = 1,
d7a839cde   Thierry Reding   drm/panel: simple...
886
  	.bpc = 6,
3e51d6093   Ajay Kumar   drm/panel: simple...
887
888
889
890
891
892
893
894
895
896
  	.size = {
  		.width = 293,
  		.height = 165,
  	},
  	.delay = {
  		.prepare = 105,
  		.enable = 20,
  		.unprepare = 50,
  	},
  };
bccfaffb7   Lukasz Majewski   display: panel: A...
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
  static const struct display_timing auo_g070vvn01_timings = {
  	.pixelclock = { 33300000, 34209000, 45000000 },
  	.hactive = { 800, 800, 800 },
  	.hfront_porch = { 20, 40, 200 },
  	.hback_porch = { 87, 40, 1 },
  	.hsync_len = { 1, 48, 87 },
  	.vactive = { 480, 480, 480 },
  	.vfront_porch = { 5, 13, 200 },
  	.vback_porch = { 31, 31, 29 },
  	.vsync_len = { 1, 1, 3 },
  };
  
  static const struct panel_desc auo_g070vvn01 = {
  	.timings = &auo_g070vvn01_timings,
  	.num_timings = 1,
  	.bpc = 8,
  	.size = {
  		.width = 152,
  		.height = 91,
  	},
  	.delay = {
  		.prepare = 200,
  		.enable = 50,
  		.disable = 50,
  		.unprepare = 1000,
  	},
  };
4fb86404a   Alex Gonzalez   drm/panel: simple...
924
925
926
927
928
929
930
931
932
933
  static const struct drm_display_mode auo_g101evn010_mode = {
  	.clock = 68930,
  	.hdisplay = 1280,
  	.hsync_start = 1280 + 82,
  	.hsync_end = 1280 + 82 + 2,
  	.htotal = 1280 + 82 + 2 + 84,
  	.vdisplay = 800,
  	.vsync_start = 800 + 8,
  	.vsync_end = 800 + 8 + 2,
  	.vtotal = 800 + 8 + 2 + 6,
4fb86404a   Alex Gonzalez   drm/panel: simple...
934
935
936
937
938
939
940
941
942
943
  };
  
  static const struct panel_desc auo_g101evn010 = {
  	.modes = &auo_g101evn010_mode,
  	.num_modes = 1,
  	.bpc = 6,
  	.size = {
  		.width = 216,
  		.height = 135,
  	},
27a46fb73   Tomi Valkeinen   drm/panel: panel-...
944
945
  	.bus_format = MEDIA_BUS_FMT_RGB666_1X7X3_SPWG,
  	.connector_type = DRM_MODE_CONNECTOR_LVDS,
4fb86404a   Alex Gonzalez   drm/panel: simple...
946
  };
4451c287e   Christoph Fritz   drm/panel: Add su...
947
948
949
950
951
952
953
954
955
956
  static const struct drm_display_mode auo_g104sn02_mode = {
  	.clock = 40000,
  	.hdisplay = 800,
  	.hsync_start = 800 + 40,
  	.hsync_end = 800 + 40 + 216,
  	.htotal = 800 + 40 + 216 + 128,
  	.vdisplay = 600,
  	.vsync_start = 600 + 10,
  	.vsync_end = 600 + 10 + 35,
  	.vtotal = 600 + 10 + 35 + 2,
4451c287e   Christoph Fritz   drm/panel: Add su...
957
958
959
960
961
962
963
964
965
966
967
  };
  
  static const struct panel_desc auo_g104sn02 = {
  	.modes = &auo_g104sn02_mode,
  	.num_modes = 1,
  	.bpc = 8,
  	.size = {
  		.width = 211,
  		.height = 158,
  	},
  };
03e909acd   Sebastian Reichel   drm/panel: simple...
968
969
970
971
972
973
974
975
976
977
  static const struct drm_display_mode auo_g121ean01_mode = {
  	.clock = 66700,
  	.hdisplay = 1280,
  	.hsync_start = 1280 + 58,
  	.hsync_end = 1280 + 58 + 8,
  	.htotal = 1280 + 58 + 8 + 70,
  	.vdisplay = 800,
  	.vsync_start = 800 + 6,
  	.vsync_end = 800 + 6 + 4,
  	.vtotal = 800 + 6 + 4 + 10,
03e909acd   Sebastian Reichel   drm/panel: simple...
978
979
980
981
982
983
984
985
986
987
988
989
990
  };
  
  static const struct panel_desc auo_g121ean01 = {
  	.modes = &auo_g121ean01_mode,
  	.num_modes = 1,
  	.bpc = 8,
  	.size = {
  		.width = 261,
  		.height = 163,
  	},
  	.bus_format = MEDIA_BUS_FMT_RGB888_1X7X4_SPWG,
  	.connector_type = DRM_MODE_CONNECTOR_LVDS,
  };
697035c6b   Lucas Stach   drm/panel: simple...
991
992
993
994
995
996
997
998
999
1000
1001
1002
1003
1004
1005
1006
1007
1008
1009
1010
1011
1012
1013
1014
1015
1016
1017
  static const struct display_timing auo_g133han01_timings = {
  	.pixelclock = { 134000000, 141200000, 149000000 },
  	.hactive = { 1920, 1920, 1920 },
  	.hfront_porch = { 39, 58, 77 },
  	.hback_porch = { 59, 88, 117 },
  	.hsync_len = { 28, 42, 56 },
  	.vactive = { 1080, 1080, 1080 },
  	.vfront_porch = { 3, 8, 11 },
  	.vback_porch = { 5, 14, 19 },
  	.vsync_len = { 4, 14, 19 },
  };
  
  static const struct panel_desc auo_g133han01 = {
  	.timings = &auo_g133han01_timings,
  	.num_timings = 1,
  	.bpc = 8,
  	.size = {
  		.width = 293,
  		.height = 165,
  	},
  	.delay = {
  		.prepare = 200,
  		.enable = 50,
  		.disable = 50,
  		.unprepare = 1000,
  	},
  	.bus_format = MEDIA_BUS_FMT_RGB888_1X7X4_JEIDA,
9a2654c0f   Laurent Pinchart   drm/panel: Add an...
1018
  	.connector_type = DRM_MODE_CONNECTOR_LVDS,
697035c6b   Lucas Stach   drm/panel: simple...
1019
  };
d9ccd1f28   Sebastian Reichel   drm/panel: simple...
1020
1021
1022
1023
1024
1025
1026
1027
1028
1029
  static const struct drm_display_mode auo_g156xtn01_mode = {
  	.clock = 76000,
  	.hdisplay = 1366,
  	.hsync_start = 1366 + 33,
  	.hsync_end = 1366 + 33 + 67,
  	.htotal = 1560,
  	.vdisplay = 768,
  	.vsync_start = 768 + 4,
  	.vsync_end = 768 + 4 + 4,
  	.vtotal = 806,
d9ccd1f28   Sebastian Reichel   drm/panel: simple...
1030
1031
1032
1033
1034
1035
1036
1037
1038
1039
1040
1041
1042
  };
  
  static const struct panel_desc auo_g156xtn01 = {
  	.modes = &auo_g156xtn01_mode,
  	.num_modes = 1,
  	.bpc = 8,
  	.size = {
  		.width = 344,
  		.height = 194,
  	},
  	.bus_format = MEDIA_BUS_FMT_RGB888_1X7X4_SPWG,
  	.connector_type = DRM_MODE_CONNECTOR_LVDS,
  };
8c31f6034   Lucas Stach   drm/panel: simple...
1043
1044
1045
  static const struct display_timing auo_g185han01_timings = {
  	.pixelclock = { 120000000, 144000000, 175000000 },
  	.hactive = { 1920, 1920, 1920 },
f8c6bfc61   Lucas Stach   drm/panel: simple...
1046
1047
1048
  	.hfront_porch = { 36, 120, 148 },
  	.hback_porch = { 24, 88, 108 },
  	.hsync_len = { 20, 48, 64 },
8c31f6034   Lucas Stach   drm/panel: simple...
1049
1050
1051
1052
1053
1054
1055
1056
1057
1058
1059
1060
1061
1062
1063
1064
1065
1066
1067
1068
1069
  	.vactive = { 1080, 1080, 1080 },
  	.vfront_porch = { 6, 10, 40 },
  	.vback_porch = { 2, 5, 20 },
  	.vsync_len = { 2, 5, 20 },
  };
  
  static const struct panel_desc auo_g185han01 = {
  	.timings = &auo_g185han01_timings,
  	.num_timings = 1,
  	.bpc = 8,
  	.size = {
  		.width = 409,
  		.height = 230,
  	},
  	.delay = {
  		.prepare = 50,
  		.enable = 200,
  		.disable = 110,
  		.unprepare = 1000,
  	},
  	.bus_format = MEDIA_BUS_FMT_RGB888_1X7X4_SPWG,
9a2654c0f   Laurent Pinchart   drm/panel: Add an...
1070
  	.connector_type = DRM_MODE_CONNECTOR_LVDS,
8c31f6034   Lucas Stach   drm/panel: simple...
1071
  };
2f7b832fc   Sebastian Reichel   drm/panel: simple...
1072
1073
1074
1075
1076
1077
1078
1079
1080
1081
1082
1083
1084
1085
1086
1087
1088
1089
1090
1091
1092
1093
1094
1095
1096
1097
1098
1099
1100
  static const struct display_timing auo_g190ean01_timings = {
  	.pixelclock = { 90000000, 108000000, 135000000 },
  	.hactive = { 1280, 1280, 1280 },
  	.hfront_porch = { 126, 184, 1266 },
  	.hback_porch = { 84, 122, 844 },
  	.hsync_len = { 70, 102, 704 },
  	.vactive = { 1024, 1024, 1024 },
  	.vfront_porch = { 4, 26, 76 },
  	.vback_porch = { 2, 8, 25 },
  	.vsync_len = { 2, 8, 25 },
  };
  
  static const struct panel_desc auo_g190ean01 = {
  	.timings = &auo_g190ean01_timings,
  	.num_timings = 1,
  	.bpc = 8,
  	.size = {
  		.width = 376,
  		.height = 301,
  	},
  	.delay = {
  		.prepare = 50,
  		.enable = 200,
  		.disable = 110,
  		.unprepare = 1000,
  	},
  	.bus_format = MEDIA_BUS_FMT_RGB888_1X7X4_SPWG,
  	.connector_type = DRM_MODE_CONNECTOR_LVDS,
  };
70c0d5b78   Lucas Stach   drm/panel: simple...
1101
1102
1103
1104
1105
1106
1107
1108
1109
1110
1111
1112
1113
1114
1115
1116
1117
1118
1119
1120
1121
1122
1123
1124
1125
  static const struct display_timing auo_p320hvn03_timings = {
  	.pixelclock = { 106000000, 148500000, 164000000 },
  	.hactive = { 1920, 1920, 1920 },
  	.hfront_porch = { 25, 50, 130 },
  	.hback_porch = { 25, 50, 130 },
  	.hsync_len = { 20, 40, 105 },
  	.vactive = { 1080, 1080, 1080 },
  	.vfront_porch = { 8, 17, 150 },
  	.vback_porch = { 8, 17, 150 },
  	.vsync_len = { 4, 11, 100 },
  };
  
  static const struct panel_desc auo_p320hvn03 = {
  	.timings = &auo_p320hvn03_timings,
  	.num_timings = 1,
  	.bpc = 8,
  	.size = {
  		.width = 698,
  		.height = 393,
  	},
  	.delay = {
  		.prepare = 1,
  		.enable = 450,
  		.unprepare = 500,
  	},
2554f154b   Lucas Stach   drm/panel: simple...
1126
  	.bus_format = MEDIA_BUS_FMT_RGB888_1X7X4_SPWG,
9a2654c0f   Laurent Pinchart   drm/panel: Add an...
1127
  	.connector_type = DRM_MODE_CONNECTOR_LVDS,
70c0d5b78   Lucas Stach   drm/panel: simple...
1128
  };
7ee933a1d   Haixia Shi   drm/panel: simple...
1129
1130
1131
1132
1133
1134
1135
1136
1137
1138
  static const struct drm_display_mode auo_t215hvn01_mode = {
  	.clock = 148800,
  	.hdisplay = 1920,
  	.hsync_start = 1920 + 88,
  	.hsync_end = 1920 + 88 + 44,
  	.htotal = 1920 + 88 + 44 + 148,
  	.vdisplay = 1080,
  	.vsync_start = 1080 + 4,
  	.vsync_end = 1080 + 4 + 5,
  	.vtotal = 1080 + 4 + 5 + 36,
7ee933a1d   Haixia Shi   drm/panel: simple...
1139
1140
1141
1142
1143
1144
1145
1146
1147
1148
1149
1150
1151
1152
1153
  };
  
  static const struct panel_desc auo_t215hvn01 = {
  	.modes = &auo_t215hvn01_mode,
  	.num_modes = 1,
  	.bpc = 8,
  	.size = {
  		.width = 430,
  		.height = 270,
  	},
  	.delay = {
  		.disable = 5,
  		.unprepare = 1000,
  	}
  };
d47df6339   Philipp Zabel   drm/panel: simple...
1154
1155
1156
1157
1158
1159
1160
1161
1162
1163
  static const struct drm_display_mode avic_tm070ddh03_mode = {
  	.clock = 51200,
  	.hdisplay = 1024,
  	.hsync_start = 1024 + 160,
  	.hsync_end = 1024 + 160 + 4,
  	.htotal = 1024 + 160 + 4 + 156,
  	.vdisplay = 600,
  	.vsync_start = 600 + 17,
  	.vsync_end = 600 + 17 + 1,
  	.vtotal = 600 + 17 + 1 + 17,
d47df6339   Philipp Zabel   drm/panel: simple...
1164
1165
1166
1167
1168
1169
1170
1171
1172
1173
1174
1175
1176
1177
1178
1179
  };
  
  static const struct panel_desc avic_tm070ddh03 = {
  	.modes = &avic_tm070ddh03_mode,
  	.num_modes = 1,
  	.bpc = 8,
  	.size = {
  		.width = 154,
  		.height = 90,
  	},
  	.delay = {
  		.prepare = 20,
  		.enable = 200,
  		.disable = 200,
  	},
  };
7ad8b41cd   Chen-Yu Tsai   drm/panel: simple...
1180
1181
1182
1183
1184
1185
1186
1187
1188
1189
1190
1191
1192
1193
1194
1195
1196
1197
1198
1199
1200
  static const struct drm_display_mode bananapi_s070wv20_ct16_mode = {
  	.clock = 30000,
  	.hdisplay = 800,
  	.hsync_start = 800 + 40,
  	.hsync_end = 800 + 40 + 48,
  	.htotal = 800 + 40 + 48 + 40,
  	.vdisplay = 480,
  	.vsync_start = 480 + 13,
  	.vsync_end = 480 + 13 + 3,
  	.vtotal = 480 + 13 + 3 + 29,
  };
  
  static const struct panel_desc bananapi_s070wv20_ct16 = {
  	.modes = &bananapi_s070wv20_ct16_mode,
  	.num_modes = 1,
  	.bpc = 6,
  	.size = {
  		.width = 154,
  		.height = 86,
  	},
  };
ae8cf41b6   Andrzej Hajda   drm/panel: simple...
1201
  static const struct drm_display_mode boe_hv070wsa_mode = {
e077e2f5f   Andrzej Hajda   drm/panel: simple...
1202
  	.clock = 42105,
ae8cf41b6   Andrzej Hajda   drm/panel: simple...
1203
  	.hdisplay = 1024,
e077e2f5f   Andrzej Hajda   drm/panel: simple...
1204
1205
1206
  	.hsync_start = 1024 + 30,
  	.hsync_end = 1024 + 30 + 30,
  	.htotal = 1024 + 30 + 30 + 30,
ae8cf41b6   Andrzej Hajda   drm/panel: simple...
1207
  	.vdisplay = 600,
e077e2f5f   Andrzej Hajda   drm/panel: simple...
1208
1209
1210
  	.vsync_start = 600 + 10,
  	.vsync_end = 600 + 10 + 10,
  	.vtotal = 600 + 10 + 10 + 10,
ae8cf41b6   Andrzej Hajda   drm/panel: simple...
1211
1212
1213
1214
1215
  };
  
  static const struct panel_desc boe_hv070wsa = {
  	.modes = &boe_hv070wsa_mode,
  	.num_modes = 1,
2a5c2ff58   Sam Ravnborg   drm/panel: add co...
1216
  	.bpc = 8,
ae8cf41b6   Andrzej Hajda   drm/panel: simple...
1217
1218
1219
1220
  	.size = {
  		.width = 154,
  		.height = 90,
  	},
2a5c2ff58   Sam Ravnborg   drm/panel: add co...
1221
1222
1223
  	.bus_format = MEDIA_BUS_FMT_RGB888_1X7X4_SPWG,
  	.bus_flags = DRM_BUS_FLAG_DE_HIGH,
  	.connector_type = DRM_MODE_CONNECTOR_LVDS,
ae8cf41b6   Andrzej Hajda   drm/panel: simple...
1224
  };
cac1a4112   Caesar Wang   drm/panel: simple...
1225
1226
1227
1228
1229
1230
1231
1232
1233
1234
1235
  static const struct drm_display_mode boe_nv101wxmn51_modes[] = {
  	{
  		.clock = 71900,
  		.hdisplay = 1280,
  		.hsync_start = 1280 + 48,
  		.hsync_end = 1280 + 48 + 32,
  		.htotal = 1280 + 48 + 32 + 80,
  		.vdisplay = 800,
  		.vsync_start = 800 + 3,
  		.vsync_end = 800 + 3 + 5,
  		.vtotal = 800 + 3 + 5 + 24,
cac1a4112   Caesar Wang   drm/panel: simple...
1236
1237
1238
1239
1240
1241
1242
1243
1244
1245
1246
  	},
  	{
  		.clock = 57500,
  		.hdisplay = 1280,
  		.hsync_start = 1280 + 48,
  		.hsync_end = 1280 + 48 + 32,
  		.htotal = 1280 + 48 + 32 + 80,
  		.vdisplay = 800,
  		.vsync_start = 800 + 3,
  		.vsync_end = 800 + 3 + 5,
  		.vtotal = 800 + 3 + 5 + 24,
cac1a4112   Caesar Wang   drm/panel: simple...
1247
1248
1249
1250
1251
1252
1253
1254
1255
1256
1257
1258
1259
1260
1261
1262
1263
  	},
  };
  
  static const struct panel_desc boe_nv101wxmn51 = {
  	.modes = boe_nv101wxmn51_modes,
  	.num_modes = ARRAY_SIZE(boe_nv101wxmn51_modes),
  	.bpc = 8,
  	.size = {
  		.width = 217,
  		.height = 136,
  	},
  	.delay = {
  		.prepare = 210,
  		.enable = 50,
  		.unprepare = 160,
  	},
  };
cfe40d022   Douglas Anderson   panel: simple: Ad...
1264
  /* Also used for boe_nv133fhm_n62 */
b0c664cc8   Bjorn Andersson   panel: simple: Ad...
1265
1266
1267
1268
1269
1270
1271
1272
1273
1274
  static const struct drm_display_mode boe_nv133fhm_n61_modes = {
  	.clock = 147840,
  	.hdisplay = 1920,
  	.hsync_start = 1920 + 48,
  	.hsync_end = 1920 + 48 + 32,
  	.htotal = 1920 + 48 + 32 + 200,
  	.vdisplay = 1080,
  	.vsync_start = 1080 + 3,
  	.vsync_end = 1080 + 3 + 6,
  	.vtotal = 1080 + 3 + 6 + 31,
1a5f0500d   Stephen Boyd   drm/panel: simple...
1275
  	.flags = DRM_MODE_FLAG_PHSYNC | DRM_MODE_FLAG_NVSYNC,
b0c664cc8   Bjorn Andersson   panel: simple: Ad...
1276
  };
cfe40d022   Douglas Anderson   panel: simple: Ad...
1277
  /* Also used for boe_nv133fhm_n62 */
b0c664cc8   Bjorn Andersson   panel: simple: Ad...
1278
1279
1280
  static const struct panel_desc boe_nv133fhm_n61 = {
  	.modes = &boe_nv133fhm_n61_modes,
  	.num_modes = 1,
9694d9c3b   Douglas Anderson   panel: simple: Fi...
1281
  	.bpc = 6,
b0c664cc8   Bjorn Andersson   panel: simple: Ad...
1282
  	.size = {
9694d9c3b   Douglas Anderson   panel: simple: Fi...
1283
1284
  		.width = 294,
  		.height = 165,
b0c664cc8   Bjorn Andersson   panel: simple: Ad...
1285
1286
  	},
  	.delay = {
667d73d72   Douglas Anderson   drm: panel: simpl...
1287
1288
1289
1290
1291
1292
1293
1294
1295
1296
1297
1298
1299
1300
  		/*
  		 * When power is first given to the panel there's a short
  		 * spike on the HPD line.  It was explained that this spike
  		 * was until the TCON data download was complete.  On
  		 * one system this was measured at 8 ms.  We'll put 15 ms
  		 * in the prepare delay just to be safe and take it away
  		 * from the hpd_absent_delay (which would otherwise be 200 ms)
  		 * to handle this.  That means:
  		 * - If HPD isn't hooked up you still have 200 ms delay.
  		 * - If HPD is hooked up we won't try to look at it for the
  		 *   first 15 ms.
  		 */
  		.prepare = 15,
  		.hpd_absent_delay = 185,
b0c664cc8   Bjorn Andersson   panel: simple: Ad...
1301
1302
1303
1304
1305
1306
  		.unprepare = 500,
  	},
  	.bus_format = MEDIA_BUS_FMT_RGB888_1X24,
  	.bus_flags = DRM_BUS_FLAG_DATA_MSB_TO_LSB,
  	.connector_type = DRM_MODE_CONNECTOR_eDP,
  };
a51198184   Tobias Schramm   drm/panel: Add su...
1307
1308
1309
1310
1311
1312
1313
1314
1315
1316
1317
  static const struct drm_display_mode boe_nv140fhmn49_modes[] = {
  	{
  		.clock = 148500,
  		.hdisplay = 1920,
  		.hsync_start = 1920 + 48,
  		.hsync_end = 1920 + 48 + 32,
  		.htotal = 2200,
  		.vdisplay = 1080,
  		.vsync_start = 1080 + 3,
  		.vsync_end = 1080 + 3 + 5,
  		.vtotal = 1125,
a51198184   Tobias Schramm   drm/panel: Add su...
1318
1319
1320
1321
1322
1323
1324
1325
1326
1327
1328
1329
1330
1331
1332
1333
1334
1335
1336
  	},
  };
  
  static const struct panel_desc boe_nv140fhmn49 = {
  	.modes = boe_nv140fhmn49_modes,
  	.num_modes = ARRAY_SIZE(boe_nv140fhmn49_modes),
  	.bpc = 6,
  	.size = {
  		.width = 309,
  		.height = 174,
  	},
  	.delay = {
  		.prepare = 210,
  		.enable = 50,
  		.unprepare = 160,
  	},
  	.bus_format = MEDIA_BUS_FMT_RGB666_1X18,
  	.connector_type = DRM_MODE_CONNECTOR_eDP,
  };
e58edce61   Giulio Benetti   drm/panel: add pa...
1337
1338
1339
1340
1341
1342
1343
1344
1345
1346
  static const struct drm_display_mode cdtech_s043wq26h_ct7_mode = {
  	.clock = 9000,
  	.hdisplay = 480,
  	.hsync_start = 480 + 5,
  	.hsync_end = 480 + 5 + 5,
  	.htotal = 480 + 5 + 5 + 40,
  	.vdisplay = 272,
  	.vsync_start = 272 + 8,
  	.vsync_end = 272 + 8 + 8,
  	.vtotal = 272 + 8 + 8 + 8,
e58edce61   Giulio Benetti   drm/panel: add pa...
1347
1348
1349
1350
1351
1352
1353
1354
1355
1356
1357
  	.flags = DRM_MODE_FLAG_NHSYNC | DRM_MODE_FLAG_NVSYNC,
  };
  
  static const struct panel_desc cdtech_s043wq26h_ct7 = {
  	.modes = &cdtech_s043wq26h_ct7_mode,
  	.num_modes = 1,
  	.bpc = 8,
  	.size = {
  		.width = 95,
  		.height = 54,
  	},
88bc41785   Laurent Pinchart   drm: Use new DRM_...
1358
  	.bus_flags = DRM_BUS_FLAG_PIXDATA_DRIVE_POSEDGE,
e58edce61   Giulio Benetti   drm/panel: add pa...
1359
  };
0e3b67f6d   Michael Krummsdorf   drm/panel: simple...
1360
1361
1362
1363
1364
1365
1366
1367
1368
1369
1370
1371
1372
1373
1374
1375
1376
1377
1378
1379
1380
1381
1382
  /* S070PWS19HP-FC21 2017/04/22 */
  static const struct drm_display_mode cdtech_s070pws19hp_fc21_mode = {
  	.clock = 51200,
  	.hdisplay = 1024,
  	.hsync_start = 1024 + 160,
  	.hsync_end = 1024 + 160 + 20,
  	.htotal = 1024 + 160 + 20 + 140,
  	.vdisplay = 600,
  	.vsync_start = 600 + 12,
  	.vsync_end = 600 + 12 + 3,
  	.vtotal = 600 + 12 + 3 + 20,
  	.flags = DRM_MODE_FLAG_NHSYNC | DRM_MODE_FLAG_NVSYNC,
  };
  
  static const struct panel_desc cdtech_s070pws19hp_fc21 = {
  	.modes = &cdtech_s070pws19hp_fc21_mode,
  	.num_modes = 1,
  	.bpc = 6,
  	.size = {
  		.width = 154,
  		.height = 86,
  	},
  	.bus_format = MEDIA_BUS_FMT_RGB666_1X18,
f5436f774   Sam Ravnborg   drm/panel: panel-...
1383
  	.bus_flags = DRM_BUS_FLAG_DE_HIGH | DRM_BUS_FLAG_PIXDATA_SAMPLE_NEGEDGE,
0e3b67f6d   Michael Krummsdorf   drm/panel: simple...
1384
1385
1386
1387
1388
1389
1390
1391
1392
1393
1394
1395
1396
1397
1398
1399
1400
1401
1402
1403
1404
1405
1406
1407
1408
1409
  	.connector_type = DRM_MODE_CONNECTOR_DPI,
  };
  
  /* S070SWV29HG-DC44 2017/09/21 */
  static const struct drm_display_mode cdtech_s070swv29hg_dc44_mode = {
  	.clock = 33300,
  	.hdisplay = 800,
  	.hsync_start = 800 + 210,
  	.hsync_end = 800 + 210 + 2,
  	.htotal = 800 + 210 + 2 + 44,
  	.vdisplay = 480,
  	.vsync_start = 480 + 22,
  	.vsync_end = 480 + 22 + 2,
  	.vtotal = 480 + 22 + 2 + 21,
  	.flags = DRM_MODE_FLAG_NHSYNC | DRM_MODE_FLAG_NVSYNC,
  };
  
  static const struct panel_desc cdtech_s070swv29hg_dc44 = {
  	.modes = &cdtech_s070swv29hg_dc44_mode,
  	.num_modes = 1,
  	.bpc = 6,
  	.size = {
  		.width = 154,
  		.height = 86,
  	},
  	.bus_format = MEDIA_BUS_FMT_RGB666_1X18,
f5436f774   Sam Ravnborg   drm/panel: panel-...
1410
  	.bus_flags = DRM_BUS_FLAG_DE_HIGH | DRM_BUS_FLAG_PIXDATA_SAMPLE_NEGEDGE,
0e3b67f6d   Michael Krummsdorf   drm/panel: simple...
1411
1412
  	.connector_type = DRM_MODE_CONNECTOR_DPI,
  };
982f944ed   Giulio Benetti   drm/panel: add pa...
1413
1414
1415
1416
1417
1418
1419
1420
1421
1422
  static const struct drm_display_mode cdtech_s070wv95_ct16_mode = {
  	.clock = 35000,
  	.hdisplay = 800,
  	.hsync_start = 800 + 40,
  	.hsync_end = 800 + 40 + 40,
  	.htotal = 800 + 40 + 40 + 48,
  	.vdisplay = 480,
  	.vsync_start = 480 + 29,
  	.vsync_end = 480 + 29 + 13,
  	.vtotal = 480 + 29 + 13 + 3,
982f944ed   Giulio Benetti   drm/panel: add pa...
1423
1424
1425
1426
1427
1428
1429
1430
1431
1432
1433
1434
  	.flags = DRM_MODE_FLAG_NHSYNC | DRM_MODE_FLAG_NVSYNC,
  };
  
  static const struct panel_desc cdtech_s070wv95_ct16 = {
  	.modes = &cdtech_s070wv95_ct16_mode,
  	.num_modes = 1,
  	.bpc = 8,
  	.size = {
  		.width = 154,
  		.height = 85,
  	},
  };
07c913c4d   Marek Vasut   drm/panel: simple...
1435
1436
1437
1438
1439
1440
1441
1442
1443
1444
1445
1446
1447
1448
1449
1450
1451
1452
1453
1454
1455
1456
1457
1458
1459
1460
1461
1462
1463
  static const struct display_timing chefree_ch101olhlwh_002_timing = {
  	.pixelclock = { 68900000, 71100000, 73400000 },
  	.hactive = { 1280, 1280, 1280 },
  	.hfront_porch = { 65, 80, 95 },
  	.hback_porch = { 64, 79, 94 },
  	.hsync_len = { 1, 1, 1 },
  	.vactive = { 800, 800, 800 },
  	.vfront_porch = { 7, 11, 14 },
  	.vback_porch = { 7, 11, 14 },
  	.vsync_len = { 1, 1, 1 },
  	.flags = DISPLAY_FLAGS_DE_HIGH,
  };
  
  static const struct panel_desc chefree_ch101olhlwh_002 = {
  	.timings = &chefree_ch101olhlwh_002_timing,
  	.num_timings = 1,
  	.bpc = 8,
  	.size = {
  		.width = 217,
  		.height = 135,
  	},
  	.delay = {
  		.enable = 200,
  		.disable = 200,
  	},
  	.bus_flags = DRM_BUS_FLAG_DE_HIGH,
  	.bus_format = MEDIA_BUS_FMT_RGB888_1X7X4_SPWG,
  	.connector_type = DRM_MODE_CONNECTOR_LVDS,
  };
2cb35c802   Randy Li   drm/panel: Add su...
1464
1465
1466
1467
1468
1469
1470
1471
1472
1473
  static const struct drm_display_mode chunghwa_claa070wp03xg_mode = {
  	.clock = 66770,
  	.hdisplay = 800,
  	.hsync_start = 800 + 49,
  	.hsync_end = 800 + 49 + 33,
  	.htotal = 800 + 49 + 33 + 17,
  	.vdisplay = 1280,
  	.vsync_start = 1280 + 1,
  	.vsync_end = 1280 + 1 + 7,
  	.vtotal = 1280 + 1 + 7 + 15,
2cb35c802   Randy Li   drm/panel: Add su...
1474
1475
1476
1477
1478
1479
1480
1481
1482
1483
1484
  	.flags = DRM_MODE_FLAG_NVSYNC | DRM_MODE_FLAG_NHSYNC,
  };
  
  static const struct panel_desc chunghwa_claa070wp03xg = {
  	.modes = &chunghwa_claa070wp03xg_mode,
  	.num_modes = 1,
  	.bpc = 6,
  	.size = {
  		.width = 94,
  		.height = 150,
  	},
855608296   Dmitry Osipenko   drm/panel-simple:...
1485
  	.bus_format = MEDIA_BUS_FMT_RGB666_1X7X3_SPWG,
c4715837b   Laurent Pinchart   drm: panel: simpl...
1486
  	.bus_flags = DRM_BUS_FLAG_DE_HIGH,
94f07917e   Dmitry Osipenko   drm/panel-simple:...
1487
  	.connector_type = DRM_MODE_CONNECTOR_LVDS,
2cb35c802   Randy Li   drm/panel: Add su...
1488
  };
4c9307577   Stephen Warren   drm/panel: Add su...
1489
1490
1491
1492
1493
1494
1495
1496
1497
1498
  static const struct drm_display_mode chunghwa_claa101wa01a_mode = {
  	.clock = 72070,
  	.hdisplay = 1366,
  	.hsync_start = 1366 + 58,
  	.hsync_end = 1366 + 58 + 58,
  	.htotal = 1366 + 58 + 58 + 58,
  	.vdisplay = 768,
  	.vsync_start = 768 + 4,
  	.vsync_end = 768 + 4 + 4,
  	.vtotal = 768 + 4 + 4 + 4,
4c9307577   Stephen Warren   drm/panel: Add su...
1499
1500
1501
1502
1503
  };
  
  static const struct panel_desc chunghwa_claa101wa01a = {
  	.modes = &chunghwa_claa101wa01a_mode,
  	.num_modes = 1,
0208d5111   Stéphane Marchesin   drm/panel: simple...
1504
  	.bpc = 6,
4c9307577   Stephen Warren   drm/panel: Add su...
1505
1506
1507
1508
  	.size = {
  		.width = 220,
  		.height = 120,
  	},
855608296   Dmitry Osipenko   drm/panel-simple:...
1509
  	.bus_format = MEDIA_BUS_FMT_RGB666_1X7X3_SPWG,
c4715837b   Laurent Pinchart   drm: panel: simpl...
1510
  	.bus_flags = DRM_BUS_FLAG_DE_HIGH,
94f07917e   Dmitry Osipenko   drm/panel-simple:...
1511
  	.connector_type = DRM_MODE_CONNECTOR_LVDS,
4c9307577   Stephen Warren   drm/panel: Add su...
1512
  };
280921de7   Thierry Reding   drm/panel: Add si...
1513
1514
1515
1516
1517
1518
1519
1520
1521
1522
  static const struct drm_display_mode chunghwa_claa101wb01_mode = {
  	.clock = 69300,
  	.hdisplay = 1366,
  	.hsync_start = 1366 + 48,
  	.hsync_end = 1366 + 48 + 32,
  	.htotal = 1366 + 48 + 32 + 20,
  	.vdisplay = 768,
  	.vsync_start = 768 + 16,
  	.vsync_end = 768 + 16 + 8,
  	.vtotal = 768 + 16 + 8 + 16,
280921de7   Thierry Reding   drm/panel: Add si...
1523
1524
1525
1526
1527
  };
  
  static const struct panel_desc chunghwa_claa101wb01 = {
  	.modes = &chunghwa_claa101wb01_mode,
  	.num_modes = 1,
0208d5111   Stéphane Marchesin   drm/panel: simple...
1528
  	.bpc = 6,
280921de7   Thierry Reding   drm/panel: Add si...
1529
1530
1531
1532
  	.size = {
  		.width = 223,
  		.height = 125,
  	},
855608296   Dmitry Osipenko   drm/panel-simple:...
1533
  	.bus_format = MEDIA_BUS_FMT_RGB666_1X7X3_SPWG,
c4715837b   Laurent Pinchart   drm: panel: simpl...
1534
  	.bus_flags = DRM_BUS_FLAG_DE_HIGH,
94f07917e   Dmitry Osipenko   drm/panel-simple:...
1535
  	.connector_type = DRM_MODE_CONNECTOR_LVDS,
280921de7   Thierry Reding   drm/panel: Add si...
1536
  };
97ceb1fb0   Michal Vokáč   drm/panel: simple...
1537
1538
1539
1540
1541
1542
1543
1544
1545
1546
  static const struct drm_display_mode dataimage_scf0700c48ggu18_mode = {
  	.clock = 33260,
  	.hdisplay = 800,
  	.hsync_start = 800 + 40,
  	.hsync_end = 800 + 40 + 128,
  	.htotal = 800 + 40 + 128 + 88,
  	.vdisplay = 480,
  	.vsync_start = 480 + 10,
  	.vsync_end = 480 + 10 + 2,
  	.vtotal = 480 + 10 + 2 + 33,
97ceb1fb0   Michal Vokáč   drm/panel: simple...
1547
1548
1549
1550
1551
1552
1553
1554
1555
1556
1557
1558
  	.flags = DRM_MODE_FLAG_NVSYNC | DRM_MODE_FLAG_NHSYNC,
  };
  
  static const struct panel_desc dataimage_scf0700c48ggu18 = {
  	.modes = &dataimage_scf0700c48ggu18_mode,
  	.num_modes = 1,
  	.bpc = 8,
  	.size = {
  		.width = 152,
  		.height = 91,
  	},
  	.bus_format = MEDIA_BUS_FMT_RGB888_1X24,
88bc41785   Laurent Pinchart   drm: Use new DRM_...
1559
  	.bus_flags = DRM_BUS_FLAG_DE_HIGH | DRM_BUS_FLAG_PIXDATA_DRIVE_POSEDGE,
97ceb1fb0   Michal Vokáč   drm/panel: simple...
1560
  };
0ca0c827e   Philipp Zabel   drm/panel: simple...
1561
1562
1563
1564
1565
1566
1567
1568
1569
1570
1571
1572
1573
1574
1575
1576
1577
1578
1579
1580
1581
1582
1583
1584
1585
1586
1587
  static const struct display_timing dlc_dlc0700yzg_1_timing = {
  	.pixelclock = { 45000000, 51200000, 57000000 },
  	.hactive = { 1024, 1024, 1024 },
  	.hfront_porch = { 100, 106, 113 },
  	.hback_porch = { 100, 106, 113 },
  	.hsync_len = { 100, 108, 114 },
  	.vactive = { 600, 600, 600 },
  	.vfront_porch = { 8, 11, 15 },
  	.vback_porch = { 8, 11, 15 },
  	.vsync_len = { 9, 13, 15 },
  	.flags = DISPLAY_FLAGS_DE_HIGH,
  };
  
  static const struct panel_desc dlc_dlc0700yzg_1 = {
  	.timings = &dlc_dlc0700yzg_1_timing,
  	.num_timings = 1,
  	.bpc = 6,
  	.size = {
  		.width = 154,
  		.height = 86,
  	},
  	.delay = {
  		.prepare = 30,
  		.enable = 200,
  		.disable = 200,
  	},
  	.bus_format = MEDIA_BUS_FMT_RGB666_1X7X3_SPWG,
9a2654c0f   Laurent Pinchart   drm/panel: Add an...
1588
  	.connector_type = DRM_MODE_CONNECTOR_LVDS,
0ca0c827e   Philipp Zabel   drm/panel: simple...
1589
  };
6cbe7cd15   Marco Felsch   drm/panel: simple...
1590
1591
1592
1593
1594
1595
1596
1597
1598
1599
1600
1601
1602
1603
1604
1605
1606
1607
1608
1609
1610
1611
1612
1613
1614
1615
1616
1617
  static const struct display_timing dlc_dlc1010gig_timing = {
  	.pixelclock = { 68900000, 71100000, 73400000 },
  	.hactive = { 1280, 1280, 1280 },
  	.hfront_porch = { 43, 53, 63 },
  	.hback_porch = { 43, 53, 63 },
  	.hsync_len = { 44, 54, 64 },
  	.vactive = { 800, 800, 800 },
  	.vfront_porch = { 5, 8, 11 },
  	.vback_porch = { 5, 8, 11 },
  	.vsync_len = { 5, 7, 11 },
  	.flags = DISPLAY_FLAGS_DE_HIGH,
  };
  
  static const struct panel_desc dlc_dlc1010gig = {
  	.timings = &dlc_dlc1010gig_timing,
  	.num_timings = 1,
  	.bpc = 8,
  	.size = {
  		.width = 216,
  		.height = 135,
  	},
  	.delay = {
  		.prepare = 60,
  		.enable = 150,
  		.disable = 100,
  		.unprepare = 60,
  	},
  	.bus_format = MEDIA_BUS_FMT_RGB888_1X7X4_SPWG,
9a2654c0f   Laurent Pinchart   drm/panel: Add an...
1618
  	.connector_type = DRM_MODE_CONNECTOR_LVDS,
6cbe7cd15   Marco Felsch   drm/panel: simple...
1619
  };
c2d24af62   Andreas Pretzsch   drm/panel: simple...
1620
1621
1622
1623
1624
1625
1626
1627
1628
1629
  static const struct drm_display_mode edt_et035012dm6_mode = {
  	.clock = 6500,
  	.hdisplay = 320,
  	.hsync_start = 320 + 20,
  	.hsync_end = 320 + 20 + 30,
  	.htotal = 320 + 20 + 68,
  	.vdisplay = 240,
  	.vsync_start = 240 + 4,
  	.vsync_end = 240 + 4 + 4,
  	.vtotal = 240 + 4 + 4 + 14,
c2d24af62   Andreas Pretzsch   drm/panel: simple...
1630
1631
1632
1633
1634
1635
1636
1637
1638
1639
1640
1641
  	.flags = DRM_MODE_FLAG_NVSYNC | DRM_MODE_FLAG_NHSYNC,
  };
  
  static const struct panel_desc edt_et035012dm6 = {
  	.modes = &edt_et035012dm6_mode,
  	.num_modes = 1,
  	.bpc = 8,
  	.size = {
  		.width = 70,
  		.height = 52,
  	},
  	.bus_format = MEDIA_BUS_FMT_RGB888_1X24,
f5436f774   Sam Ravnborg   drm/panel: panel-...
1642
  	.bus_flags = DRM_BUS_FLAG_DE_LOW | DRM_BUS_FLAG_PIXDATA_SAMPLE_POSEDGE,
c2d24af62   Andreas Pretzsch   drm/panel: simple...
1643
  };
82d57a590   Marian-Cristian Rotariu   drm/panel: simple...
1644
1645
1646
1647
1648
1649
1650
1651
1652
1653
1654
1655
1656
1657
1658
1659
  static const struct drm_display_mode edt_etm043080dh6gp_mode = {
  	.clock = 10870,
  	.hdisplay = 480,
  	.hsync_start = 480 + 8,
  	.hsync_end = 480 + 8 + 4,
  	.htotal = 480 + 8 + 4 + 41,
  
  	/*
  	 * IWG22M: Y resolution changed for "dc_linuxfb" module crashing while
  	 * fb_align
  	 */
  
  	.vdisplay = 288,
  	.vsync_start = 288 + 2,
  	.vsync_end = 288 + 2 + 4,
  	.vtotal = 288 + 2 + 4 + 10,
82d57a590   Marian-Cristian Rotariu   drm/panel: simple...
1660
1661
1662
1663
1664
1665
1666
1667
1668
1669
1670
1671
1672
  };
  
  static const struct panel_desc edt_etm043080dh6gp = {
  	.modes = &edt_etm043080dh6gp_mode,
  	.num_modes = 1,
  	.bpc = 8,
  	.size = {
  		.width = 100,
  		.height = 65,
  	},
  	.bus_format = MEDIA_BUS_FMT_RGB666_1X18,
  	.connector_type = DRM_MODE_CONNECTOR_DPI,
  };
fd819bff3   Marek Vasut   drm/panel: Add su...
1673
1674
1675
1676
1677
1678
1679
1680
1681
1682
  static const struct drm_display_mode edt_etm0430g0dh6_mode = {
  	.clock = 9000,
  	.hdisplay = 480,
  	.hsync_start = 480 + 2,
  	.hsync_end = 480 + 2 + 41,
  	.htotal = 480 + 2 + 41 + 2,
  	.vdisplay = 272,
  	.vsync_start = 272 + 2,
  	.vsync_end = 272 + 2 + 10,
  	.vtotal = 272 + 2 + 10 + 2,
fd819bff3   Marek Vasut   drm/panel: Add su...
1683
1684
1685
1686
1687
1688
1689
1690
1691
1692
1693
1694
  	.flags = DRM_MODE_FLAG_NHSYNC | DRM_MODE_FLAG_NVSYNC,
  };
  
  static const struct panel_desc edt_etm0430g0dh6 = {
  	.modes = &edt_etm0430g0dh6_mode,
  	.num_modes = 1,
  	.bpc = 6,
  	.size = {
  		.width = 95,
  		.height = 54,
  	},
  };
26ab00657   Stefan Agner   drm/panel: add su...
1695
1696
1697
1698
1699
1700
1701
1702
1703
1704
  static const struct drm_display_mode edt_et057090dhu_mode = {
  	.clock = 25175,
  	.hdisplay = 640,
  	.hsync_start = 640 + 16,
  	.hsync_end = 640 + 16 + 30,
  	.htotal = 640 + 16 + 30 + 114,
  	.vdisplay = 480,
  	.vsync_start = 480 + 10,
  	.vsync_end = 480 + 10 + 3,
  	.vtotal = 480 + 10 + 3 + 32,
26ab00657   Stefan Agner   drm/panel: add su...
1705
1706
1707
1708
1709
1710
  	.flags = DRM_MODE_FLAG_NVSYNC | DRM_MODE_FLAG_NHSYNC,
  };
  
  static const struct panel_desc edt_et057090dhu = {
  	.modes = &edt_et057090dhu_mode,
  	.num_modes = 1,
0208d5111   Stéphane Marchesin   drm/panel: simple...
1711
  	.bpc = 6,
26ab00657   Stefan Agner   drm/panel: add su...
1712
1713
1714
1715
  	.size = {
  		.width = 115,
  		.height = 86,
  	},
eaeebffa9   Stefan Agner   drm/panel: simple...
1716
  	.bus_format = MEDIA_BUS_FMT_RGB666_1X18,
88bc41785   Laurent Pinchart   drm: Use new DRM_...
1717
  	.bus_flags = DRM_BUS_FLAG_DE_HIGH | DRM_BUS_FLAG_PIXDATA_DRIVE_NEGEDGE,
75e732246   Dmitry Osipenko   drm/panel-simple:...
1718
  	.connector_type = DRM_MODE_CONNECTOR_DPI,
26ab00657   Stefan Agner   drm/panel: add su...
1719
  };
fff5de45e   Philipp Zabel   drm/panel: Add su...
1720
1721
1722
1723
1724
1725
1726
1727
1728
1729
  static const struct drm_display_mode edt_etm0700g0dh6_mode = {
  	.clock = 33260,
  	.hdisplay = 800,
  	.hsync_start = 800 + 40,
  	.hsync_end = 800 + 40 + 128,
  	.htotal = 800 + 40 + 128 + 88,
  	.vdisplay = 480,
  	.vsync_start = 480 + 10,
  	.vsync_end = 480 + 10 + 2,
  	.vtotal = 480 + 10 + 2 + 33,
fff5de45e   Philipp Zabel   drm/panel: Add su...
1730
1731
1732
1733
1734
1735
  	.flags = DRM_MODE_FLAG_NHSYNC | DRM_MODE_FLAG_NVSYNC,
  };
  
  static const struct panel_desc edt_etm0700g0dh6 = {
  	.modes = &edt_etm0700g0dh6_mode,
  	.num_modes = 1,
0208d5111   Stéphane Marchesin   drm/panel: simple...
1736
  	.bpc = 6,
fff5de45e   Philipp Zabel   drm/panel: Add su...
1737
1738
1739
1740
  	.size = {
  		.width = 152,
  		.height = 91,
  	},
eaeebffa9   Stefan Agner   drm/panel: simple...
1741
  	.bus_format = MEDIA_BUS_FMT_RGB666_1X18,
88bc41785   Laurent Pinchart   drm: Use new DRM_...
1742
  	.bus_flags = DRM_BUS_FLAG_DE_HIGH | DRM_BUS_FLAG_PIXDATA_DRIVE_NEGEDGE,
fff5de45e   Philipp Zabel   drm/panel: Add su...
1743
  };
aa7e6455e   Jan Tuerk   drm/panel: Add su...
1744
1745
1746
1747
1748
1749
1750
1751
1752
  static const struct panel_desc edt_etm0700g0bdh6 = {
  	.modes = &edt_etm0700g0dh6_mode,
  	.num_modes = 1,
  	.bpc = 6,
  	.size = {
  		.width = 152,
  		.height = 91,
  	},
  	.bus_format = MEDIA_BUS_FMT_RGB666_1X18,
88bc41785   Laurent Pinchart   drm: Use new DRM_...
1753
  	.bus_flags = DRM_BUS_FLAG_DE_HIGH | DRM_BUS_FLAG_PIXDATA_DRIVE_POSEDGE,
aa7e6455e   Jan Tuerk   drm/panel: Add su...
1754
  };
9158e3c31   Marco Felsch   drm/panel: simple...
1755
1756
1757
1758
1759
1760
1761
1762
1763
1764
1765
1766
1767
1768
1769
1770
1771
1772
1773
1774
1775
1776
1777
1778
  static const struct display_timing evervision_vgg804821_timing = {
  	.pixelclock = { 27600000, 33300000, 50000000 },
  	.hactive = { 800, 800, 800 },
  	.hfront_porch = { 40, 66, 70 },
  	.hback_porch = { 40, 67, 70 },
  	.hsync_len = { 40, 67, 70 },
  	.vactive = { 480, 480, 480 },
  	.vfront_porch = { 6, 10, 10 },
  	.vback_porch = { 7, 11, 11 },
  	.vsync_len = { 7, 11, 11 },
  	.flags = DISPLAY_FLAGS_HSYNC_HIGH | DISPLAY_FLAGS_VSYNC_HIGH |
  		 DISPLAY_FLAGS_DE_HIGH | DISPLAY_FLAGS_PIXDATA_NEGEDGE |
  		 DISPLAY_FLAGS_SYNC_NEGEDGE,
  };
  
  static const struct panel_desc evervision_vgg804821 = {
  	.timings = &evervision_vgg804821_timing,
  	.num_timings = 1,
  	.bpc = 8,
  	.size = {
  		.width = 108,
  		.height = 64,
  	},
  	.bus_format = MEDIA_BUS_FMT_RGB888_1X24,
f5436f774   Sam Ravnborg   drm/panel: panel-...
1779
  	.bus_flags = DRM_BUS_FLAG_DE_HIGH | DRM_BUS_FLAG_PIXDATA_SAMPLE_POSEDGE,
9158e3c31   Marco Felsch   drm/panel: simple...
1780
  };
102932b0e   Boris BREZILLON   drm/panel: add su...
1781
1782
1783
1784
1785
1786
1787
1788
1789
1790
  static const struct drm_display_mode foxlink_fl500wvr00_a0t_mode = {
  	.clock = 32260,
  	.hdisplay = 800,
  	.hsync_start = 800 + 168,
  	.hsync_end = 800 + 168 + 64,
  	.htotal = 800 + 168 + 64 + 88,
  	.vdisplay = 480,
  	.vsync_start = 480 + 37,
  	.vsync_end = 480 + 37 + 2,
  	.vtotal = 480 + 37 + 2 + 8,
102932b0e   Boris BREZILLON   drm/panel: add su...
1791
1792
1793
1794
1795
  };
  
  static const struct panel_desc foxlink_fl500wvr00_a0t = {
  	.modes = &foxlink_fl500wvr00_a0t_mode,
  	.num_modes = 1,
d7a839cde   Thierry Reding   drm/panel: simple...
1796
  	.bpc = 8,
102932b0e   Boris BREZILLON   drm/panel: add su...
1797
1798
1799
1800
  	.size = {
  		.width = 108,
  		.height = 65,
  	},
bb276cb3a   Boris Brezillon   drm: panel: simpl...
1801
  	.bus_format = MEDIA_BUS_FMT_RGB888_1X24,
102932b0e   Boris BREZILLON   drm/panel: add su...
1802
  };
795db2afd   Paul Cercueil   drm/panel-simple:...
1803
1804
1805
1806
1807
1808
1809
1810
1811
1812
1813
1814
1815
1816
1817
1818
1819
1820
1821
1822
1823
1824
1825
1826
1827
  static const struct drm_display_mode frida_frd350h54004_modes[] = {
  	{ /* 60 Hz */
  		.clock = 6000,
  		.hdisplay = 320,
  		.hsync_start = 320 + 44,
  		.hsync_end = 320 + 44 + 16,
  		.htotal = 320 + 44 + 16 + 20,
  		.vdisplay = 240,
  		.vsync_start = 240 + 2,
  		.vsync_end = 240 + 2 + 6,
  		.vtotal = 240 + 2 + 6 + 2,
  		.flags = DRM_MODE_FLAG_NHSYNC | DRM_MODE_FLAG_NVSYNC,
  	},
  	{ /* 50 Hz */
  		.clock = 5400,
  		.hdisplay = 320,
  		.hsync_start = 320 + 56,
  		.hsync_end = 320 + 56 + 16,
  		.htotal = 320 + 56 + 16 + 40,
  		.vdisplay = 240,
  		.vsync_start = 240 + 2,
  		.vsync_end = 240 + 2 + 6,
  		.vtotal = 240 + 2 + 6 + 2,
  		.flags = DRM_MODE_FLAG_NHSYNC | DRM_MODE_FLAG_NVSYNC,
  	},
7b6bd8433   Paul Cercueil   drm/panel: simple...
1828
1829
1830
  };
  
  static const struct panel_desc frida_frd350h54004 = {
795db2afd   Paul Cercueil   drm/panel-simple:...
1831
1832
  	.modes = frida_frd350h54004_modes,
  	.num_modes = ARRAY_SIZE(frida_frd350h54004_modes),
7b6bd8433   Paul Cercueil   drm/panel: simple...
1833
1834
1835
1836
1837
1838
  	.bpc = 8,
  	.size = {
  		.width = 77,
  		.height = 64,
  	},
  	.bus_format = MEDIA_BUS_FMT_RGB888_1X24,
f5436f774   Sam Ravnborg   drm/panel: panel-...
1839
  	.bus_flags = DRM_BUS_FLAG_DE_HIGH | DRM_BUS_FLAG_PIXDATA_SAMPLE_NEGEDGE,
7b6bd8433   Paul Cercueil   drm/panel: simple...
1840
1841
  	.connector_type = DRM_MODE_CONNECTOR_DPI,
  };
3be207100   Jagan Teki   drm/panel: simple...
1842
1843
1844
1845
1846
1847
1848
1849
1850
1851
  static const struct drm_display_mode friendlyarm_hd702e_mode = {
  	.clock		= 67185,
  	.hdisplay	= 800,
  	.hsync_start	= 800 + 20,
  	.hsync_end	= 800 + 20 + 24,
  	.htotal		= 800 + 20 + 24 + 20,
  	.vdisplay	= 1280,
  	.vsync_start	= 1280 + 4,
  	.vsync_end	= 1280 + 4 + 8,
  	.vtotal		= 1280 + 4 + 8 + 4,
3be207100   Jagan Teki   drm/panel: simple...
1852
1853
1854
1855
1856
1857
1858
1859
1860
1861
1862
  	.flags		= DRM_MODE_FLAG_NVSYNC | DRM_MODE_FLAG_NHSYNC,
  };
  
  static const struct panel_desc friendlyarm_hd702e = {
  	.modes = &friendlyarm_hd702e_mode,
  	.num_modes = 1,
  	.size = {
  		.width	= 94,
  		.height	= 151,
  	},
  };
d435a2af1   Philipp Zabel   drm/panel: simple...
1863
1864
1865
1866
1867
1868
1869
1870
1871
1872
  static const struct drm_display_mode giantplus_gpg482739qs5_mode = {
  	.clock = 9000,
  	.hdisplay = 480,
  	.hsync_start = 480 + 5,
  	.hsync_end = 480 + 5 + 1,
  	.htotal = 480 + 5 + 1 + 40,
  	.vdisplay = 272,
  	.vsync_start = 272 + 8,
  	.vsync_end = 272 + 8 + 1,
  	.vtotal = 272 + 8 + 1 + 8,
d435a2af1   Philipp Zabel   drm/panel: simple...
1873
1874
1875
1876
1877
1878
1879
1880
1881
1882
  };
  
  static const struct panel_desc giantplus_gpg482739qs5 = {
  	.modes = &giantplus_gpg482739qs5_mode,
  	.num_modes = 1,
  	.bpc = 8,
  	.size = {
  		.width = 95,
  		.height = 54,
  	},
33536a09f   Philipp Zabel   drm/panel: Add bu...
1883
  	.bus_format = MEDIA_BUS_FMT_RGB888_1X24,
d435a2af1   Philipp Zabel   drm/panel: simple...
1884
  };
2c6574a9e   Paul Cercueil   drm/panel: simple...
1885
1886
1887
1888
1889
1890
1891
1892
1893
1894
1895
1896
1897
1898
1899
1900
1901
1902
1903
1904
1905
1906
  static const struct display_timing giantplus_gpm940b0_timing = {
  	.pixelclock = { 13500000, 27000000, 27500000 },
  	.hactive = { 320, 320, 320 },
  	.hfront_porch = { 14, 686, 718 },
  	.hback_porch = { 50, 70, 255 },
  	.hsync_len = { 1, 1, 1 },
  	.vactive = { 240, 240, 240 },
  	.vfront_porch = { 1, 1, 179 },
  	.vback_porch = { 1, 21, 31 },
  	.vsync_len = { 1, 1, 6 },
  	.flags = DISPLAY_FLAGS_HSYNC_LOW | DISPLAY_FLAGS_VSYNC_LOW,
  };
  
  static const struct panel_desc giantplus_gpm940b0 = {
  	.timings = &giantplus_gpm940b0_timing,
  	.num_timings = 1,
  	.bpc = 8,
  	.size = {
  		.width = 60,
  		.height = 45,
  	},
  	.bus_format = MEDIA_BUS_FMT_RGB888_3X8,
f5436f774   Sam Ravnborg   drm/panel: panel-...
1907
  	.bus_flags = DRM_BUS_FLAG_DE_HIGH | DRM_BUS_FLAG_PIXDATA_SAMPLE_POSEDGE,
2c6574a9e   Paul Cercueil   drm/panel: simple...
1908
  };
ab07725ab   Philipp Zabel   drm/panel: Add di...
1909
1910
1911
1912
1913
  static const struct display_timing hannstar_hsd070pww1_timing = {
  	.pixelclock = { 64300000, 71100000, 82000000 },
  	.hactive = { 1280, 1280, 1280 },
  	.hfront_porch = { 1, 1, 10 },
  	.hback_porch = { 1, 1, 10 },
d901d2ba8   Philipp Zabel   drm/panel: simple...
1914
1915
1916
1917
1918
1919
  	/*
  	 * According to the data sheet, the minimum horizontal blanking interval
  	 * is 54 clocks (1 + 52 + 1), but tests with a Nitrogen6X have shown the
  	 * minimum working horizontal blanking interval to be 60 clocks.
  	 */
  	.hsync_len = { 58, 158, 661 },
ab07725ab   Philipp Zabel   drm/panel: Add di...
1920
1921
1922
1923
1924
  	.vactive = { 800, 800, 800 },
  	.vfront_porch = { 1, 1, 10 },
  	.vback_porch = { 1, 1, 10 },
  	.vsync_len = { 1, 21, 203 },
  	.flags = DISPLAY_FLAGS_DE_HIGH,
a853205ef   Philipp Zabel   drm/panel: simple...
1925
1926
1927
  };
  
  static const struct panel_desc hannstar_hsd070pww1 = {
ab07725ab   Philipp Zabel   drm/panel: Add di...
1928
1929
  	.timings = &hannstar_hsd070pww1_timing,
  	.num_timings = 1,
a853205ef   Philipp Zabel   drm/panel: simple...
1930
1931
1932
1933
1934
  	.bpc = 6,
  	.size = {
  		.width = 151,
  		.height = 94,
  	},
58d6a7bc4   Philipp Zabel   drm/panel: simple...
1935
  	.bus_format = MEDIA_BUS_FMT_RGB666_1X7X3_SPWG,
9a2654c0f   Laurent Pinchart   drm/panel: Add an...
1936
  	.connector_type = DRM_MODE_CONNECTOR_LVDS,
a853205ef   Philipp Zabel   drm/panel: simple...
1937
  };
c0d607e5a   Eric Nelson   drm/panel: simple...
1938
1939
1940
1941
1942
1943
1944
1945
1946
1947
1948
1949
1950
1951
1952
1953
1954
1955
1956
1957
1958
  static const struct display_timing hannstar_hsd100pxn1_timing = {
  	.pixelclock = { 55000000, 65000000, 75000000 },
  	.hactive = { 1024, 1024, 1024 },
  	.hfront_porch = { 40, 40, 40 },
  	.hback_porch = { 220, 220, 220 },
  	.hsync_len = { 20, 60, 100 },
  	.vactive = { 768, 768, 768 },
  	.vfront_porch = { 7, 7, 7 },
  	.vback_porch = { 21, 21, 21 },
  	.vsync_len = { 10, 10, 10 },
  	.flags = DISPLAY_FLAGS_DE_HIGH,
  };
  
  static const struct panel_desc hannstar_hsd100pxn1 = {
  	.timings = &hannstar_hsd100pxn1_timing,
  	.num_timings = 1,
  	.bpc = 6,
  	.size = {
  		.width = 203,
  		.height = 152,
  	},
4946b0430   Philipp Zabel   drm/panel: simple...
1959
  	.bus_format = MEDIA_BUS_FMT_RGB666_1X7X3_SPWG,
9a2654c0f   Laurent Pinchart   drm/panel: Add an...
1960
  	.connector_type = DRM_MODE_CONNECTOR_LVDS,
c0d607e5a   Eric Nelson   drm/panel: simple...
1961
  };
61ac0bf89   Lucas Stach   drm/panel: simple...
1962
1963
1964
1965
1966
1967
1968
1969
1970
1971
  static const struct drm_display_mode hitachi_tx23d38vm0caa_mode = {
  	.clock = 33333,
  	.hdisplay = 800,
  	.hsync_start = 800 + 85,
  	.hsync_end = 800 + 85 + 86,
  	.htotal = 800 + 85 + 86 + 85,
  	.vdisplay = 480,
  	.vsync_start = 480 + 16,
  	.vsync_end = 480 + 16 + 13,
  	.vtotal = 480 + 16 + 13 + 16,
61ac0bf89   Lucas Stach   drm/panel: simple...
1972
1973
1974
1975
1976
1977
1978
1979
1980
1981
  };
  
  static const struct panel_desc hitachi_tx23d38vm0caa = {
  	.modes = &hitachi_tx23d38vm0caa_mode,
  	.num_modes = 1,
  	.bpc = 6,
  	.size = {
  		.width = 195,
  		.height = 117,
  	},
6c684e3b6   Philipp Zabel   drm/panel: simple...
1982
1983
1984
1985
  	.delay = {
  		.enable = 160,
  		.disable = 160,
  	},
61ac0bf89   Lucas Stach   drm/panel: simple...
1986
  };
41bcceb4d   Nicolas Ferre   drm/panel: simple...
1987
1988
1989
1990
1991
1992
1993
1994
  static const struct drm_display_mode innolux_at043tn24_mode = {
  	.clock = 9000,
  	.hdisplay = 480,
  	.hsync_start = 480 + 2,
  	.hsync_end = 480 + 2 + 41,
  	.htotal = 480 + 2 + 41 + 2,
  	.vdisplay = 272,
  	.vsync_start = 272 + 2,
a483159d2   Philipp Zabel   drm/panel: simple...
1995
1996
  	.vsync_end = 272 + 2 + 10,
  	.vtotal = 272 + 2 + 10 + 2,
41bcceb4d   Nicolas Ferre   drm/panel: simple...
1997
1998
1999
2000
2001
2002
2003
2004
2005
2006
2007
2008
  	.flags = DRM_MODE_FLAG_NHSYNC | DRM_MODE_FLAG_NVSYNC,
  };
  
  static const struct panel_desc innolux_at043tn24 = {
  	.modes = &innolux_at043tn24_mode,
  	.num_modes = 1,
  	.bpc = 8,
  	.size = {
  		.width = 95,
  		.height = 54,
  	},
  	.bus_format = MEDIA_BUS_FMT_RGB888_1X24,
88bc41785   Laurent Pinchart   drm: Use new DRM_...
2009
  	.bus_flags = DRM_BUS_FLAG_DE_HIGH | DRM_BUS_FLAG_PIXDATA_DRIVE_POSEDGE,
41bcceb4d   Nicolas Ferre   drm/panel: simple...
2010
  };
4fc24ab3a   Riccardo Bortolato   drm/panel: simple...
2011
2012
2013
2014
2015
2016
2017
2018
2019
2020
  static const struct drm_display_mode innolux_at070tn92_mode = {
  	.clock = 33333,
  	.hdisplay = 800,
  	.hsync_start = 800 + 210,
  	.hsync_end = 800 + 210 + 20,
  	.htotal = 800 + 210 + 20 + 46,
  	.vdisplay = 480,
  	.vsync_start = 480 + 22,
  	.vsync_end = 480 + 22 + 10,
  	.vtotal = 480 + 22 + 23 + 10,
4fc24ab3a   Riccardo Bortolato   drm/panel: simple...
2021
2022
2023
2024
2025
2026
2027
2028
2029
2030
2031
  };
  
  static const struct panel_desc innolux_at070tn92 = {
  	.modes = &innolux_at070tn92_mode,
  	.num_modes = 1,
  	.size = {
  		.width = 154,
  		.height = 86,
  	},
  	.bus_format = MEDIA_BUS_FMT_RGB888_1X24,
  };
a5d2ade62   Christoph Fritz   drm/panel: simple...
2032
2033
2034
2035
2036
2037
2038
2039
2040
2041
2042
2043
2044
2045
2046
2047
2048
2049
2050
2051
2052
2053
2054
2055
2056
2057
2058
2059
  static const struct display_timing innolux_g070y2_l01_timing = {
  	.pixelclock = { 28000000, 29500000, 32000000 },
  	.hactive = { 800, 800, 800 },
  	.hfront_porch = { 61, 91, 141 },
  	.hback_porch = { 60, 90, 140 },
  	.hsync_len = { 12, 12, 12 },
  	.vactive = { 480, 480, 480 },
  	.vfront_porch = { 4, 9, 30 },
  	.vback_porch = { 4, 8, 28 },
  	.vsync_len = { 2, 2, 2 },
  	.flags = DISPLAY_FLAGS_DE_HIGH,
  };
  
  static const struct panel_desc innolux_g070y2_l01 = {
  	.timings = &innolux_g070y2_l01_timing,
  	.num_timings = 1,
  	.bpc = 6,
  	.size = {
  		.width = 152,
  		.height = 91,
  	},
  	.delay = {
  		.prepare = 10,
  		.enable = 100,
  		.disable = 100,
  		.unprepare = 800,
  	},
  	.bus_format = MEDIA_BUS_FMT_RGB888_1X7X4_SPWG,
9a2654c0f   Laurent Pinchart   drm/panel: Add an...
2060
  	.connector_type = DRM_MODE_CONNECTOR_LVDS,
a5d2ade62   Christoph Fritz   drm/panel: simple...
2061
  };
1e29b840a   Michael Olbrich   drm/panel: simple...
2062
2063
2064
2065
2066
2067
2068
2069
2070
2071
2072
2073
2074
2075
2076
2077
2078
2079
2080
2081
2082
2083
2084
2085
2086
2087
  static const struct display_timing innolux_g101ice_l01_timing = {
  	.pixelclock = { 60400000, 71100000, 74700000 },
  	.hactive = { 1280, 1280, 1280 },
  	.hfront_porch = { 41, 80, 100 },
  	.hback_porch = { 40, 79, 99 },
  	.hsync_len = { 1, 1, 1 },
  	.vactive = { 800, 800, 800 },
  	.vfront_porch = { 5, 11, 14 },
  	.vback_porch = { 4, 11, 14 },
  	.vsync_len = { 1, 1, 1 },
  	.flags = DISPLAY_FLAGS_DE_HIGH,
  };
  
  static const struct panel_desc innolux_g101ice_l01 = {
  	.timings = &innolux_g101ice_l01_timing,
  	.num_timings = 1,
  	.bpc = 8,
  	.size = {
  		.width = 217,
  		.height = 135,
  	},
  	.delay = {
  		.enable = 200,
  		.disable = 200,
  	},
  	.bus_format = MEDIA_BUS_FMT_RGB888_1X7X4_SPWG,
9a2654c0f   Laurent Pinchart   drm/panel: Add an...
2088
  	.connector_type = DRM_MODE_CONNECTOR_LVDS,
1e29b840a   Michael Olbrich   drm/panel: simple...
2089
  };
4ae13e486   Lucas Stach   drm/panel: simple...
2090
2091
2092
2093
2094
2095
2096
2097
2098
2099
  static const struct display_timing innolux_g121i1_l01_timing = {
  	.pixelclock = { 67450000, 71000000, 74550000 },
  	.hactive = { 1280, 1280, 1280 },
  	.hfront_porch = { 40, 80, 160 },
  	.hback_porch = { 39, 79, 159 },
  	.hsync_len = { 1, 1, 1 },
  	.vactive = { 800, 800, 800 },
  	.vfront_porch = { 5, 11, 100 },
  	.vback_porch = { 4, 11, 99 },
  	.vsync_len = { 1, 1, 1 },
d731f661b   Lucas Stach   drm/panel: simple...
2100
2101
2102
  };
  
  static const struct panel_desc innolux_g121i1_l01 = {
4ae13e486   Lucas Stach   drm/panel: simple...
2103
2104
  	.timings = &innolux_g121i1_l01_timing,
  	.num_timings = 1,
d731f661b   Lucas Stach   drm/panel: simple...
2105
2106
2107
2108
2109
  	.bpc = 6,
  	.size = {
  		.width = 261,
  		.height = 163,
  	},
4ae13e486   Lucas Stach   drm/panel: simple...
2110
2111
2112
2113
2114
  	.delay = {
  		.enable = 200,
  		.disable = 20,
  	},
  	.bus_format = MEDIA_BUS_FMT_RGB888_1X7X4_SPWG,
9a2654c0f   Laurent Pinchart   drm/panel: Add an...
2115
  	.connector_type = DRM_MODE_CONNECTOR_LVDS,
d731f661b   Lucas Stach   drm/panel: simple...
2116
  };
f8fa17ba8   Akshay Bhat   drm/panel: simple...
2117
2118
2119
2120
2121
2122
2123
2124
2125
2126
  static const struct drm_display_mode innolux_g121x1_l03_mode = {
  	.clock = 65000,
  	.hdisplay = 1024,
  	.hsync_start = 1024 + 0,
  	.hsync_end = 1024 + 1,
  	.htotal = 1024 + 0 + 1 + 320,
  	.vdisplay = 768,
  	.vsync_start = 768 + 38,
  	.vsync_end = 768 + 38 + 1,
  	.vtotal = 768 + 38 + 1 + 0,
2e8c5eb9e   Akshay Bhat   drm/panel: simple...
2127
  	.flags = DRM_MODE_FLAG_NHSYNC | DRM_MODE_FLAG_NVSYNC,
f8fa17ba8   Akshay Bhat   drm/panel: simple...
2128
2129
2130
2131
2132
2133
2134
2135
2136
2137
2138
2139
2140
2141
2142
2143
  };
  
  static const struct panel_desc innolux_g121x1_l03 = {
  	.modes = &innolux_g121x1_l03_mode,
  	.num_modes = 1,
  	.bpc = 6,
  	.size = {
  		.width = 246,
  		.height = 185,
  	},
  	.delay = {
  		.enable = 200,
  		.unprepare = 200,
  		.disable = 400,
  	},
  };
d719cbe9a   Douglas Anderson   drm/panel: simple...
2144
2145
2146
2147
2148
2149
2150
2151
2152
2153
2154
2155
2156
2157
2158
2159
2160
2161
2162
2163
2164
  /*
   * Datasheet specifies that at 60 Hz refresh rate:
   * - total horizontal time: { 1506, 1592, 1716 }
   * - total vertical time: { 788, 800, 868 }
   *
   * ...but doesn't go into exactly how that should be split into a front
   * porch, back porch, or sync length.  For now we'll leave a single setting
   * here which allows a bit of tweaking of the pixel clock at the expense of
   * refresh rate.
   */
  static const struct display_timing innolux_n116bge_timing = {
  	.pixelclock = { 72600000, 76420000, 80240000 },
  	.hactive = { 1366, 1366, 1366 },
  	.hfront_porch = { 136, 136, 136 },
  	.hback_porch = { 60, 60, 60 },
  	.hsync_len = { 30, 30, 30 },
  	.vactive = { 768, 768, 768 },
  	.vfront_porch = { 8, 8, 8 },
  	.vback_porch = { 12, 12, 12 },
  	.vsync_len = { 12, 12, 12 },
  	.flags = DISPLAY_FLAGS_VSYNC_LOW | DISPLAY_FLAGS_HSYNC_LOW,
0a2288c06   Thierry Reding   drm/panel: simple...
2165
2166
2167
  };
  
  static const struct panel_desc innolux_n116bge = {
d719cbe9a   Douglas Anderson   drm/panel: simple...
2168
2169
  	.timings = &innolux_n116bge_timing,
  	.num_timings = 1,
0a2288c06   Thierry Reding   drm/panel: simple...
2170
2171
2172
2173
2174
2175
  	.bpc = 6,
  	.size = {
  		.width = 256,
  		.height = 144,
  	},
  };
ea44739db   Alban Bedel   drm/panel: simple...
2176
2177
2178
2179
2180
2181
2182
2183
2184
2185
  static const struct drm_display_mode innolux_n156bge_l21_mode = {
  	.clock = 69300,
  	.hdisplay = 1366,
  	.hsync_start = 1366 + 16,
  	.hsync_end = 1366 + 16 + 34,
  	.htotal = 1366 + 16 + 34 + 50,
  	.vdisplay = 768,
  	.vsync_start = 768 + 2,
  	.vsync_end = 768 + 2 + 6,
  	.vtotal = 768 + 2 + 6 + 12,
ea44739db   Alban Bedel   drm/panel: simple...
2186
2187
2188
2189
2190
  };
  
  static const struct panel_desc innolux_n156bge_l21 = {
  	.modes = &innolux_n156bge_l21_mode,
  	.num_modes = 1,
0208d5111   Stéphane Marchesin   drm/panel: simple...
2191
  	.bpc = 6,
ea44739db   Alban Bedel   drm/panel: simple...
2192
2193
2194
2195
  	.size = {
  		.width = 344,
  		.height = 193,
  	},
855608296   Dmitry Osipenko   drm/panel-simple:...
2196
  	.bus_format = MEDIA_BUS_FMT_RGB666_1X7X3_SPWG,
c4715837b   Laurent Pinchart   drm: panel: simpl...
2197
  	.bus_flags = DRM_BUS_FLAG_DE_HIGH,
94f07917e   Dmitry Osipenko   drm/panel-simple:...
2198
  	.connector_type = DRM_MODE_CONNECTOR_LVDS,
ea44739db   Alban Bedel   drm/panel: simple...
2199
  };
8f054b6f5   Douglas Anderson   drm/panel: simple...
2200
  static const struct drm_display_mode innolux_p120zdg_bf1_mode = {
da50bd425   spanda@codeaurora.org   drm/panel: simple...
2201
2202
2203
2204
2205
2206
2207
2208
2209
  	.clock = 206016,
  	.hdisplay = 2160,
  	.hsync_start = 2160 + 48,
  	.hsync_end = 2160 + 48 + 32,
  	.htotal = 2160 + 48 + 32 + 80,
  	.vdisplay = 1440,
  	.vsync_start = 1440 + 3,
  	.vsync_end = 1440 + 3 + 10,
  	.vtotal = 1440 + 3 + 10 + 27,
da50bd425   spanda@codeaurora.org   drm/panel: simple...
2210
2211
  	.flags = DRM_MODE_FLAG_PHSYNC | DRM_MODE_FLAG_PVSYNC,
  };
8f054b6f5   Douglas Anderson   drm/panel: simple...
2212
2213
  static const struct panel_desc innolux_p120zdg_bf1 = {
  	.modes = &innolux_p120zdg_bf1_mode,
da50bd425   spanda@codeaurora.org   drm/panel: simple...
2214
2215
2216
  	.num_modes = 1,
  	.bpc = 8,
  	.size = {
8f054b6f5   Douglas Anderson   drm/panel: simple...
2217
2218
  		.width = 254,
  		.height = 169,
da50bd425   spanda@codeaurora.org   drm/panel: simple...
2219
  	},
22fd99e94   Sean Paul   drm/panel: simple...
2220
  	.delay = {
625d3b5c2   Douglas Anderson   drm/panel: simple...
2221
  		.hpd_absent_delay = 200,
22fd99e94   Sean Paul   drm/panel: simple...
2222
2223
  		.unprepare = 500,
  	},
da50bd425   spanda@codeaurora.org   drm/panel: simple...
2224
  };
bccac3f12   Michael Grzeschik   drm/panel: simple...
2225
2226
2227
2228
2229
2230
2231
2232
2233
2234
  static const struct drm_display_mode innolux_zj070na_01p_mode = {
  	.clock = 51501,
  	.hdisplay = 1024,
  	.hsync_start = 1024 + 128,
  	.hsync_end = 1024 + 128 + 64,
  	.htotal = 1024 + 128 + 64 + 128,
  	.vdisplay = 600,
  	.vsync_start = 600 + 16,
  	.vsync_end = 600 + 16 + 4,
  	.vtotal = 600 + 16 + 4 + 16,
bccac3f12   Michael Grzeschik   drm/panel: simple...
2235
2236
2237
2238
2239
2240
2241
  };
  
  static const struct panel_desc innolux_zj070na_01p = {
  	.modes = &innolux_zj070na_01p_mode,
  	.num_modes = 1,
  	.bpc = 6,
  	.size = {
815988464   Thierry Reding   drm/panel: simple...
2242
2243
  		.width = 154,
  		.height = 90,
bccac3f12   Michael Grzeschik   drm/panel: simple...
2244
2245
  	},
  };
e1ca51846   Bjorn Andersson   panel: simple: Ad...
2246
2247
2248
2249
2250
2251
2252
2253
2254
2255
  static const struct drm_display_mode ivo_m133nwf4_r0_mode = {
  	.clock = 138778,
  	.hdisplay = 1920,
  	.hsync_start = 1920 + 24,
  	.hsync_end = 1920 + 24 + 48,
  	.htotal = 1920 + 24 + 48 + 88,
  	.vdisplay = 1080,
  	.vsync_start = 1080 + 3,
  	.vsync_end = 1080 + 3 + 12,
  	.vtotal = 1080 + 3 + 12 + 17,
e1ca51846   Bjorn Andersson   panel: simple: Ad...
2256
2257
2258
2259
2260
2261
2262
2263
2264
2265
2266
2267
2268
2269
2270
2271
2272
2273
2274
  	.flags = DRM_MODE_FLAG_PHSYNC | DRM_MODE_FLAG_PVSYNC,
  };
  
  static const struct panel_desc ivo_m133nwf4_r0 = {
  	.modes = &ivo_m133nwf4_r0_mode,
  	.num_modes = 1,
  	.bpc = 8,
  	.size = {
  		.width = 294,
  		.height = 165,
  	},
  	.delay = {
  		.hpd_absent_delay = 200,
  		.unprepare = 500,
  	},
  	.bus_format = MEDIA_BUS_FMT_RGB888_1X24,
  	.bus_flags = DRM_BUS_FLAG_DATA_MSB_TO_LSB,
  	.connector_type = DRM_MODE_CONNECTOR_eDP,
  };
fc26a3758   Douglas Anderson   drm: panel: simpl...
2275
2276
2277
2278
2279
2280
2281
2282
2283
2284
2285
2286
2287
2288
2289
2290
2291
2292
2293
2294
2295
2296
2297
2298
2299
2300
2301
  static const struct drm_display_mode kingdisplay_kd116n21_30nv_a010_mode = {
  	.clock = 81000,
  	.hdisplay = 1366,
  	.hsync_start = 1366 + 40,
  	.hsync_end = 1366 + 40 + 32,
  	.htotal = 1366 + 40 + 32 + 62,
  	.vdisplay = 768,
  	.vsync_start = 768 + 5,
  	.vsync_end = 768 + 5 + 5,
  	.vtotal = 768 + 5 + 5 + 122,
  	.flags = DRM_MODE_FLAG_NVSYNC | DRM_MODE_FLAG_NHSYNC,
  };
  
  static const struct panel_desc kingdisplay_kd116n21_30nv_a010 = {
  	.modes = &kingdisplay_kd116n21_30nv_a010_mode,
  	.num_modes = 1,
  	.bpc = 6,
  	.size = {
  		.width = 256,
  		.height = 144,
  	},
  	.delay = {
  		.hpd_absent_delay = 200,
  	},
  	.bus_format = MEDIA_BUS_FMT_RGB666_1X18,
  	.connector_type = DRM_MODE_CONNECTOR_eDP,
  };
22014344a   Liu Ying   drm/panel: simple...
2302
2303
2304
2305
2306
2307
2308
2309
2310
2311
2312
2313
2314
2315
2316
2317
2318
2319
2320
2321
2322
2323
2324
2325
2326
2327
2328
2329
2330
2331
2332
2333
2334
2335
  static const struct display_timing jdi_tx26d202vm0bwa_timing = {
  	.pixelclock = { 151820000, 156720000, 159780000 },
  	.hactive = { 1920, 1920, 1920 },
  	.hfront_porch = { 76, 100, 112 },
  	.hback_porch = { 74, 100, 112 },
  	.hsync_len = { 30, 30, 30 },
  	.vactive = { 1200, 1200, 1200},
  	.vfront_porch = { 3, 5, 10 },
  	.vback_porch = { 2, 5, 10 },
  	.vsync_len = { 5, 5, 5 },
  	.flags = DISPLAY_FLAGS_DE_HIGH,
  };
  
  static const struct panel_desc jdi_tx26d202vm0bwa = {
  	.timings = &jdi_tx26d202vm0bwa_timing,
  	.num_timings = 1,
  	.bpc = 8,
  	.size = {
  		.width = 217,
  		.height = 136,
  	},
  	.delay = {
  		/*
  		 * The panel spec recommends one second delay
  		 * to the below items.  However, it's a bit too
  		 * long in pratice.  Based on tests, it turns
  		 * out 100 milliseconds is fine.
  		 */
  		.prepare = 100,
  		.enable = 100,
  		.unprepare = 100,
  		.disable = 100,
  	},
  	.bus_format = MEDIA_BUS_FMT_RGB888_1X7X4_SPWG,
22beccfc1   Liu Ying   LF-1441 drm/panel...
2336
  	.connector_type = DRM_MODE_CONNECTOR_LVDS,
22014344a   Liu Ying   drm/panel: simple...
2337
  };
66d2eb893   Eric Lee   Linux v5.10.9 sup...
2338
2339
2340
2341
2342
2343
2344
2345
2346
2347
2348
2349
2350
2351
2352
2353
2354
2355
2356
2357
2358
  static const struct display_timing auo_g070vw01_timing = {
          .pixelclock = { 27000000, 33300000, 39400000 },
          .hactive = { 800, 800, 800 },
          .hfront_porch = { 30, 64, 110 },
          .hback_porch = { 30, 64, 110 },
          .hsync_len = { 60, 128, 220 },
          .vactive = { 480, 480, 480},
          .vfront_porch = { 2, 7, 12 },
          .vback_porch = { 2, 7, 12 },
          .vsync_len = { 4, 14, 26 },
          .flags = DISPLAY_FLAGS_DE_HIGH,
  };
  
  static const struct panel_desc auo_g070vw01 = {
          .timings = &auo_g070vw01_timing,
          .num_timings = 1,
          .bpc = 8,
          .size = {
                  .width = 152,
                  .height = 91,
          },
91117063a   Eric Lee   Add ppp and RS485...
2359
  	.connector_type = DRM_MODE_CONNECTOR_LVDS,
66d2eb893   Eric Lee   Linux v5.10.9 sup...
2360
2361
2362
2363
2364
2365
2366
2367
2368
2369
2370
2371
2372
2373
          .delay = {
                  /*
                   * The panel spec recommends one second delay
                   * to the below items.  However, it's a bit too
                   * long in pratice.  Based on tests, it turns
                   * out 100 milliseconds is fine.
                  */
                  .prepare = 100,
                  .enable = 100,
                  .unprepare = 100,
                  .disable = 100,
          },
          .bus_format = MEDIA_BUS_FMT_RGB888_1X7X4_SPWG,
  };
802e949e8   Eric Lee   Linux kernel 5.10...
2374
2375
2376
2377
2378
2379
2380
2381
2382
2383
2384
2385
2386
2387
2388
2389
2390
2391
2392
2393
2394
2395
2396
2397
2398
2399
2400
2401
2402
2403
2404
2405
2406
2407
2408
  static const struct display_timing evervision_vgg644804_timing = {
          .pixelclock = { 21500000, 25200000, 31500000 },
          .hactive = { 640, 640, 640 },
          .hfront_porch = { 33, 33, 33 },
          .hback_porch = { 97, 97, 102 },
          .hsync_len = { 5, 30, 45 },
          .vactive = { 480, 480, 480},
          .vfront_porch = { 10, 10, 7 },
          .vback_porch = { 32, 32, 8 },
          .vsync_len = { 1, 3, 5 },
  	.flags = DISPLAY_FLAGS_DE_HIGH,
  };
  
  static const struct panel_desc evervision_vgg644804 = {
          .timings = &evervision_vgg644804_timing,
          .num_timings = 1,
          .bpc = 8,
          .size = {
                  .width = 115,
                  .height = 86,
          },
          .delay = {
                  /*
                   * The panel spec recommends one second delay
                   * to the below items.  However, it's a bit too
                   * long in pratice.  Based on tests, it turns
                   * out 100 milliseconds is fine.
                  */
                  .prepare = 100,
                  .enable = 100,
                  .unprepare = 100,
                  .disable = 100,
          },
  	.bus_format = MEDIA_BUS_FMT_RGB888_1X7X4_JEIDA,
  };
14bf60c41   Lukasz Majewski   drm/panel: simple...
2409
2410
2411
2412
2413
2414
2415
2416
2417
2418
2419
2420
2421
2422
2423
2424
2425
2426
2427
2428
2429
2430
  static const struct display_timing koe_tx14d24vm1bpa_timing = {
  	.pixelclock = { 5580000, 5850000, 6200000 },
  	.hactive = { 320, 320, 320 },
  	.hfront_porch = { 30, 30, 30 },
  	.hback_porch = { 30, 30, 30 },
  	.hsync_len = { 1, 5, 17 },
  	.vactive = { 240, 240, 240 },
  	.vfront_porch = { 6, 6, 6 },
  	.vback_porch = { 5, 5, 5 },
  	.vsync_len = { 1, 2, 11 },
  	.flags = DISPLAY_FLAGS_DE_HIGH,
  };
  
  static const struct panel_desc koe_tx14d24vm1bpa = {
  	.timings = &koe_tx14d24vm1bpa_timing,
  	.num_timings = 1,
  	.bpc = 6,
  	.size = {
  		.width = 115,
  		.height = 86,
  	},
  };
8a0705244   Liu Ying   drm/panel: simple...
2431
2432
2433
2434
2435
2436
2437
2438
2439
2440
2441
2442
2443
2444
2445
2446
2447
2448
2449
2450
2451
2452
2453
2454
2455
2456
2457
  static const struct display_timing koe_tx26d202vm0bwa_timing = {
  	.pixelclock = { 151820000, 156720000, 159780000 },
  	.hactive = { 1920, 1920, 1920 },
  	.hfront_porch = { 105, 130, 142 },
  	.hback_porch = { 45, 70, 82 },
  	.hsync_len = { 30, 30, 30 },
  	.vactive = { 1200, 1200, 1200},
  	.vfront_porch = { 3, 5, 10 },
  	.vback_porch = { 2, 5, 10 },
  	.vsync_len = { 5, 5, 5 },
  };
  
  static const struct panel_desc koe_tx26d202vm0bwa = {
  	.timings = &koe_tx26d202vm0bwa_timing,
  	.num_timings = 1,
  	.bpc = 8,
  	.size = {
  		.width = 217,
  		.height = 136,
  	},
  	.delay = {
  		.prepare = 1000,
  		.enable = 1000,
  		.unprepare = 1000,
  		.disable = 1000,
  	},
  	.bus_format = MEDIA_BUS_FMT_RGB888_1X7X4_SPWG,
c4715837b   Laurent Pinchart   drm: panel: simpl...
2458
  	.bus_flags = DRM_BUS_FLAG_DE_HIGH,
8a0705244   Liu Ying   drm/panel: simple...
2459
2460
  	.connector_type = DRM_MODE_CONNECTOR_LVDS,
  };
8cfe83419   Jagan Teki   drm/panel: simple...
2461
2462
2463
2464
2465
2466
2467
  static const struct display_timing koe_tx31d200vm0baa_timing = {
  	.pixelclock = { 39600000, 43200000, 48000000 },
  	.hactive = { 1280, 1280, 1280 },
  	.hfront_porch = { 16, 36, 56 },
  	.hback_porch = { 16, 36, 56 },
  	.hsync_len = { 8, 8, 8 },
  	.vactive = { 480, 480, 480 },
c9b6be7dc   Stefan Agner   drm/panel: simple...
2468
2469
  	.vfront_porch = { 6, 21, 33 },
  	.vback_porch = { 6, 21, 33 },
8cfe83419   Jagan Teki   drm/panel: simple...
2470
2471
2472
2473
2474
2475
2476
2477
2478
2479
2480
2481
2482
  	.vsync_len = { 8, 8, 8 },
  	.flags = DISPLAY_FLAGS_DE_HIGH,
  };
  
  static const struct panel_desc koe_tx31d200vm0baa = {
  	.timings = &koe_tx31d200vm0baa_timing,
  	.num_timings = 1,
  	.bpc = 6,
  	.size = {
  		.width = 292,
  		.height = 109,
  	},
  	.bus_format = MEDIA_BUS_FMT_RGB666_1X7X3_SPWG,
9a2654c0f   Laurent Pinchart   drm/panel: Add an...
2483
  	.connector_type = DRM_MODE_CONNECTOR_LVDS,
8cfe83419   Jagan Teki   drm/panel: simple...
2484
  };
8def22e50   Lucas Stach   drm/panel: simple...
2485
2486
2487
2488
2489
2490
2491
2492
2493
2494
2495
2496
2497
2498
2499
2500
2501
2502
2503
2504
2505
2506
  static const struct display_timing kyo_tcg121xglp_timing = {
  	.pixelclock = { 52000000, 65000000, 71000000 },
  	.hactive = { 1024, 1024, 1024 },
  	.hfront_porch = { 2, 2, 2 },
  	.hback_porch = { 2, 2, 2 },
  	.hsync_len = { 86, 124, 244 },
  	.vactive = { 768, 768, 768 },
  	.vfront_porch = { 2, 2, 2 },
  	.vback_porch = { 2, 2, 2 },
  	.vsync_len = { 6, 34, 73 },
  	.flags = DISPLAY_FLAGS_DE_HIGH,
  };
  
  static const struct panel_desc kyo_tcg121xglp = {
  	.timings = &kyo_tcg121xglp_timing,
  	.num_timings = 1,
  	.bpc = 8,
  	.size = {
  		.width = 246,
  		.height = 184,
  	},
  	.bus_format = MEDIA_BUS_FMT_RGB888_1X7X4_SPWG,
9a2654c0f   Laurent Pinchart   drm/panel: Add an...
2507
  	.connector_type = DRM_MODE_CONNECTOR_LVDS,
8def22e50   Lucas Stach   drm/panel: simple...
2508
  };
27abdd83f   Paul Kocialkowski   drm/panel: simple...
2509
2510
2511
2512
2513
2514
2515
2516
2517
2518
  static const struct drm_display_mode lemaker_bl035_rgb_002_mode = {
  	.clock = 7000,
  	.hdisplay = 320,
  	.hsync_start = 320 + 20,
  	.hsync_end = 320 + 20 + 30,
  	.htotal = 320 + 20 + 30 + 38,
  	.vdisplay = 240,
  	.vsync_start = 240 + 4,
  	.vsync_end = 240 + 4 + 3,
  	.vtotal = 240 + 4 + 3 + 15,
27abdd83f   Paul Kocialkowski   drm/panel: simple...
2519
2520
2521
2522
2523
2524
2525
2526
2527
2528
2529
2530
  };
  
  static const struct panel_desc lemaker_bl035_rgb_002 = {
  	.modes = &lemaker_bl035_rgb_002_mode,
  	.num_modes = 1,
  	.size = {
  		.width = 70,
  		.height = 52,
  	},
  	.bus_format = MEDIA_BUS_FMT_RGB888_1X24,
  	.bus_flags = DRM_BUS_FLAG_DE_LOW,
  };
dd0150026   Heiko Schocher   drm/panel: simple...
2531
2532
2533
2534
2535
2536
2537
2538
2539
2540
  static const struct drm_display_mode lg_lb070wv8_mode = {
  	.clock = 33246,
  	.hdisplay = 800,
  	.hsync_start = 800 + 88,
  	.hsync_end = 800 + 88 + 80,
  	.htotal = 800 + 88 + 80 + 88,
  	.vdisplay = 480,
  	.vsync_start = 480 + 10,
  	.vsync_end = 480 + 10 + 25,
  	.vtotal = 480 + 10 + 25 + 10,
dd0150026   Heiko Schocher   drm/panel: simple...
2541
2542
2543
2544
2545
  };
  
  static const struct panel_desc lg_lb070wv8 = {
  	.modes = &lg_lb070wv8_mode,
  	.num_modes = 1,
a6ae2fe5c   Laurent Pinchart   drm: panel: simpl...
2546
  	.bpc = 8,
dd0150026   Heiko Schocher   drm/panel: simple...
2547
2548
2549
2550
2551
  	.size = {
  		.width = 151,
  		.height = 91,
  	},
  	.bus_format = MEDIA_BUS_FMT_RGB888_1X7X4_SPWG,
9a2654c0f   Laurent Pinchart   drm/panel: Add an...
2552
  	.connector_type = DRM_MODE_CONNECTOR_LVDS,
dd0150026   Heiko Schocher   drm/panel: simple...
2553
  };
c5ece4024   Yakir Yang   drm/panel: simple...
2554
2555
2556
2557
2558
2559
2560
2561
2562
2563
  static const struct drm_display_mode lg_lp079qx1_sp0v_mode = {
  	.clock = 200000,
  	.hdisplay = 1536,
  	.hsync_start = 1536 + 12,
  	.hsync_end = 1536 + 12 + 16,
  	.htotal = 1536 + 12 + 16 + 48,
  	.vdisplay = 2048,
  	.vsync_start = 2048 + 8,
  	.vsync_end = 2048 + 8 + 4,
  	.vtotal = 2048 + 8 + 4 + 8,
c5ece4024   Yakir Yang   drm/panel: simple...
2564
2565
2566
2567
2568
2569
2570
2571
2572
2573
2574
  	.flags = DRM_MODE_FLAG_NVSYNC | DRM_MODE_FLAG_NHSYNC,
  };
  
  static const struct panel_desc lg_lp079qx1_sp0v = {
  	.modes = &lg_lp079qx1_sp0v_mode,
  	.num_modes = 1,
  	.size = {
  		.width = 129,
  		.height = 171,
  	},
  };
0355dde26   Yakir Yang   drm/panel: simple...
2575
2576
2577
2578
2579
2580
2581
2582
2583
2584
  static const struct drm_display_mode lg_lp097qx1_spa1_mode = {
  	.clock = 205210,
  	.hdisplay = 2048,
  	.hsync_start = 2048 + 150,
  	.hsync_end = 2048 + 150 + 5,
  	.htotal = 2048 + 150 + 5 + 5,
  	.vdisplay = 1536,
  	.vsync_start = 1536 + 3,
  	.vsync_end = 1536 + 3 + 1,
  	.vtotal = 1536 + 3 + 1 + 9,
0355dde26   Yakir Yang   drm/panel: simple...
2585
2586
2587
2588
2589
2590
2591
2592
2593
2594
  };
  
  static const struct panel_desc lg_lp097qx1_spa1 = {
  	.modes = &lg_lp097qx1_spa1_mode,
  	.num_modes = 1,
  	.size = {
  		.width = 208,
  		.height = 147,
  	},
  };
690d8fa70   Jitao Shi   drm/panel: simple...
2595
2596
2597
2598
2599
2600
2601
2602
2603
2604
  static const struct drm_display_mode lg_lp120up1_mode = {
  	.clock = 162300,
  	.hdisplay = 1920,
  	.hsync_start = 1920 + 40,
  	.hsync_end = 1920 + 40 + 40,
  	.htotal = 1920 + 40 + 40+ 80,
  	.vdisplay = 1280,
  	.vsync_start = 1280 + 4,
  	.vsync_end = 1280 + 4 + 4,
  	.vtotal = 1280 + 4 + 4 + 12,
690d8fa70   Jitao Shi   drm/panel: simple...
2605
2606
2607
2608
2609
2610
2611
2612
2613
2614
  };
  
  static const struct panel_desc lg_lp120up1 = {
  	.modes = &lg_lp120up1_mode,
  	.num_modes = 1,
  	.bpc = 8,
  	.size = {
  		.width = 267,
  		.height = 183,
  	},
d53139b37   Enric Balletbo i Serra   drm: panel: Set c...
2615
  	.connector_type = DRM_MODE_CONNECTOR_eDP,
690d8fa70   Jitao Shi   drm/panel: simple...
2616
  };
ec7c56538   Thierry Reding   drm/panel: Add LG...
2617
2618
2619
2620
2621
2622
2623
2624
2625
2626
  static const struct drm_display_mode lg_lp129qe_mode = {
  	.clock = 285250,
  	.hdisplay = 2560,
  	.hsync_start = 2560 + 48,
  	.hsync_end = 2560 + 48 + 32,
  	.htotal = 2560 + 48 + 32 + 80,
  	.vdisplay = 1700,
  	.vsync_start = 1700 + 3,
  	.vsync_end = 1700 + 3 + 10,
  	.vtotal = 1700 + 3 + 10 + 36,
ec7c56538   Thierry Reding   drm/panel: Add LG...
2627
2628
2629
2630
2631
  };
  
  static const struct panel_desc lg_lp129qe = {
  	.modes = &lg_lp129qe_mode,
  	.num_modes = 1,
0208d5111   Stéphane Marchesin   drm/panel: simple...
2632
  	.bpc = 8,
ec7c56538   Thierry Reding   drm/panel: Add LG...
2633
2634
2635
2636
2637
  	.size = {
  		.width = 272,
  		.height = 181,
  	},
  };
5728fe7fa   Marcel Ziswiler   drm/panel: simple...
2638
2639
2640
2641
2642
2643
2644
2645
2646
2647
2648
2649
2650
2651
2652
2653
2654
2655
2656
2657
2658
2659
2660
2661
2662
2663
2664
2665
2666
2667
2668
2669
2670
2671
2672
2673
2674
2675
2676
2677
2678
2679
2680
2681
2682
2683
2684
2685
2686
2687
2688
2689
  static const struct display_timing logictechno_lt161010_2nh_timing = {
  	.pixelclock = { 26400000, 33300000, 46800000 },
  	.hactive = { 800, 800, 800 },
  	.hfront_porch = { 16, 210, 354 },
  	.hback_porch = { 46, 46, 46 },
  	.hsync_len = { 1, 20, 40 },
  	.vactive = { 480, 480, 480 },
  	.vfront_porch = { 7, 22, 147 },
  	.vback_porch = { 23, 23, 23 },
  	.vsync_len = { 1, 10, 20 },
  	.flags = DISPLAY_FLAGS_HSYNC_LOW | DISPLAY_FLAGS_VSYNC_LOW |
  		 DISPLAY_FLAGS_DE_HIGH | DISPLAY_FLAGS_PIXDATA_POSEDGE |
  		 DISPLAY_FLAGS_SYNC_POSEDGE,
  };
  
  static const struct panel_desc logictechno_lt161010_2nh = {
  	.timings = &logictechno_lt161010_2nh_timing,
  	.num_timings = 1,
  	.size = {
  		.width = 154,
  		.height = 86,
  	},
  	.bus_format = MEDIA_BUS_FMT_RGB666_1X18,
  	.bus_flags = DRM_BUS_FLAG_DE_HIGH |
  		     DRM_BUS_FLAG_PIXDATA_SAMPLE_NEGEDGE |
  		     DRM_BUS_FLAG_SYNC_SAMPLE_NEGEDGE,
  	.connector_type = DRM_MODE_CONNECTOR_DPI,
  };
  
  static const struct display_timing logictechno_lt170410_2whc_timing = {
  	.pixelclock = { 68900000, 71100000, 73400000 },
  	.hactive = { 1280, 1280, 1280 },
  	.hfront_porch = { 23, 60, 71 },
  	.hback_porch = { 23, 60, 71 },
  	.hsync_len = { 15, 40, 47 },
  	.vactive = { 800, 800, 800 },
  	.vfront_porch = { 5, 7, 10 },
  	.vback_porch = { 5, 7, 10 },
  	.vsync_len = { 6, 9, 12 },
  	.flags = DISPLAY_FLAGS_HSYNC_LOW | DISPLAY_FLAGS_VSYNC_LOW |
  		 DISPLAY_FLAGS_DE_HIGH | DISPLAY_FLAGS_PIXDATA_POSEDGE |
  		 DISPLAY_FLAGS_SYNC_POSEDGE,
  };
  
  static const struct panel_desc logictechno_lt170410_2whc = {
  	.timings = &logictechno_lt170410_2whc_timing,
  	.num_timings = 1,
  	.size = {
  		.width = 217,
  		.height = 136,
  	},
  	.bus_format = MEDIA_BUS_FMT_RGB888_1X7X4_SPWG,
c4715837b   Laurent Pinchart   drm: panel: simpl...
2690
  	.bus_flags = DRM_BUS_FLAG_DE_HIGH,
5728fe7fa   Marcel Ziswiler   drm/panel: simple...
2691
2692
  	.connector_type = DRM_MODE_CONNECTOR_LVDS,
  };
65c766cad   Lukasz Majewski   drm/panel: simple...
2693
2694
2695
2696
2697
2698
2699
2700
2701
2702
  static const struct drm_display_mode mitsubishi_aa070mc01_mode = {
  	.clock = 30400,
  	.hdisplay = 800,
  	.hsync_start = 800 + 0,
  	.hsync_end = 800 + 1,
  	.htotal = 800 + 0 + 1 + 160,
  	.vdisplay = 480,
  	.vsync_start = 480 + 0,
  	.vsync_end = 480 + 48 + 1,
  	.vtotal = 480 + 48 + 1 + 0,
65c766cad   Lukasz Majewski   drm/panel: simple...
2703
2704
  	.flags = DRM_MODE_FLAG_NHSYNC | DRM_MODE_FLAG_NVSYNC,
  };
0d35408af   Adam Ford   drm/panel: simple...
2705
  static const struct drm_display_mode logicpd_type_28_mode = {
f873c5d88   Ville Syrjälä   drm/panel-simple:...
2706
  	.clock = 9107,
0d35408af   Adam Ford   drm/panel: simple...
2707
2708
2709
2710
2711
2712
2713
2714
2715
  	.hdisplay = 480,
  	.hsync_start = 480 + 3,
  	.hsync_end = 480 + 3 + 42,
  	.htotal = 480 + 3 + 42 + 2,
  
  	.vdisplay = 272,
  	.vsync_start = 272 + 2,
  	.vsync_end = 272 + 2 + 11,
  	.vtotal = 272 + 2 + 11 + 3,
0d35408af   Adam Ford   drm/panel: simple...
2716
2717
2718
2719
2720
2721
2722
2723
2724
2725
2726
2727
2728
2729
2730
2731
2732
2733
2734
2735
  	.flags = DRM_MODE_FLAG_PHSYNC | DRM_MODE_FLAG_PVSYNC,
  };
  
  static const struct panel_desc logicpd_type_28 = {
  	.modes = &logicpd_type_28_mode,
  	.num_modes = 1,
  	.bpc = 8,
  	.size = {
  		.width = 105,
  		.height = 67,
  	},
  	.delay = {
  		.prepare = 200,
  		.enable = 200,
  		.unprepare = 200,
  		.disable = 200,
  	},
  	.bus_format = MEDIA_BUS_FMT_RGB888_1X24,
  	.bus_flags = DRM_BUS_FLAG_DE_HIGH | DRM_BUS_FLAG_PIXDATA_DRIVE_POSEDGE |
  		     DRM_BUS_FLAG_SYNC_DRIVE_NEGEDGE,
efb947908   Adam Ford   drm/panel-simple:...
2736
  	.connector_type = DRM_MODE_CONNECTOR_DPI,
0d35408af   Adam Ford   drm/panel: simple...
2737
  };
65c766cad   Lukasz Majewski   drm/panel: simple...
2738
2739
2740
2741
2742
2743
2744
2745
2746
2747
2748
2749
2750
2751
2752
  static const struct panel_desc mitsubishi_aa070mc01 = {
  	.modes = &mitsubishi_aa070mc01_mode,
  	.num_modes = 1,
  	.bpc = 8,
  	.size = {
  		.width = 152,
  		.height = 91,
  	},
  
  	.delay = {
  		.enable = 200,
  		.unprepare = 200,
  		.disable = 400,
  	},
  	.bus_format = MEDIA_BUS_FMT_RGB888_1X7X4_SPWG,
9a2654c0f   Laurent Pinchart   drm/panel: Add an...
2753
  	.connector_type = DRM_MODE_CONNECTOR_LVDS,
65c766cad   Lukasz Majewski   drm/panel: simple...
2754
2755
  	.bus_flags = DRM_BUS_FLAG_DE_HIGH,
  };
01bacc13a   Lucas Stach   drm/panel: simple...
2756
2757
2758
2759
2760
2761
2762
2763
2764
2765
2766
2767
2768
2769
2770
2771
2772
2773
2774
2775
2776
2777
2778
2779
2780
  static const struct display_timing nec_nl12880bc20_05_timing = {
  	.pixelclock = { 67000000, 71000000, 75000000 },
  	.hactive = { 1280, 1280, 1280 },
  	.hfront_porch = { 2, 30, 30 },
  	.hback_porch = { 6, 100, 100 },
  	.hsync_len = { 2, 30, 30 },
  	.vactive = { 800, 800, 800 },
  	.vfront_porch = { 5, 5, 5 },
  	.vback_porch = { 11, 11, 11 },
  	.vsync_len = { 7, 7, 7 },
  };
  
  static const struct panel_desc nec_nl12880bc20_05 = {
  	.timings = &nec_nl12880bc20_05_timing,
  	.num_timings = 1,
  	.bpc = 8,
  	.size = {
  		.width = 261,
  		.height = 163,
  	},
  	.delay = {
  		.enable = 50,
  		.disable = 50,
  	},
  	.bus_format = MEDIA_BUS_FMT_RGB888_1X7X4_SPWG,
9a2654c0f   Laurent Pinchart   drm/panel: Add an...
2781
  	.connector_type = DRM_MODE_CONNECTOR_LVDS,
01bacc13a   Lucas Stach   drm/panel: simple...
2782
  };
c6e87f91f   jianwei wang   drm/panel: simple...
2783
2784
2785
2786
2787
2788
2789
2790
2791
2792
  static const struct drm_display_mode nec_nl4827hc19_05b_mode = {
  	.clock = 10870,
  	.hdisplay = 480,
  	.hsync_start = 480 + 2,
  	.hsync_end = 480 + 2 + 41,
  	.htotal = 480 + 2 + 41 + 2,
  	.vdisplay = 272,
  	.vsync_start = 272 + 2,
  	.vsync_end = 272 + 2 + 4,
  	.vtotal = 272 + 2 + 4 + 2,
4bc390c63   Stefan Agner   drm/fsl-dcu: use ...
2793
  	.flags = DRM_MODE_FLAG_NVSYNC | DRM_MODE_FLAG_NHSYNC,
c6e87f91f   jianwei wang   drm/panel: simple...
2794
2795
2796
2797
2798
2799
2800
2801
2802
2803
  };
  
  static const struct panel_desc nec_nl4827hc19_05b = {
  	.modes = &nec_nl4827hc19_05b_mode,
  	.num_modes = 1,
  	.bpc = 8,
  	.size = {
  		.width = 95,
  		.height = 54,
  	},
2c80661d2   Stefan Agner   drm/fsl-dcu: use ...
2804
  	.bus_format = MEDIA_BUS_FMT_RGB888_1X24,
88bc41785   Laurent Pinchart   drm: Use new DRM_...
2805
  	.bus_flags = DRM_BUS_FLAG_PIXDATA_DRIVE_POSEDGE,
c6e87f91f   jianwei wang   drm/panel: simple...
2806
  };
e6c2f066d   Maxime Ripard   drm/panel: simple...
2807
2808
2809
2810
2811
2812
2813
2814
2815
2816
  static const struct drm_display_mode netron_dy_e231732_mode = {
  	.clock = 66000,
  	.hdisplay = 1024,
  	.hsync_start = 1024 + 160,
  	.hsync_end = 1024 + 160 + 70,
  	.htotal = 1024 + 160 + 70 + 90,
  	.vdisplay = 600,
  	.vsync_start = 600 + 127,
  	.vsync_end = 600 + 127 + 20,
  	.vtotal = 600 + 127 + 20 + 3,
e6c2f066d   Maxime Ripard   drm/panel: simple...
2817
2818
2819
2820
2821
2822
2823
2824
2825
2826
2827
  };
  
  static const struct panel_desc netron_dy_e231732 = {
  	.modes = &netron_dy_e231732_mode,
  	.num_modes = 1,
  	.size = {
  		.width = 154,
  		.height = 87,
  	},
  	.bus_format = MEDIA_BUS_FMT_RGB666_1X18,
  };
258145ea3   Vasily Khoruzhick   drm/panel: simple...
2828
2829
2830
2831
2832
2833
2834
2835
2836
2837
2838
  static const struct drm_display_mode neweast_wjfh116008a_modes[] = {
  	{
  		.clock = 138500,
  		.hdisplay = 1920,
  		.hsync_start = 1920 + 48,
  		.hsync_end = 1920 + 48 + 32,
  		.htotal = 1920 + 48 + 32 + 80,
  		.vdisplay = 1080,
  		.vsync_start = 1080 + 3,
  		.vsync_end = 1080 + 3 + 5,
  		.vtotal = 1080 + 3 + 5 + 23,
258145ea3   Vasily Khoruzhick   drm/panel: simple...
2839
2840
2841
2842
2843
2844
2845
2846
2847
2848
2849
  		.flags = DRM_MODE_FLAG_NVSYNC | DRM_MODE_FLAG_NHSYNC,
  	}, {
  		.clock = 110920,
  		.hdisplay = 1920,
  		.hsync_start = 1920 + 48,
  		.hsync_end = 1920 + 48 + 32,
  		.htotal = 1920 + 48 + 32 + 80,
  		.vdisplay = 1080,
  		.vsync_start = 1080 + 3,
  		.vsync_end = 1080 + 3 + 5,
  		.vtotal = 1080 + 3 + 5 + 23,
258145ea3   Vasily Khoruzhick   drm/panel: simple...
2850
2851
2852
2853
2854
2855
2856
2857
2858
2859
2860
2861
2862
2863
2864
2865
2866
2867
2868
2869
  		.flags = DRM_MODE_FLAG_NVSYNC | DRM_MODE_FLAG_NHSYNC,
  	}
  };
  
  static const struct panel_desc neweast_wjfh116008a = {
  	.modes = neweast_wjfh116008a_modes,
  	.num_modes = 2,
  	.bpc = 6,
  	.size = {
  		.width = 260,
  		.height = 150,
  	},
  	.delay = {
  		.prepare = 110,
  		.enable = 20,
  		.unprepare = 500,
  	},
  	.bus_format = MEDIA_BUS_FMT_RGB666_1X18,
  	.connector_type = DRM_MODE_CONNECTOR_eDP,
  };
3b39ad7a5   Tomi Valkeinen   drm/panel: simple...
2870
2871
2872
2873
2874
2875
2876
2877
2878
2879
  static const struct drm_display_mode newhaven_nhd_43_480272ef_atxl_mode = {
  	.clock = 9000,
  	.hdisplay = 480,
  	.hsync_start = 480 + 2,
  	.hsync_end = 480 + 2 + 41,
  	.htotal = 480 + 2 + 41 + 2,
  	.vdisplay = 272,
  	.vsync_start = 272 + 2,
  	.vsync_end = 272 + 2 + 10,
  	.vtotal = 272 + 2 + 10 + 2,
3b39ad7a5   Tomi Valkeinen   drm/panel: simple...
2880
2881
2882
2883
2884
2885
2886
2887
2888
2889
2890
2891
  	.flags = DRM_MODE_FLAG_NVSYNC | DRM_MODE_FLAG_NHSYNC,
  };
  
  static const struct panel_desc newhaven_nhd_43_480272ef_atxl = {
  	.modes = &newhaven_nhd_43_480272ef_atxl_mode,
  	.num_modes = 1,
  	.bpc = 8,
  	.size = {
  		.width = 95,
  		.height = 54,
  	},
  	.bus_format = MEDIA_BUS_FMT_RGB888_1X24,
88bc41785   Laurent Pinchart   drm: Use new DRM_...
2892
2893
  	.bus_flags = DRM_BUS_FLAG_DE_HIGH | DRM_BUS_FLAG_PIXDATA_DRIVE_POSEDGE |
  		     DRM_BUS_FLAG_SYNC_DRIVE_POSEDGE,
8a4f5e118   Tomi Valkeinen   drm/panel-simple:...
2894
  	.connector_type = DRM_MODE_CONNECTOR_DPI,
3b39ad7a5   Tomi Valkeinen   drm/panel: simple...
2895
  };
4177fa66a   Lucas Stach   drm/panel: simple...
2896
2897
2898
2899
2900
2901
2902
2903
2904
2905
2906
2907
2908
2909
2910
2911
2912
2913
2914
2915
2916
2917
2918
2919
  static const struct display_timing nlt_nl192108ac18_02d_timing = {
  	.pixelclock = { 130000000, 148350000, 163000000 },
  	.hactive = { 1920, 1920, 1920 },
  	.hfront_porch = { 80, 100, 100 },
  	.hback_porch = { 100, 120, 120 },
  	.hsync_len = { 50, 60, 60 },
  	.vactive = { 1080, 1080, 1080 },
  	.vfront_porch = { 12, 30, 30 },
  	.vback_porch = { 4, 10, 10 },
  	.vsync_len = { 4, 5, 5 },
  };
  
  static const struct panel_desc nlt_nl192108ac18_02d = {
  	.timings = &nlt_nl192108ac18_02d_timing,
  	.num_timings = 1,
  	.bpc = 8,
  	.size = {
  		.width = 344,
  		.height = 194,
  	},
  	.delay = {
  		.unprepare = 500,
  	},
  	.bus_format = MEDIA_BUS_FMT_RGB888_1X7X4_SPWG,
9a2654c0f   Laurent Pinchart   drm/panel: Add an...
2920
  	.connector_type = DRM_MODE_CONNECTOR_LVDS,
4177fa66a   Lucas Stach   drm/panel: simple...
2921
  };
05ec0e450   Fabien Lahoudere   drm/panel: simple...
2922
2923
2924
2925
2926
2927
2928
2929
2930
2931
2932
2933
2934
2935
2936
2937
2938
2939
2940
2941
2942
  static const struct drm_display_mode nvd_9128_mode = {
  	.clock = 29500,
  	.hdisplay = 800,
  	.hsync_start = 800 + 130,
  	.hsync_end = 800 + 130 + 98,
  	.htotal = 800 + 0 + 130 + 98,
  	.vdisplay = 480,
  	.vsync_start = 480 + 10,
  	.vsync_end = 480 + 10 + 50,
  	.vtotal = 480 + 0 + 10 + 50,
  };
  
  static const struct panel_desc nvd_9128 = {
  	.modes = &nvd_9128_mode,
  	.num_modes = 1,
  	.bpc = 8,
  	.size = {
  		.width = 156,
  		.height = 88,
  	},
  	.bus_format = MEDIA_BUS_FMT_RGB888_1X7X4_SPWG,
9a2654c0f   Laurent Pinchart   drm/panel: Add an...
2943
  	.connector_type = DRM_MODE_CONNECTOR_LVDS,
05ec0e450   Fabien Lahoudere   drm/panel: simple...
2944
  };
a99fb6269   Gary Bisson   drm/panel: Add di...
2945
2946
2947
2948
2949
2950
2951
2952
2953
2954
2955
2956
2957
2958
2959
2960
2961
2962
2963
2964
2965
2966
2967
2968
2969
2970
2971
2972
2973
  static const struct display_timing okaya_rs800480t_7x0gp_timing = {
  	.pixelclock = { 30000000, 30000000, 40000000 },
  	.hactive = { 800, 800, 800 },
  	.hfront_porch = { 40, 40, 40 },
  	.hback_porch = { 40, 40, 40 },
  	.hsync_len = { 1, 48, 48 },
  	.vactive = { 480, 480, 480 },
  	.vfront_porch = { 13, 13, 13 },
  	.vback_porch = { 29, 29, 29 },
  	.vsync_len = { 3, 3, 3 },
  	.flags = DISPLAY_FLAGS_DE_HIGH,
  };
  
  static const struct panel_desc okaya_rs800480t_7x0gp = {
  	.timings = &okaya_rs800480t_7x0gp_timing,
  	.num_timings = 1,
  	.bpc = 6,
  	.size = {
  		.width = 154,
  		.height = 87,
  	},
  	.delay = {
  		.prepare = 41,
  		.enable = 50,
  		.unprepare = 41,
  		.disable = 50,
  	},
  	.bus_format = MEDIA_BUS_FMT_RGB666_1X18,
  };
cf5c9e6dc   Maxime Ripard   drm/panel: simple...
2974
2975
2976
2977
2978
2979
2980
2981
2982
2983
  static const struct drm_display_mode olimex_lcd_olinuxino_43ts_mode = {
  	.clock = 9000,
  	.hdisplay = 480,
  	.hsync_start = 480 + 5,
  	.hsync_end = 480 + 5 + 30,
  	.htotal = 480 + 5 + 30 + 10,
  	.vdisplay = 272,
  	.vsync_start = 272 + 8,
  	.vsync_end = 272 + 8 + 5,
  	.vtotal = 272 + 8 + 5 + 3,
cf5c9e6dc   Maxime Ripard   drm/panel: simple...
2984
2985
2986
2987
2988
2989
  };
  
  static const struct panel_desc olimex_lcd_olinuxino_43ts = {
  	.modes = &olimex_lcd_olinuxino_43ts_mode,
  	.num_modes = 1,
  	.size = {
30c6d7ab9   Jonathan Liu   drm/panel: simple...
2990
2991
  		.width = 95,
  		.height = 54,
cf5c9e6dc   Maxime Ripard   drm/panel: simple...
2992
  	},
5c2a7c6be   Jonathan Liu   drm/panel: simple...
2993
  	.bus_format = MEDIA_BUS_FMT_RGB888_1X24,
cf5c9e6dc   Maxime Ripard   drm/panel: simple...
2994
  };
e8b6f561b   Eric Anholt   drm/panel: simple...
2995
2996
2997
2998
2999
3000
3001
3002
3003
3004
3005
3006
3007
3008
3009
  /*
   * 800x480 CVT. The panel appears to be quite accepting, at least as far as
   * pixel clocks, but this is the timing that was being used in the Adafruit
   * installation instructions.
   */
  static const struct drm_display_mode ontat_yx700wv03_mode = {
  	.clock = 29500,
  	.hdisplay = 800,
  	.hsync_start = 824,
  	.hsync_end = 896,
  	.htotal = 992,
  	.vdisplay = 480,
  	.vsync_start = 483,
  	.vsync_end = 493,
  	.vtotal = 500,
e8b6f561b   Eric Anholt   drm/panel: simple...
3010
3011
3012
3013
3014
3015
3016
3017
3018
3019
3020
3021
3022
3023
3024
  	.flags = DRM_MODE_FLAG_NVSYNC | DRM_MODE_FLAG_NHSYNC,
  };
  
  /*
   * Specification at:
   * https://www.adafruit.com/images/product-files/2406/c3163.pdf
   */
  static const struct panel_desc ontat_yx700wv03 = {
  	.modes = &ontat_yx700wv03_mode,
  	.num_modes = 1,
  	.bpc = 8,
  	.size = {
  		.width = 154,
  		.height = 83,
  	},
5651e5e09   Eric Anholt   drm/panel: simple...
3025
  	.bus_format = MEDIA_BUS_FMT_RGB666_1X18,
e8b6f561b   Eric Anholt   drm/panel: simple...
3026
  };
9c31dcb6d   H. Nikolaus Schaller   drm/panel: simple...
3027
  static const struct drm_display_mode ortustech_com37h3m_mode  = {
855e764d3   H. Nikolaus Schaller   drm/panel-simple:...
3028
  	.clock = 22230,
9c31dcb6d   H. Nikolaus Schaller   drm/panel: simple...
3029
  	.hdisplay = 480,
855e764d3   H. Nikolaus Schaller   drm/panel-simple:...
3030
3031
3032
  	.hsync_start = 480 + 40,
  	.hsync_end = 480 + 40 + 10,
  	.htotal = 480 + 40 + 10 + 40,
9c31dcb6d   H. Nikolaus Schaller   drm/panel: simple...
3033
3034
  	.vdisplay = 640,
  	.vsync_start = 640 + 4,
855e764d3   H. Nikolaus Schaller   drm/panel-simple:...
3035
3036
  	.vsync_end = 640 + 4 + 2,
  	.vtotal = 640 + 4 + 2 + 4,
9c31dcb6d   H. Nikolaus Schaller   drm/panel: simple...
3037
3038
3039
3040
3041
3042
3043
3044
3045
3046
3047
3048
  	.flags = DRM_MODE_FLAG_NVSYNC | DRM_MODE_FLAG_NHSYNC,
  };
  
  static const struct panel_desc ortustech_com37h3m = {
  	.modes = &ortustech_com37h3m_mode,
  	.num_modes = 1,
  	.bpc = 8,
  	.size = {
  		.width = 56,	/* 56.16mm */
  		.height = 75,	/* 74.88mm */
  	},
  	.bus_format = MEDIA_BUS_FMT_RGB888_1X24,
f5436f774   Sam Ravnborg   drm/panel: panel-...
3049
  	.bus_flags = DRM_BUS_FLAG_DE_HIGH | DRM_BUS_FLAG_PIXDATA_SAMPLE_NEGEDGE |
9c31dcb6d   H. Nikolaus Schaller   drm/panel: simple...
3050
3051
  		     DRM_BUS_FLAG_SYNC_DRIVE_POSEDGE,
  };
725c9d40f   Philipp Zabel   drm/panel: Add su...
3052
3053
3054
3055
3056
3057
3058
3059
3060
3061
  static const struct drm_display_mode ortustech_com43h4m85ulc_mode  = {
  	.clock = 25000,
  	.hdisplay = 480,
  	.hsync_start = 480 + 10,
  	.hsync_end = 480 + 10 + 10,
  	.htotal = 480 + 10 + 10 + 15,
  	.vdisplay = 800,
  	.vsync_start = 800 + 3,
  	.vsync_end = 800 + 3 + 3,
  	.vtotal = 800 + 3 + 3 + 3,
725c9d40f   Philipp Zabel   drm/panel: Add su...
3062
3063
3064
3065
3066
  };
  
  static const struct panel_desc ortustech_com43h4m85ulc = {
  	.modes = &ortustech_com43h4m85ulc_mode,
  	.num_modes = 1,
3b8095169   Laurent Pinchart   drm: panel: Fix b...
3067
  	.bpc = 6,
725c9d40f   Philipp Zabel   drm/panel: Add su...
3068
3069
3070
3071
  	.size = {
  		.width = 56,
  		.height = 93,
  	},
f098f168e   Laurent Pinchart   drm: panel: Fix b...
3072
  	.bus_format = MEDIA_BUS_FMT_RGB666_1X18,
88bc41785   Laurent Pinchart   drm: Use new DRM_...
3073
  	.bus_flags = DRM_BUS_FLAG_DE_HIGH | DRM_BUS_FLAG_PIXDATA_DRIVE_POSEDGE,
2ccedf464   Laurent Pinchart   drm: panel: Set c...
3074
  	.connector_type = DRM_MODE_CONNECTOR_DPI,
725c9d40f   Philipp Zabel   drm/panel: Add su...
3075
  };
163f7a357   Laurent Pinchart   drm/panel: simple...
3076
3077
3078
3079
3080
3081
3082
3083
3084
3085
  static const struct drm_display_mode osddisplays_osd070t1718_19ts_mode  = {
  	.clock = 33000,
  	.hdisplay = 800,
  	.hsync_start = 800 + 210,
  	.hsync_end = 800 + 210 + 30,
  	.htotal = 800 + 210 + 30 + 16,
  	.vdisplay = 480,
  	.vsync_start = 480 + 22,
  	.vsync_end = 480 + 22 + 13,
  	.vtotal = 480 + 22 + 13 + 10,
163f7a357   Laurent Pinchart   drm/panel: simple...
3086
3087
3088
3089
3090
3091
3092
3093
3094
3095
3096
3097
  	.flags = DRM_MODE_FLAG_NVSYNC | DRM_MODE_FLAG_NHSYNC,
  };
  
  static const struct panel_desc osddisplays_osd070t1718_19ts = {
  	.modes = &osddisplays_osd070t1718_19ts_mode,
  	.num_modes = 1,
  	.bpc = 8,
  	.size = {
  		.width = 152,
  		.height = 91,
  	},
  	.bus_format = MEDIA_BUS_FMT_RGB888_1X24,
fb0629eee   Tomi Valkeinen   drm/panel: simple...
3098
3099
  	.bus_flags = DRM_BUS_FLAG_DE_HIGH | DRM_BUS_FLAG_PIXDATA_DRIVE_POSEDGE |
  		DRM_BUS_FLAG_SYNC_DRIVE_POSEDGE,
a793f0eeb   Laurent Pinchart   drm/panel: panel-...
3100
  	.connector_type = DRM_MODE_CONNECTOR_DPI,
163f7a357   Laurent Pinchart   drm/panel: simple...
3101
  };
4ba3e5634   Eugen Hristev   drm/panel: simple...
3102
3103
3104
3105
3106
3107
3108
3109
3110
3111
  static const struct drm_display_mode pda_91_00156_a0_mode = {
  	.clock = 33300,
  	.hdisplay = 800,
  	.hsync_start = 800 + 1,
  	.hsync_end = 800 + 1 + 64,
  	.htotal = 800 + 1 + 64 + 64,
  	.vdisplay = 480,
  	.vsync_start = 480 + 1,
  	.vsync_end = 480 + 1 + 23,
  	.vtotal = 480 + 1 + 23 + 22,
4ba3e5634   Eugen Hristev   drm/panel: simple...
3112
3113
3114
3115
3116
3117
3118
3119
3120
3121
3122
  };
  
  static const struct panel_desc pda_91_00156_a0  = {
  	.modes = &pda_91_00156_a0_mode,
  	.num_modes = 1,
  	.size = {
  		.width = 152,
  		.height = 91,
  	},
  	.bus_format = MEDIA_BUS_FMT_RGB888_1X24,
  };
d69de69f2   Marek Vasut   drm/panel: simple...
3123
3124
3125
3126
3127
3128
3129
3130
3131
3132
3133
3134
3135
3136
3137
3138
3139
3140
3141
3142
3143
3144
3145
3146
3147
  static const struct drm_display_mode powertip_ph800480t013_idf02_mode = {
  	.clock = 24750,
  	.hdisplay = 800,
  	.hsync_start = 800 + 54,
  	.hsync_end = 800 + 54 + 2,
  	.htotal = 800 + 54 + 2 + 44,
  	.vdisplay = 480,
  	.vsync_start = 480 + 49,
  	.vsync_end = 480 + 49 + 2,
  	.vtotal = 480 + 49 + 2 + 22,
  };
  
  static const struct panel_desc powertip_ph800480t013_idf02  = {
  	.modes = &powertip_ph800480t013_idf02_mode,
  	.num_modes = 1,
  	.size = {
  		.width = 152,
  		.height = 91,
  	},
  	.bus_flags = DRM_BUS_FLAG_DE_HIGH |
  		     DRM_BUS_FLAG_PIXDATA_SAMPLE_NEGEDGE |
  		     DRM_BUS_FLAG_SYNC_SAMPLE_NEGEDGE,
  	.bus_format = MEDIA_BUS_FMT_RGB888_1X24,
  	.connector_type = DRM_MODE_CONNECTOR_DPI,
  };
4ba3e5634   Eugen Hristev   drm/panel: simple...
3148

d2a6f0f55   Josh Wu   drm/panel: simple...
3149
3150
3151
3152
3153
3154
3155
3156
3157
3158
  static const struct drm_display_mode qd43003c0_40_mode = {
  	.clock = 9000,
  	.hdisplay = 480,
  	.hsync_start = 480 + 8,
  	.hsync_end = 480 + 8 + 4,
  	.htotal = 480 + 8 + 4 + 39,
  	.vdisplay = 272,
  	.vsync_start = 272 + 4,
  	.vsync_end = 272 + 4 + 10,
  	.vtotal = 272 + 4 + 10 + 2,
d2a6f0f55   Josh Wu   drm/panel: simple...
3159
3160
3161
3162
3163
3164
3165
3166
3167
3168
3169
3170
  };
  
  static const struct panel_desc qd43003c0_40 = {
  	.modes = &qd43003c0_40_mode,
  	.num_modes = 1,
  	.bpc = 8,
  	.size = {
  		.width = 95,
  		.height = 53,
  	},
  	.bus_format = MEDIA_BUS_FMT_RGB888_1X24,
  };
23167fa9a   Jagan Teki   drm/panel: simple...
3171
3172
3173
3174
3175
3176
3177
3178
3179
3180
3181
3182
3183
3184
3185
3186
3187
3188
3189
3190
3191
3192
3193
3194
3195
3196
3197
3198
3199
  static const struct display_timing rocktech_rk070er9427_timing = {
  	.pixelclock = { 26400000, 33300000, 46800000 },
  	.hactive = { 800, 800, 800 },
  	.hfront_porch = { 16, 210, 354 },
  	.hback_porch = { 46, 46, 46 },
  	.hsync_len = { 1, 1, 1 },
  	.vactive = { 480, 480, 480 },
  	.vfront_porch = { 7, 22, 147 },
  	.vback_porch = { 23, 23, 23 },
  	.vsync_len = { 1, 1, 1 },
  	.flags = DISPLAY_FLAGS_DE_HIGH,
  };
  
  static const struct panel_desc rocktech_rk070er9427 = {
  	.timings = &rocktech_rk070er9427_timing,
  	.num_timings = 1,
  	.bpc = 6,
  	.size = {
  		.width = 154,
  		.height = 86,
  	},
  	.delay = {
  		.prepare = 41,
  		.enable = 50,
  		.unprepare = 41,
  		.disable = 50,
  	},
  	.bus_format = MEDIA_BUS_FMT_RGB666_1X18,
  };
f305047b4   Jyri Sarha   drm/panel: simple...
3200
3201
3202
3203
3204
3205
3206
3207
3208
3209
  static const struct drm_display_mode rocktech_rk101ii01d_ct_mode = {
  	.clock = 71100,
  	.hdisplay = 1280,
  	.hsync_start = 1280 + 48,
  	.hsync_end = 1280 + 48 + 32,
  	.htotal = 1280 + 48 + 32 + 80,
  	.vdisplay = 800,
  	.vsync_start = 800 + 2,
  	.vsync_end = 800 + 2 + 5,
  	.vtotal = 800 + 2 + 5 + 16,
f305047b4   Jyri Sarha   drm/panel: simple...
3210
3211
3212
3213
3214
3215
3216
3217
3218
3219
3220
3221
3222
3223
3224
3225
3226
  };
  
  static const struct panel_desc rocktech_rk101ii01d_ct = {
  	.modes = &rocktech_rk101ii01d_ct_mode,
  	.num_modes = 1,
  	.size = {
  		.width = 217,
  		.height = 136,
  	},
  	.delay = {
  		.prepare = 50,
  		.disable = 50,
  	},
  	.bus_flags = DRM_BUS_FLAG_DE_HIGH,
  	.bus_format = MEDIA_BUS_FMT_RGB888_1X7X4_SPWG,
  	.connector_type = DRM_MODE_CONNECTOR_LVDS,
  };
0330eaf39   Yakir Yang   drm/panel: simple...
3227
3228
3229
3230
3231
3232
3233
3234
3235
3236
  static const struct drm_display_mode samsung_lsn122dl01_c01_mode = {
  	.clock = 271560,
  	.hdisplay = 2560,
  	.hsync_start = 2560 + 48,
  	.hsync_end = 2560 + 48 + 32,
  	.htotal = 2560 + 48 + 32 + 80,
  	.vdisplay = 1600,
  	.vsync_start = 1600 + 2,
  	.vsync_end = 1600 + 2 + 5,
  	.vtotal = 1600 + 2 + 5 + 57,
0330eaf39   Yakir Yang   drm/panel: simple...
3237
3238
3239
3240
3241
3242
3243
3244
3245
3246
  };
  
  static const struct panel_desc samsung_lsn122dl01_c01 = {
  	.modes = &samsung_lsn122dl01_c01_mode,
  	.num_modes = 1,
  	.size = {
  		.width = 263,
  		.height = 164,
  	},
  };
6d54e3d27   Marc Dietrich   drm/panel: Add su...
3247
3248
3249
3250
3251
3252
3253
3254
3255
3256
  static const struct drm_display_mode samsung_ltn101nt05_mode = {
  	.clock = 54030,
  	.hdisplay = 1024,
  	.hsync_start = 1024 + 24,
  	.hsync_end = 1024 + 24 + 136,
  	.htotal = 1024 + 24 + 136 + 160,
  	.vdisplay = 600,
  	.vsync_start = 600 + 3,
  	.vsync_end = 600 + 3 + 6,
  	.vtotal = 600 + 3 + 6 + 61,
6d54e3d27   Marc Dietrich   drm/panel: Add su...
3257
3258
3259
3260
3261
  };
  
  static const struct panel_desc samsung_ltn101nt05 = {
  	.modes = &samsung_ltn101nt05_mode,
  	.num_modes = 1,
0208d5111   Stéphane Marchesin   drm/panel: simple...
3262
  	.bpc = 6,
6d54e3d27   Marc Dietrich   drm/panel: Add su...
3263
  	.size = {
815988464   Thierry Reding   drm/panel: simple...
3264
3265
  		.width = 223,
  		.height = 125,
6d54e3d27   Marc Dietrich   drm/panel: Add su...
3266
  	},
855608296   Dmitry Osipenko   drm/panel-simple:...
3267
  	.bus_format = MEDIA_BUS_FMT_RGB666_1X7X3_SPWG,
c4715837b   Laurent Pinchart   drm: panel: simpl...
3268
  	.bus_flags = DRM_BUS_FLAG_DE_HIGH,
94f07917e   Dmitry Osipenko   drm/panel-simple:...
3269
  	.connector_type = DRM_MODE_CONNECTOR_LVDS,
6d54e3d27   Marc Dietrich   drm/panel: Add su...
3270
  };
0c934306e   Stéphane Marchesin   drm/panel: simple...
3271
3272
3273
3274
3275
3276
3277
3278
3279
3280
  static const struct drm_display_mode samsung_ltn140at29_301_mode = {
  	.clock = 76300,
  	.hdisplay = 1366,
  	.hsync_start = 1366 + 64,
  	.hsync_end = 1366 + 64 + 48,
  	.htotal = 1366 + 64 + 48 + 128,
  	.vdisplay = 768,
  	.vsync_start = 768 + 2,
  	.vsync_end = 768 + 2 + 5,
  	.vtotal = 768 + 2 + 5 + 17,
0c934306e   Stéphane Marchesin   drm/panel: simple...
3281
3282
3283
3284
3285
3286
3287
3288
3289
3290
3291
  };
  
  static const struct panel_desc samsung_ltn140at29_301 = {
  	.modes = &samsung_ltn140at29_301_mode,
  	.num_modes = 1,
  	.bpc = 6,
  	.size = {
  		.width = 320,
  		.height = 187,
  	},
  };
44c58c520   Miquel Raynal   drm/panel: simple...
3292
3293
3294
3295
3296
3297
3298
3299
3300
3301
3302
3303
3304
3305
3306
3307
3308
3309
3310
3311
  static const struct display_timing satoz_sat050at40h12r2_timing = {
  	.pixelclock = {33300000, 33300000, 50000000},
  	.hactive = {800, 800, 800},
  	.hfront_porch = {16, 210, 354},
  	.hback_porch = {46, 46, 46},
  	.hsync_len = {1, 1, 40},
  	.vactive = {480, 480, 480},
  	.vfront_porch = {7, 22, 147},
  	.vback_porch = {23, 23, 23},
  	.vsync_len = {1, 1, 20},
  };
  
  static const struct panel_desc satoz_sat050at40h12r2 = {
  	.timings = &satoz_sat050at40h12r2_timing,
  	.num_timings = 1,
  	.bpc = 8,
  	.size = {
  		.width = 108,
  		.height = 65,
  	},
34ca6b535   Laurent Pinchart   drm: panel: simpl...
3312
  	.bus_format = MEDIA_BUS_FMT_RGB888_1X7X4_SPWG,
44c58c520   Miquel Raynal   drm/panel: simple...
3313
3314
  	.connector_type = DRM_MODE_CONNECTOR_LVDS,
  };
cd5e1cbe1   Jeffrey Hugo   drm/panel: simple...
3315
3316
3317
3318
3319
3320
3321
3322
3323
3324
  static const struct drm_display_mode sharp_ld_d5116z01b_mode = {
  	.clock = 168480,
  	.hdisplay = 1920,
  	.hsync_start = 1920 + 48,
  	.hsync_end = 1920 + 48 + 32,
  	.htotal = 1920 + 48 + 32 + 80,
  	.vdisplay = 1280,
  	.vsync_start = 1280 + 3,
  	.vsync_end = 1280 + 3 + 10,
  	.vtotal = 1280 + 3 + 10 + 57,
cd5e1cbe1   Jeffrey Hugo   drm/panel: simple...
3325
3326
3327
3328
3329
3330
3331
3332
3333
3334
3335
3336
3337
3338
  	.flags = DRM_MODE_FLAG_PHSYNC | DRM_MODE_FLAG_PVSYNC,
  };
  
  static const struct panel_desc sharp_ld_d5116z01b = {
  	.modes = &sharp_ld_d5116z01b_mode,
  	.num_modes = 1,
  	.bpc = 8,
  	.size = {
  		.width = 260,
  		.height = 120,
  	},
  	.bus_format = MEDIA_BUS_FMT_RGB888_1X24,
  	.bus_flags = DRM_BUS_FLAG_DATA_MSB_TO_LSB,
  };
dda0e4bdb   H. Nikolaus Schaller   drm/panel: simple...
3339
3340
3341
3342
3343
3344
3345
3346
3347
3348
  static const struct drm_display_mode sharp_lq070y3dg3b_mode = {
  	.clock = 33260,
  	.hdisplay = 800,
  	.hsync_start = 800 + 64,
  	.hsync_end = 800 + 64 + 128,
  	.htotal = 800 + 64 + 128 + 64,
  	.vdisplay = 480,
  	.vsync_start = 480 + 8,
  	.vsync_end = 480 + 8 + 2,
  	.vtotal = 480 + 8 + 2 + 35,
dda0e4bdb   H. Nikolaus Schaller   drm/panel: simple...
3349
3350
3351
3352
3353
3354
3355
3356
3357
3358
3359
3360
  	.flags = DISPLAY_FLAGS_PIXDATA_POSEDGE,
  };
  
  static const struct panel_desc sharp_lq070y3dg3b = {
  	.modes = &sharp_lq070y3dg3b_mode,
  	.num_modes = 1,
  	.bpc = 8,
  	.size = {
  		.width = 152,	/* 152.4mm */
  		.height = 91,	/* 91.4mm */
  	},
  	.bus_format = MEDIA_BUS_FMT_RGB888_1X24,
f5436f774   Sam Ravnborg   drm/panel: panel-...
3361
  	.bus_flags = DRM_BUS_FLAG_DE_HIGH | DRM_BUS_FLAG_PIXDATA_SAMPLE_NEGEDGE |
dda0e4bdb   H. Nikolaus Schaller   drm/panel: simple...
3362
3363
  		     DRM_BUS_FLAG_SYNC_DRIVE_POSEDGE,
  };
03e3ec9ad   Vladimir Zapolskiy   drm/panel: simple...
3364
3365
3366
3367
3368
3369
3370
3371
3372
3373
  static const struct drm_display_mode sharp_lq035q7db03_mode = {
  	.clock = 5500,
  	.hdisplay = 240,
  	.hsync_start = 240 + 16,
  	.hsync_end = 240 + 16 + 7,
  	.htotal = 240 + 16 + 7 + 5,
  	.vdisplay = 320,
  	.vsync_start = 320 + 9,
  	.vsync_end = 320 + 9 + 1,
  	.vtotal = 320 + 9 + 1 + 7,
03e3ec9ad   Vladimir Zapolskiy   drm/panel: simple...
3374
3375
3376
3377
3378
3379
3380
3381
3382
3383
3384
3385
  };
  
  static const struct panel_desc sharp_lq035q7db03 = {
  	.modes = &sharp_lq035q7db03_mode,
  	.num_modes = 1,
  	.bpc = 6,
  	.size = {
  		.width = 54,
  		.height = 72,
  	},
  	.bus_format = MEDIA_BUS_FMT_RGB666_1X18,
  };
592aa02bd   Joshua Clayton   drm/panel: simple...
3386
3387
3388
3389
3390
3391
3392
3393
3394
3395
3396
3397
3398
3399
3400
3401
3402
3403
3404
3405
3406
3407
  static const struct display_timing sharp_lq101k1ly04_timing = {
  	.pixelclock = { 60000000, 65000000, 80000000 },
  	.hactive = { 1280, 1280, 1280 },
  	.hfront_porch = { 20, 20, 20 },
  	.hback_porch = { 20, 20, 20 },
  	.hsync_len = { 10, 10, 10 },
  	.vactive = { 800, 800, 800 },
  	.vfront_porch = { 4, 4, 4 },
  	.vback_porch = { 4, 4, 4 },
  	.vsync_len = { 4, 4, 4 },
  	.flags = DISPLAY_FLAGS_PIXDATA_POSEDGE,
  };
  
  static const struct panel_desc sharp_lq101k1ly04 = {
  	.timings = &sharp_lq101k1ly04_timing,
  	.num_timings = 1,
  	.bpc = 8,
  	.size = {
  		.width = 217,
  		.height = 136,
  	},
  	.bus_format = MEDIA_BUS_FMT_RGB888_1X7X4_JEIDA,
9a2654c0f   Laurent Pinchart   drm/panel: Add an...
3408
  	.connector_type = DRM_MODE_CONNECTOR_LVDS,
592aa02bd   Joshua Clayton   drm/panel: simple...
3409
  };
9f7bae2db   Sean Paul   drm/panel: simple...
3410
3411
3412
3413
3414
3415
3416
3417
3418
3419
3420
  static const struct display_timing sharp_lq123p1jx31_timing = {
  	.pixelclock = { 252750000, 252750000, 266604720 },
  	.hactive = { 2400, 2400, 2400 },
  	.hfront_porch = { 48, 48, 48 },
  	.hback_porch = { 80, 80, 84 },
  	.hsync_len = { 32, 32, 32 },
  	.vactive = { 1600, 1600, 1600 },
  	.vfront_porch = { 3, 3, 3 },
  	.vback_porch = { 33, 33, 120 },
  	.vsync_len = { 10, 10, 10 },
  	.flags = DISPLAY_FLAGS_VSYNC_LOW | DISPLAY_FLAGS_HSYNC_LOW,
739c7de9a   Yakir Yang   drm/panel: simple...
3421
3422
3423
  };
  
  static const struct panel_desc sharp_lq123p1jx31 = {
9f7bae2db   Sean Paul   drm/panel: simple...
3424
3425
  	.timings = &sharp_lq123p1jx31_timing,
  	.num_timings = 1,
5466a631b   zain wang   drm/panel: simple...
3426
  	.bpc = 8,
739c7de9a   Yakir Yang   drm/panel: simple...
3427
3428
3429
3430
  	.size = {
  		.width = 259,
  		.height = 173,
  	},
a42f6e3f8   Yakir Yang   drm/panel: simple...
3431
3432
3433
3434
3435
  	.delay = {
  		.prepare = 110,
  		.enable = 50,
  		.unprepare = 550,
  	},
739c7de9a   Yakir Yang   drm/panel: simple...
3436
  };
656b75963   Paul Cercueil   drm/panel: simple...
3437
  static const struct drm_display_mode sharp_ls020b1dd01d_modes[] = {
e6c21e6f9   Paul Cercueil   drm/panel: simple...
3438
3439
3440
3441
3442
3443
3444
3445
3446
3447
3448
3449
  	{ /* 50 Hz */
  		.clock = 3000,
  		.hdisplay = 240,
  		.hsync_start = 240 + 58,
  		.hsync_end = 240 + 58 + 1,
  		.htotal = 240 + 58 + 1 + 1,
  		.vdisplay = 160,
  		.vsync_start = 160 + 24,
  		.vsync_end = 160 + 24 + 10,
  		.vtotal = 160 + 24 + 10 + 6,
  		.flags = DRM_MODE_FLAG_PHSYNC | DRM_MODE_FLAG_NVSYNC,
  	},
656b75963   Paul Cercueil   drm/panel: simple...
3450
  	{ /* 60 Hz */
c1bd32b5f   Paul Cercueil   drm/panel: simple...
3451
  		.clock = 3000,
656b75963   Paul Cercueil   drm/panel: simple...
3452
  		.hdisplay = 240,
c1bd32b5f   Paul Cercueil   drm/panel: simple...
3453
3454
3455
  		.hsync_start = 240 + 8,
  		.hsync_end = 240 + 8 + 1,
  		.htotal = 240 + 8 + 1 + 1,
656b75963   Paul Cercueil   drm/panel: simple...
3456
  		.vdisplay = 160,
c1bd32b5f   Paul Cercueil   drm/panel: simple...
3457
3458
3459
  		.vsync_start = 160 + 24,
  		.vsync_end = 160 + 24 + 10,
  		.vtotal = 160 + 24 + 10 + 6,
656b75963   Paul Cercueil   drm/panel: simple...
3460
3461
  		.flags = DRM_MODE_FLAG_PHSYNC | DRM_MODE_FLAG_NVSYNC,
  	},
f1bd37f30   Paul Cercueil   drm/panel: simple...
3462
3463
3464
  };
  
  static const struct panel_desc sharp_ls020b1dd01d = {
656b75963   Paul Cercueil   drm/panel: simple...
3465
3466
  	.modes = sharp_ls020b1dd01d_modes,
  	.num_modes = ARRAY_SIZE(sharp_ls020b1dd01d_modes),
f1bd37f30   Paul Cercueil   drm/panel: simple...
3467
3468
3469
3470
3471
3472
3473
  	.bpc = 6,
  	.size = {
  		.width = 42,
  		.height = 28,
  	},
  	.bus_format = MEDIA_BUS_FMT_RGB565_1X16,
  	.bus_flags = DRM_BUS_FLAG_DE_HIGH
f5436f774   Sam Ravnborg   drm/panel: panel-...
3474
  		   | DRM_BUS_FLAG_PIXDATA_SAMPLE_POSEDGE
f1bd37f30   Paul Cercueil   drm/panel: simple...
3475
3476
  		   | DRM_BUS_FLAG_SHARP_SIGNALS,
  };
9c6615bc3   Boris BREZILLON   drm/panel: simple...
3477
3478
3479
3480
3481
3482
3483
3484
3485
3486
  static const struct drm_display_mode shelly_sca07010_bfn_lnn_mode = {
  	.clock = 33300,
  	.hdisplay = 800,
  	.hsync_start = 800 + 1,
  	.hsync_end = 800 + 1 + 64,
  	.htotal = 800 + 1 + 64 + 64,
  	.vdisplay = 480,
  	.vsync_start = 480 + 1,
  	.vsync_end = 480 + 1 + 23,
  	.vtotal = 480 + 1 + 23 + 22,
9c6615bc3   Boris BREZILLON   drm/panel: simple...
3487
3488
3489
3490
3491
3492
3493
3494
3495
3496
3497
  };
  
  static const struct panel_desc shelly_sca07010_bfn_lnn = {
  	.modes = &shelly_sca07010_bfn_lnn_mode,
  	.num_modes = 1,
  	.size = {
  		.width = 152,
  		.height = 91,
  	},
  	.bus_format = MEDIA_BUS_FMT_RGB666_1X18,
  };
105235e4a   Pascal Roeleven   drm: panel: Add S...
3498
3499
3500
3501
3502
3503
3504
3505
3506
3507
  static const struct drm_display_mode starry_kr070pe2t_mode = {
  	.clock = 33000,
  	.hdisplay = 800,
  	.hsync_start = 800 + 209,
  	.hsync_end = 800 + 209 + 1,
  	.htotal = 800 + 209 + 1 + 45,
  	.vdisplay = 480,
  	.vsync_start = 480 + 22,
  	.vsync_end = 480 + 22 + 1,
  	.vtotal = 480 + 22 + 1 + 22,
105235e4a   Pascal Roeleven   drm: panel: Add S...
3508
3509
3510
3511
3512
3513
3514
3515
3516
3517
3518
3519
  };
  
  static const struct panel_desc starry_kr070pe2t = {
  	.modes = &starry_kr070pe2t_mode,
  	.num_modes = 1,
  	.bpc = 8,
  	.size = {
  		.width = 152,
  		.height = 86,
  	},
  	.bus_format = MEDIA_BUS_FMT_RGB888_1X24,
  	.bus_flags = DRM_BUS_FLAG_DE_HIGH | DRM_BUS_FLAG_PIXDATA_DRIVE_NEGEDGE,
41fad307b   Laurent Pinchart   drm: panel: simpl...
3520
  	.connector_type = DRM_MODE_CONNECTOR_DPI,
105235e4a   Pascal Roeleven   drm: panel: Add S...
3521
  };
9bb34c4c7   Douglas Anderson   drm/panel: simple...
3522
3523
3524
3525
3526
3527
3528
3529
3530
3531
  static const struct drm_display_mode starry_kr122ea0sra_mode = {
  	.clock = 147000,
  	.hdisplay = 1920,
  	.hsync_start = 1920 + 16,
  	.hsync_end = 1920 + 16 + 16,
  	.htotal = 1920 + 16 + 16 + 32,
  	.vdisplay = 1200,
  	.vsync_start = 1200 + 15,
  	.vsync_end = 1200 + 15 + 2,
  	.vtotal = 1200 + 15 + 2 + 18,
9bb34c4c7   Douglas Anderson   drm/panel: simple...
3532
3533
3534
3535
3536
3537
3538
3539
3540
3541
  	.flags = DRM_MODE_FLAG_NVSYNC | DRM_MODE_FLAG_NHSYNC,
  };
  
  static const struct panel_desc starry_kr122ea0sra = {
  	.modes = &starry_kr122ea0sra_mode,
  	.num_modes = 1,
  	.size = {
  		.width = 263,
  		.height = 164,
  	},
c46b924bb   Brian Norris   drm/panel: simple...
3542
3543
3544
3545
3546
  	.delay = {
  		.prepare = 10 + 200,
  		.enable = 50,
  		.unprepare = 10 + 500,
  	},
9bb34c4c7   Douglas Anderson   drm/panel: simple...
3547
  };
421615318   Jyri Sarha   drm/panel: simple...
3548
3549
3550
3551
3552
3553
3554
3555
3556
3557
  static const struct drm_display_mode tfc_s9700rtwv43tr_01b_mode = {
  	.clock = 30000,
  	.hdisplay = 800,
  	.hsync_start = 800 + 39,
  	.hsync_end = 800 + 39 + 47,
  	.htotal = 800 + 39 + 47 + 39,
  	.vdisplay = 480,
  	.vsync_start = 480 + 13,
  	.vsync_end = 480 + 13 + 2,
  	.vtotal = 480 + 13 + 2 + 29,
421615318   Jyri Sarha   drm/panel: simple...
3558
3559
3560
3561
3562
3563
3564
3565
3566
3567
3568
  };
  
  static const struct panel_desc tfc_s9700rtwv43tr_01b = {
  	.modes = &tfc_s9700rtwv43tr_01b_mode,
  	.num_modes = 1,
  	.bpc = 8,
  	.size = {
  		.width = 155,
  		.height = 90,
  	},
  	.bus_format = MEDIA_BUS_FMT_RGB888_1X24,
f5436f774   Sam Ravnborg   drm/panel: panel-...
3569
  	.bus_flags = DRM_BUS_FLAG_DE_HIGH | DRM_BUS_FLAG_PIXDATA_SAMPLE_NEGEDGE,
421615318   Jyri Sarha   drm/panel: simple...
3570
  };
adb973ef5   Gary Bisson   drm/panel: simple...
3571
3572
3573
3574
3575
3576
3577
3578
3579
3580
3581
3582
3583
3584
3585
3586
3587
3588
3589
3590
3591
3592
  static const struct display_timing tianma_tm070jdhg30_timing = {
  	.pixelclock = { 62600000, 68200000, 78100000 },
  	.hactive = { 1280, 1280, 1280 },
  	.hfront_porch = { 15, 64, 159 },
  	.hback_porch = { 5, 5, 5 },
  	.hsync_len = { 1, 1, 256 },
  	.vactive = { 800, 800, 800 },
  	.vfront_porch = { 3, 40, 99 },
  	.vback_porch = { 2, 2, 2 },
  	.vsync_len = { 1, 1, 128 },
  	.flags = DISPLAY_FLAGS_DE_HIGH,
  };
  
  static const struct panel_desc tianma_tm070jdhg30 = {
  	.timings = &tianma_tm070jdhg30_timing,
  	.num_timings = 1,
  	.bpc = 8,
  	.size = {
  		.width = 151,
  		.height = 95,
  	},
  	.bus_format = MEDIA_BUS_FMT_RGB888_1X7X4_SPWG,
9a2654c0f   Laurent Pinchart   drm/panel: Add an...
3593
  	.connector_type = DRM_MODE_CONNECTOR_LVDS,
adb973ef5   Gary Bisson   drm/panel: simple...
3594
  };
b3bfcdf8a   Max Merchel   drm/panel: simple...
3595
3596
3597
3598
3599
3600
3601
3602
3603
3604
3605
  static const struct panel_desc tianma_tm070jvhg33 = {
  	.timings = &tianma_tm070jdhg30_timing,
  	.num_timings = 1,
  	.bpc = 8,
  	.size = {
  		.width = 150,
  		.height = 94,
  	},
  	.bus_format = MEDIA_BUS_FMT_RGB888_1X7X4_SPWG,
  	.connector_type = DRM_MODE_CONNECTOR_LVDS,
  };
870a0b12d   Lukasz Majewski   drm/panel: simple...
3606
3607
3608
3609
3610
3611
3612
3613
3614
3615
3616
3617
3618
3619
3620
3621
3622
3623
3624
3625
3626
3627
  static const struct display_timing tianma_tm070rvhg71_timing = {
  	.pixelclock = { 27700000, 29200000, 39600000 },
  	.hactive = { 800, 800, 800 },
  	.hfront_porch = { 12, 40, 212 },
  	.hback_porch = { 88, 88, 88 },
  	.hsync_len = { 1, 1, 40 },
  	.vactive = { 480, 480, 480 },
  	.vfront_porch = { 1, 13, 88 },
  	.vback_porch = { 32, 32, 32 },
  	.vsync_len = { 1, 1, 3 },
  	.flags = DISPLAY_FLAGS_DE_HIGH,
  };
  
  static const struct panel_desc tianma_tm070rvhg71 = {
  	.timings = &tianma_tm070rvhg71_timing,
  	.num_timings = 1,
  	.bpc = 8,
  	.size = {
  		.width = 154,
  		.height = 86,
  	},
  	.bus_format = MEDIA_BUS_FMT_RGB888_1X7X4_SPWG,
9a2654c0f   Laurent Pinchart   drm/panel: Add an...
3628
  	.connector_type = DRM_MODE_CONNECTOR_LVDS,
870a0b12d   Lukasz Majewski   drm/panel: simple...
3629
  };
d8a0d6a3b   Linus Walleij   drm/panel: simple...
3630
3631
3632
3633
3634
3635
3636
3637
3638
3639
3640
  static const struct drm_display_mode ti_nspire_cx_lcd_mode[] = {
  	{
  		.clock = 10000,
  		.hdisplay = 320,
  		.hsync_start = 320 + 50,
  		.hsync_end = 320 + 50 + 6,
  		.htotal = 320 + 50 + 6 + 38,
  		.vdisplay = 240,
  		.vsync_start = 240 + 3,
  		.vsync_end = 240 + 3 + 1,
  		.vtotal = 240 + 3 + 1 + 17,
d8a0d6a3b   Linus Walleij   drm/panel: simple...
3641
3642
3643
3644
3645
3646
3647
3648
3649
3650
3651
3652
3653
  		.flags = DRM_MODE_FLAG_NVSYNC | DRM_MODE_FLAG_NHSYNC,
  	},
  };
  
  static const struct panel_desc ti_nspire_cx_lcd_panel = {
  	.modes = ti_nspire_cx_lcd_mode,
  	.num_modes = 1,
  	.bpc = 8,
  	.size = {
  		.width = 65,
  		.height = 49,
  	},
  	.bus_format = MEDIA_BUS_FMT_RGB888_1X24,
f5436f774   Sam Ravnborg   drm/panel: panel-...
3654
  	.bus_flags = DRM_BUS_FLAG_PIXDATA_SAMPLE_POSEDGE,
d8a0d6a3b   Linus Walleij   drm/panel: simple...
3655
3656
3657
3658
3659
3660
3661
3662
3663
3664
3665
3666
3667
  };
  
  static const struct drm_display_mode ti_nspire_classic_lcd_mode[] = {
  	{
  		.clock = 10000,
  		.hdisplay = 320,
  		.hsync_start = 320 + 6,
  		.hsync_end = 320 + 6 + 6,
  		.htotal = 320 + 6 + 6 + 6,
  		.vdisplay = 240,
  		.vsync_start = 240 + 0,
  		.vsync_end = 240 + 0 + 1,
  		.vtotal = 240 + 0 + 1 + 0,
d8a0d6a3b   Linus Walleij   drm/panel: simple...
3668
3669
3670
3671
3672
3673
3674
3675
3676
3677
3678
3679
3680
3681
3682
  		.flags = DRM_MODE_FLAG_PHSYNC | DRM_MODE_FLAG_PVSYNC,
  	},
  };
  
  static const struct panel_desc ti_nspire_classic_lcd_panel = {
  	.modes = ti_nspire_classic_lcd_mode,
  	.num_modes = 1,
  	/* The grayscale panel has 8 bit for the color .. Y (black) */
  	.bpc = 8,
  	.size = {
  		.width = 71,
  		.height = 53,
  	},
  	/* This is the grayscale bus format */
  	.bus_format = MEDIA_BUS_FMT_Y8_1X8,
f5436f774   Sam Ravnborg   drm/panel: panel-...
3683
  	.bus_flags = DRM_BUS_FLAG_PIXDATA_SAMPLE_NEGEDGE,
d8a0d6a3b   Linus Walleij   drm/panel: simple...
3684
  };
06e733e41   Lucas Stach   drm/panel: simple...
3685
3686
3687
3688
3689
3690
3691
3692
3693
3694
  static const struct drm_display_mode toshiba_lt089ac29000_mode = {
  	.clock = 79500,
  	.hdisplay = 1280,
  	.hsync_start = 1280 + 192,
  	.hsync_end = 1280 + 192 + 128,
  	.htotal = 1280 + 192 + 128 + 64,
  	.vdisplay = 768,
  	.vsync_start = 768 + 20,
  	.vsync_end = 768 + 20 + 7,
  	.vtotal = 768 + 20 + 7 + 3,
06e733e41   Lucas Stach   drm/panel: simple...
3695
3696
3697
3698
3699
3700
3701
3702
3703
  };
  
  static const struct panel_desc toshiba_lt089ac29000 = {
  	.modes = &toshiba_lt089ac29000_mode,
  	.num_modes = 1,
  	.size = {
  		.width = 194,
  		.height = 116,
  	},
9781bd1dd   Boris Brezillon   drm/panel: simple...
3704
  	.bus_format = MEDIA_BUS_FMT_RGB888_1X7X4_JEIDA,
c4715837b   Laurent Pinchart   drm: panel: simpl...
3705
  	.bus_flags = DRM_BUS_FLAG_DE_HIGH,
9a2654c0f   Laurent Pinchart   drm/panel: Add an...
3706
  	.connector_type = DRM_MODE_CONNECTOR_LVDS,
06e733e41   Lucas Stach   drm/panel: simple...
3707
  };
227e4f407   Bhuvanchandra DV   drm/panel: simple...
3708
3709
3710
3711
3712
3713
3714
3715
3716
3717
  static const struct drm_display_mode tpk_f07a_0102_mode = {
  	.clock = 33260,
  	.hdisplay = 800,
  	.hsync_start = 800 + 40,
  	.hsync_end = 800 + 40 + 128,
  	.htotal = 800 + 40 + 128 + 88,
  	.vdisplay = 480,
  	.vsync_start = 480 + 10,
  	.vsync_end = 480 + 10 + 2,
  	.vtotal = 480 + 10 + 2 + 33,
227e4f407   Bhuvanchandra DV   drm/panel: simple...
3718
3719
3720
3721
3722
3723
3724
3725
3726
  };
  
  static const struct panel_desc tpk_f07a_0102 = {
  	.modes = &tpk_f07a_0102_mode,
  	.num_modes = 1,
  	.size = {
  		.width = 152,
  		.height = 91,
  	},
88bc41785   Laurent Pinchart   drm: Use new DRM_...
3727
  	.bus_flags = DRM_BUS_FLAG_PIXDATA_DRIVE_POSEDGE,
227e4f407   Bhuvanchandra DV   drm/panel: simple...
3728
3729
3730
3731
3732
3733
3734
3735
3736
3737
3738
3739
  };
  
  static const struct drm_display_mode tpk_f10a_0102_mode = {
  	.clock = 45000,
  	.hdisplay = 1024,
  	.hsync_start = 1024 + 176,
  	.hsync_end = 1024 + 176 + 5,
  	.htotal = 1024 + 176 + 5 + 88,
  	.vdisplay = 600,
  	.vsync_start = 600 + 20,
  	.vsync_end = 600 + 20 + 5,
  	.vtotal = 600 + 20 + 5 + 25,
227e4f407   Bhuvanchandra DV   drm/panel: simple...
3740
3741
3742
3743
3744
3745
3746
3747
3748
3749
  };
  
  static const struct panel_desc tpk_f10a_0102 = {
  	.modes = &tpk_f10a_0102_mode,
  	.num_modes = 1,
  	.size = {
  		.width = 223,
  		.height = 125,
  	},
  };
06a9dc65a   Maciej S. Szmigiero   drm/panel: simple...
3750
3751
3752
3753
3754
3755
3756
3757
3758
3759
3760
3761
3762
3763
3764
3765
3766
3767
3768
3769
3770
3771
3772
  static const struct display_timing urt_umsh_8596md_timing = {
  	.pixelclock = { 33260000, 33260000, 33260000 },
  	.hactive = { 800, 800, 800 },
  	.hfront_porch = { 41, 41, 41 },
  	.hback_porch = { 216 - 128, 216 - 128, 216 - 128 },
  	.hsync_len = { 71, 128, 128 },
  	.vactive = { 480, 480, 480 },
  	.vfront_porch = { 10, 10, 10 },
  	.vback_porch = { 35 - 2, 35 - 2, 35 - 2 },
  	.vsync_len = { 2, 2, 2 },
  	.flags = DISPLAY_FLAGS_DE_HIGH | DISPLAY_FLAGS_PIXDATA_NEGEDGE |
  		DISPLAY_FLAGS_HSYNC_LOW | DISPLAY_FLAGS_VSYNC_LOW,
  };
  
  static const struct panel_desc urt_umsh_8596md_lvds = {
  	.timings = &urt_umsh_8596md_timing,
  	.num_timings = 1,
  	.bpc = 6,
  	.size = {
  		.width = 152,
  		.height = 91,
  	},
  	.bus_format = MEDIA_BUS_FMT_RGB666_1X7X3_SPWG,
9a2654c0f   Laurent Pinchart   drm/panel: Add an...
3773
  	.connector_type = DRM_MODE_CONNECTOR_LVDS,
06a9dc65a   Maciej S. Szmigiero   drm/panel: simple...
3774
3775
3776
3777
3778
3779
3780
3781
3782
3783
3784
3785
  };
  
  static const struct panel_desc urt_umsh_8596md_parallel = {
  	.timings = &urt_umsh_8596md_timing,
  	.num_timings = 1,
  	.bpc = 6,
  	.size = {
  		.width = 152,
  		.height = 91,
  	},
  	.bus_format = MEDIA_BUS_FMT_RGB666_1X18,
  };
04206185a   Fabio Estevam   drm/panel: simple...
3786
3787
3788
3789
3790
3791
3792
3793
3794
3795
  static const struct drm_display_mode vl050_8048nt_c01_mode = {
  	.clock = 33333,
  	.hdisplay = 800,
  	.hsync_start = 800 + 210,
  	.hsync_end = 800 + 210 + 20,
  	.htotal = 800 + 210 + 20 + 46,
  	.vdisplay =  480,
  	.vsync_start = 480 + 22,
  	.vsync_end = 480 + 22 + 10,
  	.vtotal = 480 + 22 + 10 + 23,
04206185a   Fabio Estevam   drm/panel: simple...
3796
3797
3798
3799
3800
3801
3802
3803
3804
3805
3806
3807
  	.flags = DRM_MODE_FLAG_NHSYNC | DRM_MODE_FLAG_NVSYNC,
  };
  
  static const struct panel_desc vl050_8048nt_c01 = {
  	.modes = &vl050_8048nt_c01_mode,
  	.num_modes = 1,
  	.bpc = 8,
  	.size = {
  		.width = 120,
  		.height = 76,
  	},
  	.bus_format = MEDIA_BUS_FMT_RGB888_1X24,
f5436f774   Sam Ravnborg   drm/panel: panel-...
3808
  	.bus_flags = DRM_BUS_FLAG_DE_HIGH | DRM_BUS_FLAG_PIXDATA_SAMPLE_NEGEDGE,
04206185a   Fabio Estevam   drm/panel: simple...
3809
  };
e4bac408b   Richard Genoud   drm/panel: simple...
3810
3811
3812
3813
3814
3815
3816
3817
3818
3819
  static const struct drm_display_mode winstar_wf35ltiacd_mode = {
  	.clock = 6410,
  	.hdisplay = 320,
  	.hsync_start = 320 + 20,
  	.hsync_end = 320 + 20 + 30,
  	.htotal = 320 + 20 + 30 + 38,
  	.vdisplay = 240,
  	.vsync_start = 240 + 4,
  	.vsync_end = 240 + 4 + 3,
  	.vtotal = 240 + 4 + 3 + 15,
e4bac408b   Richard Genoud   drm/panel: simple...
3820
3821
3822
3823
3824
3825
3826
3827
3828
3829
3830
3831
3832
  	.flags = DRM_MODE_FLAG_NVSYNC | DRM_MODE_FLAG_NHSYNC,
  };
  
  static const struct panel_desc winstar_wf35ltiacd = {
  	.modes = &winstar_wf35ltiacd_mode,
  	.num_modes = 1,
  	.bpc = 8,
  	.size = {
  		.width = 70,
  		.height = 53,
  	},
  	.bus_format = MEDIA_BUS_FMT_RGB888_1X24,
  };
fcec4163a   Linus Walleij   drm/panel: Add si...
3833
3834
3835
3836
3837
3838
3839
3840
3841
3842
3843
  static const struct drm_display_mode arm_rtsm_mode[] = {
  	{
  		.clock = 65000,
  		.hdisplay = 1024,
  		.hsync_start = 1024 + 24,
  		.hsync_end = 1024 + 24 + 136,
  		.htotal = 1024 + 24 + 136 + 160,
  		.vdisplay = 768,
  		.vsync_start = 768 + 3,
  		.vsync_end = 768 + 3 + 6,
  		.vtotal = 768 + 3 + 6 + 29,
fcec4163a   Linus Walleij   drm/panel: Add si...
3844
3845
3846
3847
3848
3849
3850
3851
3852
3853
3854
3855
3856
3857
  		.flags = DRM_MODE_FLAG_NVSYNC | DRM_MODE_FLAG_NHSYNC,
  	},
  };
  
  static const struct panel_desc arm_rtsm = {
  	.modes = arm_rtsm_mode,
  	.num_modes = 1,
  	.bpc = 8,
  	.size = {
  		.width = 400,
  		.height = 300,
  	},
  	.bus_format = MEDIA_BUS_FMT_RGB888_1X24,
  };
280921de7   Thierry Reding   drm/panel: Add si...
3858
3859
  static const struct of_device_id platform_of_match[] = {
  	{
bca684e69   Jagan Teki   drm/panel: simple...
3860
3861
3862
  		.compatible = "ampire,am-1280800n3tzqw-t00h",
  		.data = &ampire_am_1280800n3tzqw_t00h,
  	}, {
966fea78a   Yannick Fertre   drm/panel: simple...
3863
3864
3865
  		.compatible = "ampire,am-480272h3tmqw-t01h",
  		.data = &ampire_am_480272h3tmqw_t01h,
  	}, {
1c550fa19   Philipp Zabel   drm/panel: Add su...
3866
3867
3868
  		.compatible = "ampire,am800480r3tmqwa1h",
  		.data = &ampire_am800480r3tmqwa1h,
  	}, {
fcec4163a   Linus Walleij   drm/panel: Add si...
3869
3870
3871
  		.compatible = "arm,rtsm-display",
  		.data = &arm_rtsm,
  	}, {
c479450f6   Sébastien Szymanski   drm/panel: Add su...
3872
3873
3874
  		.compatible = "armadeus,st0700-adapt",
  		.data = &armadeus_st0700_adapt,
  	}, {
280921de7   Thierry Reding   drm/panel: Add si...
3875
3876
3877
  		.compatible = "auo,b101aw03",
  		.data = &auo_b101aw03,
  	}, {
a531bc3d9   Huang Lin   drm/panel: simple...
3878
3879
3880
  		.compatible = "auo,b101ean01",
  		.data = &auo_b101ean01,
  	}, {
dac746e04   Rob Clark   drm/panel/simple:...
3881
3882
3883
  		.compatible = "auo,b101xtn01",
  		.data = &auo_b101xtn01,
  	}, {
da458286a   Rob Clark   drm/panel: Add su...
3884
3885
3886
  		.compatible = "auo,b116xa01",
  		.data = &auo_b116xak01,
  	}, {
e35e305ef   Ajay Kumar   drm/panel: simple...
3887
3888
3889
  		.compatible = "auo,b116xw03",
  		.data = &auo_b116xw03,
  	}, {
3e51d6093   Ajay Kumar   drm/panel: simple...
3890
3891
3892
  		.compatible = "auo,b133htn01",
  		.data = &auo_b133htn01,
  	}, {
a333f7ad1   Stéphane Marchesin   drm/panel: simple...
3893
3894
3895
  		.compatible = "auo,b133xtn01",
  		.data = &auo_b133xtn01,
  	}, {
bccfaffb7   Lukasz Majewski   display: panel: A...
3896
3897
3898
  		.compatible = "auo,g070vvn01",
  		.data = &auo_g070vvn01,
  	}, {
4fb86404a   Alex Gonzalez   drm/panel: simple...
3899
3900
3901
  		.compatible = "auo,g101evn010",
  		.data = &auo_g101evn010,
  	}, {
4451c287e   Christoph Fritz   drm/panel: Add su...
3902
3903
3904
  		.compatible = "auo,g104sn02",
  		.data = &auo_g104sn02,
  	}, {
03e909acd   Sebastian Reichel   drm/panel: simple...
3905
3906
3907
  		.compatible = "auo,g121ean01",
  		.data = &auo_g121ean01,
  	}, {
697035c6b   Lucas Stach   drm/panel: simple...
3908
3909
3910
  		.compatible = "auo,g133han01",
  		.data = &auo_g133han01,
  	}, {
d9ccd1f28   Sebastian Reichel   drm/panel: simple...
3911
3912
3913
  		.compatible = "auo,g156xtn01",
  		.data = &auo_g156xtn01,
  	}, {
8c31f6034   Lucas Stach   drm/panel: simple...
3914
3915
3916
  		.compatible = "auo,g185han01",
  		.data = &auo_g185han01,
  	}, {
2f7b832fc   Sebastian Reichel   drm/panel: simple...
3917
3918
3919
  		.compatible = "auo,g190ean01",
  		.data = &auo_g190ean01,
  	}, {
70c0d5b78   Lucas Stach   drm/panel: simple...
3920
3921
3922
  		.compatible = "auo,p320hvn03",
  		.data = &auo_p320hvn03,
  	}, {
7ee933a1d   Haixia Shi   drm/panel: simple...
3923
3924
3925
  		.compatible = "auo,t215hvn01",
  		.data = &auo_t215hvn01,
  	}, {
d47df6339   Philipp Zabel   drm/panel: simple...
3926
3927
3928
  		.compatible = "avic,tm070ddh03",
  		.data = &avic_tm070ddh03,
  	}, {
7ad8b41cd   Chen-Yu Tsai   drm/panel: simple...
3929
3930
3931
  		.compatible = "bananapi,s070wv20-ct16",
  		.data = &bananapi_s070wv20_ct16,
  	}, {
ae8cf41b6   Andrzej Hajda   drm/panel: simple...
3932
3933
3934
  		.compatible = "boe,hv070wsa-100",
  		.data = &boe_hv070wsa
  	}, {
cac1a4112   Caesar Wang   drm/panel: simple...
3935
3936
3937
  		.compatible = "boe,nv101wxmn51",
  		.data = &boe_nv101wxmn51,
  	}, {
b0c664cc8   Bjorn Andersson   panel: simple: Ad...
3938
3939
3940
  		.compatible = "boe,nv133fhm-n61",
  		.data = &boe_nv133fhm_n61,
  	}, {
cfe40d022   Douglas Anderson   panel: simple: Ad...
3941
3942
3943
  		.compatible = "boe,nv133fhm-n62",
  		.data = &boe_nv133fhm_n61,
  	}, {
a51198184   Tobias Schramm   drm/panel: Add su...
3944
3945
3946
  		.compatible = "boe,nv140fhmn49",
  		.data = &boe_nv140fhmn49,
  	}, {
e58edce61   Giulio Benetti   drm/panel: add pa...
3947
3948
3949
  		.compatible = "cdtech,s043wq26h-ct7",
  		.data = &cdtech_s043wq26h_ct7,
  	}, {
0e3b67f6d   Michael Krummsdorf   drm/panel: simple...
3950
3951
3952
3953
3954
3955
  		.compatible = "cdtech,s070pws19hp-fc21",
  		.data = &cdtech_s070pws19hp_fc21,
  	}, {
  		.compatible = "cdtech,s070swv29hg-dc44",
  		.data = &cdtech_s070swv29hg_dc44,
  	}, {
982f944ed   Giulio Benetti   drm/panel: add pa...
3956
3957
3958
  		.compatible = "cdtech,s070wv95-ct16",
  		.data = &cdtech_s070wv95_ct16,
  	}, {
07c913c4d   Marek Vasut   drm/panel: simple...
3959
3960
3961
  		.compatible = "chefree,ch101olhlwh-002",
  		.data = &chefree_ch101olhlwh_002,
  	}, {
2cb35c802   Randy Li   drm/panel: Add su...
3962
3963
3964
  		.compatible = "chunghwa,claa070wp03xg",
  		.data = &chunghwa_claa070wp03xg,
  	}, {
4c9307577   Stephen Warren   drm/panel: Add su...
3965
3966
3967
  		.compatible = "chunghwa,claa101wa01a",
  		.data = &chunghwa_claa101wa01a
  	}, {
280921de7   Thierry Reding   drm/panel: Add si...
3968
3969
3970
  		.compatible = "chunghwa,claa101wb01",
  		.data = &chunghwa_claa101wb01
  	}, {
97ceb1fb0   Michal Vokáč   drm/panel: simple...
3971
3972
3973
  		.compatible = "dataimage,scf0700c48ggu18",
  		.data = &dataimage_scf0700c48ggu18,
  	}, {
0ca0c827e   Philipp Zabel   drm/panel: simple...
3974
3975
3976
  		.compatible = "dlc,dlc0700yzg-1",
  		.data = &dlc_dlc0700yzg_1,
  	}, {
6cbe7cd15   Marco Felsch   drm/panel: simple...
3977
3978
3979
  		.compatible = "dlc,dlc1010gig",
  		.data = &dlc_dlc1010gig,
  	}, {
c2d24af62   Andreas Pretzsch   drm/panel: simple...
3980
3981
3982
  		.compatible = "edt,et035012dm6",
  		.data = &edt_et035012dm6,
  	}, {
82d57a590   Marian-Cristian Rotariu   drm/panel: simple...
3983
3984
3985
  		.compatible = "edt,etm043080dh6gp",
  		.data = &edt_etm043080dh6gp,
  	}, {
fd819bff3   Marek Vasut   drm/panel: Add su...
3986
3987
3988
  		.compatible = "edt,etm0430g0dh6",
  		.data = &edt_etm0430g0dh6,
  	}, {
26ab00657   Stefan Agner   drm/panel: add su...
3989
3990
3991
  		.compatible = "edt,et057090dhu",
  		.data = &edt_et057090dhu,
  	}, {
fff5de45e   Philipp Zabel   drm/panel: Add su...
3992
3993
3994
3995
3996
3997
  		.compatible = "edt,et070080dh6",
  		.data = &edt_etm0700g0dh6,
  	}, {
  		.compatible = "edt,etm0700g0dh6",
  		.data = &edt_etm0700g0dh6,
  	}, {
aa7e6455e   Jan Tuerk   drm/panel: Add su...
3998
3999
4000
  		.compatible = "edt,etm0700g0bdh6",
  		.data = &edt_etm0700g0bdh6,
  	}, {
aad34de22   Jan Tuerk   drm/panel: Add su...
4001
4002
4003
  		.compatible = "edt,etm0700g0edh6",
  		.data = &edt_etm0700g0bdh6,
  	}, {
9158e3c31   Marco Felsch   drm/panel: simple...
4004
4005
4006
  		.compatible = "evervision,vgg804821",
  		.data = &evervision_vgg804821,
  	}, {
102932b0e   Boris BREZILLON   drm/panel: add su...
4007
4008
4009
  		.compatible = "foxlink,fl500wvr00-a0t",
  		.data = &foxlink_fl500wvr00_a0t,
  	}, {
7b6bd8433   Paul Cercueil   drm/panel: simple...
4010
4011
4012
  		.compatible = "frida,frd350h54004",
  		.data = &frida_frd350h54004,
  	}, {
3be207100   Jagan Teki   drm/panel: simple...
4013
4014
4015
  		.compatible = "friendlyarm,hd702e",
  		.data = &friendlyarm_hd702e,
  	}, {
d435a2af1   Philipp Zabel   drm/panel: simple...
4016
4017
4018
  		.compatible = "giantplus,gpg482739qs5",
  		.data = &giantplus_gpg482739qs5
  	}, {
2c6574a9e   Paul Cercueil   drm/panel: simple...
4019
4020
4021
  		.compatible = "giantplus,gpm940b0",
  		.data = &giantplus_gpm940b0,
  	}, {
a853205ef   Philipp Zabel   drm/panel: simple...
4022
4023
4024
  		.compatible = "hannstar,hsd070pww1",
  		.data = &hannstar_hsd070pww1,
  	}, {
c0d607e5a   Eric Nelson   drm/panel: simple...
4025
4026
4027
  		.compatible = "hannstar,hsd100pxn1",
  		.data = &hannstar_hsd100pxn1,
  	}, {
61ac0bf89   Lucas Stach   drm/panel: simple...
4028
4029
4030
  		.compatible = "hit,tx23d38vm0caa",
  		.data = &hitachi_tx23d38vm0caa
  	}, {
41bcceb4d   Nicolas Ferre   drm/panel: simple...
4031
4032
4033
  		.compatible = "innolux,at043tn24",
  		.data = &innolux_at043tn24,
  	}, {
4fc24ab3a   Riccardo Bortolato   drm/panel: simple...
4034
4035
4036
  		.compatible = "innolux,at070tn92",
  		.data = &innolux_at070tn92,
  	}, {
a5d2ade62   Christoph Fritz   drm/panel: simple...
4037
4038
4039
4040
  		.compatible = "innolux,g070y2-l01",
  		.data = &innolux_g070y2_l01,
  	}, {
  		.compatible = "innolux,g101ice-l01",
1e29b840a   Michael Olbrich   drm/panel: simple...
4041
4042
  		.data = &innolux_g101ice_l01
  	}, {
a5d2ade62   Christoph Fritz   drm/panel: simple...
4043
  		.compatible = "innolux,g121i1-l01",
d731f661b   Lucas Stach   drm/panel: simple...
4044
4045
  		.data = &innolux_g121i1_l01
  	}, {
f8fa17ba8   Akshay Bhat   drm/panel: simple...
4046
4047
4048
  		.compatible = "innolux,g121x1-l03",
  		.data = &innolux_g121x1_l03,
  	}, {
0a2288c06   Thierry Reding   drm/panel: simple...
4049
4050
4051
  		.compatible = "innolux,n116bge",
  		.data = &innolux_n116bge,
  	}, {
ea44739db   Alban Bedel   drm/panel: simple...
4052
4053
4054
  		.compatible = "innolux,n156bge-l21",
  		.data = &innolux_n156bge_l21,
  	}, {
8f054b6f5   Douglas Anderson   drm/panel: simple...
4055
4056
  		.compatible = "innolux,p120zdg-bf1",
  		.data = &innolux_p120zdg_bf1,
da50bd425   spanda@codeaurora.org   drm/panel: simple...
4057
  	}, {
bccac3f12   Michael Grzeschik   drm/panel: simple...
4058
4059
4060
  		.compatible = "innolux,zj070na-01p",
  		.data = &innolux_zj070na_01p,
  	}, {
e1ca51846   Bjorn Andersson   panel: simple: Ad...
4061
4062
4063
  		.compatible = "ivo,m133nwf4-r0",
  		.data = &ivo_m133nwf4_r0,
  	}, {
fc26a3758   Douglas Anderson   drm: panel: simpl...
4064
4065
4066
  		.compatible = "kingdisplay,kd116n21-30nv-a010",
  		.data = &kingdisplay_kd116n21_30nv_a010,
  	}, {
22014344a   Liu Ying   drm/panel: simple...
4067
4068
4069
  		.compatible = "jdi,tx26d202vm0bwa",
  		.data = &jdi_tx26d202vm0bwa,
  	}, {
66d2eb893   Eric Lee   Linux v5.10.9 sup...
4070
4071
4072
                  .compatible = "auo,g070vw01",
                  .data = &auo_g070vw01,
          }, {
802e949e8   Eric Lee   Linux kernel 5.10...
4073
4074
4075
  		.compatible = "evervision,vgg644804",
  		.data = &evervision_vgg644804,
  	}, {
14bf60c41   Lukasz Majewski   drm/panel: simple...
4076
4077
4078
  		.compatible = "koe,tx14d24vm1bpa",
  		.data = &koe_tx14d24vm1bpa,
  	}, {
8a0705244   Liu Ying   drm/panel: simple...
4079
4080
4081
  		.compatible = "koe,tx26d202vm0bwa",
  		.data = &koe_tx26d202vm0bwa,
  	}, {
8cfe83419   Jagan Teki   drm/panel: simple...
4082
4083
4084
  		.compatible = "koe,tx31d200vm0baa",
  		.data = &koe_tx31d200vm0baa,
  	}, {
8def22e50   Lucas Stach   drm/panel: simple...
4085
4086
4087
  		.compatible = "kyo,tcg121xglp",
  		.data = &kyo_tcg121xglp,
  	}, {
27abdd83f   Paul Kocialkowski   drm/panel: simple...
4088
4089
4090
  		.compatible = "lemaker,bl035-rgb-002",
  		.data = &lemaker_bl035_rgb_002,
  	}, {
dd0150026   Heiko Schocher   drm/panel: simple...
4091
4092
4093
  		.compatible = "lg,lb070wv8",
  		.data = &lg_lb070wv8,
  	}, {
c5ece4024   Yakir Yang   drm/panel: simple...
4094
4095
4096
  		.compatible = "lg,lp079qx1-sp0v",
  		.data = &lg_lp079qx1_sp0v,
  	}, {
0355dde26   Yakir Yang   drm/panel: simple...
4097
4098
4099
  		.compatible = "lg,lp097qx1-spa1",
  		.data = &lg_lp097qx1_spa1,
  	}, {
690d8fa70   Jitao Shi   drm/panel: simple...
4100
4101
4102
  		.compatible = "lg,lp120up1",
  		.data = &lg_lp120up1,
  	}, {
ec7c56538   Thierry Reding   drm/panel: Add LG...
4103
4104
4105
  		.compatible = "lg,lp129qe",
  		.data = &lg_lp129qe,
  	}, {
0d35408af   Adam Ford   drm/panel: simple...
4106
4107
4108
  		.compatible = "logicpd,type28",
  		.data = &logicpd_type_28,
  	}, {
5728fe7fa   Marcel Ziswiler   drm/panel: simple...
4109
4110
4111
4112
4113
4114
4115
4116
4117
  		.compatible = "logictechno,lt161010-2nhc",
  		.data = &logictechno_lt161010_2nh,
  	}, {
  		.compatible = "logictechno,lt161010-2nhr",
  		.data = &logictechno_lt161010_2nh,
  	}, {
  		.compatible = "logictechno,lt170410-2whc",
  		.data = &logictechno_lt170410_2whc,
  	}, {
65c766cad   Lukasz Majewski   drm/panel: simple...
4118
4119
4120
  		.compatible = "mitsubishi,aa070mc01-ca1",
  		.data = &mitsubishi_aa070mc01,
  	}, {
01bacc13a   Lucas Stach   drm/panel: simple...
4121
4122
4123
  		.compatible = "nec,nl12880bc20-05",
  		.data = &nec_nl12880bc20_05,
  	}, {
c6e87f91f   jianwei wang   drm/panel: simple...
4124
4125
4126
  		.compatible = "nec,nl4827hc19-05b",
  		.data = &nec_nl4827hc19_05b,
  	}, {
e6c2f066d   Maxime Ripard   drm/panel: simple...
4127
4128
4129
  		.compatible = "netron-dy,e231732",
  		.data = &netron_dy_e231732,
  	}, {
258145ea3   Vasily Khoruzhick   drm/panel: simple...
4130
4131
4132
  		.compatible = "neweast,wjfh116008a",
  		.data = &neweast_wjfh116008a,
  	}, {
3b39ad7a5   Tomi Valkeinen   drm/panel: simple...
4133
4134
4135
  		.compatible = "newhaven,nhd-4.3-480272ef-atxl",
  		.data = &newhaven_nhd_43_480272ef_atxl,
  	}, {
4177fa66a   Lucas Stach   drm/panel: simple...
4136
4137
4138
  		.compatible = "nlt,nl192108ac18-02d",
  		.data = &nlt_nl192108ac18_02d,
  	}, {
05ec0e450   Fabien Lahoudere   drm/panel: simple...
4139
4140
4141
  		.compatible = "nvd,9128",
  		.data = &nvd_9128,
  	}, {
a99fb6269   Gary Bisson   drm/panel: Add di...
4142
4143
4144
  		.compatible = "okaya,rs800480t-7x0gp",
  		.data = &okaya_rs800480t_7x0gp,
  	}, {
cf5c9e6dc   Maxime Ripard   drm/panel: simple...
4145
4146
4147
  		.compatible = "olimex,lcd-olinuxino-43-ts",
  		.data = &olimex_lcd_olinuxino_43ts,
  	}, {
e8b6f561b   Eric Anholt   drm/panel: simple...
4148
4149
4150
  		.compatible = "ontat,yx700wv03",
  		.data = &ontat_yx700wv03,
  	}, {
9c31dcb6d   H. Nikolaus Schaller   drm/panel: simple...
4151
4152
4153
4154
4155
4156
  		.compatible = "ortustech,com37h3m05dtc",
  		.data = &ortustech_com37h3m,
  	}, {
  		.compatible = "ortustech,com37h3m99dtc",
  		.data = &ortustech_com37h3m,
  	}, {
725c9d40f   Philipp Zabel   drm/panel: Add su...
4157
4158
4159
  		.compatible = "ortustech,com43h4m85ulc",
  		.data = &ortustech_com43h4m85ulc,
  	}, {
163f7a357   Laurent Pinchart   drm/panel: simple...
4160
4161
4162
  		.compatible = "osddisplays,osd070t1718-19ts",
  		.data = &osddisplays_osd070t1718_19ts,
  	}, {
4ba3e5634   Eugen Hristev   drm/panel: simple...
4163
4164
4165
  		.compatible = "pda,91-00156-a0",
  		.data = &pda_91_00156_a0,
  	}, {
d69de69f2   Marek Vasut   drm/panel: simple...
4166
4167
4168
  		.compatible = "powertip,ph800480t013-idf02",
  		.data = &powertip_ph800480t013_idf02,
  	}, {
d2a6f0f55   Josh Wu   drm/panel: simple...
4169
4170
4171
  		.compatible = "qiaodian,qd43003c0-40",
  		.data = &qd43003c0_40,
  	}, {
23167fa9a   Jagan Teki   drm/panel: simple...
4172
4173
4174
  		.compatible = "rocktech,rk070er9427",
  		.data = &rocktech_rk070er9427,
  	}, {
f305047b4   Jyri Sarha   drm/panel: simple...
4175
4176
4177
  		.compatible = "rocktech,rk101ii01d-ct",
  		.data = &rocktech_rk101ii01d_ct,
  	}, {
0330eaf39   Yakir Yang   drm/panel: simple...
4178
4179
4180
  		.compatible = "samsung,lsn122dl01-c01",
  		.data = &samsung_lsn122dl01_c01,
  	}, {
6d54e3d27   Marc Dietrich   drm/panel: Add su...
4181
4182
4183
  		.compatible = "samsung,ltn101nt05",
  		.data = &samsung_ltn101nt05,
  	}, {
0c934306e   Stéphane Marchesin   drm/panel: simple...
4184
4185
4186
  		.compatible = "samsung,ltn140at29-301",
  		.data = &samsung_ltn140at29_301,
  	}, {
44c58c520   Miquel Raynal   drm/panel: simple...
4187
4188
4189
  		.compatible = "satoz,sat050at40h12r2",
  		.data = &satoz_sat050at40h12r2,
  	}, {
cd5e1cbe1   Jeffrey Hugo   drm/panel: simple...
4190
4191
4192
  		.compatible = "sharp,ld-d5116z01b",
  		.data = &sharp_ld_d5116z01b,
  	}, {
03e3ec9ad   Vladimir Zapolskiy   drm/panel: simple...
4193
4194
4195
  		.compatible = "sharp,lq035q7db03",
  		.data = &sharp_lq035q7db03,
  	}, {
dda0e4bdb   H. Nikolaus Schaller   drm/panel: simple...
4196
4197
4198
  		.compatible = "sharp,lq070y3dg3b",
  		.data = &sharp_lq070y3dg3b,
  	}, {
592aa02bd   Joshua Clayton   drm/panel: simple...
4199
4200
4201
  		.compatible = "sharp,lq101k1ly04",
  		.data = &sharp_lq101k1ly04,
  	}, {
739c7de9a   Yakir Yang   drm/panel: simple...
4202
4203
4204
  		.compatible = "sharp,lq123p1jx31",
  		.data = &sharp_lq123p1jx31,
  	}, {
f1bd37f30   Paul Cercueil   drm/panel: simple...
4205
4206
4207
  		.compatible = "sharp,ls020b1dd01d",
  		.data = &sharp_ls020b1dd01d,
  	}, {
9c6615bc3   Boris BREZILLON   drm/panel: simple...
4208
4209
4210
  		.compatible = "shelly,sca07010-bfn-lnn",
  		.data = &shelly_sca07010_bfn_lnn,
  	}, {
105235e4a   Pascal Roeleven   drm: panel: Add S...
4211
4212
4213
  		.compatible = "starry,kr070pe2t",
  		.data = &starry_kr070pe2t,
  	}, {
9bb34c4c7   Douglas Anderson   drm/panel: simple...
4214
4215
4216
  		.compatible = "starry,kr122ea0sra",
  		.data = &starry_kr122ea0sra,
  	}, {
421615318   Jyri Sarha   drm/panel: simple...
4217
4218
4219
  		.compatible = "tfc,s9700rtwv43tr-01b",
  		.data = &tfc_s9700rtwv43tr_01b,
  	}, {
adb973ef5   Gary Bisson   drm/panel: simple...
4220
4221
4222
  		.compatible = "tianma,tm070jdhg30",
  		.data = &tianma_tm070jdhg30,
  	}, {
b3bfcdf8a   Max Merchel   drm/panel: simple...
4223
4224
4225
  		.compatible = "tianma,tm070jvhg33",
  		.data = &tianma_tm070jvhg33,
  	}, {
870a0b12d   Lukasz Majewski   drm/panel: simple...
4226
4227
4228
  		.compatible = "tianma,tm070rvhg71",
  		.data = &tianma_tm070rvhg71,
  	}, {
d8a0d6a3b   Linus Walleij   drm/panel: simple...
4229
4230
4231
4232
4233
4234
  		.compatible = "ti,nspire-cx-lcd-panel",
  		.data = &ti_nspire_cx_lcd_panel,
  	}, {
  		.compatible = "ti,nspire-classic-lcd-panel",
  		.data = &ti_nspire_classic_lcd_panel,
  	}, {
06e733e41   Lucas Stach   drm/panel: simple...
4235
4236
4237
  		.compatible = "toshiba,lt089ac29000",
  		.data = &toshiba_lt089ac29000,
  	}, {
227e4f407   Bhuvanchandra DV   drm/panel: simple...
4238
4239
4240
4241
4242
4243
  		.compatible = "tpk,f07a-0102",
  		.data = &tpk_f07a_0102,
  	}, {
  		.compatible = "tpk,f10a-0102",
  		.data = &tpk_f10a_0102,
  	}, {
06a9dc65a   Maciej S. Szmigiero   drm/panel: simple...
4244
4245
4246
4247
4248
4249
4250
4251
4252
4253
4254
4255
4256
4257
4258
4259
4260
4261
  		.compatible = "urt,umsh-8596md-t",
  		.data = &urt_umsh_8596md_parallel,
  	}, {
  		.compatible = "urt,umsh-8596md-1t",
  		.data = &urt_umsh_8596md_parallel,
  	}, {
  		.compatible = "urt,umsh-8596md-7t",
  		.data = &urt_umsh_8596md_parallel,
  	}, {
  		.compatible = "urt,umsh-8596md-11t",
  		.data = &urt_umsh_8596md_lvds,
  	}, {
  		.compatible = "urt,umsh-8596md-19t",
  		.data = &urt_umsh_8596md_lvds,
  	}, {
  		.compatible = "urt,umsh-8596md-20t",
  		.data = &urt_umsh_8596md_parallel,
  	}, {
04206185a   Fabio Estevam   drm/panel: simple...
4262
4263
4264
  		.compatible = "vxt,vl050-8048nt-c01",
  		.data = &vl050_8048nt_c01,
  	}, {
e4bac408b   Richard Genoud   drm/panel: simple...
4265
4266
4267
  		.compatible = "winstar,wf35ltiacd",
  		.data = &winstar_wf35ltiacd,
  	}, {
4a1d0dbc8   Sam Ravnborg   drm/panel: simple...
4268
4269
4270
4271
  		/* Must be the last entry */
  		.compatible = "panel-dpi",
  		.data = &panel_dpi,
  	}, {
280921de7   Thierry Reding   drm/panel: Add si...
4272
4273
4274
4275
4276
4277
4278
4279
4280
4281
4282
4283
4284
4285
4286
4287
4288
4289
4290
4291
  		/* sentinel */
  	}
  };
  MODULE_DEVICE_TABLE(of, platform_of_match);
  
  static int panel_simple_platform_probe(struct platform_device *pdev)
  {
  	const struct of_device_id *id;
  
  	id = of_match_node(platform_of_match, pdev->dev.of_node);
  	if (!id)
  		return -ENODEV;
  
  	return panel_simple_probe(&pdev->dev, id->data);
  }
  
  static int panel_simple_platform_remove(struct platform_device *pdev)
  {
  	return panel_simple_remove(&pdev->dev);
  }
d02fd93e2   Thierry Reding   drm/panel: simple...
4292
4293
4294
4295
  static void panel_simple_platform_shutdown(struct platform_device *pdev)
  {
  	panel_simple_shutdown(&pdev->dev);
  }
280921de7   Thierry Reding   drm/panel: Add si...
4296
4297
4298
  static struct platform_driver panel_simple_platform_driver = {
  	.driver = {
  		.name = "panel-simple",
280921de7   Thierry Reding   drm/panel: Add si...
4299
4300
4301
4302
  		.of_match_table = platform_of_match,
  	},
  	.probe = panel_simple_platform_probe,
  	.remove = panel_simple_platform_remove,
d02fd93e2   Thierry Reding   drm/panel: simple...
4303
  	.shutdown = panel_simple_platform_shutdown,
280921de7   Thierry Reding   drm/panel: Add si...
4304
  };
210fcd9d9   Thierry Reding   drm/panel: Add su...
4305
4306
  struct panel_desc_dsi {
  	struct panel_desc desc;
462658b8b   Thierry Reding   drm/panel: simple...
4307
  	unsigned long flags;
210fcd9d9   Thierry Reding   drm/panel: Add su...
4308
4309
4310
  	enum mipi_dsi_pixel_format format;
  	unsigned int lanes;
  };
d718d79e5   Thierry Reding   drm/panel: simple...
4311
4312
4313
4314
4315
4316
4317
4318
4319
4320
  static const struct drm_display_mode auo_b080uan01_mode = {
  	.clock = 154500,
  	.hdisplay = 1200,
  	.hsync_start = 1200 + 62,
  	.hsync_end = 1200 + 62 + 4,
  	.htotal = 1200 + 62 + 4 + 62,
  	.vdisplay = 1920,
  	.vsync_start = 1920 + 9,
  	.vsync_end = 1920 + 9 + 2,
  	.vtotal = 1920 + 9 + 2 + 8,
d718d79e5   Thierry Reding   drm/panel: simple...
4321
4322
4323
4324
4325
4326
4327
4328
4329
4330
4331
  };
  
  static const struct panel_desc_dsi auo_b080uan01 = {
  	.desc = {
  		.modes = &auo_b080uan01_mode,
  		.num_modes = 1,
  		.bpc = 8,
  		.size = {
  			.width = 108,
  			.height = 272,
  		},
cb62cdec6   Laurent Pinchart   drm/panel: simple...
4332
  		.connector_type = DRM_MODE_CONNECTOR_DSI,
d718d79e5   Thierry Reding   drm/panel: simple...
4333
4334
4335
4336
4337
  	},
  	.flags = MIPI_DSI_MODE_VIDEO | MIPI_DSI_CLOCK_NON_CONTINUOUS,
  	.format = MIPI_DSI_FMT_RGB888,
  	.lanes = 4,
  };
c8521969d   Chris Zhong   drm/panel: simple...
4338
4339
4340
4341
4342
4343
4344
4345
4346
4347
  static const struct drm_display_mode boe_tv080wum_nl0_mode = {
  	.clock = 160000,
  	.hdisplay = 1200,
  	.hsync_start = 1200 + 120,
  	.hsync_end = 1200 + 120 + 20,
  	.htotal = 1200 + 120 + 20 + 21,
  	.vdisplay = 1920,
  	.vsync_start = 1920 + 21,
  	.vsync_end = 1920 + 21 + 3,
  	.vtotal = 1920 + 21 + 3 + 18,
c8521969d   Chris Zhong   drm/panel: simple...
4348
4349
4350
4351
4352
4353
4354
4355
4356
4357
4358
  	.flags = DRM_MODE_FLAG_NVSYNC | DRM_MODE_FLAG_NHSYNC,
  };
  
  static const struct panel_desc_dsi boe_tv080wum_nl0 = {
  	.desc = {
  		.modes = &boe_tv080wum_nl0_mode,
  		.num_modes = 1,
  		.size = {
  			.width = 107,
  			.height = 172,
  		},
cb62cdec6   Laurent Pinchart   drm/panel: simple...
4359
  		.connector_type = DRM_MODE_CONNECTOR_DSI,
c8521969d   Chris Zhong   drm/panel: simple...
4360
4361
4362
4363
4364
4365
4366
  	},
  	.flags = MIPI_DSI_MODE_VIDEO |
  		 MIPI_DSI_MODE_VIDEO_BURST |
  		 MIPI_DSI_MODE_VIDEO_SYNC_PULSE,
  	.format = MIPI_DSI_FMT_RGB888,
  	.lanes = 4,
  };
712ac1ba6   Alexandre Courbot   drm/panel: add su...
4367
4368
4369
4370
4371
4372
4373
4374
4375
4376
  static const struct drm_display_mode lg_ld070wx3_sl01_mode = {
  	.clock = 71000,
  	.hdisplay = 800,
  	.hsync_start = 800 + 32,
  	.hsync_end = 800 + 32 + 1,
  	.htotal = 800 + 32 + 1 + 57,
  	.vdisplay = 1280,
  	.vsync_start = 1280 + 28,
  	.vsync_end = 1280 + 28 + 1,
  	.vtotal = 1280 + 28 + 1 + 14,
712ac1ba6   Alexandre Courbot   drm/panel: add su...
4377
4378
4379
4380
4381
4382
  };
  
  static const struct panel_desc_dsi lg_ld070wx3_sl01 = {
  	.desc = {
  		.modes = &lg_ld070wx3_sl01_mode,
  		.num_modes = 1,
d7a839cde   Thierry Reding   drm/panel: simple...
4383
  		.bpc = 8,
712ac1ba6   Alexandre Courbot   drm/panel: add su...
4384
4385
4386
4387
  		.size = {
  			.width = 94,
  			.height = 151,
  		},
cb62cdec6   Laurent Pinchart   drm/panel: simple...
4388
  		.connector_type = DRM_MODE_CONNECTOR_DSI,
712ac1ba6   Alexandre Courbot   drm/panel: add su...
4389
  	},
5e4cc2786   Alexandre Courbot   drm/panel: Set no...
4390
  	.flags = MIPI_DSI_MODE_VIDEO | MIPI_DSI_CLOCK_NON_CONTINUOUS,
712ac1ba6   Alexandre Courbot   drm/panel: add su...
4391
4392
4393
  	.format = MIPI_DSI_FMT_RGB888,
  	.lanes = 4,
  };
499ce85af   Alexandre Courbot   drm/panel: add su...
4394
4395
4396
4397
4398
4399
4400
4401
4402
4403
  static const struct drm_display_mode lg_lh500wx1_sd03_mode = {
  	.clock = 67000,
  	.hdisplay = 720,
  	.hsync_start = 720 + 12,
  	.hsync_end = 720 + 12 + 4,
  	.htotal = 720 + 12 + 4 + 112,
  	.vdisplay = 1280,
  	.vsync_start = 1280 + 8,
  	.vsync_end = 1280 + 8 + 4,
  	.vtotal = 1280 + 8 + 4 + 12,
499ce85af   Alexandre Courbot   drm/panel: add su...
4404
4405
4406
4407
4408
4409
  };
  
  static const struct panel_desc_dsi lg_lh500wx1_sd03 = {
  	.desc = {
  		.modes = &lg_lh500wx1_sd03_mode,
  		.num_modes = 1,
d7a839cde   Thierry Reding   drm/panel: simple...
4410
  		.bpc = 8,
499ce85af   Alexandre Courbot   drm/panel: add su...
4411
4412
4413
4414
  		.size = {
  			.width = 62,
  			.height = 110,
  		},
cb62cdec6   Laurent Pinchart   drm/panel: simple...
4415
  		.connector_type = DRM_MODE_CONNECTOR_DSI,
499ce85af   Alexandre Courbot   drm/panel: add su...
4416
4417
4418
4419
4420
  	},
  	.flags = MIPI_DSI_MODE_VIDEO,
  	.format = MIPI_DSI_FMT_RGB888,
  	.lanes = 4,
  };
280921de7   Thierry Reding   drm/panel: Add si...
4421
4422
4423
4424
4425
4426
4427
4428
4429
4430
  static const struct drm_display_mode panasonic_vvx10f004b00_mode = {
  	.clock = 157200,
  	.hdisplay = 1920,
  	.hsync_start = 1920 + 154,
  	.hsync_end = 1920 + 154 + 16,
  	.htotal = 1920 + 154 + 16 + 32,
  	.vdisplay = 1200,
  	.vsync_start = 1200 + 17,
  	.vsync_end = 1200 + 17 + 2,
  	.vtotal = 1200 + 17 + 2 + 16,
280921de7   Thierry Reding   drm/panel: Add si...
4431
  };
210fcd9d9   Thierry Reding   drm/panel: Add su...
4432
4433
4434
4435
  static const struct panel_desc_dsi panasonic_vvx10f004b00 = {
  	.desc = {
  		.modes = &panasonic_vvx10f004b00_mode,
  		.num_modes = 1,
d7a839cde   Thierry Reding   drm/panel: simple...
4436
  		.bpc = 8,
210fcd9d9   Thierry Reding   drm/panel: Add su...
4437
4438
4439
4440
  		.size = {
  			.width = 217,
  			.height = 136,
  		},
cb62cdec6   Laurent Pinchart   drm/panel: simple...
4441
  		.connector_type = DRM_MODE_CONNECTOR_DSI,
280921de7   Thierry Reding   drm/panel: Add si...
4442
  	},
5e4cc2786   Alexandre Courbot   drm/panel: Set no...
4443
4444
  	.flags = MIPI_DSI_MODE_VIDEO | MIPI_DSI_MODE_VIDEO_SYNC_PULSE |
  		 MIPI_DSI_CLOCK_NON_CONTINUOUS,
210fcd9d9   Thierry Reding   drm/panel: Add su...
4445
4446
4447
  	.format = MIPI_DSI_FMT_RGB888,
  	.lanes = 4,
  };
debcd8f95   Jonathan Marek   drm/panel: simple...
4448
4449
4450
4451
4452
4453
4454
4455
4456
4457
  static const struct drm_display_mode lg_acx467akm_7_mode = {
  	.clock = 150000,
  	.hdisplay = 1080,
  	.hsync_start = 1080 + 2,
  	.hsync_end = 1080 + 2 + 2,
  	.htotal = 1080 + 2 + 2 + 2,
  	.vdisplay = 1920,
  	.vsync_start = 1920 + 2,
  	.vsync_end = 1920 + 2 + 2,
  	.vtotal = 1920 + 2 + 2 + 2,
debcd8f95   Jonathan Marek   drm/panel: simple...
4458
4459
4460
4461
4462
4463
4464
4465
4466
4467
4468
  };
  
  static const struct panel_desc_dsi lg_acx467akm_7 = {
  	.desc = {
  		.modes = &lg_acx467akm_7_mode,
  		.num_modes = 1,
  		.bpc = 8,
  		.size = {
  			.width = 62,
  			.height = 110,
  		},
cb62cdec6   Laurent Pinchart   drm/panel: simple...
4469
  		.connector_type = DRM_MODE_CONNECTOR_DSI,
debcd8f95   Jonathan Marek   drm/panel: simple...
4470
4471
4472
4473
4474
  	},
  	.flags = 0,
  	.format = MIPI_DSI_FMT_RGB888,
  	.lanes = 4,
  };
62967232f   Peter Ujfalusi   drm/panel: simple...
4475
4476
4477
4478
4479
4480
4481
4482
4483
4484
  static const struct drm_display_mode osd101t2045_53ts_mode = {
  	.clock = 154500,
  	.hdisplay = 1920,
  	.hsync_start = 1920 + 112,
  	.hsync_end = 1920 + 112 + 16,
  	.htotal = 1920 + 112 + 16 + 32,
  	.vdisplay = 1200,
  	.vsync_start = 1200 + 16,
  	.vsync_end = 1200 + 16 + 2,
  	.vtotal = 1200 + 16 + 2 + 16,
62967232f   Peter Ujfalusi   drm/panel: simple...
4485
4486
4487
4488
4489
4490
4491
4492
4493
4494
4495
4496
  	.flags = DRM_MODE_FLAG_NHSYNC | DRM_MODE_FLAG_NVSYNC,
  };
  
  static const struct panel_desc_dsi osd101t2045_53ts = {
  	.desc = {
  		.modes = &osd101t2045_53ts_mode,
  		.num_modes = 1,
  		.bpc = 8,
  		.size = {
  			.width = 217,
  			.height = 136,
  		},
cb62cdec6   Laurent Pinchart   drm/panel: simple...
4497
  		.connector_type = DRM_MODE_CONNECTOR_DSI,
62967232f   Peter Ujfalusi   drm/panel: simple...
4498
4499
4500
4501
4502
4503
4504
  	},
  	.flags = MIPI_DSI_MODE_VIDEO | MIPI_DSI_MODE_VIDEO_BURST |
  		 MIPI_DSI_MODE_VIDEO_SYNC_PULSE |
  		 MIPI_DSI_MODE_EOT_PACKET,
  	.format = MIPI_DSI_FMT_RGB888,
  	.lanes = 4,
  };
210fcd9d9   Thierry Reding   drm/panel: Add su...
4505
4506
  static const struct of_device_id dsi_of_match[] = {
  	{
d718d79e5   Thierry Reding   drm/panel: simple...
4507
4508
4509
  		.compatible = "auo,b080uan01",
  		.data = &auo_b080uan01
  	}, {
c8521969d   Chris Zhong   drm/panel: simple...
4510
4511
4512
  		.compatible = "boe,tv080wum-nl0",
  		.data = &boe_tv080wum_nl0
  	}, {
712ac1ba6   Alexandre Courbot   drm/panel: add su...
4513
4514
4515
  		.compatible = "lg,ld070wx3-sl01",
  		.data = &lg_ld070wx3_sl01
  	}, {
499ce85af   Alexandre Courbot   drm/panel: add su...
4516
4517
4518
  		.compatible = "lg,lh500wx1-sd03",
  		.data = &lg_lh500wx1_sd03
  	}, {
210fcd9d9   Thierry Reding   drm/panel: Add su...
4519
4520
4521
  		.compatible = "panasonic,vvx10f004b00",
  		.data = &panasonic_vvx10f004b00
  	}, {
debcd8f95   Jonathan Marek   drm/panel: simple...
4522
4523
4524
  		.compatible = "lg,acx467akm-7",
  		.data = &lg_acx467akm_7
  	}, {
62967232f   Peter Ujfalusi   drm/panel: simple...
4525
4526
4527
  		.compatible = "osddisplays,osd101t2045-53ts",
  		.data = &osd101t2045_53ts
  	}, {
210fcd9d9   Thierry Reding   drm/panel: Add su...
4528
4529
4530
4531
4532
4533
4534
4535
4536
4537
4538
4539
4540
4541
4542
4543
4544
4545
4546
4547
  		/* sentinel */
  	}
  };
  MODULE_DEVICE_TABLE(of, dsi_of_match);
  
  static int panel_simple_dsi_probe(struct mipi_dsi_device *dsi)
  {
  	const struct panel_desc_dsi *desc;
  	const struct of_device_id *id;
  	int err;
  
  	id = of_match_node(dsi_of_match, dsi->dev.of_node);
  	if (!id)
  		return -ENODEV;
  
  	desc = id->data;
  
  	err = panel_simple_probe(&dsi->dev, &desc->desc);
  	if (err < 0)
  		return err;
462658b8b   Thierry Reding   drm/panel: simple...
4548
  	dsi->mode_flags = desc->flags;
210fcd9d9   Thierry Reding   drm/panel: Add su...
4549
4550
  	dsi->format = desc->format;
  	dsi->lanes = desc->lanes;
7ad9db66f   Peter Ujfalusi   drm/panel: simple...
4551
4552
4553
4554
4555
4556
4557
4558
  	err = mipi_dsi_attach(dsi);
  	if (err) {
  		struct panel_simple *panel = dev_get_drvdata(&dsi->dev);
  
  		drm_panel_remove(&panel->base);
  	}
  
  	return err;
210fcd9d9   Thierry Reding   drm/panel: Add su...
4559
4560
4561
4562
4563
4564
4565
4566
4567
4568
4569
4570
4571
  }
  
  static int panel_simple_dsi_remove(struct mipi_dsi_device *dsi)
  {
  	int err;
  
  	err = mipi_dsi_detach(dsi);
  	if (err < 0)
  		dev_err(&dsi->dev, "failed to detach from DSI host: %d
  ", err);
  
  	return panel_simple_remove(&dsi->dev);
  }
d02fd93e2   Thierry Reding   drm/panel: simple...
4572
4573
4574
4575
  static void panel_simple_dsi_shutdown(struct mipi_dsi_device *dsi)
  {
  	panel_simple_shutdown(&dsi->dev);
  }
210fcd9d9   Thierry Reding   drm/panel: Add su...
4576
4577
4578
  static struct mipi_dsi_driver panel_simple_dsi_driver = {
  	.driver = {
  		.name = "panel-simple-dsi",
210fcd9d9   Thierry Reding   drm/panel: Add su...
4579
4580
4581
4582
  		.of_match_table = dsi_of_match,
  	},
  	.probe = panel_simple_dsi_probe,
  	.remove = panel_simple_dsi_remove,
d02fd93e2   Thierry Reding   drm/panel: simple...
4583
  	.shutdown = panel_simple_dsi_shutdown,
280921de7   Thierry Reding   drm/panel: Add si...
4584
4585
4586
4587
  };
  
  static int __init panel_simple_init(void)
  {
210fcd9d9   Thierry Reding   drm/panel: Add su...
4588
4589
4590
4591
4592
4593
4594
4595
4596
4597
4598
4599
4600
  	int err;
  
  	err = platform_driver_register(&panel_simple_platform_driver);
  	if (err < 0)
  		return err;
  
  	if (IS_ENABLED(CONFIG_DRM_MIPI_DSI)) {
  		err = mipi_dsi_driver_register(&panel_simple_dsi_driver);
  		if (err < 0)
  			return err;
  	}
  
  	return 0;
280921de7   Thierry Reding   drm/panel: Add si...
4601
4602
4603
4604
4605
  }
  module_init(panel_simple_init);
  
  static void __exit panel_simple_exit(void)
  {
210fcd9d9   Thierry Reding   drm/panel: Add su...
4606
4607
  	if (IS_ENABLED(CONFIG_DRM_MIPI_DSI))
  		mipi_dsi_driver_unregister(&panel_simple_dsi_driver);
280921de7   Thierry Reding   drm/panel: Add si...
4608
4609
4610
4611
4612
4613
4614
  	platform_driver_unregister(&panel_simple_platform_driver);
  }
  module_exit(panel_simple_exit);
  
  MODULE_AUTHOR("Thierry Reding <treding@nvidia.com>");
  MODULE_DESCRIPTION("DRM Driver for Simple Panels");
  MODULE_LICENSE("GPL and additional rights");