Thierry Reding | 280921d | 2013-08-30 15:10:14 +0200 | [diff] [blame] | 1 | /* |
| 2 | * Copyright (C) 2013, NVIDIA Corporation. All rights reserved. |
| 3 | * |
| 4 | * Permission is hereby granted, free of charge, to any person obtaining a |
| 5 | * copy of this software and associated documentation files (the "Software"), |
| 6 | * to deal in the Software without restriction, including without limitation |
| 7 | * the rights to use, copy, modify, merge, publish, distribute, sub license, |
| 8 | * and/or sell copies of the Software, and to permit persons to whom the |
| 9 | * Software is furnished to do so, subject to the following conditions: |
| 10 | * |
| 11 | * The above copyright notice and this permission notice (including the |
| 12 | * next paragraph) shall be included in all copies or substantial portions |
| 13 | * of the Software. |
| 14 | * |
| 15 | * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR |
| 16 | * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, |
| 17 | * FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT. IN NO EVENT SHALL |
| 18 | * THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER |
| 19 | * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING |
| 20 | * FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER |
| 21 | * DEALINGS IN THE SOFTWARE. |
| 22 | */ |
| 23 | |
Sam Ravnborg | cb23eae | 2019-05-26 20:05:32 +0200 | [diff] [blame] | 24 | #include <linux/delay.h> |
Alexandre Courbot | cfdf054 | 2014-03-01 14:00:58 +0900 | [diff] [blame] | 25 | #include <linux/gpio/consumer.h> |
Douglas Anderson | 48834e6 | 2020-05-07 14:34:57 -0700 | [diff] [blame] | 26 | #include <linux/iopoll.h> |
Thierry Reding | 280921d | 2013-08-30 15:10:14 +0200 | [diff] [blame] | 27 | #include <linux/module.h> |
Thierry Reding | 280921d | 2013-08-30 15:10:14 +0200 | [diff] [blame] | 28 | #include <linux/of_platform.h> |
| 29 | #include <linux/platform_device.h> |
Douglas Anderson | 3235b0f | 2021-04-16 15:39:30 -0700 | [diff] [blame] | 30 | #include <linux/pm_runtime.h> |
Thierry Reding | 280921d | 2013-08-30 15:10:14 +0200 | [diff] [blame] | 31 | #include <linux/regulator/consumer.h> |
| 32 | |
Philipp Zabel | a5d3e62 | 2014-12-11 18:32:45 +0100 | [diff] [blame] | 33 | #include <video/display_timing.h> |
Sean Paul | b8a2948 | 2019-07-11 13:34:53 -0700 | [diff] [blame] | 34 | #include <video/of_display_timing.h> |
Philipp Zabel | a5d3e62 | 2014-12-11 18:32:45 +0100 | [diff] [blame] | 35 | #include <video/videomode.h> |
| 36 | |
Sam Ravnborg | cb23eae | 2019-05-26 20:05:32 +0200 | [diff] [blame] | 37 | #include <drm/drm_crtc.h> |
| 38 | #include <drm/drm_device.h> |
Douglas Anderson | 74c06c2 | 2021-06-11 10:17:41 -0700 | [diff] [blame] | 39 | #include <drm/drm_dp_aux_bus.h> |
Douglas Anderson | cc5a3fc | 2021-06-11 10:17:42 -0700 | [diff] [blame] | 40 | #include <drm/drm_dp_helper.h> |
Sam Ravnborg | cb23eae | 2019-05-26 20:05:32 +0200 | [diff] [blame] | 41 | #include <drm/drm_mipi_dsi.h> |
| 42 | #include <drm/drm_panel.h> |
| 43 | |
Douglas Anderson | e362cc6 | 2019-07-12 09:33:33 -0700 | [diff] [blame] | 44 | /** |
Douglas Anderson | a00fa42 | 2020-12-01 12:59:12 -0800 | [diff] [blame] | 45 | * struct panel_desc - Describes a simple panel. |
Douglas Anderson | e362cc6 | 2019-07-12 09:33:33 -0700 | [diff] [blame] | 46 | */ |
Thierry Reding | 280921d | 2013-08-30 15:10:14 +0200 | [diff] [blame] | 47 | struct panel_desc { |
Douglas Anderson | a00fa42 | 2020-12-01 12:59:12 -0800 | [diff] [blame] | 48 | /** |
| 49 | * @modes: Pointer to array of fixed modes appropriate for this panel. |
| 50 | * |
| 51 | * If only one mode then this can just be the address of the mode. |
| 52 | * NOTE: cannot be used with "timings" and also if this is specified |
| 53 | * then you cannot override the mode in the device tree. |
| 54 | */ |
Thierry Reding | 280921d | 2013-08-30 15:10:14 +0200 | [diff] [blame] | 55 | const struct drm_display_mode *modes; |
Douglas Anderson | a00fa42 | 2020-12-01 12:59:12 -0800 | [diff] [blame] | 56 | |
| 57 | /** @num_modes: Number of elements in modes array. */ |
Thierry Reding | 280921d | 2013-08-30 15:10:14 +0200 | [diff] [blame] | 58 | unsigned int num_modes; |
Douglas Anderson | a00fa42 | 2020-12-01 12:59:12 -0800 | [diff] [blame] | 59 | |
| 60 | /** |
| 61 | * @timings: Pointer to array of display timings |
| 62 | * |
| 63 | * NOTE: cannot be used with "modes" and also these will be used to |
| 64 | * validate a device tree override if one is present. |
| 65 | */ |
Philipp Zabel | a5d3e62 | 2014-12-11 18:32:45 +0100 | [diff] [blame] | 66 | const struct display_timing *timings; |
Douglas Anderson | a00fa42 | 2020-12-01 12:59:12 -0800 | [diff] [blame] | 67 | |
| 68 | /** @num_timings: Number of elements in timings array. */ |
Philipp Zabel | a5d3e62 | 2014-12-11 18:32:45 +0100 | [diff] [blame] | 69 | unsigned int num_timings; |
Thierry Reding | 280921d | 2013-08-30 15:10:14 +0200 | [diff] [blame] | 70 | |
Douglas Anderson | a00fa42 | 2020-12-01 12:59:12 -0800 | [diff] [blame] | 71 | /** @bpc: Bits per color. */ |
Stéphane Marchesin | 0208d51 | 2014-06-19 18:18:28 -0700 | [diff] [blame] | 72 | unsigned int bpc; |
| 73 | |
Douglas Anderson | a00fa42 | 2020-12-01 12:59:12 -0800 | [diff] [blame] | 74 | /** @size: Structure containing the physical size of this panel. */ |
Thierry Reding | 280921d | 2013-08-30 15:10:14 +0200 | [diff] [blame] | 75 | struct { |
Douglas Anderson | 131f909 | 2020-11-09 17:00:55 -0800 | [diff] [blame] | 76 | /** |
| 77 | * @size.width: Width (in mm) of the active display area. |
| 78 | */ |
Thierry Reding | 280921d | 2013-08-30 15:10:14 +0200 | [diff] [blame] | 79 | unsigned int width; |
Douglas Anderson | 131f909 | 2020-11-09 17:00:55 -0800 | [diff] [blame] | 80 | |
| 81 | /** |
| 82 | * @size.height: Height (in mm) of the active display area. |
| 83 | */ |
Thierry Reding | 280921d | 2013-08-30 15:10:14 +0200 | [diff] [blame] | 84 | unsigned int height; |
| 85 | } size; |
Ajay Kumar | f673c37 | 2014-07-31 23:12:11 +0530 | [diff] [blame] | 86 | |
Douglas Anderson | a00fa42 | 2020-12-01 12:59:12 -0800 | [diff] [blame] | 87 | /** @delay: Structure containing various delay values for this panel. */ |
Ajay Kumar | f673c37 | 2014-07-31 23:12:11 +0530 | [diff] [blame] | 88 | struct { |
Douglas Anderson | 131f909 | 2020-11-09 17:00:55 -0800 | [diff] [blame] | 89 | /** |
| 90 | * @delay.prepare: Time for the panel to become ready. |
| 91 | * |
| 92 | * The time (in milliseconds) that it takes for the panel to |
| 93 | * become ready and start receiving video data |
| 94 | */ |
Ajay Kumar | f673c37 | 2014-07-31 23:12:11 +0530 | [diff] [blame] | 95 | unsigned int prepare; |
Douglas Anderson | 131f909 | 2020-11-09 17:00:55 -0800 | [diff] [blame] | 96 | |
| 97 | /** |
| 98 | * @delay.hpd_absent_delay: Time to wait if HPD isn't hooked up. |
| 99 | * |
| 100 | * Add this to the prepare delay if we know Hot Plug Detect |
| 101 | * isn't used. |
| 102 | */ |
Douglas Anderson | 2ed3e95 | 2018-10-25 15:21:30 -0700 | [diff] [blame] | 103 | unsigned int hpd_absent_delay; |
Douglas Anderson | 131f909 | 2020-11-09 17:00:55 -0800 | [diff] [blame] | 104 | |
| 105 | /** |
Douglas Anderson | 4beb04b | 2020-11-09 17:00:57 -0800 | [diff] [blame] | 106 | * @delay.prepare_to_enable: Time between prepare and enable. |
| 107 | * |
| 108 | * The minimum time, in milliseconds, that needs to have passed |
| 109 | * between when prepare finished and enable may begin. If at |
| 110 | * enable time less time has passed since prepare finished, |
| 111 | * the driver waits for the remaining time. |
| 112 | * |
| 113 | * If a fixed enable delay is also specified, we'll start |
| 114 | * counting before delaying for the fixed delay. |
| 115 | * |
| 116 | * If a fixed prepare delay is also specified, we won't start |
| 117 | * counting until after the fixed delay. We can't overlap this |
| 118 | * fixed delay with the min time because the fixed delay |
| 119 | * doesn't happen at the end of the function if a HPD GPIO was |
| 120 | * specified. |
| 121 | * |
| 122 | * In other words: |
| 123 | * prepare() |
| 124 | * ... |
| 125 | * // do fixed prepare delay |
| 126 | * // wait for HPD GPIO if applicable |
| 127 | * // start counting for prepare_to_enable |
| 128 | * |
| 129 | * enable() |
| 130 | * // do fixed enable delay |
| 131 | * // enforce prepare_to_enable min time |
| 132 | */ |
| 133 | unsigned int prepare_to_enable; |
| 134 | |
| 135 | /** |
Douglas Anderson | 131f909 | 2020-11-09 17:00:55 -0800 | [diff] [blame] | 136 | * @delay.enable: Time for the panel to display a valid frame. |
| 137 | * |
| 138 | * The time (in milliseconds) that it takes for the panel to |
| 139 | * display the first valid frame after starting to receive |
| 140 | * video data. |
| 141 | */ |
Ajay Kumar | f673c37 | 2014-07-31 23:12:11 +0530 | [diff] [blame] | 142 | unsigned int enable; |
Douglas Anderson | 131f909 | 2020-11-09 17:00:55 -0800 | [diff] [blame] | 143 | |
| 144 | /** |
| 145 | * @delay.disable: Time for the panel to turn the display off. |
| 146 | * |
| 147 | * The time (in milliseconds) that it takes for the panel to |
| 148 | * turn the display off (no content is visible). |
| 149 | */ |
Ajay Kumar | f673c37 | 2014-07-31 23:12:11 +0530 | [diff] [blame] | 150 | unsigned int disable; |
Douglas Anderson | 131f909 | 2020-11-09 17:00:55 -0800 | [diff] [blame] | 151 | |
| 152 | /** |
| 153 | * @delay.unprepare: Time to power down completely. |
| 154 | * |
| 155 | * The time (in milliseconds) that it takes for the panel |
| 156 | * to power itself down completely. |
Douglas Anderson | e5e30df | 2020-11-09 17:00:56 -0800 | [diff] [blame] | 157 | * |
| 158 | * This time is used to prevent a future "prepare" from |
| 159 | * starting until at least this many milliseconds has passed. |
| 160 | * If at prepare time less time has passed since unprepare |
| 161 | * finished, the driver waits for the remaining time. |
Douglas Anderson | 131f909 | 2020-11-09 17:00:55 -0800 | [diff] [blame] | 162 | */ |
Ajay Kumar | f673c37 | 2014-07-31 23:12:11 +0530 | [diff] [blame] | 163 | unsigned int unprepare; |
| 164 | } delay; |
Boris Brezillon | 795f7ab | 2014-07-22 13:33:59 +0200 | [diff] [blame] | 165 | |
Douglas Anderson | a00fa42 | 2020-12-01 12:59:12 -0800 | [diff] [blame] | 166 | /** @bus_format: See MEDIA_BUS_FMT_... defines. */ |
Boris Brezillon | 795f7ab | 2014-07-22 13:33:59 +0200 | [diff] [blame] | 167 | u32 bus_format; |
Douglas Anderson | a00fa42 | 2020-12-01 12:59:12 -0800 | [diff] [blame] | 168 | |
| 169 | /** @bus_flags: See DRM_BUS_FLAG_... defines. */ |
Stefan Agner | f0aa083 | 2016-02-08 11:38:14 -0800 | [diff] [blame] | 170 | u32 bus_flags; |
Douglas Anderson | a00fa42 | 2020-12-01 12:59:12 -0800 | [diff] [blame] | 171 | |
| 172 | /** @connector_type: LVDS, eDP, DSI, DPI, etc. */ |
Laurent Pinchart | 9a2654c | 2019-09-04 16:28:03 +0300 | [diff] [blame] | 173 | int connector_type; |
Thierry Reding | 280921d | 2013-08-30 15:10:14 +0200 | [diff] [blame] | 174 | }; |
| 175 | |
Thierry Reding | 280921d | 2013-08-30 15:10:14 +0200 | [diff] [blame] | 176 | struct panel_simple { |
| 177 | struct drm_panel base; |
| 178 | bool enabled; |
Douglas Anderson | 2ed3e95 | 2018-10-25 15:21:30 -0700 | [diff] [blame] | 179 | bool no_hpd; |
Thierry Reding | 280921d | 2013-08-30 15:10:14 +0200 | [diff] [blame] | 180 | |
Douglas Anderson | 3235b0f | 2021-04-16 15:39:30 -0700 | [diff] [blame] | 181 | bool prepared; |
| 182 | |
Douglas Anderson | 4beb04b | 2020-11-09 17:00:57 -0800 | [diff] [blame] | 183 | ktime_t prepared_time; |
Douglas Anderson | e5e30df | 2020-11-09 17:00:56 -0800 | [diff] [blame] | 184 | ktime_t unprepared_time; |
| 185 | |
Thierry Reding | 280921d | 2013-08-30 15:10:14 +0200 | [diff] [blame] | 186 | const struct panel_desc *desc; |
| 187 | |
Thierry Reding | 280921d | 2013-08-30 15:10:14 +0200 | [diff] [blame] | 188 | struct regulator *supply; |
| 189 | struct i2c_adapter *ddc; |
Douglas Anderson | cc5a3fc | 2021-06-11 10:17:42 -0700 | [diff] [blame] | 190 | struct drm_dp_aux *aux; |
Thierry Reding | 280921d | 2013-08-30 15:10:14 +0200 | [diff] [blame] | 191 | |
Alexandre Courbot | cfdf054 | 2014-03-01 14:00:58 +0900 | [diff] [blame] | 192 | struct gpio_desc *enable_gpio; |
Douglas Anderson | 48834e6 | 2020-05-07 14:34:57 -0700 | [diff] [blame] | 193 | struct gpio_desc *hpd_gpio; |
Sean Paul | b8a2948 | 2019-07-11 13:34:53 -0700 | [diff] [blame] | 194 | |
Douglas Anderson | 63358e2 | 2021-04-23 09:59:04 -0700 | [diff] [blame] | 195 | struct edid *edid; |
| 196 | |
Sean Paul | b8a2948 | 2019-07-11 13:34:53 -0700 | [diff] [blame] | 197 | struct drm_display_mode override_mode; |
Dmitry Osipenko | 5759c96 | 2020-08-14 00:56:09 +0300 | [diff] [blame] | 198 | |
| 199 | enum drm_panel_orientation orientation; |
Thierry Reding | 280921d | 2013-08-30 15:10:14 +0200 | [diff] [blame] | 200 | }; |
| 201 | |
| 202 | static inline struct panel_simple *to_panel_simple(struct drm_panel *panel) |
| 203 | { |
| 204 | return container_of(panel, struct panel_simple, base); |
| 205 | } |
| 206 | |
Sam Ravnborg | 0ce8ddd | 2019-12-07 15:03:33 +0100 | [diff] [blame] | 207 | static unsigned int panel_simple_get_timings_modes(struct panel_simple *panel, |
| 208 | struct drm_connector *connector) |
Thierry Reding | 280921d | 2013-08-30 15:10:14 +0200 | [diff] [blame] | 209 | { |
Thierry Reding | 280921d | 2013-08-30 15:10:14 +0200 | [diff] [blame] | 210 | struct drm_display_mode *mode; |
| 211 | unsigned int i, num = 0; |
| 212 | |
Philipp Zabel | a5d3e62 | 2014-12-11 18:32:45 +0100 | [diff] [blame] | 213 | for (i = 0; i < panel->desc->num_timings; i++) { |
| 214 | const struct display_timing *dt = &panel->desc->timings[i]; |
| 215 | struct videomode vm; |
| 216 | |
| 217 | videomode_from_timing(dt, &vm); |
Sam Ravnborg | aa6c436 | 2019-12-07 15:03:35 +0100 | [diff] [blame] | 218 | mode = drm_mode_create(connector->dev); |
Philipp Zabel | a5d3e62 | 2014-12-11 18:32:45 +0100 | [diff] [blame] | 219 | if (!mode) { |
Sam Ravnborg | aa6c436 | 2019-12-07 15:03:35 +0100 | [diff] [blame] | 220 | dev_err(panel->base.dev, "failed to add mode %ux%u\n", |
Philipp Zabel | a5d3e62 | 2014-12-11 18:32:45 +0100 | [diff] [blame] | 221 | dt->hactive.typ, dt->vactive.typ); |
| 222 | continue; |
| 223 | } |
| 224 | |
| 225 | drm_display_mode_from_videomode(&vm, mode); |
Boris Brezillon | cda5537 | 2016-04-15 18:23:33 +0200 | [diff] [blame] | 226 | |
| 227 | mode->type |= DRM_MODE_TYPE_DRIVER; |
| 228 | |
Chen-Yu Tsai | 230c5b4 | 2016-10-24 21:21:15 +0800 | [diff] [blame] | 229 | if (panel->desc->num_timings == 1) |
Boris Brezillon | cda5537 | 2016-04-15 18:23:33 +0200 | [diff] [blame] | 230 | mode->type |= DRM_MODE_TYPE_PREFERRED; |
| 231 | |
Philipp Zabel | a5d3e62 | 2014-12-11 18:32:45 +0100 | [diff] [blame] | 232 | drm_mode_probed_add(connector, mode); |
| 233 | num++; |
| 234 | } |
| 235 | |
Sean Paul | b8a2948 | 2019-07-11 13:34:53 -0700 | [diff] [blame] | 236 | return num; |
| 237 | } |
| 238 | |
Sam Ravnborg | 0ce8ddd | 2019-12-07 15:03:33 +0100 | [diff] [blame] | 239 | static unsigned int panel_simple_get_display_modes(struct panel_simple *panel, |
| 240 | struct drm_connector *connector) |
Sean Paul | b8a2948 | 2019-07-11 13:34:53 -0700 | [diff] [blame] | 241 | { |
Sean Paul | b8a2948 | 2019-07-11 13:34:53 -0700 | [diff] [blame] | 242 | struct drm_display_mode *mode; |
| 243 | unsigned int i, num = 0; |
| 244 | |
Thierry Reding | 280921d | 2013-08-30 15:10:14 +0200 | [diff] [blame] | 245 | for (i = 0; i < panel->desc->num_modes; i++) { |
| 246 | const struct drm_display_mode *m = &panel->desc->modes[i]; |
| 247 | |
Sam Ravnborg | aa6c436 | 2019-12-07 15:03:35 +0100 | [diff] [blame] | 248 | mode = drm_mode_duplicate(connector->dev, m); |
Thierry Reding | 280921d | 2013-08-30 15:10:14 +0200 | [diff] [blame] | 249 | if (!mode) { |
Sam Ravnborg | aa6c436 | 2019-12-07 15:03:35 +0100 | [diff] [blame] | 250 | dev_err(panel->base.dev, "failed to add mode %ux%u@%u\n", |
Ville Syrjälä | 0425662 | 2020-04-28 20:19:27 +0300 | [diff] [blame] | 251 | m->hdisplay, m->vdisplay, |
| 252 | drm_mode_vrefresh(m)); |
Thierry Reding | 280921d | 2013-08-30 15:10:14 +0200 | [diff] [blame] | 253 | continue; |
| 254 | } |
| 255 | |
Boris Brezillon | cda5537 | 2016-04-15 18:23:33 +0200 | [diff] [blame] | 256 | mode->type |= DRM_MODE_TYPE_DRIVER; |
| 257 | |
| 258 | if (panel->desc->num_modes == 1) |
| 259 | mode->type |= DRM_MODE_TYPE_PREFERRED; |
| 260 | |
Thierry Reding | 280921d | 2013-08-30 15:10:14 +0200 | [diff] [blame] | 261 | drm_mode_set_name(mode); |
| 262 | |
| 263 | drm_mode_probed_add(connector, mode); |
| 264 | num++; |
| 265 | } |
| 266 | |
Sean Paul | b8a2948 | 2019-07-11 13:34:53 -0700 | [diff] [blame] | 267 | return num; |
| 268 | } |
| 269 | |
Sam Ravnborg | 0ce8ddd | 2019-12-07 15:03:33 +0100 | [diff] [blame] | 270 | static int panel_simple_get_non_edid_modes(struct panel_simple *panel, |
| 271 | struct drm_connector *connector) |
Sean Paul | b8a2948 | 2019-07-11 13:34:53 -0700 | [diff] [blame] | 272 | { |
Sean Paul | b8a2948 | 2019-07-11 13:34:53 -0700 | [diff] [blame] | 273 | struct drm_display_mode *mode; |
| 274 | bool has_override = panel->override_mode.type; |
| 275 | unsigned int num = 0; |
| 276 | |
| 277 | if (!panel->desc) |
| 278 | return 0; |
| 279 | |
| 280 | if (has_override) { |
Sam Ravnborg | aa6c436 | 2019-12-07 15:03:35 +0100 | [diff] [blame] | 281 | mode = drm_mode_duplicate(connector->dev, |
| 282 | &panel->override_mode); |
Sean Paul | b8a2948 | 2019-07-11 13:34:53 -0700 | [diff] [blame] | 283 | if (mode) { |
| 284 | drm_mode_probed_add(connector, mode); |
| 285 | num = 1; |
| 286 | } else { |
Sam Ravnborg | aa6c436 | 2019-12-07 15:03:35 +0100 | [diff] [blame] | 287 | dev_err(panel->base.dev, "failed to add override mode\n"); |
Sean Paul | b8a2948 | 2019-07-11 13:34:53 -0700 | [diff] [blame] | 288 | } |
| 289 | } |
| 290 | |
| 291 | /* Only add timings if override was not there or failed to validate */ |
| 292 | if (num == 0 && panel->desc->num_timings) |
Sam Ravnborg | 0ce8ddd | 2019-12-07 15:03:33 +0100 | [diff] [blame] | 293 | num = panel_simple_get_timings_modes(panel, connector); |
Sean Paul | b8a2948 | 2019-07-11 13:34:53 -0700 | [diff] [blame] | 294 | |
| 295 | /* |
| 296 | * Only add fixed modes if timings/override added no mode. |
| 297 | * |
| 298 | * We should only ever have either the display timings specified |
| 299 | * or a fixed mode. Anything else is rather bogus. |
| 300 | */ |
| 301 | WARN_ON(panel->desc->num_timings && panel->desc->num_modes); |
| 302 | if (num == 0) |
Sam Ravnborg | 0ce8ddd | 2019-12-07 15:03:33 +0100 | [diff] [blame] | 303 | num = panel_simple_get_display_modes(panel, connector); |
Sean Paul | b8a2948 | 2019-07-11 13:34:53 -0700 | [diff] [blame] | 304 | |
Stéphane Marchesin | 0208d51 | 2014-06-19 18:18:28 -0700 | [diff] [blame] | 305 | connector->display_info.bpc = panel->desc->bpc; |
Thierry Reding | 280921d | 2013-08-30 15:10:14 +0200 | [diff] [blame] | 306 | connector->display_info.width_mm = panel->desc->size.width; |
| 307 | connector->display_info.height_mm = panel->desc->size.height; |
Boris Brezillon | 795f7ab | 2014-07-22 13:33:59 +0200 | [diff] [blame] | 308 | if (panel->desc->bus_format) |
| 309 | drm_display_info_set_bus_formats(&connector->display_info, |
| 310 | &panel->desc->bus_format, 1); |
Stefan Agner | f0aa083 | 2016-02-08 11:38:14 -0800 | [diff] [blame] | 311 | connector->display_info.bus_flags = panel->desc->bus_flags; |
Thierry Reding | 280921d | 2013-08-30 15:10:14 +0200 | [diff] [blame] | 312 | |
| 313 | return num; |
| 314 | } |
| 315 | |
Douglas Anderson | e5e30df | 2020-11-09 17:00:56 -0800 | [diff] [blame] | 316 | static void panel_simple_wait(ktime_t start_ktime, unsigned int min_ms) |
| 317 | { |
| 318 | ktime_t now_ktime, min_ktime; |
| 319 | |
| 320 | if (!min_ms) |
| 321 | return; |
| 322 | |
| 323 | min_ktime = ktime_add(start_ktime, ms_to_ktime(min_ms)); |
| 324 | now_ktime = ktime_get(); |
| 325 | |
| 326 | if (ktime_before(now_ktime, min_ktime)) |
| 327 | msleep(ktime_to_ms(ktime_sub(min_ktime, now_ktime)) + 1); |
| 328 | } |
| 329 | |
Thierry Reding | 280921d | 2013-08-30 15:10:14 +0200 | [diff] [blame] | 330 | static int panel_simple_disable(struct drm_panel *panel) |
| 331 | { |
| 332 | struct panel_simple *p = to_panel_simple(panel); |
| 333 | |
| 334 | if (!p->enabled) |
| 335 | return 0; |
| 336 | |
Ajay Kumar | f673c37 | 2014-07-31 23:12:11 +0530 | [diff] [blame] | 337 | if (p->desc->delay.disable) |
| 338 | msleep(p->desc->delay.disable); |
| 339 | |
Thierry Reding | 280921d | 2013-08-30 15:10:14 +0200 | [diff] [blame] | 340 | p->enabled = false; |
| 341 | |
| 342 | return 0; |
| 343 | } |
| 344 | |
Douglas Anderson | 3235b0f | 2021-04-16 15:39:30 -0700 | [diff] [blame] | 345 | static int panel_simple_suspend(struct device *dev) |
| 346 | { |
| 347 | struct panel_simple *p = dev_get_drvdata(dev); |
| 348 | |
| 349 | gpiod_set_value_cansleep(p->enable_gpio, 0); |
| 350 | regulator_disable(p->supply); |
| 351 | p->unprepared_time = ktime_get(); |
| 352 | |
Douglas Anderson | 63358e2 | 2021-04-23 09:59:04 -0700 | [diff] [blame] | 353 | kfree(p->edid); |
| 354 | p->edid = NULL; |
| 355 | |
Douglas Anderson | 3235b0f | 2021-04-16 15:39:30 -0700 | [diff] [blame] | 356 | return 0; |
| 357 | } |
| 358 | |
Ajay Kumar | c0e1d17 | 2014-07-31 23:12:04 +0530 | [diff] [blame] | 359 | static int panel_simple_unprepare(struct drm_panel *panel) |
| 360 | { |
Ajay Kumar | 613a633 | 2014-07-31 23:12:10 +0530 | [diff] [blame] | 361 | struct panel_simple *p = to_panel_simple(panel); |
Douglas Anderson | 3235b0f | 2021-04-16 15:39:30 -0700 | [diff] [blame] | 362 | int ret; |
Ajay Kumar | 613a633 | 2014-07-31 23:12:10 +0530 | [diff] [blame] | 363 | |
Douglas Anderson | 3235b0f | 2021-04-16 15:39:30 -0700 | [diff] [blame] | 364 | /* Unpreparing when already unprepared is a no-op */ |
| 365 | if (!p->prepared) |
Ajay Kumar | 613a633 | 2014-07-31 23:12:10 +0530 | [diff] [blame] | 366 | return 0; |
| 367 | |
Douglas Anderson | 3235b0f | 2021-04-16 15:39:30 -0700 | [diff] [blame] | 368 | pm_runtime_mark_last_busy(panel->dev); |
| 369 | ret = pm_runtime_put_autosuspend(panel->dev); |
| 370 | if (ret < 0) |
| 371 | return ret; |
| 372 | p->prepared = false; |
Ajay Kumar | 613a633 | 2014-07-31 23:12:10 +0530 | [diff] [blame] | 373 | |
Ajay Kumar | c0e1d17 | 2014-07-31 23:12:04 +0530 | [diff] [blame] | 374 | return 0; |
| 375 | } |
| 376 | |
Douglas Anderson | 5c4381e | 2021-04-23 09:58:56 -0700 | [diff] [blame] | 377 | static int panel_simple_get_hpd_gpio(struct device *dev, struct panel_simple *p) |
Douglas Anderson | 48834e6 | 2020-05-07 14:34:57 -0700 | [diff] [blame] | 378 | { |
| 379 | int err; |
| 380 | |
| 381 | p->hpd_gpio = devm_gpiod_get_optional(dev, "hpd", GPIOD_IN); |
| 382 | if (IS_ERR(p->hpd_gpio)) { |
| 383 | err = PTR_ERR(p->hpd_gpio); |
| 384 | |
Douglas Anderson | 5c4381e | 2021-04-23 09:58:56 -0700 | [diff] [blame] | 385 | if (err != -EPROBE_DEFER) |
Douglas Anderson | 48834e6 | 2020-05-07 14:34:57 -0700 | [diff] [blame] | 386 | dev_err(dev, "failed to get 'hpd' GPIO: %d\n", err); |
Douglas Anderson | 5c4381e | 2021-04-23 09:58:56 -0700 | [diff] [blame] | 387 | |
| 388 | return err; |
Douglas Anderson | 48834e6 | 2020-05-07 14:34:57 -0700 | [diff] [blame] | 389 | } |
| 390 | |
| 391 | return 0; |
| 392 | } |
| 393 | |
Douglas Anderson | 3235b0f | 2021-04-16 15:39:30 -0700 | [diff] [blame] | 394 | static int panel_simple_prepare_once(struct panel_simple *p) |
Ajay Kumar | c0e1d17 | 2014-07-31 23:12:04 +0530 | [diff] [blame] | 395 | { |
Douglas Anderson | 3235b0f | 2021-04-16 15:39:30 -0700 | [diff] [blame] | 396 | struct device *dev = p->base.dev; |
Douglas Anderson | 2ed3e95 | 2018-10-25 15:21:30 -0700 | [diff] [blame] | 397 | unsigned int delay; |
Thierry Reding | 280921d | 2013-08-30 15:10:14 +0200 | [diff] [blame] | 398 | int err; |
Douglas Anderson | 48834e6 | 2020-05-07 14:34:57 -0700 | [diff] [blame] | 399 | int hpd_asserted; |
Douglas Anderson | 6ec5262 | 2021-01-15 14:44:17 -0800 | [diff] [blame] | 400 | unsigned long hpd_wait_us; |
Thierry Reding | 280921d | 2013-08-30 15:10:14 +0200 | [diff] [blame] | 401 | |
Douglas Anderson | e5e30df | 2020-11-09 17:00:56 -0800 | [diff] [blame] | 402 | panel_simple_wait(p->unprepared_time, p->desc->delay.unprepare); |
| 403 | |
Thierry Reding | 280921d | 2013-08-30 15:10:14 +0200 | [diff] [blame] | 404 | err = regulator_enable(p->supply); |
| 405 | if (err < 0) { |
Douglas Anderson | 3235b0f | 2021-04-16 15:39:30 -0700 | [diff] [blame] | 406 | dev_err(dev, "failed to enable supply: %d\n", err); |
Thierry Reding | 280921d | 2013-08-30 15:10:14 +0200 | [diff] [blame] | 407 | return err; |
| 408 | } |
| 409 | |
Fabio Estevam | 756b918 | 2017-07-16 21:05:39 -0300 | [diff] [blame] | 410 | gpiod_set_value_cansleep(p->enable_gpio, 1); |
Thierry Reding | 280921d | 2013-08-30 15:10:14 +0200 | [diff] [blame] | 411 | |
Douglas Anderson | 2ed3e95 | 2018-10-25 15:21:30 -0700 | [diff] [blame] | 412 | delay = p->desc->delay.prepare; |
| 413 | if (p->no_hpd) |
| 414 | delay += p->desc->delay.hpd_absent_delay; |
| 415 | if (delay) |
| 416 | msleep(delay); |
Ajay Kumar | f673c37 | 2014-07-31 23:12:11 +0530 | [diff] [blame] | 417 | |
Douglas Anderson | 48834e6 | 2020-05-07 14:34:57 -0700 | [diff] [blame] | 418 | if (p->hpd_gpio) { |
Douglas Anderson | 6ec5262 | 2021-01-15 14:44:17 -0800 | [diff] [blame] | 419 | if (p->desc->delay.hpd_absent_delay) |
| 420 | hpd_wait_us = p->desc->delay.hpd_absent_delay * 1000UL; |
| 421 | else |
| 422 | hpd_wait_us = 2000000; |
| 423 | |
Douglas Anderson | 48834e6 | 2020-05-07 14:34:57 -0700 | [diff] [blame] | 424 | err = readx_poll_timeout(gpiod_get_value_cansleep, p->hpd_gpio, |
| 425 | hpd_asserted, hpd_asserted, |
Douglas Anderson | 6ec5262 | 2021-01-15 14:44:17 -0800 | [diff] [blame] | 426 | 1000, hpd_wait_us); |
Douglas Anderson | 48834e6 | 2020-05-07 14:34:57 -0700 | [diff] [blame] | 427 | if (hpd_asserted < 0) |
| 428 | err = hpd_asserted; |
| 429 | |
| 430 | if (err) { |
Douglas Anderson | 87b4971 | 2021-01-15 14:44:18 -0800 | [diff] [blame] | 431 | if (err != -ETIMEDOUT) |
Douglas Anderson | 3235b0f | 2021-04-16 15:39:30 -0700 | [diff] [blame] | 432 | dev_err(dev, |
Douglas Anderson | 87b4971 | 2021-01-15 14:44:18 -0800 | [diff] [blame] | 433 | "error waiting for hpd GPIO: %d\n", err); |
Douglas Anderson | 5e7222a | 2021-01-15 14:44:16 -0800 | [diff] [blame] | 434 | goto error; |
Douglas Anderson | 48834e6 | 2020-05-07 14:34:57 -0700 | [diff] [blame] | 435 | } |
| 436 | } |
| 437 | |
Douglas Anderson | 4beb04b | 2020-11-09 17:00:57 -0800 | [diff] [blame] | 438 | p->prepared_time = ktime_get(); |
Ajay Kumar | 613a633 | 2014-07-31 23:12:10 +0530 | [diff] [blame] | 439 | |
| 440 | return 0; |
Douglas Anderson | 5e7222a | 2021-01-15 14:44:16 -0800 | [diff] [blame] | 441 | |
| 442 | error: |
| 443 | gpiod_set_value_cansleep(p->enable_gpio, 0); |
| 444 | regulator_disable(p->supply); |
| 445 | p->unprepared_time = ktime_get(); |
| 446 | |
| 447 | return err; |
Ajay Kumar | 613a633 | 2014-07-31 23:12:10 +0530 | [diff] [blame] | 448 | } |
| 449 | |
Douglas Anderson | 87b4971 | 2021-01-15 14:44:18 -0800 | [diff] [blame] | 450 | /* |
| 451 | * Some panels simply don't always come up and need to be power cycled to |
| 452 | * work properly. We'll allow for a handful of retries. |
| 453 | */ |
| 454 | #define MAX_PANEL_PREPARE_TRIES 5 |
| 455 | |
Douglas Anderson | 3235b0f | 2021-04-16 15:39:30 -0700 | [diff] [blame] | 456 | static int panel_simple_resume(struct device *dev) |
Douglas Anderson | 87b4971 | 2021-01-15 14:44:18 -0800 | [diff] [blame] | 457 | { |
Douglas Anderson | 3235b0f | 2021-04-16 15:39:30 -0700 | [diff] [blame] | 458 | struct panel_simple *p = dev_get_drvdata(dev); |
Douglas Anderson | 87b4971 | 2021-01-15 14:44:18 -0800 | [diff] [blame] | 459 | int ret; |
| 460 | int try; |
| 461 | |
| 462 | for (try = 0; try < MAX_PANEL_PREPARE_TRIES; try++) { |
Douglas Anderson | 3235b0f | 2021-04-16 15:39:30 -0700 | [diff] [blame] | 463 | ret = panel_simple_prepare_once(p); |
Douglas Anderson | 87b4971 | 2021-01-15 14:44:18 -0800 | [diff] [blame] | 464 | if (ret != -ETIMEDOUT) |
| 465 | break; |
| 466 | } |
| 467 | |
| 468 | if (ret == -ETIMEDOUT) |
Douglas Anderson | 3235b0f | 2021-04-16 15:39:30 -0700 | [diff] [blame] | 469 | dev_err(dev, "Prepare timeout after %d tries\n", try); |
Douglas Anderson | 87b4971 | 2021-01-15 14:44:18 -0800 | [diff] [blame] | 470 | else if (try) |
Douglas Anderson | 3235b0f | 2021-04-16 15:39:30 -0700 | [diff] [blame] | 471 | dev_warn(dev, "Prepare needed %d retries\n", try); |
Douglas Anderson | 87b4971 | 2021-01-15 14:44:18 -0800 | [diff] [blame] | 472 | |
| 473 | return ret; |
| 474 | } |
| 475 | |
Douglas Anderson | 3235b0f | 2021-04-16 15:39:30 -0700 | [diff] [blame] | 476 | static int panel_simple_prepare(struct drm_panel *panel) |
| 477 | { |
| 478 | struct panel_simple *p = to_panel_simple(panel); |
| 479 | int ret; |
| 480 | |
| 481 | /* Preparing when already prepared is a no-op */ |
| 482 | if (p->prepared) |
| 483 | return 0; |
| 484 | |
| 485 | ret = pm_runtime_get_sync(panel->dev); |
| 486 | if (ret < 0) { |
| 487 | pm_runtime_put_autosuspend(panel->dev); |
| 488 | return ret; |
| 489 | } |
| 490 | |
| 491 | p->prepared = true; |
| 492 | |
| 493 | return 0; |
| 494 | } |
| 495 | |
Ajay Kumar | 613a633 | 2014-07-31 23:12:10 +0530 | [diff] [blame] | 496 | static int panel_simple_enable(struct drm_panel *panel) |
| 497 | { |
| 498 | struct panel_simple *p = to_panel_simple(panel); |
| 499 | |
| 500 | if (p->enabled) |
| 501 | return 0; |
| 502 | |
Ajay Kumar | f673c37 | 2014-07-31 23:12:11 +0530 | [diff] [blame] | 503 | if (p->desc->delay.enable) |
| 504 | msleep(p->desc->delay.enable); |
| 505 | |
Douglas Anderson | 4beb04b | 2020-11-09 17:00:57 -0800 | [diff] [blame] | 506 | panel_simple_wait(p->prepared_time, p->desc->delay.prepare_to_enable); |
| 507 | |
Thierry Reding | 280921d | 2013-08-30 15:10:14 +0200 | [diff] [blame] | 508 | p->enabled = true; |
| 509 | |
| 510 | return 0; |
| 511 | } |
| 512 | |
Sam Ravnborg | 0ce8ddd | 2019-12-07 15:03:33 +0100 | [diff] [blame] | 513 | static int panel_simple_get_modes(struct drm_panel *panel, |
| 514 | struct drm_connector *connector) |
Thierry Reding | 280921d | 2013-08-30 15:10:14 +0200 | [diff] [blame] | 515 | { |
| 516 | struct panel_simple *p = to_panel_simple(panel); |
| 517 | int num = 0; |
| 518 | |
| 519 | /* probe EDID if a DDC bus is available */ |
| 520 | if (p->ddc) { |
Douglas Anderson | 31e2539 | 2021-04-23 09:59:03 -0700 | [diff] [blame] | 521 | pm_runtime_get_sync(panel->dev); |
| 522 | |
Douglas Anderson | 63358e2 | 2021-04-23 09:59:04 -0700 | [diff] [blame] | 523 | if (!p->edid) |
| 524 | p->edid = drm_get_edid(connector, p->ddc); |
| 525 | |
| 526 | if (p->edid) |
| 527 | num += drm_add_edid_modes(connector, p->edid); |
Douglas Anderson | 31e2539 | 2021-04-23 09:59:03 -0700 | [diff] [blame] | 528 | |
| 529 | pm_runtime_mark_last_busy(panel->dev); |
| 530 | pm_runtime_put_autosuspend(panel->dev); |
Thierry Reding | 280921d | 2013-08-30 15:10:14 +0200 | [diff] [blame] | 531 | } |
| 532 | |
| 533 | /* add hard-coded panel modes */ |
Sam Ravnborg | 0ce8ddd | 2019-12-07 15:03:33 +0100 | [diff] [blame] | 534 | num += panel_simple_get_non_edid_modes(p, connector); |
Thierry Reding | 280921d | 2013-08-30 15:10:14 +0200 | [diff] [blame] | 535 | |
Dmitry Osipenko | 5759c96 | 2020-08-14 00:56:09 +0300 | [diff] [blame] | 536 | /* set up connector's "panel orientation" property */ |
| 537 | drm_connector_set_panel_orientation(connector, p->orientation); |
| 538 | |
Thierry Reding | 280921d | 2013-08-30 15:10:14 +0200 | [diff] [blame] | 539 | return num; |
| 540 | } |
| 541 | |
Philipp Zabel | a5d3e62 | 2014-12-11 18:32:45 +0100 | [diff] [blame] | 542 | static int panel_simple_get_timings(struct drm_panel *panel, |
| 543 | unsigned int num_timings, |
| 544 | struct display_timing *timings) |
| 545 | { |
| 546 | struct panel_simple *p = to_panel_simple(panel); |
| 547 | unsigned int i; |
| 548 | |
| 549 | if (p->desc->num_timings < num_timings) |
| 550 | num_timings = p->desc->num_timings; |
| 551 | |
| 552 | if (timings) |
| 553 | for (i = 0; i < num_timings; i++) |
| 554 | timings[i] = p->desc->timings[i]; |
| 555 | |
| 556 | return p->desc->num_timings; |
| 557 | } |
| 558 | |
Thierry Reding | 280921d | 2013-08-30 15:10:14 +0200 | [diff] [blame] | 559 | static const struct drm_panel_funcs panel_simple_funcs = { |
| 560 | .disable = panel_simple_disable, |
Ajay Kumar | c0e1d17 | 2014-07-31 23:12:04 +0530 | [diff] [blame] | 561 | .unprepare = panel_simple_unprepare, |
| 562 | .prepare = panel_simple_prepare, |
Thierry Reding | 280921d | 2013-08-30 15:10:14 +0200 | [diff] [blame] | 563 | .enable = panel_simple_enable, |
| 564 | .get_modes = panel_simple_get_modes, |
Philipp Zabel | a5d3e62 | 2014-12-11 18:32:45 +0100 | [diff] [blame] | 565 | .get_timings = panel_simple_get_timings, |
Thierry Reding | 280921d | 2013-08-30 15:10:14 +0200 | [diff] [blame] | 566 | }; |
| 567 | |
Sam Ravnborg | 4a1d0db | 2020-02-16 19:15:13 +0100 | [diff] [blame] | 568 | static struct panel_desc panel_dpi; |
| 569 | |
| 570 | static int panel_dpi_probe(struct device *dev, |
| 571 | struct panel_simple *panel) |
| 572 | { |
| 573 | struct display_timing *timing; |
| 574 | const struct device_node *np; |
| 575 | struct panel_desc *desc; |
| 576 | unsigned int bus_flags; |
| 577 | struct videomode vm; |
Sam Ravnborg | 4a1d0db | 2020-02-16 19:15:13 +0100 | [diff] [blame] | 578 | int ret; |
| 579 | |
| 580 | np = dev->of_node; |
| 581 | desc = devm_kzalloc(dev, sizeof(*desc), GFP_KERNEL); |
| 582 | if (!desc) |
| 583 | return -ENOMEM; |
| 584 | |
| 585 | timing = devm_kzalloc(dev, sizeof(*timing), GFP_KERNEL); |
| 586 | if (!timing) |
| 587 | return -ENOMEM; |
| 588 | |
| 589 | ret = of_get_display_timing(np, "panel-timing", timing); |
| 590 | if (ret < 0) { |
| 591 | dev_err(dev, "%pOF: no panel-timing node found for \"panel-dpi\" binding\n", |
| 592 | np); |
| 593 | return ret; |
| 594 | } |
| 595 | |
| 596 | desc->timings = timing; |
| 597 | desc->num_timings = 1; |
| 598 | |
| 599 | of_property_read_u32(np, "width-mm", &desc->size.width); |
| 600 | of_property_read_u32(np, "height-mm", &desc->size.height); |
| 601 | |
Sam Ravnborg | 4a1d0db | 2020-02-16 19:15:13 +0100 | [diff] [blame] | 602 | /* Extract bus_flags from display_timing */ |
| 603 | bus_flags = 0; |
| 604 | vm.flags = timing->flags; |
| 605 | drm_bus_flags_from_videomode(&vm, &bus_flags); |
| 606 | desc->bus_flags = bus_flags; |
| 607 | |
| 608 | /* We do not know the connector for the DT node, so guess it */ |
| 609 | desc->connector_type = DRM_MODE_CONNECTOR_DPI; |
| 610 | |
| 611 | panel->desc = desc; |
| 612 | |
| 613 | return 0; |
| 614 | } |
| 615 | |
Sean Paul | b8a2948 | 2019-07-11 13:34:53 -0700 | [diff] [blame] | 616 | #define PANEL_SIMPLE_BOUNDS_CHECK(to_check, bounds, field) \ |
| 617 | (to_check->field.typ >= bounds->field.min && \ |
| 618 | to_check->field.typ <= bounds->field.max) |
Douglas Anderson | e362cc6 | 2019-07-12 09:33:33 -0700 | [diff] [blame] | 619 | static void panel_simple_parse_panel_timing_node(struct device *dev, |
| 620 | struct panel_simple *panel, |
| 621 | const struct display_timing *ot) |
Sean Paul | b8a2948 | 2019-07-11 13:34:53 -0700 | [diff] [blame] | 622 | { |
| 623 | const struct panel_desc *desc = panel->desc; |
| 624 | struct videomode vm; |
| 625 | unsigned int i; |
| 626 | |
| 627 | if (WARN_ON(desc->num_modes)) { |
| 628 | dev_err(dev, "Reject override mode: panel has a fixed mode\n"); |
| 629 | return; |
| 630 | } |
| 631 | if (WARN_ON(!desc->num_timings)) { |
| 632 | dev_err(dev, "Reject override mode: no timings specified\n"); |
| 633 | return; |
| 634 | } |
| 635 | |
| 636 | for (i = 0; i < panel->desc->num_timings; i++) { |
| 637 | const struct display_timing *dt = &panel->desc->timings[i]; |
| 638 | |
| 639 | if (!PANEL_SIMPLE_BOUNDS_CHECK(ot, dt, hactive) || |
| 640 | !PANEL_SIMPLE_BOUNDS_CHECK(ot, dt, hfront_porch) || |
| 641 | !PANEL_SIMPLE_BOUNDS_CHECK(ot, dt, hback_porch) || |
| 642 | !PANEL_SIMPLE_BOUNDS_CHECK(ot, dt, hsync_len) || |
| 643 | !PANEL_SIMPLE_BOUNDS_CHECK(ot, dt, vactive) || |
| 644 | !PANEL_SIMPLE_BOUNDS_CHECK(ot, dt, vfront_porch) || |
| 645 | !PANEL_SIMPLE_BOUNDS_CHECK(ot, dt, vback_porch) || |
| 646 | !PANEL_SIMPLE_BOUNDS_CHECK(ot, dt, vsync_len)) |
| 647 | continue; |
| 648 | |
| 649 | if (ot->flags != dt->flags) |
| 650 | continue; |
| 651 | |
| 652 | videomode_from_timing(ot, &vm); |
| 653 | drm_display_mode_from_videomode(&vm, &panel->override_mode); |
| 654 | panel->override_mode.type |= DRM_MODE_TYPE_DRIVER | |
| 655 | DRM_MODE_TYPE_PREFERRED; |
| 656 | break; |
| 657 | } |
| 658 | |
| 659 | if (WARN_ON(!panel->override_mode.type)) |
| 660 | dev_err(dev, "Reject override mode: No display_timing found\n"); |
| 661 | } |
| 662 | |
Douglas Anderson | cc5a3fc | 2021-06-11 10:17:42 -0700 | [diff] [blame] | 663 | static int panel_simple_probe(struct device *dev, const struct panel_desc *desc, |
| 664 | struct drm_dp_aux *aux) |
Thierry Reding | 280921d | 2013-08-30 15:10:14 +0200 | [diff] [blame] | 665 | { |
Thierry Reding | 280921d | 2013-08-30 15:10:14 +0200 | [diff] [blame] | 666 | struct panel_simple *panel; |
Sean Paul | b8a2948 | 2019-07-11 13:34:53 -0700 | [diff] [blame] | 667 | struct display_timing dt; |
Sam Ravnborg | 0fe1564 | 2019-12-07 15:03:31 +0100 | [diff] [blame] | 668 | struct device_node *ddc; |
Sam Ravnborg | 9f069c6 | 2020-07-26 22:33:11 +0200 | [diff] [blame] | 669 | int connector_type; |
Sam Ravnborg | ddb8e85 | 2020-07-26 22:33:10 +0200 | [diff] [blame] | 670 | u32 bus_flags; |
Thierry Reding | 280921d | 2013-08-30 15:10:14 +0200 | [diff] [blame] | 671 | int err; |
| 672 | |
| 673 | panel = devm_kzalloc(dev, sizeof(*panel), GFP_KERNEL); |
| 674 | if (!panel) |
| 675 | return -ENOMEM; |
| 676 | |
| 677 | panel->enabled = false; |
Douglas Anderson | 4beb04b | 2020-11-09 17:00:57 -0800 | [diff] [blame] | 678 | panel->prepared_time = 0; |
Thierry Reding | 280921d | 2013-08-30 15:10:14 +0200 | [diff] [blame] | 679 | panel->desc = desc; |
Douglas Anderson | cc5a3fc | 2021-06-11 10:17:42 -0700 | [diff] [blame] | 680 | panel->aux = aux; |
Thierry Reding | 280921d | 2013-08-30 15:10:14 +0200 | [diff] [blame] | 681 | |
Douglas Anderson | 2ed3e95 | 2018-10-25 15:21:30 -0700 | [diff] [blame] | 682 | panel->no_hpd = of_property_read_bool(dev->of_node, "no-hpd"); |
Douglas Anderson | 48834e6 | 2020-05-07 14:34:57 -0700 | [diff] [blame] | 683 | if (!panel->no_hpd) { |
Douglas Anderson | 5c4381e | 2021-04-23 09:58:56 -0700 | [diff] [blame] | 684 | err = panel_simple_get_hpd_gpio(dev, panel); |
Douglas Anderson | 48834e6 | 2020-05-07 14:34:57 -0700 | [diff] [blame] | 685 | if (err) |
| 686 | return err; |
| 687 | } |
Douglas Anderson | 2ed3e95 | 2018-10-25 15:21:30 -0700 | [diff] [blame] | 688 | |
Thierry Reding | 280921d | 2013-08-30 15:10:14 +0200 | [diff] [blame] | 689 | panel->supply = devm_regulator_get(dev, "power"); |
| 690 | if (IS_ERR(panel->supply)) |
| 691 | return PTR_ERR(panel->supply); |
| 692 | |
Alexandre Courbot | a61400d | 2014-10-23 17:16:58 +0900 | [diff] [blame] | 693 | panel->enable_gpio = devm_gpiod_get_optional(dev, "enable", |
| 694 | GPIOD_OUT_LOW); |
Alexandre Courbot | cfdf054 | 2014-03-01 14:00:58 +0900 | [diff] [blame] | 695 | if (IS_ERR(panel->enable_gpio)) { |
| 696 | err = PTR_ERR(panel->enable_gpio); |
Fabio Estevam | b8e9380 | 2017-06-30 18:14:46 -0300 | [diff] [blame] | 697 | if (err != -EPROBE_DEFER) |
| 698 | dev_err(dev, "failed to request GPIO: %d\n", err); |
Alexandre Courbot | 9746c61 | 2014-07-25 23:47:25 +0900 | [diff] [blame] | 699 | return err; |
| 700 | } |
Thierry Reding | 280921d | 2013-08-30 15:10:14 +0200 | [diff] [blame] | 701 | |
Dmitry Osipenko | 5759c96 | 2020-08-14 00:56:09 +0300 | [diff] [blame] | 702 | err = of_drm_get_panel_orientation(dev->of_node, &panel->orientation); |
| 703 | if (err) { |
| 704 | dev_err(dev, "%pOF: failed to get orientation %d\n", dev->of_node, err); |
| 705 | return err; |
| 706 | } |
| 707 | |
Thierry Reding | 280921d | 2013-08-30 15:10:14 +0200 | [diff] [blame] | 708 | ddc = of_parse_phandle(dev->of_node, "ddc-i2c-bus", 0); |
| 709 | if (ddc) { |
| 710 | panel->ddc = of_find_i2c_adapter_by_node(ddc); |
| 711 | of_node_put(ddc); |
| 712 | |
Sam Ravnborg | 0fe1564 | 2019-12-07 15:03:31 +0100 | [diff] [blame] | 713 | if (!panel->ddc) |
| 714 | return -EPROBE_DEFER; |
Douglas Anderson | cc5a3fc | 2021-06-11 10:17:42 -0700 | [diff] [blame] | 715 | } else if (aux) { |
| 716 | panel->ddc = &aux->ddc; |
Thierry Reding | 280921d | 2013-08-30 15:10:14 +0200 | [diff] [blame] | 717 | } |
| 718 | |
Sam Ravnborg | 4a1d0db | 2020-02-16 19:15:13 +0100 | [diff] [blame] | 719 | if (desc == &panel_dpi) { |
| 720 | /* Handle the generic panel-dpi binding */ |
| 721 | err = panel_dpi_probe(dev, panel); |
| 722 | if (err) |
| 723 | goto free_ddc; |
| 724 | } else { |
| 725 | if (!of_get_display_timing(dev->of_node, "panel-timing", &dt)) |
| 726 | panel_simple_parse_panel_timing_node(dev, panel, &dt); |
| 727 | } |
Sean Paul | b8a2948 | 2019-07-11 13:34:53 -0700 | [diff] [blame] | 728 | |
Sam Ravnborg | 9f069c6 | 2020-07-26 22:33:11 +0200 | [diff] [blame] | 729 | connector_type = desc->connector_type; |
Sam Ravnborg | ddb8e85 | 2020-07-26 22:33:10 +0200 | [diff] [blame] | 730 | /* Catch common mistakes for panels. */ |
Sam Ravnborg | 9f069c6 | 2020-07-26 22:33:11 +0200 | [diff] [blame] | 731 | switch (connector_type) { |
Sam Ravnborg | ddb8e85 | 2020-07-26 22:33:10 +0200 | [diff] [blame] | 732 | case 0: |
| 733 | dev_warn(dev, "Specify missing connector_type\n"); |
Sam Ravnborg | 9f069c6 | 2020-07-26 22:33:11 +0200 | [diff] [blame] | 734 | connector_type = DRM_MODE_CONNECTOR_DPI; |
Sam Ravnborg | ddb8e85 | 2020-07-26 22:33:10 +0200 | [diff] [blame] | 735 | break; |
| 736 | case DRM_MODE_CONNECTOR_LVDS: |
Laurent Pinchart | c471583 | 2020-06-30 02:33:19 +0300 | [diff] [blame] | 737 | WARN_ON(desc->bus_flags & |
| 738 | ~(DRM_BUS_FLAG_DE_LOW | |
| 739 | DRM_BUS_FLAG_DE_HIGH | |
| 740 | DRM_BUS_FLAG_DATA_MSB_TO_LSB | |
| 741 | DRM_BUS_FLAG_DATA_LSB_TO_MSB)); |
Laurent Pinchart | 1185c40 | 2020-06-30 02:33:20 +0300 | [diff] [blame] | 742 | WARN_ON(desc->bus_format != MEDIA_BUS_FMT_RGB666_1X7X3_SPWG && |
| 743 | desc->bus_format != MEDIA_BUS_FMT_RGB888_1X7X4_SPWG && |
| 744 | desc->bus_format != MEDIA_BUS_FMT_RGB888_1X7X4_JEIDA); |
| 745 | WARN_ON(desc->bus_format == MEDIA_BUS_FMT_RGB666_1X7X3_SPWG && |
| 746 | desc->bpc != 6); |
| 747 | WARN_ON((desc->bus_format == MEDIA_BUS_FMT_RGB888_1X7X4_SPWG || |
| 748 | desc->bus_format == MEDIA_BUS_FMT_RGB888_1X7X4_JEIDA) && |
| 749 | desc->bpc != 8); |
Sam Ravnborg | ddb8e85 | 2020-07-26 22:33:10 +0200 | [diff] [blame] | 750 | break; |
| 751 | case DRM_MODE_CONNECTOR_eDP: |
| 752 | if (desc->bus_format == 0) |
| 753 | dev_warn(dev, "Specify missing bus_format\n"); |
| 754 | if (desc->bpc != 6 && desc->bpc != 8) |
| 755 | dev_warn(dev, "Expected bpc in {6,8} but got: %u\n", desc->bpc); |
| 756 | break; |
| 757 | case DRM_MODE_CONNECTOR_DSI: |
| 758 | if (desc->bpc != 6 && desc->bpc != 8) |
| 759 | dev_warn(dev, "Expected bpc in {6,8} but got: %u\n", desc->bpc); |
| 760 | break; |
| 761 | case DRM_MODE_CONNECTOR_DPI: |
| 762 | bus_flags = DRM_BUS_FLAG_DE_LOW | |
| 763 | DRM_BUS_FLAG_DE_HIGH | |
| 764 | DRM_BUS_FLAG_PIXDATA_SAMPLE_POSEDGE | |
| 765 | DRM_BUS_FLAG_PIXDATA_SAMPLE_NEGEDGE | |
| 766 | DRM_BUS_FLAG_DATA_MSB_TO_LSB | |
| 767 | DRM_BUS_FLAG_DATA_LSB_TO_MSB | |
| 768 | DRM_BUS_FLAG_SYNC_SAMPLE_POSEDGE | |
| 769 | DRM_BUS_FLAG_SYNC_SAMPLE_NEGEDGE; |
| 770 | if (desc->bus_flags & ~bus_flags) |
| 771 | dev_warn(dev, "Unexpected bus_flags(%d)\n", desc->bus_flags & ~bus_flags); |
| 772 | if (!(desc->bus_flags & bus_flags)) |
| 773 | dev_warn(dev, "Specify missing bus_flags\n"); |
| 774 | if (desc->bus_format == 0) |
| 775 | dev_warn(dev, "Specify missing bus_format\n"); |
| 776 | if (desc->bpc != 6 && desc->bpc != 8) |
| 777 | dev_warn(dev, "Expected bpc in {6,8} but got: %u\n", desc->bpc); |
| 778 | break; |
| 779 | default: |
| 780 | dev_warn(dev, "Specify a valid connector_type: %d\n", desc->connector_type); |
Sam Ravnborg | 9f069c6 | 2020-07-26 22:33:11 +0200 | [diff] [blame] | 781 | connector_type = DRM_MODE_CONNECTOR_DPI; |
Sam Ravnborg | ddb8e85 | 2020-07-26 22:33:10 +0200 | [diff] [blame] | 782 | break; |
Laurent Pinchart | 1185c40 | 2020-06-30 02:33:20 +0300 | [diff] [blame] | 783 | } |
Laurent Pinchart | c471583 | 2020-06-30 02:33:19 +0300 | [diff] [blame] | 784 | |
Douglas Anderson | 3235b0f | 2021-04-16 15:39:30 -0700 | [diff] [blame] | 785 | dev_set_drvdata(dev, panel); |
| 786 | |
| 787 | /* |
| 788 | * We use runtime PM for prepare / unprepare since those power the panel |
| 789 | * on and off and those can be very slow operations. This is important |
| 790 | * to optimize powering the panel on briefly to read the EDID before |
| 791 | * fully enabling the panel. |
| 792 | */ |
| 793 | pm_runtime_enable(dev); |
| 794 | pm_runtime_set_autosuspend_delay(dev, 1000); |
| 795 | pm_runtime_use_autosuspend(dev); |
| 796 | |
Sam Ravnborg | 9f069c6 | 2020-07-26 22:33:11 +0200 | [diff] [blame] | 797 | drm_panel_init(&panel->base, dev, &panel_simple_funcs, connector_type); |
Thierry Reding | 280921d | 2013-08-30 15:10:14 +0200 | [diff] [blame] | 798 | |
Sam Ravnborg | 0fe1564 | 2019-12-07 15:03:31 +0100 | [diff] [blame] | 799 | err = drm_panel_of_backlight(&panel->base); |
| 800 | if (err) |
Douglas Anderson | 70e1256 | 2021-04-23 09:58:47 -0700 | [diff] [blame] | 801 | goto disable_pm_runtime; |
Sam Ravnborg | 0fe1564 | 2019-12-07 15:03:31 +0100 | [diff] [blame] | 802 | |
Bernard Zhao | c3ee8c6 | 2020-08-01 20:02:13 +0800 | [diff] [blame] | 803 | drm_panel_add(&panel->base); |
Thierry Reding | 280921d | 2013-08-30 15:10:14 +0200 | [diff] [blame] | 804 | |
Thierry Reding | 280921d | 2013-08-30 15:10:14 +0200 | [diff] [blame] | 805 | return 0; |
| 806 | |
Douglas Anderson | 70e1256 | 2021-04-23 09:58:47 -0700 | [diff] [blame] | 807 | disable_pm_runtime: |
Douglas Anderson | a596fcd | 2021-05-17 13:08:58 -0700 | [diff] [blame] | 808 | pm_runtime_dont_use_autosuspend(dev); |
Douglas Anderson | 70e1256 | 2021-04-23 09:58:47 -0700 | [diff] [blame] | 809 | pm_runtime_disable(dev); |
Thierry Reding | 280921d | 2013-08-30 15:10:14 +0200 | [diff] [blame] | 810 | free_ddc: |
Douglas Anderson | cc5a3fc | 2021-06-11 10:17:42 -0700 | [diff] [blame] | 811 | if (panel->ddc && (!panel->aux || panel->ddc != &panel->aux->ddc)) |
Thierry Reding | 280921d | 2013-08-30 15:10:14 +0200 | [diff] [blame] | 812 | put_device(&panel->ddc->dev); |
Thierry Reding | 280921d | 2013-08-30 15:10:14 +0200 | [diff] [blame] | 813 | |
| 814 | return err; |
| 815 | } |
| 816 | |
| 817 | static int panel_simple_remove(struct device *dev) |
| 818 | { |
| 819 | struct panel_simple *panel = dev_get_drvdata(dev); |
| 820 | |
Thierry Reding | 280921d | 2013-08-30 15:10:14 +0200 | [diff] [blame] | 821 | drm_panel_remove(&panel->base); |
Sam Ravnborg | 0fe1564 | 2019-12-07 15:03:31 +0100 | [diff] [blame] | 822 | drm_panel_disable(&panel->base); |
| 823 | drm_panel_unprepare(&panel->base); |
Thierry Reding | 280921d | 2013-08-30 15:10:14 +0200 | [diff] [blame] | 824 | |
Douglas Anderson | a596fcd | 2021-05-17 13:08:58 -0700 | [diff] [blame] | 825 | pm_runtime_dont_use_autosuspend(dev); |
Douglas Anderson | 70e1256 | 2021-04-23 09:58:47 -0700 | [diff] [blame] | 826 | pm_runtime_disable(dev); |
Douglas Anderson | cc5a3fc | 2021-06-11 10:17:42 -0700 | [diff] [blame] | 827 | if (panel->ddc && (!panel->aux || panel->ddc != &panel->aux->ddc)) |
Thierry Reding | 280921d | 2013-08-30 15:10:14 +0200 | [diff] [blame] | 828 | put_device(&panel->ddc->dev); |
| 829 | |
Thierry Reding | 280921d | 2013-08-30 15:10:14 +0200 | [diff] [blame] | 830 | return 0; |
| 831 | } |
| 832 | |
Thierry Reding | d02fd93 | 2014-04-29 17:21:21 +0200 | [diff] [blame] | 833 | static void panel_simple_shutdown(struct device *dev) |
| 834 | { |
| 835 | struct panel_simple *panel = dev_get_drvdata(dev); |
| 836 | |
Sam Ravnborg | 0fe1564 | 2019-12-07 15:03:31 +0100 | [diff] [blame] | 837 | drm_panel_disable(&panel->base); |
| 838 | drm_panel_unprepare(&panel->base); |
Thierry Reding | d02fd93 | 2014-04-29 17:21:21 +0200 | [diff] [blame] | 839 | } |
| 840 | |
Jagan Teki | bca684e | 2020-08-29 22:03:28 +0530 | [diff] [blame] | 841 | static const struct drm_display_mode ampire_am_1280800n3tzqw_t00h_mode = { |
| 842 | .clock = 71100, |
| 843 | .hdisplay = 1280, |
| 844 | .hsync_start = 1280 + 40, |
| 845 | .hsync_end = 1280 + 40 + 80, |
| 846 | .htotal = 1280 + 40 + 80 + 40, |
| 847 | .vdisplay = 800, |
| 848 | .vsync_start = 800 + 3, |
| 849 | .vsync_end = 800 + 3 + 10, |
| 850 | .vtotal = 800 + 3 + 10 + 10, |
| 851 | .flags = DRM_MODE_FLAG_PHSYNC | DRM_MODE_FLAG_PVSYNC, |
| 852 | }; |
| 853 | |
| 854 | static const struct panel_desc ampire_am_1280800n3tzqw_t00h = { |
| 855 | .modes = &ire_am_1280800n3tzqw_t00h_mode, |
| 856 | .num_modes = 1, |
| 857 | .bpc = 6, |
| 858 | .size = { |
| 859 | .width = 217, |
| 860 | .height = 136, |
| 861 | }, |
| 862 | .bus_flags = DRM_BUS_FLAG_DE_HIGH, |
| 863 | .bus_format = MEDIA_BUS_FMT_RGB888_1X7X4_SPWG, |
| 864 | .connector_type = DRM_MODE_CONNECTOR_LVDS, |
| 865 | }; |
| 866 | |
Yannick Fertre | 966fea7 | 2017-03-28 11:44:49 +0200 | [diff] [blame] | 867 | static const struct drm_display_mode ampire_am_480272h3tmqw_t01h_mode = { |
| 868 | .clock = 9000, |
| 869 | .hdisplay = 480, |
| 870 | .hsync_start = 480 + 2, |
| 871 | .hsync_end = 480 + 2 + 41, |
| 872 | .htotal = 480 + 2 + 41 + 2, |
| 873 | .vdisplay = 272, |
| 874 | .vsync_start = 272 + 2, |
| 875 | .vsync_end = 272 + 2 + 10, |
| 876 | .vtotal = 272 + 2 + 10 + 2, |
Yannick Fertre | 966fea7 | 2017-03-28 11:44:49 +0200 | [diff] [blame] | 877 | .flags = DRM_MODE_FLAG_PHSYNC | DRM_MODE_FLAG_PVSYNC, |
| 878 | }; |
| 879 | |
| 880 | static const struct panel_desc ampire_am_480272h3tmqw_t01h = { |
| 881 | .modes = &ire_am_480272h3tmqw_t01h_mode, |
| 882 | .num_modes = 1, |
| 883 | .bpc = 8, |
| 884 | .size = { |
| 885 | .width = 105, |
| 886 | .height = 67, |
| 887 | }, |
| 888 | .bus_format = MEDIA_BUS_FMT_RGB888_1X24, |
| 889 | }; |
| 890 | |
Philipp Zabel | 1c550fa1 | 2015-02-11 18:50:09 +0100 | [diff] [blame] | 891 | static const struct drm_display_mode ampire_am800480r3tmqwa1h_mode = { |
| 892 | .clock = 33333, |
| 893 | .hdisplay = 800, |
| 894 | .hsync_start = 800 + 0, |
| 895 | .hsync_end = 800 + 0 + 255, |
| 896 | .htotal = 800 + 0 + 255 + 0, |
| 897 | .vdisplay = 480, |
| 898 | .vsync_start = 480 + 2, |
| 899 | .vsync_end = 480 + 2 + 45, |
| 900 | .vtotal = 480 + 2 + 45 + 0, |
Philipp Zabel | 1c550fa1 | 2015-02-11 18:50:09 +0100 | [diff] [blame] | 901 | .flags = DRM_MODE_FLAG_PHSYNC | DRM_MODE_FLAG_PVSYNC, |
| 902 | }; |
| 903 | |
| 904 | static const struct panel_desc ampire_am800480r3tmqwa1h = { |
| 905 | .modes = &ire_am800480r3tmqwa1h_mode, |
| 906 | .num_modes = 1, |
| 907 | .bpc = 6, |
| 908 | .size = { |
| 909 | .width = 152, |
| 910 | .height = 91, |
| 911 | }, |
| 912 | .bus_format = MEDIA_BUS_FMT_RGB666_1X18, |
| 913 | }; |
| 914 | |
Sébastien Szymanski | c479450f | 2019-05-07 17:27:12 +0200 | [diff] [blame] | 915 | static const struct display_timing santek_st0700i5y_rbslw_f_timing = { |
| 916 | .pixelclock = { 26400000, 33300000, 46800000 }, |
| 917 | .hactive = { 800, 800, 800 }, |
| 918 | .hfront_porch = { 16, 210, 354 }, |
| 919 | .hback_porch = { 45, 36, 6 }, |
| 920 | .hsync_len = { 1, 10, 40 }, |
| 921 | .vactive = { 480, 480, 480 }, |
| 922 | .vfront_porch = { 7, 22, 147 }, |
| 923 | .vback_porch = { 22, 13, 3 }, |
| 924 | .vsync_len = { 1, 10, 20 }, |
| 925 | .flags = DISPLAY_FLAGS_HSYNC_LOW | DISPLAY_FLAGS_VSYNC_LOW | |
| 926 | DISPLAY_FLAGS_DE_HIGH | DISPLAY_FLAGS_PIXDATA_POSEDGE |
| 927 | }; |
| 928 | |
| 929 | static const struct panel_desc armadeus_st0700_adapt = { |
| 930 | .timings = &santek_st0700i5y_rbslw_f_timing, |
| 931 | .num_timings = 1, |
| 932 | .bpc = 6, |
| 933 | .size = { |
| 934 | .width = 154, |
| 935 | .height = 86, |
| 936 | }, |
| 937 | .bus_format = MEDIA_BUS_FMT_RGB666_1X18, |
Sam Ravnborg | f5436f7 | 2020-06-30 20:05:43 +0200 | [diff] [blame] | 938 | .bus_flags = DRM_BUS_FLAG_DE_HIGH | DRM_BUS_FLAG_PIXDATA_SAMPLE_NEGEDGE, |
Sébastien Szymanski | c479450f | 2019-05-07 17:27:12 +0200 | [diff] [blame] | 939 | }; |
| 940 | |
Thierry Reding | 280921d | 2013-08-30 15:10:14 +0200 | [diff] [blame] | 941 | static const struct drm_display_mode auo_b101aw03_mode = { |
| 942 | .clock = 51450, |
| 943 | .hdisplay = 1024, |
| 944 | .hsync_start = 1024 + 156, |
| 945 | .hsync_end = 1024 + 156 + 8, |
| 946 | .htotal = 1024 + 156 + 8 + 156, |
| 947 | .vdisplay = 600, |
| 948 | .vsync_start = 600 + 16, |
| 949 | .vsync_end = 600 + 16 + 6, |
| 950 | .vtotal = 600 + 16 + 6 + 16, |
Thierry Reding | 280921d | 2013-08-30 15:10:14 +0200 | [diff] [blame] | 951 | }; |
| 952 | |
| 953 | static const struct panel_desc auo_b101aw03 = { |
| 954 | .modes = &auo_b101aw03_mode, |
| 955 | .num_modes = 1, |
Stéphane Marchesin | 0208d51 | 2014-06-19 18:18:28 -0700 | [diff] [blame] | 956 | .bpc = 6, |
Thierry Reding | 280921d | 2013-08-30 15:10:14 +0200 | [diff] [blame] | 957 | .size = { |
| 958 | .width = 223, |
| 959 | .height = 125, |
| 960 | }, |
Dmitry Osipenko | 8556082 | 2020-06-22 01:27:42 +0300 | [diff] [blame] | 961 | .bus_format = MEDIA_BUS_FMT_RGB666_1X7X3_SPWG, |
Laurent Pinchart | c471583 | 2020-06-30 02:33:19 +0300 | [diff] [blame] | 962 | .bus_flags = DRM_BUS_FLAG_DE_HIGH, |
Dmitry Osipenko | 94f0791 | 2020-06-18 01:27:03 +0300 | [diff] [blame] | 963 | .connector_type = DRM_MODE_CONNECTOR_LVDS, |
Thierry Reding | 280921d | 2013-08-30 15:10:14 +0200 | [diff] [blame] | 964 | }; |
| 965 | |
Douglas Anderson | 374bf82 | 2019-07-11 13:34:55 -0700 | [diff] [blame] | 966 | static const struct display_timing auo_b101ean01_timing = { |
| 967 | .pixelclock = { 65300000, 72500000, 75000000 }, |
| 968 | .hactive = { 1280, 1280, 1280 }, |
| 969 | .hfront_porch = { 18, 119, 119 }, |
| 970 | .hback_porch = { 21, 21, 21 }, |
| 971 | .hsync_len = { 32, 32, 32 }, |
| 972 | .vactive = { 800, 800, 800 }, |
| 973 | .vfront_porch = { 4, 4, 4 }, |
| 974 | .vback_porch = { 8, 8, 8 }, |
| 975 | .vsync_len = { 18, 20, 20 }, |
Huang Lin | a531bc3 | 2015-02-28 10:18:58 +0800 | [diff] [blame] | 976 | }; |
| 977 | |
| 978 | static const struct panel_desc auo_b101ean01 = { |
Douglas Anderson | 374bf82 | 2019-07-11 13:34:55 -0700 | [diff] [blame] | 979 | .timings = &auo_b101ean01_timing, |
| 980 | .num_timings = 1, |
Huang Lin | a531bc3 | 2015-02-28 10:18:58 +0800 | [diff] [blame] | 981 | .bpc = 6, |
| 982 | .size = { |
| 983 | .width = 217, |
| 984 | .height = 136, |
| 985 | }, |
| 986 | }; |
| 987 | |
Rob Clark | dac746e | 2014-08-01 17:01:06 -0400 | [diff] [blame] | 988 | static const struct drm_display_mode auo_b101xtn01_mode = { |
| 989 | .clock = 72000, |
| 990 | .hdisplay = 1366, |
| 991 | .hsync_start = 1366 + 20, |
| 992 | .hsync_end = 1366 + 20 + 70, |
| 993 | .htotal = 1366 + 20 + 70, |
| 994 | .vdisplay = 768, |
| 995 | .vsync_start = 768 + 14, |
| 996 | .vsync_end = 768 + 14 + 42, |
| 997 | .vtotal = 768 + 14 + 42, |
Rob Clark | dac746e | 2014-08-01 17:01:06 -0400 | [diff] [blame] | 998 | .flags = DRM_MODE_FLAG_NVSYNC | DRM_MODE_FLAG_NHSYNC, |
| 999 | }; |
| 1000 | |
| 1001 | static const struct panel_desc auo_b101xtn01 = { |
| 1002 | .modes = &auo_b101xtn01_mode, |
| 1003 | .num_modes = 1, |
| 1004 | .bpc = 6, |
| 1005 | .size = { |
| 1006 | .width = 223, |
| 1007 | .height = 125, |
| 1008 | }, |
| 1009 | }; |
| 1010 | |
Rob Clark | da458286 | 2020-01-08 15:53:56 -0800 | [diff] [blame] | 1011 | static const struct drm_display_mode auo_b116xak01_mode = { |
| 1012 | .clock = 69300, |
| 1013 | .hdisplay = 1366, |
| 1014 | .hsync_start = 1366 + 48, |
| 1015 | .hsync_end = 1366 + 48 + 32, |
| 1016 | .htotal = 1366 + 48 + 32 + 10, |
| 1017 | .vdisplay = 768, |
| 1018 | .vsync_start = 768 + 4, |
| 1019 | .vsync_end = 768 + 4 + 6, |
| 1020 | .vtotal = 768 + 4 + 6 + 15, |
Rob Clark | da458286 | 2020-01-08 15:53:56 -0800 | [diff] [blame] | 1021 | .flags = DRM_MODE_FLAG_NVSYNC | DRM_MODE_FLAG_NHSYNC, |
| 1022 | }; |
| 1023 | |
| 1024 | static const struct panel_desc auo_b116xak01 = { |
| 1025 | .modes = &auo_b116xak01_mode, |
| 1026 | .num_modes = 1, |
| 1027 | .bpc = 6, |
| 1028 | .size = { |
| 1029 | .width = 256, |
| 1030 | .height = 144, |
| 1031 | }, |
| 1032 | .delay = { |
| 1033 | .hpd_absent_delay = 200, |
| 1034 | }, |
| 1035 | .bus_format = MEDIA_BUS_FMT_RGB666_1X18, |
| 1036 | .connector_type = DRM_MODE_CONNECTOR_eDP, |
| 1037 | }; |
| 1038 | |
Ajay Kumar | e35e305 | 2014-09-01 15:40:02 +0530 | [diff] [blame] | 1039 | static const struct drm_display_mode auo_b116xw03_mode = { |
| 1040 | .clock = 70589, |
| 1041 | .hdisplay = 1366, |
| 1042 | .hsync_start = 1366 + 40, |
| 1043 | .hsync_end = 1366 + 40 + 40, |
| 1044 | .htotal = 1366 + 40 + 40 + 32, |
| 1045 | .vdisplay = 768, |
| 1046 | .vsync_start = 768 + 10, |
| 1047 | .vsync_end = 768 + 10 + 12, |
| 1048 | .vtotal = 768 + 10 + 12 + 6, |
Jitao Shi | 88d3457 | 2020-07-05 17:45:14 +0800 | [diff] [blame] | 1049 | .flags = DRM_MODE_FLAG_NVSYNC | DRM_MODE_FLAG_NHSYNC, |
Ajay Kumar | e35e305 | 2014-09-01 15:40:02 +0530 | [diff] [blame] | 1050 | }; |
| 1051 | |
| 1052 | static const struct panel_desc auo_b116xw03 = { |
| 1053 | .modes = &auo_b116xw03_mode, |
| 1054 | .num_modes = 1, |
| 1055 | .bpc = 6, |
| 1056 | .size = { |
| 1057 | .width = 256, |
| 1058 | .height = 144, |
| 1059 | }, |
Jitao Shi | 88d3457 | 2020-07-05 17:45:14 +0800 | [diff] [blame] | 1060 | .delay = { |
| 1061 | .enable = 400, |
| 1062 | }, |
| 1063 | .bus_flags = DRM_BUS_FLAG_SYNC_DRIVE_NEGEDGE, |
| 1064 | .bus_format = MEDIA_BUS_FMT_RGB666_1X18, |
| 1065 | .connector_type = DRM_MODE_CONNECTOR_eDP, |
Ajay Kumar | e35e305 | 2014-09-01 15:40:02 +0530 | [diff] [blame] | 1066 | }; |
| 1067 | |
Stéphane Marchesin | a333f7a | 2014-05-23 19:27:59 -0700 | [diff] [blame] | 1068 | static const struct drm_display_mode auo_b133xtn01_mode = { |
| 1069 | .clock = 69500, |
| 1070 | .hdisplay = 1366, |
| 1071 | .hsync_start = 1366 + 48, |
| 1072 | .hsync_end = 1366 + 48 + 32, |
| 1073 | .htotal = 1366 + 48 + 32 + 20, |
| 1074 | .vdisplay = 768, |
| 1075 | .vsync_start = 768 + 3, |
| 1076 | .vsync_end = 768 + 3 + 6, |
| 1077 | .vtotal = 768 + 3 + 6 + 13, |
Stéphane Marchesin | a333f7a | 2014-05-23 19:27:59 -0700 | [diff] [blame] | 1078 | }; |
| 1079 | |
| 1080 | static const struct panel_desc auo_b133xtn01 = { |
| 1081 | .modes = &auo_b133xtn01_mode, |
| 1082 | .num_modes = 1, |
Stéphane Marchesin | 0208d51 | 2014-06-19 18:18:28 -0700 | [diff] [blame] | 1083 | .bpc = 6, |
Stéphane Marchesin | a333f7a | 2014-05-23 19:27:59 -0700 | [diff] [blame] | 1084 | .size = { |
| 1085 | .width = 293, |
| 1086 | .height = 165, |
| 1087 | }, |
| 1088 | }; |
| 1089 | |
Ajay Kumar | 3e51d60 | 2014-07-31 23:12:12 +0530 | [diff] [blame] | 1090 | static const struct drm_display_mode auo_b133htn01_mode = { |
| 1091 | .clock = 150660, |
| 1092 | .hdisplay = 1920, |
| 1093 | .hsync_start = 1920 + 172, |
| 1094 | .hsync_end = 1920 + 172 + 80, |
| 1095 | .htotal = 1920 + 172 + 80 + 60, |
| 1096 | .vdisplay = 1080, |
| 1097 | .vsync_start = 1080 + 25, |
| 1098 | .vsync_end = 1080 + 25 + 10, |
| 1099 | .vtotal = 1080 + 25 + 10 + 10, |
Ajay Kumar | 3e51d60 | 2014-07-31 23:12:12 +0530 | [diff] [blame] | 1100 | }; |
| 1101 | |
| 1102 | static const struct panel_desc auo_b133htn01 = { |
| 1103 | .modes = &auo_b133htn01_mode, |
| 1104 | .num_modes = 1, |
Thierry Reding | d7a839c | 2014-11-06 10:11:01 +0100 | [diff] [blame] | 1105 | .bpc = 6, |
Ajay Kumar | 3e51d60 | 2014-07-31 23:12:12 +0530 | [diff] [blame] | 1106 | .size = { |
| 1107 | .width = 293, |
| 1108 | .height = 165, |
| 1109 | }, |
| 1110 | .delay = { |
| 1111 | .prepare = 105, |
| 1112 | .enable = 20, |
| 1113 | .unprepare = 50, |
| 1114 | }, |
| 1115 | }; |
| 1116 | |
Lukasz Majewski | bccfaff | 2018-05-14 21:08:49 +0200 | [diff] [blame] | 1117 | static const struct display_timing auo_g070vvn01_timings = { |
| 1118 | .pixelclock = { 33300000, 34209000, 45000000 }, |
| 1119 | .hactive = { 800, 800, 800 }, |
| 1120 | .hfront_porch = { 20, 40, 200 }, |
| 1121 | .hback_porch = { 87, 40, 1 }, |
| 1122 | .hsync_len = { 1, 48, 87 }, |
| 1123 | .vactive = { 480, 480, 480 }, |
| 1124 | .vfront_porch = { 5, 13, 200 }, |
| 1125 | .vback_porch = { 31, 31, 29 }, |
| 1126 | .vsync_len = { 1, 1, 3 }, |
| 1127 | }; |
| 1128 | |
| 1129 | static const struct panel_desc auo_g070vvn01 = { |
| 1130 | .timings = &auo_g070vvn01_timings, |
| 1131 | .num_timings = 1, |
| 1132 | .bpc = 8, |
| 1133 | .size = { |
| 1134 | .width = 152, |
| 1135 | .height = 91, |
| 1136 | }, |
| 1137 | .delay = { |
| 1138 | .prepare = 200, |
| 1139 | .enable = 50, |
| 1140 | .disable = 50, |
| 1141 | .unprepare = 1000, |
| 1142 | }, |
| 1143 | }; |
| 1144 | |
Alex Gonzalez | 4fb8640 | 2018-10-25 17:09:30 +0200 | [diff] [blame] | 1145 | static const struct drm_display_mode auo_g101evn010_mode = { |
| 1146 | .clock = 68930, |
| 1147 | .hdisplay = 1280, |
| 1148 | .hsync_start = 1280 + 82, |
| 1149 | .hsync_end = 1280 + 82 + 2, |
| 1150 | .htotal = 1280 + 82 + 2 + 84, |
| 1151 | .vdisplay = 800, |
| 1152 | .vsync_start = 800 + 8, |
| 1153 | .vsync_end = 800 + 8 + 2, |
| 1154 | .vtotal = 800 + 8 + 2 + 6, |
Alex Gonzalez | 4fb8640 | 2018-10-25 17:09:30 +0200 | [diff] [blame] | 1155 | }; |
| 1156 | |
| 1157 | static const struct panel_desc auo_g101evn010 = { |
| 1158 | .modes = &auo_g101evn010_mode, |
| 1159 | .num_modes = 1, |
| 1160 | .bpc = 6, |
| 1161 | .size = { |
| 1162 | .width = 216, |
| 1163 | .height = 135, |
| 1164 | }, |
Tomi Valkeinen | 27a46fb | 2020-04-17 14:40:43 +0300 | [diff] [blame] | 1165 | .bus_format = MEDIA_BUS_FMT_RGB666_1X7X3_SPWG, |
| 1166 | .connector_type = DRM_MODE_CONNECTOR_LVDS, |
Alex Gonzalez | 4fb8640 | 2018-10-25 17:09:30 +0200 | [diff] [blame] | 1167 | }; |
| 1168 | |
Christoph Fritz | 4451c28 | 2017-12-16 14:13:36 +0100 | [diff] [blame] | 1169 | static const struct drm_display_mode auo_g104sn02_mode = { |
| 1170 | .clock = 40000, |
| 1171 | .hdisplay = 800, |
| 1172 | .hsync_start = 800 + 40, |
| 1173 | .hsync_end = 800 + 40 + 216, |
| 1174 | .htotal = 800 + 40 + 216 + 128, |
| 1175 | .vdisplay = 600, |
| 1176 | .vsync_start = 600 + 10, |
| 1177 | .vsync_end = 600 + 10 + 35, |
| 1178 | .vtotal = 600 + 10 + 35 + 2, |
Christoph Fritz | 4451c28 | 2017-12-16 14:13:36 +0100 | [diff] [blame] | 1179 | }; |
| 1180 | |
| 1181 | static const struct panel_desc auo_g104sn02 = { |
| 1182 | .modes = &auo_g104sn02_mode, |
| 1183 | .num_modes = 1, |
| 1184 | .bpc = 8, |
| 1185 | .size = { |
| 1186 | .width = 211, |
| 1187 | .height = 158, |
| 1188 | }, |
Stefan Riedmueller | a3050f2 | 2021-06-21 17:09:28 +0200 | [diff] [blame] | 1189 | .bus_format = MEDIA_BUS_FMT_RGB888_1X7X4_SPWG, |
| 1190 | .connector_type = DRM_MODE_CONNECTOR_LVDS, |
Christoph Fritz | 4451c28 | 2017-12-16 14:13:36 +0100 | [diff] [blame] | 1191 | }; |
| 1192 | |
Sebastian Reichel | 03e909a | 2020-04-15 19:27:25 +0200 | [diff] [blame] | 1193 | static const struct drm_display_mode auo_g121ean01_mode = { |
| 1194 | .clock = 66700, |
| 1195 | .hdisplay = 1280, |
| 1196 | .hsync_start = 1280 + 58, |
| 1197 | .hsync_end = 1280 + 58 + 8, |
| 1198 | .htotal = 1280 + 58 + 8 + 70, |
| 1199 | .vdisplay = 800, |
| 1200 | .vsync_start = 800 + 6, |
| 1201 | .vsync_end = 800 + 6 + 4, |
| 1202 | .vtotal = 800 + 6 + 4 + 10, |
Sebastian Reichel | 03e909a | 2020-04-15 19:27:25 +0200 | [diff] [blame] | 1203 | }; |
| 1204 | |
| 1205 | static const struct panel_desc auo_g121ean01 = { |
| 1206 | .modes = &auo_g121ean01_mode, |
| 1207 | .num_modes = 1, |
| 1208 | .bpc = 8, |
| 1209 | .size = { |
| 1210 | .width = 261, |
| 1211 | .height = 163, |
| 1212 | }, |
| 1213 | .bus_format = MEDIA_BUS_FMT_RGB888_1X7X4_SPWG, |
| 1214 | .connector_type = DRM_MODE_CONNECTOR_LVDS, |
| 1215 | }; |
| 1216 | |
Lucas Stach | 697035c | 2016-11-30 14:09:55 +0100 | [diff] [blame] | 1217 | static const struct display_timing auo_g133han01_timings = { |
| 1218 | .pixelclock = { 134000000, 141200000, 149000000 }, |
| 1219 | .hactive = { 1920, 1920, 1920 }, |
| 1220 | .hfront_porch = { 39, 58, 77 }, |
| 1221 | .hback_porch = { 59, 88, 117 }, |
| 1222 | .hsync_len = { 28, 42, 56 }, |
| 1223 | .vactive = { 1080, 1080, 1080 }, |
| 1224 | .vfront_porch = { 3, 8, 11 }, |
| 1225 | .vback_porch = { 5, 14, 19 }, |
| 1226 | .vsync_len = { 4, 14, 19 }, |
| 1227 | }; |
| 1228 | |
| 1229 | static const struct panel_desc auo_g133han01 = { |
| 1230 | .timings = &auo_g133han01_timings, |
| 1231 | .num_timings = 1, |
| 1232 | .bpc = 8, |
| 1233 | .size = { |
| 1234 | .width = 293, |
| 1235 | .height = 165, |
| 1236 | }, |
| 1237 | .delay = { |
| 1238 | .prepare = 200, |
| 1239 | .enable = 50, |
| 1240 | .disable = 50, |
| 1241 | .unprepare = 1000, |
| 1242 | }, |
| 1243 | .bus_format = MEDIA_BUS_FMT_RGB888_1X7X4_JEIDA, |
Laurent Pinchart | 9a2654c | 2019-09-04 16:28:03 +0300 | [diff] [blame] | 1244 | .connector_type = DRM_MODE_CONNECTOR_LVDS, |
Lucas Stach | 697035c | 2016-11-30 14:09:55 +0100 | [diff] [blame] | 1245 | }; |
| 1246 | |
Sebastian Reichel | d9ccd1f | 2020-04-15 19:27:24 +0200 | [diff] [blame] | 1247 | static const struct drm_display_mode auo_g156xtn01_mode = { |
| 1248 | .clock = 76000, |
| 1249 | .hdisplay = 1366, |
| 1250 | .hsync_start = 1366 + 33, |
| 1251 | .hsync_end = 1366 + 33 + 67, |
| 1252 | .htotal = 1560, |
| 1253 | .vdisplay = 768, |
| 1254 | .vsync_start = 768 + 4, |
| 1255 | .vsync_end = 768 + 4 + 4, |
| 1256 | .vtotal = 806, |
Sebastian Reichel | d9ccd1f | 2020-04-15 19:27:24 +0200 | [diff] [blame] | 1257 | }; |
| 1258 | |
| 1259 | static const struct panel_desc auo_g156xtn01 = { |
| 1260 | .modes = &auo_g156xtn01_mode, |
| 1261 | .num_modes = 1, |
| 1262 | .bpc = 8, |
| 1263 | .size = { |
| 1264 | .width = 344, |
| 1265 | .height = 194, |
| 1266 | }, |
| 1267 | .bus_format = MEDIA_BUS_FMT_RGB888_1X7X4_SPWG, |
| 1268 | .connector_type = DRM_MODE_CONNECTOR_LVDS, |
| 1269 | }; |
| 1270 | |
Lucas Stach | 8c31f60 | 2016-11-30 14:09:56 +0100 | [diff] [blame] | 1271 | static const struct display_timing auo_g185han01_timings = { |
| 1272 | .pixelclock = { 120000000, 144000000, 175000000 }, |
| 1273 | .hactive = { 1920, 1920, 1920 }, |
Lucas Stach | f8c6bfc | 2019-07-10 15:07:40 +0200 | [diff] [blame] | 1274 | .hfront_porch = { 36, 120, 148 }, |
| 1275 | .hback_porch = { 24, 88, 108 }, |
| 1276 | .hsync_len = { 20, 48, 64 }, |
Lucas Stach | 8c31f60 | 2016-11-30 14:09:56 +0100 | [diff] [blame] | 1277 | .vactive = { 1080, 1080, 1080 }, |
| 1278 | .vfront_porch = { 6, 10, 40 }, |
| 1279 | .vback_porch = { 2, 5, 20 }, |
| 1280 | .vsync_len = { 2, 5, 20 }, |
| 1281 | }; |
| 1282 | |
| 1283 | static const struct panel_desc auo_g185han01 = { |
| 1284 | .timings = &auo_g185han01_timings, |
| 1285 | .num_timings = 1, |
| 1286 | .bpc = 8, |
| 1287 | .size = { |
| 1288 | .width = 409, |
| 1289 | .height = 230, |
| 1290 | }, |
| 1291 | .delay = { |
| 1292 | .prepare = 50, |
| 1293 | .enable = 200, |
| 1294 | .disable = 110, |
| 1295 | .unprepare = 1000, |
| 1296 | }, |
| 1297 | .bus_format = MEDIA_BUS_FMT_RGB888_1X7X4_SPWG, |
Laurent Pinchart | 9a2654c | 2019-09-04 16:28:03 +0300 | [diff] [blame] | 1298 | .connector_type = DRM_MODE_CONNECTOR_LVDS, |
Lucas Stach | 8c31f60 | 2016-11-30 14:09:56 +0100 | [diff] [blame] | 1299 | }; |
| 1300 | |
Sebastian Reichel | 2f7b832 | 2020-04-15 19:27:23 +0200 | [diff] [blame] | 1301 | static const struct display_timing auo_g190ean01_timings = { |
| 1302 | .pixelclock = { 90000000, 108000000, 135000000 }, |
| 1303 | .hactive = { 1280, 1280, 1280 }, |
| 1304 | .hfront_porch = { 126, 184, 1266 }, |
| 1305 | .hback_porch = { 84, 122, 844 }, |
| 1306 | .hsync_len = { 70, 102, 704 }, |
| 1307 | .vactive = { 1024, 1024, 1024 }, |
| 1308 | .vfront_porch = { 4, 26, 76 }, |
| 1309 | .vback_porch = { 2, 8, 25 }, |
| 1310 | .vsync_len = { 2, 8, 25 }, |
| 1311 | }; |
| 1312 | |
| 1313 | static const struct panel_desc auo_g190ean01 = { |
| 1314 | .timings = &auo_g190ean01_timings, |
| 1315 | .num_timings = 1, |
| 1316 | .bpc = 8, |
| 1317 | .size = { |
| 1318 | .width = 376, |
| 1319 | .height = 301, |
| 1320 | }, |
| 1321 | .delay = { |
| 1322 | .prepare = 50, |
| 1323 | .enable = 200, |
| 1324 | .disable = 110, |
| 1325 | .unprepare = 1000, |
| 1326 | }, |
| 1327 | .bus_format = MEDIA_BUS_FMT_RGB888_1X7X4_SPWG, |
| 1328 | .connector_type = DRM_MODE_CONNECTOR_LVDS, |
| 1329 | }; |
| 1330 | |
Lucas Stach | 70c0d5b | 2017-06-08 20:07:58 +0200 | [diff] [blame] | 1331 | static const struct display_timing auo_p320hvn03_timings = { |
| 1332 | .pixelclock = { 106000000, 148500000, 164000000 }, |
| 1333 | .hactive = { 1920, 1920, 1920 }, |
| 1334 | .hfront_porch = { 25, 50, 130 }, |
| 1335 | .hback_porch = { 25, 50, 130 }, |
| 1336 | .hsync_len = { 20, 40, 105 }, |
| 1337 | .vactive = { 1080, 1080, 1080 }, |
| 1338 | .vfront_porch = { 8, 17, 150 }, |
| 1339 | .vback_porch = { 8, 17, 150 }, |
| 1340 | .vsync_len = { 4, 11, 100 }, |
| 1341 | }; |
| 1342 | |
| 1343 | static const struct panel_desc auo_p320hvn03 = { |
| 1344 | .timings = &auo_p320hvn03_timings, |
| 1345 | .num_timings = 1, |
| 1346 | .bpc = 8, |
| 1347 | .size = { |
| 1348 | .width = 698, |
| 1349 | .height = 393, |
| 1350 | }, |
| 1351 | .delay = { |
| 1352 | .prepare = 1, |
| 1353 | .enable = 450, |
| 1354 | .unprepare = 500, |
| 1355 | }, |
Lucas Stach | 2554f15 | 2018-04-11 17:27:41 +0200 | [diff] [blame] | 1356 | .bus_format = MEDIA_BUS_FMT_RGB888_1X7X4_SPWG, |
Laurent Pinchart | 9a2654c | 2019-09-04 16:28:03 +0300 | [diff] [blame] | 1357 | .connector_type = DRM_MODE_CONNECTOR_LVDS, |
Lucas Stach | 70c0d5b | 2017-06-08 20:07:58 +0200 | [diff] [blame] | 1358 | }; |
| 1359 | |
Haixia Shi | 7ee933a | 2016-10-11 14:59:16 -0700 | [diff] [blame] | 1360 | static const struct drm_display_mode auo_t215hvn01_mode = { |
| 1361 | .clock = 148800, |
| 1362 | .hdisplay = 1920, |
| 1363 | .hsync_start = 1920 + 88, |
| 1364 | .hsync_end = 1920 + 88 + 44, |
| 1365 | .htotal = 1920 + 88 + 44 + 148, |
| 1366 | .vdisplay = 1080, |
| 1367 | .vsync_start = 1080 + 4, |
| 1368 | .vsync_end = 1080 + 4 + 5, |
| 1369 | .vtotal = 1080 + 4 + 5 + 36, |
Haixia Shi | 7ee933a | 2016-10-11 14:59:16 -0700 | [diff] [blame] | 1370 | }; |
| 1371 | |
| 1372 | static const struct panel_desc auo_t215hvn01 = { |
| 1373 | .modes = &auo_t215hvn01_mode, |
| 1374 | .num_modes = 1, |
| 1375 | .bpc = 8, |
| 1376 | .size = { |
| 1377 | .width = 430, |
| 1378 | .height = 270, |
| 1379 | }, |
| 1380 | .delay = { |
| 1381 | .disable = 5, |
| 1382 | .unprepare = 1000, |
| 1383 | } |
| 1384 | }; |
| 1385 | |
Philipp Zabel | d47df63 | 2014-12-18 16:43:43 +0100 | [diff] [blame] | 1386 | static const struct drm_display_mode avic_tm070ddh03_mode = { |
| 1387 | .clock = 51200, |
| 1388 | .hdisplay = 1024, |
| 1389 | .hsync_start = 1024 + 160, |
| 1390 | .hsync_end = 1024 + 160 + 4, |
| 1391 | .htotal = 1024 + 160 + 4 + 156, |
| 1392 | .vdisplay = 600, |
| 1393 | .vsync_start = 600 + 17, |
| 1394 | .vsync_end = 600 + 17 + 1, |
| 1395 | .vtotal = 600 + 17 + 1 + 17, |
Philipp Zabel | d47df63 | 2014-12-18 16:43:43 +0100 | [diff] [blame] | 1396 | }; |
| 1397 | |
| 1398 | static const struct panel_desc avic_tm070ddh03 = { |
| 1399 | .modes = &avic_tm070ddh03_mode, |
| 1400 | .num_modes = 1, |
| 1401 | .bpc = 8, |
| 1402 | .size = { |
| 1403 | .width = 154, |
| 1404 | .height = 90, |
| 1405 | }, |
| 1406 | .delay = { |
| 1407 | .prepare = 20, |
| 1408 | .enable = 200, |
| 1409 | .disable = 200, |
| 1410 | }, |
| 1411 | }; |
| 1412 | |
Chen-Yu Tsai | 7ad8b41 | 2018-09-07 12:19:46 +0800 | [diff] [blame] | 1413 | static const struct drm_display_mode bananapi_s070wv20_ct16_mode = { |
| 1414 | .clock = 30000, |
| 1415 | .hdisplay = 800, |
| 1416 | .hsync_start = 800 + 40, |
| 1417 | .hsync_end = 800 + 40 + 48, |
| 1418 | .htotal = 800 + 40 + 48 + 40, |
| 1419 | .vdisplay = 480, |
| 1420 | .vsync_start = 480 + 13, |
| 1421 | .vsync_end = 480 + 13 + 3, |
| 1422 | .vtotal = 480 + 13 + 3 + 29, |
| 1423 | }; |
| 1424 | |
| 1425 | static const struct panel_desc bananapi_s070wv20_ct16 = { |
| 1426 | .modes = &bananapi_s070wv20_ct16_mode, |
| 1427 | .num_modes = 1, |
| 1428 | .bpc = 6, |
| 1429 | .size = { |
| 1430 | .width = 154, |
| 1431 | .height = 86, |
| 1432 | }, |
| 1433 | }; |
| 1434 | |
Andrzej Hajda | ae8cf41 | 2018-06-19 10:19:26 +0200 | [diff] [blame] | 1435 | static const struct drm_display_mode boe_hv070wsa_mode = { |
Andrzej Hajda | e077e2f | 2018-07-25 17:46:43 +0200 | [diff] [blame] | 1436 | .clock = 42105, |
Andrzej Hajda | ae8cf41 | 2018-06-19 10:19:26 +0200 | [diff] [blame] | 1437 | .hdisplay = 1024, |
Andrzej Hajda | e077e2f | 2018-07-25 17:46:43 +0200 | [diff] [blame] | 1438 | .hsync_start = 1024 + 30, |
| 1439 | .hsync_end = 1024 + 30 + 30, |
| 1440 | .htotal = 1024 + 30 + 30 + 30, |
Andrzej Hajda | ae8cf41 | 2018-06-19 10:19:26 +0200 | [diff] [blame] | 1441 | .vdisplay = 600, |
Andrzej Hajda | e077e2f | 2018-07-25 17:46:43 +0200 | [diff] [blame] | 1442 | .vsync_start = 600 + 10, |
| 1443 | .vsync_end = 600 + 10 + 10, |
| 1444 | .vtotal = 600 + 10 + 10 + 10, |
Andrzej Hajda | ae8cf41 | 2018-06-19 10:19:26 +0200 | [diff] [blame] | 1445 | }; |
| 1446 | |
| 1447 | static const struct panel_desc boe_hv070wsa = { |
| 1448 | .modes = &boe_hv070wsa_mode, |
| 1449 | .num_modes = 1, |
Sam Ravnborg | 2a5c2ff | 2020-04-13 20:30:05 +0200 | [diff] [blame] | 1450 | .bpc = 8, |
Andrzej Hajda | ae8cf41 | 2018-06-19 10:19:26 +0200 | [diff] [blame] | 1451 | .size = { |
| 1452 | .width = 154, |
| 1453 | .height = 90, |
| 1454 | }, |
Sam Ravnborg | 2a5c2ff | 2020-04-13 20:30:05 +0200 | [diff] [blame] | 1455 | .bus_format = MEDIA_BUS_FMT_RGB888_1X7X4_SPWG, |
| 1456 | .bus_flags = DRM_BUS_FLAG_DE_HIGH, |
| 1457 | .connector_type = DRM_MODE_CONNECTOR_LVDS, |
Andrzej Hajda | ae8cf41 | 2018-06-19 10:19:26 +0200 | [diff] [blame] | 1458 | }; |
| 1459 | |
Caesar Wang | cac1a41 | 2016-12-14 11:19:56 +0800 | [diff] [blame] | 1460 | static const struct drm_display_mode boe_nv101wxmn51_modes[] = { |
| 1461 | { |
| 1462 | .clock = 71900, |
| 1463 | .hdisplay = 1280, |
| 1464 | .hsync_start = 1280 + 48, |
| 1465 | .hsync_end = 1280 + 48 + 32, |
| 1466 | .htotal = 1280 + 48 + 32 + 80, |
| 1467 | .vdisplay = 800, |
| 1468 | .vsync_start = 800 + 3, |
| 1469 | .vsync_end = 800 + 3 + 5, |
| 1470 | .vtotal = 800 + 3 + 5 + 24, |
Caesar Wang | cac1a41 | 2016-12-14 11:19:56 +0800 | [diff] [blame] | 1471 | }, |
| 1472 | { |
| 1473 | .clock = 57500, |
| 1474 | .hdisplay = 1280, |
| 1475 | .hsync_start = 1280 + 48, |
| 1476 | .hsync_end = 1280 + 48 + 32, |
| 1477 | .htotal = 1280 + 48 + 32 + 80, |
| 1478 | .vdisplay = 800, |
| 1479 | .vsync_start = 800 + 3, |
| 1480 | .vsync_end = 800 + 3 + 5, |
| 1481 | .vtotal = 800 + 3 + 5 + 24, |
Caesar Wang | cac1a41 | 2016-12-14 11:19:56 +0800 | [diff] [blame] | 1482 | }, |
| 1483 | }; |
| 1484 | |
| 1485 | static const struct panel_desc boe_nv101wxmn51 = { |
| 1486 | .modes = boe_nv101wxmn51_modes, |
| 1487 | .num_modes = ARRAY_SIZE(boe_nv101wxmn51_modes), |
| 1488 | .bpc = 8, |
| 1489 | .size = { |
| 1490 | .width = 217, |
| 1491 | .height = 136, |
| 1492 | }, |
| 1493 | .delay = { |
| 1494 | .prepare = 210, |
| 1495 | .enable = 50, |
| 1496 | .unprepare = 160, |
| 1497 | }, |
| 1498 | }; |
| 1499 | |
Douglas Anderson | a96ee0f | 2020-11-09 17:00:58 -0800 | [diff] [blame] | 1500 | static const struct drm_display_mode boe_nv110wtm_n61_modes[] = { |
| 1501 | { |
| 1502 | .clock = 207800, |
| 1503 | .hdisplay = 2160, |
| 1504 | .hsync_start = 2160 + 48, |
| 1505 | .hsync_end = 2160 + 48 + 32, |
| 1506 | .htotal = 2160 + 48 + 32 + 100, |
| 1507 | .vdisplay = 1440, |
| 1508 | .vsync_start = 1440 + 3, |
| 1509 | .vsync_end = 1440 + 3 + 6, |
| 1510 | .vtotal = 1440 + 3 + 6 + 31, |
Douglas Anderson | 9dbf1a4 | 2020-12-01 12:56:11 -0800 | [diff] [blame] | 1511 | .flags = DRM_MODE_FLAG_PHSYNC | DRM_MODE_FLAG_NVSYNC, |
Douglas Anderson | a96ee0f | 2020-11-09 17:00:58 -0800 | [diff] [blame] | 1512 | }, |
| 1513 | { |
| 1514 | .clock = 138500, |
| 1515 | .hdisplay = 2160, |
| 1516 | .hsync_start = 2160 + 48, |
| 1517 | .hsync_end = 2160 + 48 + 32, |
| 1518 | .htotal = 2160 + 48 + 32 + 100, |
| 1519 | .vdisplay = 1440, |
| 1520 | .vsync_start = 1440 + 3, |
| 1521 | .vsync_end = 1440 + 3 + 6, |
| 1522 | .vtotal = 1440 + 3 + 6 + 31, |
Douglas Anderson | 9dbf1a4 | 2020-12-01 12:56:11 -0800 | [diff] [blame] | 1523 | .flags = DRM_MODE_FLAG_PHSYNC | DRM_MODE_FLAG_NVSYNC, |
Douglas Anderson | a96ee0f | 2020-11-09 17:00:58 -0800 | [diff] [blame] | 1524 | }, |
| 1525 | }; |
| 1526 | |
| 1527 | static const struct panel_desc boe_nv110wtm_n61 = { |
| 1528 | .modes = boe_nv110wtm_n61_modes, |
| 1529 | .num_modes = ARRAY_SIZE(boe_nv110wtm_n61_modes), |
| 1530 | .bpc = 8, |
| 1531 | .size = { |
| 1532 | .width = 233, |
| 1533 | .height = 155, |
| 1534 | }, |
| 1535 | .delay = { |
| 1536 | .hpd_absent_delay = 200, |
| 1537 | .prepare_to_enable = 80, |
Douglas Anderson | 67cc24a | 2021-02-22 08:17:24 -0800 | [diff] [blame] | 1538 | .enable = 50, |
Douglas Anderson | a96ee0f | 2020-11-09 17:00:58 -0800 | [diff] [blame] | 1539 | .unprepare = 500, |
| 1540 | }, |
| 1541 | .bus_format = MEDIA_BUS_FMT_RGB888_1X24, |
| 1542 | .bus_flags = DRM_BUS_FLAG_DATA_MSB_TO_LSB, |
| 1543 | .connector_type = DRM_MODE_CONNECTOR_eDP, |
| 1544 | }; |
| 1545 | |
Douglas Anderson | cfe40d0 | 2020-05-08 15:59:02 -0700 | [diff] [blame] | 1546 | /* Also used for boe_nv133fhm_n62 */ |
Bjorn Andersson | b0c664c | 2020-04-20 14:57:42 -0700 | [diff] [blame] | 1547 | static const struct drm_display_mode boe_nv133fhm_n61_modes = { |
| 1548 | .clock = 147840, |
| 1549 | .hdisplay = 1920, |
| 1550 | .hsync_start = 1920 + 48, |
| 1551 | .hsync_end = 1920 + 48 + 32, |
| 1552 | .htotal = 1920 + 48 + 32 + 200, |
| 1553 | .vdisplay = 1080, |
| 1554 | .vsync_start = 1080 + 3, |
| 1555 | .vsync_end = 1080 + 3 + 6, |
| 1556 | .vtotal = 1080 + 3 + 6 + 31, |
Stephen Boyd | ab6fd5d | 2020-11-06 10:23:33 -0800 | [diff] [blame] | 1557 | .flags = DRM_MODE_FLAG_PHSYNC | DRM_MODE_FLAG_NVSYNC, |
Bjorn Andersson | b0c664c | 2020-04-20 14:57:42 -0700 | [diff] [blame] | 1558 | }; |
| 1559 | |
Douglas Anderson | cfe40d0 | 2020-05-08 15:59:02 -0700 | [diff] [blame] | 1560 | /* Also used for boe_nv133fhm_n62 */ |
Bjorn Andersson | b0c664c | 2020-04-20 14:57:42 -0700 | [diff] [blame] | 1561 | static const struct panel_desc boe_nv133fhm_n61 = { |
| 1562 | .modes = &boe_nv133fhm_n61_modes, |
| 1563 | .num_modes = 1, |
Douglas Anderson | 9694d9c | 2020-05-08 15:59:00 -0700 | [diff] [blame] | 1564 | .bpc = 6, |
Bjorn Andersson | b0c664c | 2020-04-20 14:57:42 -0700 | [diff] [blame] | 1565 | .size = { |
Douglas Anderson | 9694d9c | 2020-05-08 15:59:00 -0700 | [diff] [blame] | 1566 | .width = 294, |
| 1567 | .height = 165, |
Bjorn Andersson | b0c664c | 2020-04-20 14:57:42 -0700 | [diff] [blame] | 1568 | }, |
| 1569 | .delay = { |
Douglas Anderson | 667d73d | 2020-07-16 13:21:22 -0700 | [diff] [blame] | 1570 | /* |
| 1571 | * When power is first given to the panel there's a short |
| 1572 | * spike on the HPD line. It was explained that this spike |
| 1573 | * was until the TCON data download was complete. On |
| 1574 | * one system this was measured at 8 ms. We'll put 15 ms |
| 1575 | * in the prepare delay just to be safe and take it away |
| 1576 | * from the hpd_absent_delay (which would otherwise be 200 ms) |
| 1577 | * to handle this. That means: |
| 1578 | * - If HPD isn't hooked up you still have 200 ms delay. |
| 1579 | * - If HPD is hooked up we won't try to look at it for the |
| 1580 | * first 15 ms. |
| 1581 | */ |
| 1582 | .prepare = 15, |
| 1583 | .hpd_absent_delay = 185, |
| 1584 | |
Bjorn Andersson | b0c664c | 2020-04-20 14:57:42 -0700 | [diff] [blame] | 1585 | .unprepare = 500, |
| 1586 | }, |
| 1587 | .bus_format = MEDIA_BUS_FMT_RGB888_1X24, |
| 1588 | .bus_flags = DRM_BUS_FLAG_DATA_MSB_TO_LSB, |
| 1589 | .connector_type = DRM_MODE_CONNECTOR_eDP, |
| 1590 | }; |
| 1591 | |
Tobias Schramm | a511981 | 2020-01-09 12:29:52 +0100 | [diff] [blame] | 1592 | static const struct drm_display_mode boe_nv140fhmn49_modes[] = { |
| 1593 | { |
| 1594 | .clock = 148500, |
| 1595 | .hdisplay = 1920, |
| 1596 | .hsync_start = 1920 + 48, |
| 1597 | .hsync_end = 1920 + 48 + 32, |
| 1598 | .htotal = 2200, |
| 1599 | .vdisplay = 1080, |
| 1600 | .vsync_start = 1080 + 3, |
| 1601 | .vsync_end = 1080 + 3 + 5, |
| 1602 | .vtotal = 1125, |
Tobias Schramm | a511981 | 2020-01-09 12:29:52 +0100 | [diff] [blame] | 1603 | }, |
| 1604 | }; |
| 1605 | |
| 1606 | static const struct panel_desc boe_nv140fhmn49 = { |
| 1607 | .modes = boe_nv140fhmn49_modes, |
| 1608 | .num_modes = ARRAY_SIZE(boe_nv140fhmn49_modes), |
| 1609 | .bpc = 6, |
| 1610 | .size = { |
| 1611 | .width = 309, |
| 1612 | .height = 174, |
| 1613 | }, |
| 1614 | .delay = { |
| 1615 | .prepare = 210, |
| 1616 | .enable = 50, |
| 1617 | .unprepare = 160, |
| 1618 | }, |
| 1619 | .bus_format = MEDIA_BUS_FMT_RGB666_1X18, |
| 1620 | .connector_type = DRM_MODE_CONNECTOR_eDP, |
| 1621 | }; |
| 1622 | |
Giulio Benetti | e58edce | 2018-07-31 01:11:16 +0200 | [diff] [blame] | 1623 | static const struct drm_display_mode cdtech_s043wq26h_ct7_mode = { |
| 1624 | .clock = 9000, |
| 1625 | .hdisplay = 480, |
| 1626 | .hsync_start = 480 + 5, |
| 1627 | .hsync_end = 480 + 5 + 5, |
| 1628 | .htotal = 480 + 5 + 5 + 40, |
| 1629 | .vdisplay = 272, |
| 1630 | .vsync_start = 272 + 8, |
| 1631 | .vsync_end = 272 + 8 + 8, |
| 1632 | .vtotal = 272 + 8 + 8 + 8, |
Giulio Benetti | e58edce | 2018-07-31 01:11:16 +0200 | [diff] [blame] | 1633 | .flags = DRM_MODE_FLAG_NHSYNC | DRM_MODE_FLAG_NVSYNC, |
| 1634 | }; |
| 1635 | |
| 1636 | static const struct panel_desc cdtech_s043wq26h_ct7 = { |
| 1637 | .modes = &cdtech_s043wq26h_ct7_mode, |
| 1638 | .num_modes = 1, |
| 1639 | .bpc = 8, |
| 1640 | .size = { |
| 1641 | .width = 95, |
| 1642 | .height = 54, |
| 1643 | }, |
Laurent Pinchart | 88bc417 | 2018-09-22 15:02:42 +0300 | [diff] [blame] | 1644 | .bus_flags = DRM_BUS_FLAG_PIXDATA_DRIVE_POSEDGE, |
Giulio Benetti | e58edce | 2018-07-31 01:11:16 +0200 | [diff] [blame] | 1645 | }; |
| 1646 | |
Michael Krummsdorf | 0e3b67f | 2020-06-12 09:22:18 +0200 | [diff] [blame] | 1647 | /* S070PWS19HP-FC21 2017/04/22 */ |
| 1648 | static const struct drm_display_mode cdtech_s070pws19hp_fc21_mode = { |
| 1649 | .clock = 51200, |
| 1650 | .hdisplay = 1024, |
| 1651 | .hsync_start = 1024 + 160, |
| 1652 | .hsync_end = 1024 + 160 + 20, |
| 1653 | .htotal = 1024 + 160 + 20 + 140, |
| 1654 | .vdisplay = 600, |
| 1655 | .vsync_start = 600 + 12, |
| 1656 | .vsync_end = 600 + 12 + 3, |
| 1657 | .vtotal = 600 + 12 + 3 + 20, |
| 1658 | .flags = DRM_MODE_FLAG_NHSYNC | DRM_MODE_FLAG_NVSYNC, |
| 1659 | }; |
| 1660 | |
| 1661 | static const struct panel_desc cdtech_s070pws19hp_fc21 = { |
| 1662 | .modes = &cdtech_s070pws19hp_fc21_mode, |
| 1663 | .num_modes = 1, |
| 1664 | .bpc = 6, |
| 1665 | .size = { |
| 1666 | .width = 154, |
| 1667 | .height = 86, |
| 1668 | }, |
| 1669 | .bus_format = MEDIA_BUS_FMT_RGB666_1X18, |
Sam Ravnborg | f5436f7 | 2020-06-30 20:05:43 +0200 | [diff] [blame] | 1670 | .bus_flags = DRM_BUS_FLAG_DE_HIGH | DRM_BUS_FLAG_PIXDATA_SAMPLE_NEGEDGE, |
Michael Krummsdorf | 0e3b67f | 2020-06-12 09:22:18 +0200 | [diff] [blame] | 1671 | .connector_type = DRM_MODE_CONNECTOR_DPI, |
| 1672 | }; |
| 1673 | |
| 1674 | /* S070SWV29HG-DC44 2017/09/21 */ |
| 1675 | static const struct drm_display_mode cdtech_s070swv29hg_dc44_mode = { |
| 1676 | .clock = 33300, |
| 1677 | .hdisplay = 800, |
| 1678 | .hsync_start = 800 + 210, |
| 1679 | .hsync_end = 800 + 210 + 2, |
| 1680 | .htotal = 800 + 210 + 2 + 44, |
| 1681 | .vdisplay = 480, |
| 1682 | .vsync_start = 480 + 22, |
| 1683 | .vsync_end = 480 + 22 + 2, |
| 1684 | .vtotal = 480 + 22 + 2 + 21, |
| 1685 | .flags = DRM_MODE_FLAG_NHSYNC | DRM_MODE_FLAG_NVSYNC, |
| 1686 | }; |
| 1687 | |
| 1688 | static const struct panel_desc cdtech_s070swv29hg_dc44 = { |
| 1689 | .modes = &cdtech_s070swv29hg_dc44_mode, |
| 1690 | .num_modes = 1, |
| 1691 | .bpc = 6, |
| 1692 | .size = { |
| 1693 | .width = 154, |
| 1694 | .height = 86, |
| 1695 | }, |
| 1696 | .bus_format = MEDIA_BUS_FMT_RGB666_1X18, |
Sam Ravnborg | f5436f7 | 2020-06-30 20:05:43 +0200 | [diff] [blame] | 1697 | .bus_flags = DRM_BUS_FLAG_DE_HIGH | DRM_BUS_FLAG_PIXDATA_SAMPLE_NEGEDGE, |
Michael Krummsdorf | 0e3b67f | 2020-06-12 09:22:18 +0200 | [diff] [blame] | 1698 | .connector_type = DRM_MODE_CONNECTOR_DPI, |
| 1699 | }; |
| 1700 | |
Giulio Benetti | 982f944 | 2018-07-31 01:11:14 +0200 | [diff] [blame] | 1701 | static const struct drm_display_mode cdtech_s070wv95_ct16_mode = { |
| 1702 | .clock = 35000, |
| 1703 | .hdisplay = 800, |
| 1704 | .hsync_start = 800 + 40, |
| 1705 | .hsync_end = 800 + 40 + 40, |
| 1706 | .htotal = 800 + 40 + 40 + 48, |
| 1707 | .vdisplay = 480, |
| 1708 | .vsync_start = 480 + 29, |
| 1709 | .vsync_end = 480 + 29 + 13, |
| 1710 | .vtotal = 480 + 29 + 13 + 3, |
Giulio Benetti | 982f944 | 2018-07-31 01:11:14 +0200 | [diff] [blame] | 1711 | .flags = DRM_MODE_FLAG_NHSYNC | DRM_MODE_FLAG_NVSYNC, |
| 1712 | }; |
| 1713 | |
| 1714 | static const struct panel_desc cdtech_s070wv95_ct16 = { |
| 1715 | .modes = &cdtech_s070wv95_ct16_mode, |
| 1716 | .num_modes = 1, |
| 1717 | .bpc = 8, |
| 1718 | .size = { |
| 1719 | .width = 154, |
| 1720 | .height = 85, |
| 1721 | }, |
| 1722 | }; |
| 1723 | |
Marek Vasut | 07c913c | 2020-07-28 22:12:42 +0200 | [diff] [blame] | 1724 | static const struct display_timing chefree_ch101olhlwh_002_timing = { |
| 1725 | .pixelclock = { 68900000, 71100000, 73400000 }, |
| 1726 | .hactive = { 1280, 1280, 1280 }, |
| 1727 | .hfront_porch = { 65, 80, 95 }, |
| 1728 | .hback_porch = { 64, 79, 94 }, |
| 1729 | .hsync_len = { 1, 1, 1 }, |
| 1730 | .vactive = { 800, 800, 800 }, |
| 1731 | .vfront_porch = { 7, 11, 14 }, |
| 1732 | .vback_porch = { 7, 11, 14 }, |
| 1733 | .vsync_len = { 1, 1, 1 }, |
| 1734 | .flags = DISPLAY_FLAGS_DE_HIGH, |
| 1735 | }; |
| 1736 | |
| 1737 | static const struct panel_desc chefree_ch101olhlwh_002 = { |
| 1738 | .timings = &chefree_ch101olhlwh_002_timing, |
| 1739 | .num_timings = 1, |
| 1740 | .bpc = 8, |
| 1741 | .size = { |
| 1742 | .width = 217, |
| 1743 | .height = 135, |
| 1744 | }, |
| 1745 | .delay = { |
| 1746 | .enable = 200, |
| 1747 | .disable = 200, |
| 1748 | }, |
| 1749 | .bus_flags = DRM_BUS_FLAG_DE_HIGH, |
| 1750 | .bus_format = MEDIA_BUS_FMT_RGB888_1X7X4_SPWG, |
| 1751 | .connector_type = DRM_MODE_CONNECTOR_LVDS, |
| 1752 | }; |
| 1753 | |
Randy Li | 2cb35c8 | 2016-09-20 03:02:51 +0800 | [diff] [blame] | 1754 | static const struct drm_display_mode chunghwa_claa070wp03xg_mode = { |
| 1755 | .clock = 66770, |
| 1756 | .hdisplay = 800, |
| 1757 | .hsync_start = 800 + 49, |
| 1758 | .hsync_end = 800 + 49 + 33, |
| 1759 | .htotal = 800 + 49 + 33 + 17, |
| 1760 | .vdisplay = 1280, |
| 1761 | .vsync_start = 1280 + 1, |
| 1762 | .vsync_end = 1280 + 1 + 7, |
| 1763 | .vtotal = 1280 + 1 + 7 + 15, |
Randy Li | 2cb35c8 | 2016-09-20 03:02:51 +0800 | [diff] [blame] | 1764 | .flags = DRM_MODE_FLAG_NVSYNC | DRM_MODE_FLAG_NHSYNC, |
| 1765 | }; |
| 1766 | |
| 1767 | static const struct panel_desc chunghwa_claa070wp03xg = { |
| 1768 | .modes = &chunghwa_claa070wp03xg_mode, |
| 1769 | .num_modes = 1, |
| 1770 | .bpc = 6, |
| 1771 | .size = { |
| 1772 | .width = 94, |
| 1773 | .height = 150, |
| 1774 | }, |
Dmitry Osipenko | 8556082 | 2020-06-22 01:27:42 +0300 | [diff] [blame] | 1775 | .bus_format = MEDIA_BUS_FMT_RGB666_1X7X3_SPWG, |
Laurent Pinchart | c471583 | 2020-06-30 02:33:19 +0300 | [diff] [blame] | 1776 | .bus_flags = DRM_BUS_FLAG_DE_HIGH, |
Dmitry Osipenko | 94f0791 | 2020-06-18 01:27:03 +0300 | [diff] [blame] | 1777 | .connector_type = DRM_MODE_CONNECTOR_LVDS, |
Randy Li | 2cb35c8 | 2016-09-20 03:02:51 +0800 | [diff] [blame] | 1778 | }; |
| 1779 | |
Stephen Warren | 4c93075 | 2014-01-07 16:46:26 -0700 | [diff] [blame] | 1780 | static const struct drm_display_mode chunghwa_claa101wa01a_mode = { |
| 1781 | .clock = 72070, |
| 1782 | .hdisplay = 1366, |
| 1783 | .hsync_start = 1366 + 58, |
| 1784 | .hsync_end = 1366 + 58 + 58, |
| 1785 | .htotal = 1366 + 58 + 58 + 58, |
| 1786 | .vdisplay = 768, |
| 1787 | .vsync_start = 768 + 4, |
| 1788 | .vsync_end = 768 + 4 + 4, |
| 1789 | .vtotal = 768 + 4 + 4 + 4, |
Stephen Warren | 4c93075 | 2014-01-07 16:46:26 -0700 | [diff] [blame] | 1790 | }; |
| 1791 | |
| 1792 | static const struct panel_desc chunghwa_claa101wa01a = { |
| 1793 | .modes = &chunghwa_claa101wa01a_mode, |
| 1794 | .num_modes = 1, |
Stéphane Marchesin | 0208d51 | 2014-06-19 18:18:28 -0700 | [diff] [blame] | 1795 | .bpc = 6, |
Stephen Warren | 4c93075 | 2014-01-07 16:46:26 -0700 | [diff] [blame] | 1796 | .size = { |
| 1797 | .width = 220, |
| 1798 | .height = 120, |
| 1799 | }, |
Dmitry Osipenko | 8556082 | 2020-06-22 01:27:42 +0300 | [diff] [blame] | 1800 | .bus_format = MEDIA_BUS_FMT_RGB666_1X7X3_SPWG, |
Laurent Pinchart | c471583 | 2020-06-30 02:33:19 +0300 | [diff] [blame] | 1801 | .bus_flags = DRM_BUS_FLAG_DE_HIGH, |
Dmitry Osipenko | 94f0791 | 2020-06-18 01:27:03 +0300 | [diff] [blame] | 1802 | .connector_type = DRM_MODE_CONNECTOR_LVDS, |
Stephen Warren | 4c93075 | 2014-01-07 16:46:26 -0700 | [diff] [blame] | 1803 | }; |
| 1804 | |
Thierry Reding | 280921d | 2013-08-30 15:10:14 +0200 | [diff] [blame] | 1805 | static const struct drm_display_mode chunghwa_claa101wb01_mode = { |
| 1806 | .clock = 69300, |
| 1807 | .hdisplay = 1366, |
| 1808 | .hsync_start = 1366 + 48, |
| 1809 | .hsync_end = 1366 + 48 + 32, |
| 1810 | .htotal = 1366 + 48 + 32 + 20, |
| 1811 | .vdisplay = 768, |
| 1812 | .vsync_start = 768 + 16, |
| 1813 | .vsync_end = 768 + 16 + 8, |
| 1814 | .vtotal = 768 + 16 + 8 + 16, |
Thierry Reding | 280921d | 2013-08-30 15:10:14 +0200 | [diff] [blame] | 1815 | }; |
| 1816 | |
| 1817 | static const struct panel_desc chunghwa_claa101wb01 = { |
| 1818 | .modes = &chunghwa_claa101wb01_mode, |
| 1819 | .num_modes = 1, |
Stéphane Marchesin | 0208d51 | 2014-06-19 18:18:28 -0700 | [diff] [blame] | 1820 | .bpc = 6, |
Thierry Reding | 280921d | 2013-08-30 15:10:14 +0200 | [diff] [blame] | 1821 | .size = { |
| 1822 | .width = 223, |
| 1823 | .height = 125, |
| 1824 | }, |
Dmitry Osipenko | 8556082 | 2020-06-22 01:27:42 +0300 | [diff] [blame] | 1825 | .bus_format = MEDIA_BUS_FMT_RGB666_1X7X3_SPWG, |
Laurent Pinchart | c471583 | 2020-06-30 02:33:19 +0300 | [diff] [blame] | 1826 | .bus_flags = DRM_BUS_FLAG_DE_HIGH, |
Dmitry Osipenko | 94f0791 | 2020-06-18 01:27:03 +0300 | [diff] [blame] | 1827 | .connector_type = DRM_MODE_CONNECTOR_LVDS, |
Thierry Reding | 280921d | 2013-08-30 15:10:14 +0200 | [diff] [blame] | 1828 | }; |
| 1829 | |
Michal Vokáč | 97ceb1f | 2018-06-25 14:41:30 +0200 | [diff] [blame] | 1830 | static const struct drm_display_mode dataimage_scf0700c48ggu18_mode = { |
| 1831 | .clock = 33260, |
| 1832 | .hdisplay = 800, |
| 1833 | .hsync_start = 800 + 40, |
| 1834 | .hsync_end = 800 + 40 + 128, |
| 1835 | .htotal = 800 + 40 + 128 + 88, |
| 1836 | .vdisplay = 480, |
| 1837 | .vsync_start = 480 + 10, |
| 1838 | .vsync_end = 480 + 10 + 2, |
| 1839 | .vtotal = 480 + 10 + 2 + 33, |
Michal Vokáč | 97ceb1f | 2018-06-25 14:41:30 +0200 | [diff] [blame] | 1840 | .flags = DRM_MODE_FLAG_NVSYNC | DRM_MODE_FLAG_NHSYNC, |
| 1841 | }; |
| 1842 | |
| 1843 | static const struct panel_desc dataimage_scf0700c48ggu18 = { |
| 1844 | .modes = &dataimage_scf0700c48ggu18_mode, |
| 1845 | .num_modes = 1, |
| 1846 | .bpc = 8, |
| 1847 | .size = { |
| 1848 | .width = 152, |
| 1849 | .height = 91, |
| 1850 | }, |
| 1851 | .bus_format = MEDIA_BUS_FMT_RGB888_1X24, |
Laurent Pinchart | 88bc417 | 2018-09-22 15:02:42 +0300 | [diff] [blame] | 1852 | .bus_flags = DRM_BUS_FLAG_DE_HIGH | DRM_BUS_FLAG_PIXDATA_DRIVE_POSEDGE, |
Michal Vokáč | 97ceb1f | 2018-06-25 14:41:30 +0200 | [diff] [blame] | 1853 | }; |
| 1854 | |
Philipp Zabel | 0ca0c82 | 2018-05-23 11:25:04 +0200 | [diff] [blame] | 1855 | static const struct display_timing dlc_dlc0700yzg_1_timing = { |
| 1856 | .pixelclock = { 45000000, 51200000, 57000000 }, |
| 1857 | .hactive = { 1024, 1024, 1024 }, |
| 1858 | .hfront_porch = { 100, 106, 113 }, |
| 1859 | .hback_porch = { 100, 106, 113 }, |
| 1860 | .hsync_len = { 100, 108, 114 }, |
| 1861 | .vactive = { 600, 600, 600 }, |
| 1862 | .vfront_porch = { 8, 11, 15 }, |
| 1863 | .vback_porch = { 8, 11, 15 }, |
| 1864 | .vsync_len = { 9, 13, 15 }, |
| 1865 | .flags = DISPLAY_FLAGS_DE_HIGH, |
| 1866 | }; |
| 1867 | |
| 1868 | static const struct panel_desc dlc_dlc0700yzg_1 = { |
| 1869 | .timings = &dlc_dlc0700yzg_1_timing, |
| 1870 | .num_timings = 1, |
| 1871 | .bpc = 6, |
| 1872 | .size = { |
| 1873 | .width = 154, |
| 1874 | .height = 86, |
| 1875 | }, |
| 1876 | .delay = { |
| 1877 | .prepare = 30, |
| 1878 | .enable = 200, |
| 1879 | .disable = 200, |
| 1880 | }, |
| 1881 | .bus_format = MEDIA_BUS_FMT_RGB666_1X7X3_SPWG, |
Laurent Pinchart | 9a2654c | 2019-09-04 16:28:03 +0300 | [diff] [blame] | 1882 | .connector_type = DRM_MODE_CONNECTOR_LVDS, |
Philipp Zabel | 0ca0c82 | 2018-05-23 11:25:04 +0200 | [diff] [blame] | 1883 | }; |
| 1884 | |
Marco Felsch | 6cbe7cd | 2018-09-24 17:26:10 +0200 | [diff] [blame] | 1885 | static const struct display_timing dlc_dlc1010gig_timing = { |
| 1886 | .pixelclock = { 68900000, 71100000, 73400000 }, |
| 1887 | .hactive = { 1280, 1280, 1280 }, |
| 1888 | .hfront_porch = { 43, 53, 63 }, |
| 1889 | .hback_porch = { 43, 53, 63 }, |
| 1890 | .hsync_len = { 44, 54, 64 }, |
| 1891 | .vactive = { 800, 800, 800 }, |
| 1892 | .vfront_porch = { 5, 8, 11 }, |
| 1893 | .vback_porch = { 5, 8, 11 }, |
| 1894 | .vsync_len = { 5, 7, 11 }, |
| 1895 | .flags = DISPLAY_FLAGS_DE_HIGH, |
| 1896 | }; |
| 1897 | |
| 1898 | static const struct panel_desc dlc_dlc1010gig = { |
| 1899 | .timings = &dlc_dlc1010gig_timing, |
| 1900 | .num_timings = 1, |
| 1901 | .bpc = 8, |
| 1902 | .size = { |
| 1903 | .width = 216, |
| 1904 | .height = 135, |
| 1905 | }, |
| 1906 | .delay = { |
| 1907 | .prepare = 60, |
| 1908 | .enable = 150, |
| 1909 | .disable = 100, |
| 1910 | .unprepare = 60, |
| 1911 | }, |
| 1912 | .bus_format = MEDIA_BUS_FMT_RGB888_1X7X4_SPWG, |
Laurent Pinchart | 9a2654c | 2019-09-04 16:28:03 +0300 | [diff] [blame] | 1913 | .connector_type = DRM_MODE_CONNECTOR_LVDS, |
Marco Felsch | 6cbe7cd | 2018-09-24 17:26:10 +0200 | [diff] [blame] | 1914 | }; |
| 1915 | |
Andreas Pretzsch | c2d24af | 2019-04-16 12:16:30 +0200 | [diff] [blame] | 1916 | static const struct drm_display_mode edt_et035012dm6_mode = { |
| 1917 | .clock = 6500, |
| 1918 | .hdisplay = 320, |
| 1919 | .hsync_start = 320 + 20, |
| 1920 | .hsync_end = 320 + 20 + 30, |
| 1921 | .htotal = 320 + 20 + 68, |
| 1922 | .vdisplay = 240, |
| 1923 | .vsync_start = 240 + 4, |
| 1924 | .vsync_end = 240 + 4 + 4, |
| 1925 | .vtotal = 240 + 4 + 4 + 14, |
Andreas Pretzsch | c2d24af | 2019-04-16 12:16:30 +0200 | [diff] [blame] | 1926 | .flags = DRM_MODE_FLAG_NVSYNC | DRM_MODE_FLAG_NHSYNC, |
| 1927 | }; |
| 1928 | |
| 1929 | static const struct panel_desc edt_et035012dm6 = { |
| 1930 | .modes = &edt_et035012dm6_mode, |
| 1931 | .num_modes = 1, |
| 1932 | .bpc = 8, |
| 1933 | .size = { |
| 1934 | .width = 70, |
| 1935 | .height = 52, |
| 1936 | }, |
| 1937 | .bus_format = MEDIA_BUS_FMT_RGB888_1X24, |
Sam Ravnborg | f5436f7 | 2020-06-30 20:05:43 +0200 | [diff] [blame] | 1938 | .bus_flags = DRM_BUS_FLAG_DE_LOW | DRM_BUS_FLAG_PIXDATA_SAMPLE_POSEDGE, |
Andreas Pretzsch | c2d24af | 2019-04-16 12:16:30 +0200 | [diff] [blame] | 1939 | }; |
| 1940 | |
Marian-Cristian Rotariu | 82d57a5 | 2020-01-30 12:08:38 +0000 | [diff] [blame] | 1941 | static const struct drm_display_mode edt_etm043080dh6gp_mode = { |
| 1942 | .clock = 10870, |
| 1943 | .hdisplay = 480, |
| 1944 | .hsync_start = 480 + 8, |
| 1945 | .hsync_end = 480 + 8 + 4, |
| 1946 | .htotal = 480 + 8 + 4 + 41, |
| 1947 | |
| 1948 | /* |
| 1949 | * IWG22M: Y resolution changed for "dc_linuxfb" module crashing while |
| 1950 | * fb_align |
| 1951 | */ |
| 1952 | |
| 1953 | .vdisplay = 288, |
| 1954 | .vsync_start = 288 + 2, |
| 1955 | .vsync_end = 288 + 2 + 4, |
| 1956 | .vtotal = 288 + 2 + 4 + 10, |
Marian-Cristian Rotariu | 82d57a5 | 2020-01-30 12:08:38 +0000 | [diff] [blame] | 1957 | }; |
| 1958 | |
| 1959 | static const struct panel_desc edt_etm043080dh6gp = { |
| 1960 | .modes = &edt_etm043080dh6gp_mode, |
| 1961 | .num_modes = 1, |
| 1962 | .bpc = 8, |
| 1963 | .size = { |
| 1964 | .width = 100, |
| 1965 | .height = 65, |
| 1966 | }, |
| 1967 | .bus_format = MEDIA_BUS_FMT_RGB666_1X18, |
| 1968 | .connector_type = DRM_MODE_CONNECTOR_DPI, |
| 1969 | }; |
| 1970 | |
Marek Vasut | fd819bf | 2019-02-19 15:04:38 +0100 | [diff] [blame] | 1971 | static const struct drm_display_mode edt_etm0430g0dh6_mode = { |
| 1972 | .clock = 9000, |
| 1973 | .hdisplay = 480, |
| 1974 | .hsync_start = 480 + 2, |
| 1975 | .hsync_end = 480 + 2 + 41, |
| 1976 | .htotal = 480 + 2 + 41 + 2, |
| 1977 | .vdisplay = 272, |
| 1978 | .vsync_start = 272 + 2, |
| 1979 | .vsync_end = 272 + 2 + 10, |
| 1980 | .vtotal = 272 + 2 + 10 + 2, |
Marek Vasut | fd819bf | 2019-02-19 15:04:38 +0100 | [diff] [blame] | 1981 | .flags = DRM_MODE_FLAG_NHSYNC | DRM_MODE_FLAG_NVSYNC, |
| 1982 | }; |
| 1983 | |
| 1984 | static const struct panel_desc edt_etm0430g0dh6 = { |
| 1985 | .modes = &edt_etm0430g0dh6_mode, |
| 1986 | .num_modes = 1, |
| 1987 | .bpc = 6, |
| 1988 | .size = { |
| 1989 | .width = 95, |
| 1990 | .height = 54, |
| 1991 | }, |
Stefan Riedmueller | 4824a5f | 2021-06-21 17:09:30 +0200 | [diff] [blame^] | 1992 | .bus_format = MEDIA_BUS_FMT_RGB666_1X18, |
| 1993 | .bus_flags = DRM_BUS_FLAG_DE_HIGH | DRM_BUS_FLAG_PIXDATA_SAMPLE_POSEDGE, |
Stefan Riedmueller | d112e10 | 2021-06-21 17:09:29 +0200 | [diff] [blame] | 1994 | .connector_type = DRM_MODE_CONNECTOR_DPI, |
Marek Vasut | fd819bf | 2019-02-19 15:04:38 +0100 | [diff] [blame] | 1995 | }; |
| 1996 | |
Stefan Agner | 26ab006 | 2014-05-15 11:38:45 +0200 | [diff] [blame] | 1997 | static const struct drm_display_mode edt_et057090dhu_mode = { |
| 1998 | .clock = 25175, |
| 1999 | .hdisplay = 640, |
| 2000 | .hsync_start = 640 + 16, |
| 2001 | .hsync_end = 640 + 16 + 30, |
| 2002 | .htotal = 640 + 16 + 30 + 114, |
| 2003 | .vdisplay = 480, |
| 2004 | .vsync_start = 480 + 10, |
| 2005 | .vsync_end = 480 + 10 + 3, |
| 2006 | .vtotal = 480 + 10 + 3 + 32, |
Stefan Agner | 26ab006 | 2014-05-15 11:38:45 +0200 | [diff] [blame] | 2007 | .flags = DRM_MODE_FLAG_NVSYNC | DRM_MODE_FLAG_NHSYNC, |
| 2008 | }; |
| 2009 | |
| 2010 | static const struct panel_desc edt_et057090dhu = { |
| 2011 | .modes = &edt_et057090dhu_mode, |
| 2012 | .num_modes = 1, |
Stéphane Marchesin | 0208d51 | 2014-06-19 18:18:28 -0700 | [diff] [blame] | 2013 | .bpc = 6, |
Stefan Agner | 26ab006 | 2014-05-15 11:38:45 +0200 | [diff] [blame] | 2014 | .size = { |
| 2015 | .width = 115, |
| 2016 | .height = 86, |
| 2017 | }, |
Stefan Agner | eaeebff | 2016-12-08 14:54:31 -0800 | [diff] [blame] | 2018 | .bus_format = MEDIA_BUS_FMT_RGB666_1X18, |
Laurent Pinchart | 88bc417 | 2018-09-22 15:02:42 +0300 | [diff] [blame] | 2019 | .bus_flags = DRM_BUS_FLAG_DE_HIGH | DRM_BUS_FLAG_PIXDATA_DRIVE_NEGEDGE, |
Dmitry Osipenko | 75e7322 | 2020-06-22 01:27:41 +0300 | [diff] [blame] | 2020 | .connector_type = DRM_MODE_CONNECTOR_DPI, |
Stefan Agner | 26ab006 | 2014-05-15 11:38:45 +0200 | [diff] [blame] | 2021 | }; |
| 2022 | |
Philipp Zabel | fff5de4 | 2014-05-15 12:25:47 +0200 | [diff] [blame] | 2023 | static const struct drm_display_mode edt_etm0700g0dh6_mode = { |
| 2024 | .clock = 33260, |
| 2025 | .hdisplay = 800, |
| 2026 | .hsync_start = 800 + 40, |
| 2027 | .hsync_end = 800 + 40 + 128, |
| 2028 | .htotal = 800 + 40 + 128 + 88, |
| 2029 | .vdisplay = 480, |
| 2030 | .vsync_start = 480 + 10, |
| 2031 | .vsync_end = 480 + 10 + 2, |
| 2032 | .vtotal = 480 + 10 + 2 + 33, |
Philipp Zabel | fff5de4 | 2014-05-15 12:25:47 +0200 | [diff] [blame] | 2033 | .flags = DRM_MODE_FLAG_NHSYNC | DRM_MODE_FLAG_NVSYNC, |
| 2034 | }; |
| 2035 | |
| 2036 | static const struct panel_desc edt_etm0700g0dh6 = { |
| 2037 | .modes = &edt_etm0700g0dh6_mode, |
| 2038 | .num_modes = 1, |
Stéphane Marchesin | 0208d51 | 2014-06-19 18:18:28 -0700 | [diff] [blame] | 2039 | .bpc = 6, |
Philipp Zabel | fff5de4 | 2014-05-15 12:25:47 +0200 | [diff] [blame] | 2040 | .size = { |
| 2041 | .width = 152, |
| 2042 | .height = 91, |
| 2043 | }, |
Stefan Agner | eaeebff | 2016-12-08 14:54:31 -0800 | [diff] [blame] | 2044 | .bus_format = MEDIA_BUS_FMT_RGB666_1X18, |
Laurent Pinchart | 88bc417 | 2018-09-22 15:02:42 +0300 | [diff] [blame] | 2045 | .bus_flags = DRM_BUS_FLAG_DE_HIGH | DRM_BUS_FLAG_PIXDATA_DRIVE_NEGEDGE, |
Biju Das | 281edb9 | 2020-10-20 10:49:10 +0100 | [diff] [blame] | 2046 | .connector_type = DRM_MODE_CONNECTOR_DPI, |
Philipp Zabel | fff5de4 | 2014-05-15 12:25:47 +0200 | [diff] [blame] | 2047 | }; |
| 2048 | |
Jan Tuerk | aa7e645 | 2018-06-19 11:55:44 +0200 | [diff] [blame] | 2049 | static const struct panel_desc edt_etm0700g0bdh6 = { |
| 2050 | .modes = &edt_etm0700g0dh6_mode, |
| 2051 | .num_modes = 1, |
| 2052 | .bpc = 6, |
| 2053 | .size = { |
| 2054 | .width = 152, |
| 2055 | .height = 91, |
| 2056 | }, |
| 2057 | .bus_format = MEDIA_BUS_FMT_RGB666_1X18, |
Laurent Pinchart | 88bc417 | 2018-09-22 15:02:42 +0300 | [diff] [blame] | 2058 | .bus_flags = DRM_BUS_FLAG_DE_HIGH | DRM_BUS_FLAG_PIXDATA_DRIVE_POSEDGE, |
Stefan Riedmueller | d112e10 | 2021-06-21 17:09:29 +0200 | [diff] [blame] | 2059 | .connector_type = DRM_MODE_CONNECTOR_DPI, |
Jan Tuerk | aa7e645 | 2018-06-19 11:55:44 +0200 | [diff] [blame] | 2060 | }; |
| 2061 | |
Marco Felsch | 9158e3c | 2019-04-16 12:06:45 +0200 | [diff] [blame] | 2062 | static const struct display_timing evervision_vgg804821_timing = { |
| 2063 | .pixelclock = { 27600000, 33300000, 50000000 }, |
| 2064 | .hactive = { 800, 800, 800 }, |
| 2065 | .hfront_porch = { 40, 66, 70 }, |
| 2066 | .hback_porch = { 40, 67, 70 }, |
| 2067 | .hsync_len = { 40, 67, 70 }, |
| 2068 | .vactive = { 480, 480, 480 }, |
| 2069 | .vfront_porch = { 6, 10, 10 }, |
| 2070 | .vback_porch = { 7, 11, 11 }, |
| 2071 | .vsync_len = { 7, 11, 11 }, |
| 2072 | .flags = DISPLAY_FLAGS_HSYNC_HIGH | DISPLAY_FLAGS_VSYNC_HIGH | |
| 2073 | DISPLAY_FLAGS_DE_HIGH | DISPLAY_FLAGS_PIXDATA_NEGEDGE | |
| 2074 | DISPLAY_FLAGS_SYNC_NEGEDGE, |
| 2075 | }; |
| 2076 | |
| 2077 | static const struct panel_desc evervision_vgg804821 = { |
| 2078 | .timings = &evervision_vgg804821_timing, |
| 2079 | .num_timings = 1, |
| 2080 | .bpc = 8, |
| 2081 | .size = { |
| 2082 | .width = 108, |
| 2083 | .height = 64, |
| 2084 | }, |
| 2085 | .bus_format = MEDIA_BUS_FMT_RGB888_1X24, |
Sam Ravnborg | f5436f7 | 2020-06-30 20:05:43 +0200 | [diff] [blame] | 2086 | .bus_flags = DRM_BUS_FLAG_DE_HIGH | DRM_BUS_FLAG_PIXDATA_SAMPLE_POSEDGE, |
Marco Felsch | 9158e3c | 2019-04-16 12:06:45 +0200 | [diff] [blame] | 2087 | }; |
| 2088 | |
Boris BREZILLON | 102932b | 2014-06-05 15:53:32 +0200 | [diff] [blame] | 2089 | static const struct drm_display_mode foxlink_fl500wvr00_a0t_mode = { |
| 2090 | .clock = 32260, |
| 2091 | .hdisplay = 800, |
| 2092 | .hsync_start = 800 + 168, |
| 2093 | .hsync_end = 800 + 168 + 64, |
| 2094 | .htotal = 800 + 168 + 64 + 88, |
| 2095 | .vdisplay = 480, |
| 2096 | .vsync_start = 480 + 37, |
| 2097 | .vsync_end = 480 + 37 + 2, |
| 2098 | .vtotal = 480 + 37 + 2 + 8, |
Boris BREZILLON | 102932b | 2014-06-05 15:53:32 +0200 | [diff] [blame] | 2099 | }; |
| 2100 | |
| 2101 | static const struct panel_desc foxlink_fl500wvr00_a0t = { |
| 2102 | .modes = &foxlink_fl500wvr00_a0t_mode, |
| 2103 | .num_modes = 1, |
Thierry Reding | d7a839c | 2014-11-06 10:11:01 +0100 | [diff] [blame] | 2104 | .bpc = 8, |
Boris BREZILLON | 102932b | 2014-06-05 15:53:32 +0200 | [diff] [blame] | 2105 | .size = { |
| 2106 | .width = 108, |
| 2107 | .height = 65, |
| 2108 | }, |
Boris Brezillon | bb276cb | 2014-07-22 13:35:47 +0200 | [diff] [blame] | 2109 | .bus_format = MEDIA_BUS_FMT_RGB888_1X24, |
Boris BREZILLON | 102932b | 2014-06-05 15:53:32 +0200 | [diff] [blame] | 2110 | }; |
| 2111 | |
Paul Cercueil | 795db2a | 2020-07-16 14:56:47 +0200 | [diff] [blame] | 2112 | static const struct drm_display_mode frida_frd350h54004_modes[] = { |
| 2113 | { /* 60 Hz */ |
| 2114 | .clock = 6000, |
| 2115 | .hdisplay = 320, |
| 2116 | .hsync_start = 320 + 44, |
| 2117 | .hsync_end = 320 + 44 + 16, |
| 2118 | .htotal = 320 + 44 + 16 + 20, |
| 2119 | .vdisplay = 240, |
| 2120 | .vsync_start = 240 + 2, |
| 2121 | .vsync_end = 240 + 2 + 6, |
| 2122 | .vtotal = 240 + 2 + 6 + 2, |
| 2123 | .flags = DRM_MODE_FLAG_NHSYNC | DRM_MODE_FLAG_NVSYNC, |
| 2124 | }, |
| 2125 | { /* 50 Hz */ |
| 2126 | .clock = 5400, |
| 2127 | .hdisplay = 320, |
| 2128 | .hsync_start = 320 + 56, |
| 2129 | .hsync_end = 320 + 56 + 16, |
| 2130 | .htotal = 320 + 56 + 16 + 40, |
| 2131 | .vdisplay = 240, |
| 2132 | .vsync_start = 240 + 2, |
| 2133 | .vsync_end = 240 + 2 + 6, |
| 2134 | .vtotal = 240 + 2 + 6 + 2, |
| 2135 | .flags = DRM_MODE_FLAG_NHSYNC | DRM_MODE_FLAG_NVSYNC, |
| 2136 | }, |
Paul Cercueil | 7b6bd84 | 2020-01-13 13:17:41 -0300 | [diff] [blame] | 2137 | }; |
| 2138 | |
| 2139 | static const struct panel_desc frida_frd350h54004 = { |
Paul Cercueil | 795db2a | 2020-07-16 14:56:47 +0200 | [diff] [blame] | 2140 | .modes = frida_frd350h54004_modes, |
| 2141 | .num_modes = ARRAY_SIZE(frida_frd350h54004_modes), |
Paul Cercueil | 7b6bd84 | 2020-01-13 13:17:41 -0300 | [diff] [blame] | 2142 | .bpc = 8, |
| 2143 | .size = { |
| 2144 | .width = 77, |
| 2145 | .height = 64, |
| 2146 | }, |
| 2147 | .bus_format = MEDIA_BUS_FMT_RGB888_1X24, |
Sam Ravnborg | f5436f7 | 2020-06-30 20:05:43 +0200 | [diff] [blame] | 2148 | .bus_flags = DRM_BUS_FLAG_DE_HIGH | DRM_BUS_FLAG_PIXDATA_SAMPLE_NEGEDGE, |
Paul Cercueil | 7b6bd84 | 2020-01-13 13:17:41 -0300 | [diff] [blame] | 2149 | .connector_type = DRM_MODE_CONNECTOR_DPI, |
| 2150 | }; |
| 2151 | |
Jagan Teki | 3be2071 | 2019-05-07 18:37:07 +0530 | [diff] [blame] | 2152 | static const struct drm_display_mode friendlyarm_hd702e_mode = { |
| 2153 | .clock = 67185, |
| 2154 | .hdisplay = 800, |
| 2155 | .hsync_start = 800 + 20, |
| 2156 | .hsync_end = 800 + 20 + 24, |
| 2157 | .htotal = 800 + 20 + 24 + 20, |
| 2158 | .vdisplay = 1280, |
| 2159 | .vsync_start = 1280 + 4, |
| 2160 | .vsync_end = 1280 + 4 + 8, |
| 2161 | .vtotal = 1280 + 4 + 8 + 4, |
Jagan Teki | 3be2071 | 2019-05-07 18:37:07 +0530 | [diff] [blame] | 2162 | .flags = DRM_MODE_FLAG_NVSYNC | DRM_MODE_FLAG_NHSYNC, |
| 2163 | }; |
| 2164 | |
| 2165 | static const struct panel_desc friendlyarm_hd702e = { |
| 2166 | .modes = &friendlyarm_hd702e_mode, |
| 2167 | .num_modes = 1, |
| 2168 | .size = { |
| 2169 | .width = 94, |
| 2170 | .height = 151, |
| 2171 | }, |
| 2172 | }; |
| 2173 | |
Philipp Zabel | d435a2a | 2014-11-19 10:29:55 +0100 | [diff] [blame] | 2174 | static const struct drm_display_mode giantplus_gpg482739qs5_mode = { |
| 2175 | .clock = 9000, |
| 2176 | .hdisplay = 480, |
| 2177 | .hsync_start = 480 + 5, |
| 2178 | .hsync_end = 480 + 5 + 1, |
| 2179 | .htotal = 480 + 5 + 1 + 40, |
| 2180 | .vdisplay = 272, |
| 2181 | .vsync_start = 272 + 8, |
| 2182 | .vsync_end = 272 + 8 + 1, |
| 2183 | .vtotal = 272 + 8 + 1 + 8, |
Philipp Zabel | d435a2a | 2014-11-19 10:29:55 +0100 | [diff] [blame] | 2184 | }; |
| 2185 | |
| 2186 | static const struct panel_desc giantplus_gpg482739qs5 = { |
| 2187 | .modes = &giantplus_gpg482739qs5_mode, |
| 2188 | .num_modes = 1, |
| 2189 | .bpc = 8, |
| 2190 | .size = { |
| 2191 | .width = 95, |
| 2192 | .height = 54, |
| 2193 | }, |
Philipp Zabel | 33536a0 | 2015-02-11 18:50:07 +0100 | [diff] [blame] | 2194 | .bus_format = MEDIA_BUS_FMT_RGB888_1X24, |
Philipp Zabel | d435a2a | 2014-11-19 10:29:55 +0100 | [diff] [blame] | 2195 | }; |
| 2196 | |
Paul Cercueil | 2c6574a | 2019-06-06 00:22:47 +0200 | [diff] [blame] | 2197 | static const struct display_timing giantplus_gpm940b0_timing = { |
| 2198 | .pixelclock = { 13500000, 27000000, 27500000 }, |
| 2199 | .hactive = { 320, 320, 320 }, |
| 2200 | .hfront_porch = { 14, 686, 718 }, |
| 2201 | .hback_porch = { 50, 70, 255 }, |
| 2202 | .hsync_len = { 1, 1, 1 }, |
| 2203 | .vactive = { 240, 240, 240 }, |
| 2204 | .vfront_porch = { 1, 1, 179 }, |
| 2205 | .vback_porch = { 1, 21, 31 }, |
| 2206 | .vsync_len = { 1, 1, 6 }, |
| 2207 | .flags = DISPLAY_FLAGS_HSYNC_LOW | DISPLAY_FLAGS_VSYNC_LOW, |
| 2208 | }; |
| 2209 | |
| 2210 | static const struct panel_desc giantplus_gpm940b0 = { |
| 2211 | .timings = &giantplus_gpm940b0_timing, |
| 2212 | .num_timings = 1, |
| 2213 | .bpc = 8, |
| 2214 | .size = { |
| 2215 | .width = 60, |
| 2216 | .height = 45, |
| 2217 | }, |
| 2218 | .bus_format = MEDIA_BUS_FMT_RGB888_3X8, |
Sam Ravnborg | f5436f7 | 2020-06-30 20:05:43 +0200 | [diff] [blame] | 2219 | .bus_flags = DRM_BUS_FLAG_DE_HIGH | DRM_BUS_FLAG_PIXDATA_SAMPLE_POSEDGE, |
Paul Cercueil | 2c6574a | 2019-06-06 00:22:47 +0200 | [diff] [blame] | 2220 | }; |
| 2221 | |
Philipp Zabel | ab07725 | 2014-12-11 18:32:46 +0100 | [diff] [blame] | 2222 | static const struct display_timing hannstar_hsd070pww1_timing = { |
| 2223 | .pixelclock = { 64300000, 71100000, 82000000 }, |
| 2224 | .hactive = { 1280, 1280, 1280 }, |
| 2225 | .hfront_porch = { 1, 1, 10 }, |
| 2226 | .hback_porch = { 1, 1, 10 }, |
Philipp Zabel | d901d2b | 2015-08-12 12:32:13 +0200 | [diff] [blame] | 2227 | /* |
| 2228 | * According to the data sheet, the minimum horizontal blanking interval |
| 2229 | * is 54 clocks (1 + 52 + 1), but tests with a Nitrogen6X have shown the |
| 2230 | * minimum working horizontal blanking interval to be 60 clocks. |
| 2231 | */ |
| 2232 | .hsync_len = { 58, 158, 661 }, |
Philipp Zabel | ab07725 | 2014-12-11 18:32:46 +0100 | [diff] [blame] | 2233 | .vactive = { 800, 800, 800 }, |
| 2234 | .vfront_porch = { 1, 1, 10 }, |
| 2235 | .vback_porch = { 1, 1, 10 }, |
| 2236 | .vsync_len = { 1, 21, 203 }, |
| 2237 | .flags = DISPLAY_FLAGS_DE_HIGH, |
Philipp Zabel | a853205 | 2014-10-23 16:31:06 +0200 | [diff] [blame] | 2238 | }; |
| 2239 | |
| 2240 | static const struct panel_desc hannstar_hsd070pww1 = { |
Philipp Zabel | ab07725 | 2014-12-11 18:32:46 +0100 | [diff] [blame] | 2241 | .timings = &hannstar_hsd070pww1_timing, |
| 2242 | .num_timings = 1, |
Philipp Zabel | a853205 | 2014-10-23 16:31:06 +0200 | [diff] [blame] | 2243 | .bpc = 6, |
| 2244 | .size = { |
| 2245 | .width = 151, |
| 2246 | .height = 94, |
| 2247 | }, |
Philipp Zabel | 58d6a7b | 2015-08-12 12:32:12 +0200 | [diff] [blame] | 2248 | .bus_format = MEDIA_BUS_FMT_RGB666_1X7X3_SPWG, |
Laurent Pinchart | 9a2654c | 2019-09-04 16:28:03 +0300 | [diff] [blame] | 2249 | .connector_type = DRM_MODE_CONNECTOR_LVDS, |
Philipp Zabel | a853205 | 2014-10-23 16:31:06 +0200 | [diff] [blame] | 2250 | }; |
| 2251 | |
Eric Nelson | c0d607e | 2015-04-13 15:09:26 -0700 | [diff] [blame] | 2252 | static const struct display_timing hannstar_hsd100pxn1_timing = { |
| 2253 | .pixelclock = { 55000000, 65000000, 75000000 }, |
| 2254 | .hactive = { 1024, 1024, 1024 }, |
| 2255 | .hfront_porch = { 40, 40, 40 }, |
| 2256 | .hback_porch = { 220, 220, 220 }, |
| 2257 | .hsync_len = { 20, 60, 100 }, |
| 2258 | .vactive = { 768, 768, 768 }, |
| 2259 | .vfront_porch = { 7, 7, 7 }, |
| 2260 | .vback_porch = { 21, 21, 21 }, |
| 2261 | .vsync_len = { 10, 10, 10 }, |
| 2262 | .flags = DISPLAY_FLAGS_DE_HIGH, |
| 2263 | }; |
| 2264 | |
| 2265 | static const struct panel_desc hannstar_hsd100pxn1 = { |
| 2266 | .timings = &hannstar_hsd100pxn1_timing, |
| 2267 | .num_timings = 1, |
| 2268 | .bpc = 6, |
| 2269 | .size = { |
| 2270 | .width = 203, |
| 2271 | .height = 152, |
| 2272 | }, |
Philipp Zabel | 4946b04 | 2015-05-20 11:34:08 +0200 | [diff] [blame] | 2273 | .bus_format = MEDIA_BUS_FMT_RGB666_1X7X3_SPWG, |
Laurent Pinchart | 9a2654c | 2019-09-04 16:28:03 +0300 | [diff] [blame] | 2274 | .connector_type = DRM_MODE_CONNECTOR_LVDS, |
Eric Nelson | c0d607e | 2015-04-13 15:09:26 -0700 | [diff] [blame] | 2275 | }; |
| 2276 | |
Lucas Stach | 61ac0bf | 2014-11-06 17:44:35 +0100 | [diff] [blame] | 2277 | static const struct drm_display_mode hitachi_tx23d38vm0caa_mode = { |
| 2278 | .clock = 33333, |
| 2279 | .hdisplay = 800, |
| 2280 | .hsync_start = 800 + 85, |
| 2281 | .hsync_end = 800 + 85 + 86, |
| 2282 | .htotal = 800 + 85 + 86 + 85, |
| 2283 | .vdisplay = 480, |
| 2284 | .vsync_start = 480 + 16, |
| 2285 | .vsync_end = 480 + 16 + 13, |
| 2286 | .vtotal = 480 + 16 + 13 + 16, |
Lucas Stach | 61ac0bf | 2014-11-06 17:44:35 +0100 | [diff] [blame] | 2287 | }; |
| 2288 | |
| 2289 | static const struct panel_desc hitachi_tx23d38vm0caa = { |
| 2290 | .modes = &hitachi_tx23d38vm0caa_mode, |
| 2291 | .num_modes = 1, |
| 2292 | .bpc = 6, |
| 2293 | .size = { |
| 2294 | .width = 195, |
| 2295 | .height = 117, |
| 2296 | }, |
Philipp Zabel | 6c684e3 | 2017-10-11 14:59:58 +0200 | [diff] [blame] | 2297 | .delay = { |
| 2298 | .enable = 160, |
| 2299 | .disable = 160, |
| 2300 | }, |
Lucas Stach | 61ac0bf | 2014-11-06 17:44:35 +0100 | [diff] [blame] | 2301 | }; |
| 2302 | |
Nicolas Ferre | 41bcceb | 2015-03-19 14:43:01 +0100 | [diff] [blame] | 2303 | static const struct drm_display_mode innolux_at043tn24_mode = { |
| 2304 | .clock = 9000, |
| 2305 | .hdisplay = 480, |
| 2306 | .hsync_start = 480 + 2, |
| 2307 | .hsync_end = 480 + 2 + 41, |
| 2308 | .htotal = 480 + 2 + 41 + 2, |
| 2309 | .vdisplay = 272, |
| 2310 | .vsync_start = 272 + 2, |
Philipp Zabel | a483159 | 2017-10-11 14:59:56 +0200 | [diff] [blame] | 2311 | .vsync_end = 272 + 2 + 10, |
| 2312 | .vtotal = 272 + 2 + 10 + 2, |
Nicolas Ferre | 41bcceb | 2015-03-19 14:43:01 +0100 | [diff] [blame] | 2313 | .flags = DRM_MODE_FLAG_NHSYNC | DRM_MODE_FLAG_NVSYNC, |
| 2314 | }; |
| 2315 | |
| 2316 | static const struct panel_desc innolux_at043tn24 = { |
| 2317 | .modes = &innolux_at043tn24_mode, |
| 2318 | .num_modes = 1, |
| 2319 | .bpc = 8, |
| 2320 | .size = { |
| 2321 | .width = 95, |
| 2322 | .height = 54, |
| 2323 | }, |
| 2324 | .bus_format = MEDIA_BUS_FMT_RGB888_1X24, |
Laurent Pinchart | 88bc417 | 2018-09-22 15:02:42 +0300 | [diff] [blame] | 2325 | .bus_flags = DRM_BUS_FLAG_DE_HIGH | DRM_BUS_FLAG_PIXDATA_DRIVE_POSEDGE, |
Nicolas Ferre | 41bcceb | 2015-03-19 14:43:01 +0100 | [diff] [blame] | 2326 | }; |
| 2327 | |
Riccardo Bortolato | 4fc24ab | 2016-04-20 15:37:15 +0200 | [diff] [blame] | 2328 | static const struct drm_display_mode innolux_at070tn92_mode = { |
| 2329 | .clock = 33333, |
| 2330 | .hdisplay = 800, |
| 2331 | .hsync_start = 800 + 210, |
| 2332 | .hsync_end = 800 + 210 + 20, |
| 2333 | .htotal = 800 + 210 + 20 + 46, |
| 2334 | .vdisplay = 480, |
| 2335 | .vsync_start = 480 + 22, |
| 2336 | .vsync_end = 480 + 22 + 10, |
| 2337 | .vtotal = 480 + 22 + 23 + 10, |
Riccardo Bortolato | 4fc24ab | 2016-04-20 15:37:15 +0200 | [diff] [blame] | 2338 | }; |
| 2339 | |
| 2340 | static const struct panel_desc innolux_at070tn92 = { |
| 2341 | .modes = &innolux_at070tn92_mode, |
| 2342 | .num_modes = 1, |
| 2343 | .size = { |
| 2344 | .width = 154, |
| 2345 | .height = 86, |
| 2346 | }, |
| 2347 | .bus_format = MEDIA_BUS_FMT_RGB888_1X24, |
| 2348 | }; |
| 2349 | |
Christoph Fritz | a5d2ade | 2018-06-04 13:16:48 +0200 | [diff] [blame] | 2350 | static const struct display_timing innolux_g070y2_l01_timing = { |
| 2351 | .pixelclock = { 28000000, 29500000, 32000000 }, |
| 2352 | .hactive = { 800, 800, 800 }, |
| 2353 | .hfront_porch = { 61, 91, 141 }, |
| 2354 | .hback_porch = { 60, 90, 140 }, |
| 2355 | .hsync_len = { 12, 12, 12 }, |
| 2356 | .vactive = { 480, 480, 480 }, |
| 2357 | .vfront_porch = { 4, 9, 30 }, |
| 2358 | .vback_porch = { 4, 8, 28 }, |
| 2359 | .vsync_len = { 2, 2, 2 }, |
| 2360 | .flags = DISPLAY_FLAGS_DE_HIGH, |
| 2361 | }; |
| 2362 | |
| 2363 | static const struct panel_desc innolux_g070y2_l01 = { |
| 2364 | .timings = &innolux_g070y2_l01_timing, |
| 2365 | .num_timings = 1, |
| 2366 | .bpc = 6, |
| 2367 | .size = { |
| 2368 | .width = 152, |
| 2369 | .height = 91, |
| 2370 | }, |
| 2371 | .delay = { |
| 2372 | .prepare = 10, |
| 2373 | .enable = 100, |
| 2374 | .disable = 100, |
| 2375 | .unprepare = 800, |
| 2376 | }, |
| 2377 | .bus_format = MEDIA_BUS_FMT_RGB888_1X7X4_SPWG, |
Laurent Pinchart | 9a2654c | 2019-09-04 16:28:03 +0300 | [diff] [blame] | 2378 | .connector_type = DRM_MODE_CONNECTOR_LVDS, |
Christoph Fritz | a5d2ade | 2018-06-04 13:16:48 +0200 | [diff] [blame] | 2379 | }; |
| 2380 | |
Michael Olbrich | 1e29b84 | 2016-08-15 14:32:02 +0200 | [diff] [blame] | 2381 | static const struct display_timing innolux_g101ice_l01_timing = { |
| 2382 | .pixelclock = { 60400000, 71100000, 74700000 }, |
| 2383 | .hactive = { 1280, 1280, 1280 }, |
| 2384 | .hfront_porch = { 41, 80, 100 }, |
| 2385 | .hback_porch = { 40, 79, 99 }, |
| 2386 | .hsync_len = { 1, 1, 1 }, |
| 2387 | .vactive = { 800, 800, 800 }, |
| 2388 | .vfront_porch = { 5, 11, 14 }, |
| 2389 | .vback_porch = { 4, 11, 14 }, |
| 2390 | .vsync_len = { 1, 1, 1 }, |
| 2391 | .flags = DISPLAY_FLAGS_DE_HIGH, |
| 2392 | }; |
| 2393 | |
| 2394 | static const struct panel_desc innolux_g101ice_l01 = { |
| 2395 | .timings = &innolux_g101ice_l01_timing, |
| 2396 | .num_timings = 1, |
| 2397 | .bpc = 8, |
| 2398 | .size = { |
| 2399 | .width = 217, |
| 2400 | .height = 135, |
| 2401 | }, |
| 2402 | .delay = { |
| 2403 | .enable = 200, |
| 2404 | .disable = 200, |
| 2405 | }, |
| 2406 | .bus_format = MEDIA_BUS_FMT_RGB888_1X7X4_SPWG, |
Laurent Pinchart | 9a2654c | 2019-09-04 16:28:03 +0300 | [diff] [blame] | 2407 | .connector_type = DRM_MODE_CONNECTOR_LVDS, |
Michael Olbrich | 1e29b84 | 2016-08-15 14:32:02 +0200 | [diff] [blame] | 2408 | }; |
| 2409 | |
Lucas Stach | 4ae13e4 | 2016-11-30 14:09:54 +0100 | [diff] [blame] | 2410 | static const struct display_timing innolux_g121i1_l01_timing = { |
| 2411 | .pixelclock = { 67450000, 71000000, 74550000 }, |
| 2412 | .hactive = { 1280, 1280, 1280 }, |
| 2413 | .hfront_porch = { 40, 80, 160 }, |
| 2414 | .hback_porch = { 39, 79, 159 }, |
| 2415 | .hsync_len = { 1, 1, 1 }, |
| 2416 | .vactive = { 800, 800, 800 }, |
| 2417 | .vfront_porch = { 5, 11, 100 }, |
| 2418 | .vback_porch = { 4, 11, 99 }, |
| 2419 | .vsync_len = { 1, 1, 1 }, |
Lucas Stach | d731f66 | 2014-11-06 17:44:33 +0100 | [diff] [blame] | 2420 | }; |
| 2421 | |
| 2422 | static const struct panel_desc innolux_g121i1_l01 = { |
Lucas Stach | 4ae13e4 | 2016-11-30 14:09:54 +0100 | [diff] [blame] | 2423 | .timings = &innolux_g121i1_l01_timing, |
| 2424 | .num_timings = 1, |
Lucas Stach | d731f66 | 2014-11-06 17:44:33 +0100 | [diff] [blame] | 2425 | .bpc = 6, |
| 2426 | .size = { |
| 2427 | .width = 261, |
| 2428 | .height = 163, |
| 2429 | }, |
Lucas Stach | 4ae13e4 | 2016-11-30 14:09:54 +0100 | [diff] [blame] | 2430 | .delay = { |
| 2431 | .enable = 200, |
| 2432 | .disable = 20, |
| 2433 | }, |
| 2434 | .bus_format = MEDIA_BUS_FMT_RGB888_1X7X4_SPWG, |
Laurent Pinchart | 9a2654c | 2019-09-04 16:28:03 +0300 | [diff] [blame] | 2435 | .connector_type = DRM_MODE_CONNECTOR_LVDS, |
Lucas Stach | d731f66 | 2014-11-06 17:44:33 +0100 | [diff] [blame] | 2436 | }; |
| 2437 | |
Akshay Bhat | f8fa17b | 2015-11-18 15:57:47 -0500 | [diff] [blame] | 2438 | static const struct drm_display_mode innolux_g121x1_l03_mode = { |
| 2439 | .clock = 65000, |
| 2440 | .hdisplay = 1024, |
| 2441 | .hsync_start = 1024 + 0, |
| 2442 | .hsync_end = 1024 + 1, |
| 2443 | .htotal = 1024 + 0 + 1 + 320, |
| 2444 | .vdisplay = 768, |
| 2445 | .vsync_start = 768 + 38, |
| 2446 | .vsync_end = 768 + 38 + 1, |
| 2447 | .vtotal = 768 + 38 + 1 + 0, |
Akshay Bhat | 2e8c5eb | 2016-03-01 18:06:54 -0500 | [diff] [blame] | 2448 | .flags = DRM_MODE_FLAG_NHSYNC | DRM_MODE_FLAG_NVSYNC, |
Akshay Bhat | f8fa17b | 2015-11-18 15:57:47 -0500 | [diff] [blame] | 2449 | }; |
| 2450 | |
| 2451 | static const struct panel_desc innolux_g121x1_l03 = { |
| 2452 | .modes = &innolux_g121x1_l03_mode, |
| 2453 | .num_modes = 1, |
| 2454 | .bpc = 6, |
| 2455 | .size = { |
| 2456 | .width = 246, |
| 2457 | .height = 185, |
| 2458 | }, |
| 2459 | .delay = { |
| 2460 | .enable = 200, |
| 2461 | .unprepare = 200, |
| 2462 | .disable = 400, |
| 2463 | }, |
| 2464 | }; |
| 2465 | |
Douglas Anderson | 51d3563 | 2021-01-15 14:44:20 -0800 | [diff] [blame] | 2466 | static const struct drm_display_mode innolux_n116bca_ea1_mode = { |
| 2467 | .clock = 76420, |
| 2468 | .hdisplay = 1366, |
| 2469 | .hsync_start = 1366 + 136, |
| 2470 | .hsync_end = 1366 + 136 + 30, |
| 2471 | .htotal = 1366 + 136 + 30 + 60, |
| 2472 | .vdisplay = 768, |
| 2473 | .vsync_start = 768 + 8, |
| 2474 | .vsync_end = 768 + 8 + 12, |
| 2475 | .vtotal = 768 + 8 + 12 + 12, |
| 2476 | .flags = DRM_MODE_FLAG_NHSYNC | DRM_MODE_FLAG_NVSYNC, |
| 2477 | }; |
| 2478 | |
| 2479 | static const struct panel_desc innolux_n116bca_ea1 = { |
| 2480 | .modes = &innolux_n116bca_ea1_mode, |
| 2481 | .num_modes = 1, |
| 2482 | .bpc = 6, |
| 2483 | .size = { |
| 2484 | .width = 256, |
| 2485 | .height = 144, |
| 2486 | }, |
| 2487 | .delay = { |
| 2488 | .hpd_absent_delay = 200, |
| 2489 | .prepare_to_enable = 80, |
| 2490 | .unprepare = 500, |
| 2491 | }, |
| 2492 | .bus_format = MEDIA_BUS_FMT_RGB666_1X18, |
| 2493 | .connector_type = DRM_MODE_CONNECTOR_eDP, |
| 2494 | }; |
| 2495 | |
Douglas Anderson | d719cbe | 2019-07-11 13:34:54 -0700 | [diff] [blame] | 2496 | /* |
| 2497 | * Datasheet specifies that at 60 Hz refresh rate: |
| 2498 | * - total horizontal time: { 1506, 1592, 1716 } |
| 2499 | * - total vertical time: { 788, 800, 868 } |
| 2500 | * |
| 2501 | * ...but doesn't go into exactly how that should be split into a front |
| 2502 | * porch, back porch, or sync length. For now we'll leave a single setting |
| 2503 | * here which allows a bit of tweaking of the pixel clock at the expense of |
| 2504 | * refresh rate. |
| 2505 | */ |
| 2506 | static const struct display_timing innolux_n116bge_timing = { |
| 2507 | .pixelclock = { 72600000, 76420000, 80240000 }, |
| 2508 | .hactive = { 1366, 1366, 1366 }, |
| 2509 | .hfront_porch = { 136, 136, 136 }, |
| 2510 | .hback_porch = { 60, 60, 60 }, |
| 2511 | .hsync_len = { 30, 30, 30 }, |
| 2512 | .vactive = { 768, 768, 768 }, |
| 2513 | .vfront_porch = { 8, 8, 8 }, |
| 2514 | .vback_porch = { 12, 12, 12 }, |
| 2515 | .vsync_len = { 12, 12, 12 }, |
| 2516 | .flags = DISPLAY_FLAGS_VSYNC_LOW | DISPLAY_FLAGS_HSYNC_LOW, |
Thierry Reding | 0a2288c | 2014-07-03 14:02:59 +0200 | [diff] [blame] | 2517 | }; |
| 2518 | |
| 2519 | static const struct panel_desc innolux_n116bge = { |
Douglas Anderson | d719cbe | 2019-07-11 13:34:54 -0700 | [diff] [blame] | 2520 | .timings = &innolux_n116bge_timing, |
| 2521 | .num_timings = 1, |
Thierry Reding | 0a2288c | 2014-07-03 14:02:59 +0200 | [diff] [blame] | 2522 | .bpc = 6, |
| 2523 | .size = { |
| 2524 | .width = 256, |
| 2525 | .height = 144, |
| 2526 | }, |
Heiko Stuebner | 87969bc | 2021-01-09 14:09:51 +0100 | [diff] [blame] | 2527 | .bus_format = MEDIA_BUS_FMT_RGB666_1X18, |
| 2528 | .connector_type = DRM_MODE_CONNECTOR_eDP, |
Thierry Reding | 0a2288c | 2014-07-03 14:02:59 +0200 | [diff] [blame] | 2529 | }; |
| 2530 | |
Lukas F. Hartmann | a14c6b0 | 2020-11-24 18:26:04 +0100 | [diff] [blame] | 2531 | static const struct drm_display_mode innolux_n125hce_gn1_mode = { |
| 2532 | .clock = 162000, |
| 2533 | .hdisplay = 1920, |
| 2534 | .hsync_start = 1920 + 40, |
| 2535 | .hsync_end = 1920 + 40 + 40, |
| 2536 | .htotal = 1920 + 40 + 40 + 80, |
| 2537 | .vdisplay = 1080, |
| 2538 | .vsync_start = 1080 + 4, |
| 2539 | .vsync_end = 1080 + 4 + 4, |
| 2540 | .vtotal = 1080 + 4 + 4 + 24, |
| 2541 | }; |
| 2542 | |
| 2543 | static const struct panel_desc innolux_n125hce_gn1 = { |
| 2544 | .modes = &innolux_n125hce_gn1_mode, |
| 2545 | .num_modes = 1, |
| 2546 | .bpc = 8, |
| 2547 | .size = { |
| 2548 | .width = 276, |
| 2549 | .height = 155, |
| 2550 | }, |
| 2551 | .bus_format = MEDIA_BUS_FMT_RGB888_1X24, |
| 2552 | .bus_flags = DRM_BUS_FLAG_DATA_MSB_TO_LSB, |
| 2553 | .connector_type = DRM_MODE_CONNECTOR_eDP, |
| 2554 | }; |
| 2555 | |
Alban Bedel | ea44739 | 2014-07-22 08:38:55 +0200 | [diff] [blame] | 2556 | static const struct drm_display_mode innolux_n156bge_l21_mode = { |
| 2557 | .clock = 69300, |
| 2558 | .hdisplay = 1366, |
| 2559 | .hsync_start = 1366 + 16, |
| 2560 | .hsync_end = 1366 + 16 + 34, |
| 2561 | .htotal = 1366 + 16 + 34 + 50, |
| 2562 | .vdisplay = 768, |
| 2563 | .vsync_start = 768 + 2, |
| 2564 | .vsync_end = 768 + 2 + 6, |
| 2565 | .vtotal = 768 + 2 + 6 + 12, |
Alban Bedel | ea44739 | 2014-07-22 08:38:55 +0200 | [diff] [blame] | 2566 | }; |
| 2567 | |
| 2568 | static const struct panel_desc innolux_n156bge_l21 = { |
| 2569 | .modes = &innolux_n156bge_l21_mode, |
| 2570 | .num_modes = 1, |
Stéphane Marchesin | 0208d51 | 2014-06-19 18:18:28 -0700 | [diff] [blame] | 2571 | .bpc = 6, |
Alban Bedel | ea44739 | 2014-07-22 08:38:55 +0200 | [diff] [blame] | 2572 | .size = { |
| 2573 | .width = 344, |
| 2574 | .height = 193, |
| 2575 | }, |
Dmitry Osipenko | 8556082 | 2020-06-22 01:27:42 +0300 | [diff] [blame] | 2576 | .bus_format = MEDIA_BUS_FMT_RGB666_1X7X3_SPWG, |
Laurent Pinchart | c471583 | 2020-06-30 02:33:19 +0300 | [diff] [blame] | 2577 | .bus_flags = DRM_BUS_FLAG_DE_HIGH, |
Dmitry Osipenko | 94f0791 | 2020-06-18 01:27:03 +0300 | [diff] [blame] | 2578 | .connector_type = DRM_MODE_CONNECTOR_LVDS, |
Alban Bedel | ea44739 | 2014-07-22 08:38:55 +0200 | [diff] [blame] | 2579 | }; |
| 2580 | |
Douglas Anderson | 8f054b6 | 2018-10-25 15:21:34 -0700 | [diff] [blame] | 2581 | static const struct drm_display_mode innolux_p120zdg_bf1_mode = { |
spanda@codeaurora.org | da50bd4 | 2018-05-15 11:22:43 +0530 | [diff] [blame] | 2582 | .clock = 206016, |
| 2583 | .hdisplay = 2160, |
| 2584 | .hsync_start = 2160 + 48, |
| 2585 | .hsync_end = 2160 + 48 + 32, |
| 2586 | .htotal = 2160 + 48 + 32 + 80, |
| 2587 | .vdisplay = 1440, |
| 2588 | .vsync_start = 1440 + 3, |
| 2589 | .vsync_end = 1440 + 3 + 10, |
| 2590 | .vtotal = 1440 + 3 + 10 + 27, |
spanda@codeaurora.org | da50bd4 | 2018-05-15 11:22:43 +0530 | [diff] [blame] | 2591 | .flags = DRM_MODE_FLAG_PHSYNC | DRM_MODE_FLAG_PVSYNC, |
| 2592 | }; |
| 2593 | |
Douglas Anderson | 8f054b6 | 2018-10-25 15:21:34 -0700 | [diff] [blame] | 2594 | static const struct panel_desc innolux_p120zdg_bf1 = { |
| 2595 | .modes = &innolux_p120zdg_bf1_mode, |
spanda@codeaurora.org | da50bd4 | 2018-05-15 11:22:43 +0530 | [diff] [blame] | 2596 | .num_modes = 1, |
| 2597 | .bpc = 8, |
| 2598 | .size = { |
Douglas Anderson | 8f054b6 | 2018-10-25 15:21:34 -0700 | [diff] [blame] | 2599 | .width = 254, |
| 2600 | .height = 169, |
spanda@codeaurora.org | da50bd4 | 2018-05-15 11:22:43 +0530 | [diff] [blame] | 2601 | }, |
Sean Paul | 22fd99e | 2018-08-13 17:30:40 -0400 | [diff] [blame] | 2602 | .delay = { |
Douglas Anderson | 625d3b5 | 2018-10-25 15:21:31 -0700 | [diff] [blame] | 2603 | .hpd_absent_delay = 200, |
Sean Paul | 22fd99e | 2018-08-13 17:30:40 -0400 | [diff] [blame] | 2604 | .unprepare = 500, |
| 2605 | }, |
spanda@codeaurora.org | da50bd4 | 2018-05-15 11:22:43 +0530 | [diff] [blame] | 2606 | }; |
| 2607 | |
Michael Grzeschik | bccac3f | 2015-03-19 12:22:44 +0100 | [diff] [blame] | 2608 | static const struct drm_display_mode innolux_zj070na_01p_mode = { |
| 2609 | .clock = 51501, |
| 2610 | .hdisplay = 1024, |
| 2611 | .hsync_start = 1024 + 128, |
| 2612 | .hsync_end = 1024 + 128 + 64, |
| 2613 | .htotal = 1024 + 128 + 64 + 128, |
| 2614 | .vdisplay = 600, |
| 2615 | .vsync_start = 600 + 16, |
| 2616 | .vsync_end = 600 + 16 + 4, |
| 2617 | .vtotal = 600 + 16 + 4 + 16, |
Michael Grzeschik | bccac3f | 2015-03-19 12:22:44 +0100 | [diff] [blame] | 2618 | }; |
| 2619 | |
| 2620 | static const struct panel_desc innolux_zj070na_01p = { |
| 2621 | .modes = &innolux_zj070na_01p_mode, |
| 2622 | .num_modes = 1, |
| 2623 | .bpc = 6, |
| 2624 | .size = { |
Thierry Reding | 8159884 | 2016-06-10 15:33:13 +0200 | [diff] [blame] | 2625 | .width = 154, |
| 2626 | .height = 90, |
Michael Grzeschik | bccac3f | 2015-03-19 12:22:44 +0100 | [diff] [blame] | 2627 | }, |
| 2628 | }; |
| 2629 | |
Bjorn Andersson | e1ca518 | 2020-04-20 14:57:28 -0700 | [diff] [blame] | 2630 | static const struct drm_display_mode ivo_m133nwf4_r0_mode = { |
| 2631 | .clock = 138778, |
| 2632 | .hdisplay = 1920, |
| 2633 | .hsync_start = 1920 + 24, |
| 2634 | .hsync_end = 1920 + 24 + 48, |
| 2635 | .htotal = 1920 + 24 + 48 + 88, |
| 2636 | .vdisplay = 1080, |
| 2637 | .vsync_start = 1080 + 3, |
| 2638 | .vsync_end = 1080 + 3 + 12, |
| 2639 | .vtotal = 1080 + 3 + 12 + 17, |
Bjorn Andersson | e1ca518 | 2020-04-20 14:57:28 -0700 | [diff] [blame] | 2640 | .flags = DRM_MODE_FLAG_PHSYNC | DRM_MODE_FLAG_PVSYNC, |
| 2641 | }; |
| 2642 | |
| 2643 | static const struct panel_desc ivo_m133nwf4_r0 = { |
| 2644 | .modes = &ivo_m133nwf4_r0_mode, |
| 2645 | .num_modes = 1, |
| 2646 | .bpc = 8, |
| 2647 | .size = { |
| 2648 | .width = 294, |
| 2649 | .height = 165, |
| 2650 | }, |
| 2651 | .delay = { |
| 2652 | .hpd_absent_delay = 200, |
| 2653 | .unprepare = 500, |
| 2654 | }, |
| 2655 | .bus_format = MEDIA_BUS_FMT_RGB888_1X24, |
| 2656 | .bus_flags = DRM_BUS_FLAG_DATA_MSB_TO_LSB, |
| 2657 | .connector_type = DRM_MODE_CONNECTOR_eDP, |
| 2658 | }; |
| 2659 | |
Douglas Anderson | fc26a37 | 2020-08-21 08:35:15 -0700 | [diff] [blame] | 2660 | static const struct drm_display_mode kingdisplay_kd116n21_30nv_a010_mode = { |
| 2661 | .clock = 81000, |
| 2662 | .hdisplay = 1366, |
| 2663 | .hsync_start = 1366 + 40, |
| 2664 | .hsync_end = 1366 + 40 + 32, |
| 2665 | .htotal = 1366 + 40 + 32 + 62, |
| 2666 | .vdisplay = 768, |
| 2667 | .vsync_start = 768 + 5, |
| 2668 | .vsync_end = 768 + 5 + 5, |
| 2669 | .vtotal = 768 + 5 + 5 + 122, |
| 2670 | .flags = DRM_MODE_FLAG_NVSYNC | DRM_MODE_FLAG_NHSYNC, |
| 2671 | }; |
| 2672 | |
| 2673 | static const struct panel_desc kingdisplay_kd116n21_30nv_a010 = { |
| 2674 | .modes = &kingdisplay_kd116n21_30nv_a010_mode, |
| 2675 | .num_modes = 1, |
| 2676 | .bpc = 6, |
| 2677 | .size = { |
| 2678 | .width = 256, |
| 2679 | .height = 144, |
| 2680 | }, |
| 2681 | .delay = { |
| 2682 | .hpd_absent_delay = 200, |
| 2683 | }, |
| 2684 | .bus_format = MEDIA_BUS_FMT_RGB666_1X18, |
| 2685 | .connector_type = DRM_MODE_CONNECTOR_eDP, |
| 2686 | }; |
| 2687 | |
Lukasz Majewski | 14bf60c | 2019-05-15 18:06:12 +0200 | [diff] [blame] | 2688 | static const struct display_timing koe_tx14d24vm1bpa_timing = { |
| 2689 | .pixelclock = { 5580000, 5850000, 6200000 }, |
| 2690 | .hactive = { 320, 320, 320 }, |
| 2691 | .hfront_porch = { 30, 30, 30 }, |
| 2692 | .hback_porch = { 30, 30, 30 }, |
| 2693 | .hsync_len = { 1, 5, 17 }, |
| 2694 | .vactive = { 240, 240, 240 }, |
| 2695 | .vfront_porch = { 6, 6, 6 }, |
| 2696 | .vback_porch = { 5, 5, 5 }, |
| 2697 | .vsync_len = { 1, 2, 11 }, |
| 2698 | .flags = DISPLAY_FLAGS_DE_HIGH, |
| 2699 | }; |
| 2700 | |
| 2701 | static const struct panel_desc koe_tx14d24vm1bpa = { |
| 2702 | .timings = &koe_tx14d24vm1bpa_timing, |
| 2703 | .num_timings = 1, |
| 2704 | .bpc = 6, |
| 2705 | .size = { |
| 2706 | .width = 115, |
| 2707 | .height = 86, |
| 2708 | }, |
| 2709 | }; |
| 2710 | |
Liu Ying | 8a07052 | 2020-06-01 14:11:20 +0800 | [diff] [blame] | 2711 | static const struct display_timing koe_tx26d202vm0bwa_timing = { |
| 2712 | .pixelclock = { 151820000, 156720000, 159780000 }, |
| 2713 | .hactive = { 1920, 1920, 1920 }, |
| 2714 | .hfront_porch = { 105, 130, 142 }, |
| 2715 | .hback_porch = { 45, 70, 82 }, |
| 2716 | .hsync_len = { 30, 30, 30 }, |
| 2717 | .vactive = { 1200, 1200, 1200}, |
| 2718 | .vfront_porch = { 3, 5, 10 }, |
| 2719 | .vback_porch = { 2, 5, 10 }, |
| 2720 | .vsync_len = { 5, 5, 5 }, |
| 2721 | }; |
| 2722 | |
| 2723 | static const struct panel_desc koe_tx26d202vm0bwa = { |
| 2724 | .timings = &koe_tx26d202vm0bwa_timing, |
| 2725 | .num_timings = 1, |
| 2726 | .bpc = 8, |
| 2727 | .size = { |
| 2728 | .width = 217, |
| 2729 | .height = 136, |
| 2730 | }, |
| 2731 | .delay = { |
| 2732 | .prepare = 1000, |
| 2733 | .enable = 1000, |
| 2734 | .unprepare = 1000, |
| 2735 | .disable = 1000, |
| 2736 | }, |
| 2737 | .bus_format = MEDIA_BUS_FMT_RGB888_1X7X4_SPWG, |
Laurent Pinchart | c471583 | 2020-06-30 02:33:19 +0300 | [diff] [blame] | 2738 | .bus_flags = DRM_BUS_FLAG_DE_HIGH, |
Liu Ying | 8a07052 | 2020-06-01 14:11:20 +0800 | [diff] [blame] | 2739 | .connector_type = DRM_MODE_CONNECTOR_LVDS, |
| 2740 | }; |
| 2741 | |
Jagan Teki | 8cfe834 | 2018-02-04 23:19:28 +0530 | [diff] [blame] | 2742 | static const struct display_timing koe_tx31d200vm0baa_timing = { |
| 2743 | .pixelclock = { 39600000, 43200000, 48000000 }, |
| 2744 | .hactive = { 1280, 1280, 1280 }, |
| 2745 | .hfront_porch = { 16, 36, 56 }, |
| 2746 | .hback_porch = { 16, 36, 56 }, |
| 2747 | .hsync_len = { 8, 8, 8 }, |
| 2748 | .vactive = { 480, 480, 480 }, |
Stefan Agner | c9b6be7 | 2018-04-19 23:20:03 +0200 | [diff] [blame] | 2749 | .vfront_porch = { 6, 21, 33 }, |
| 2750 | .vback_porch = { 6, 21, 33 }, |
Jagan Teki | 8cfe834 | 2018-02-04 23:19:28 +0530 | [diff] [blame] | 2751 | .vsync_len = { 8, 8, 8 }, |
| 2752 | .flags = DISPLAY_FLAGS_DE_HIGH, |
| 2753 | }; |
| 2754 | |
| 2755 | static const struct panel_desc koe_tx31d200vm0baa = { |
| 2756 | .timings = &koe_tx31d200vm0baa_timing, |
| 2757 | .num_timings = 1, |
| 2758 | .bpc = 6, |
| 2759 | .size = { |
| 2760 | .width = 292, |
| 2761 | .height = 109, |
| 2762 | }, |
| 2763 | .bus_format = MEDIA_BUS_FMT_RGB666_1X7X3_SPWG, |
Laurent Pinchart | 9a2654c | 2019-09-04 16:28:03 +0300 | [diff] [blame] | 2764 | .connector_type = DRM_MODE_CONNECTOR_LVDS, |
Jagan Teki | 8cfe834 | 2018-02-04 23:19:28 +0530 | [diff] [blame] | 2765 | }; |
| 2766 | |
Lucas Stach | 8def22e | 2015-12-02 19:41:11 +0100 | [diff] [blame] | 2767 | static const struct display_timing kyo_tcg121xglp_timing = { |
| 2768 | .pixelclock = { 52000000, 65000000, 71000000 }, |
| 2769 | .hactive = { 1024, 1024, 1024 }, |
| 2770 | .hfront_porch = { 2, 2, 2 }, |
| 2771 | .hback_porch = { 2, 2, 2 }, |
| 2772 | .hsync_len = { 86, 124, 244 }, |
| 2773 | .vactive = { 768, 768, 768 }, |
| 2774 | .vfront_porch = { 2, 2, 2 }, |
| 2775 | .vback_porch = { 2, 2, 2 }, |
| 2776 | .vsync_len = { 6, 34, 73 }, |
| 2777 | .flags = DISPLAY_FLAGS_DE_HIGH, |
| 2778 | }; |
| 2779 | |
| 2780 | static const struct panel_desc kyo_tcg121xglp = { |
| 2781 | .timings = &kyo_tcg121xglp_timing, |
| 2782 | .num_timings = 1, |
| 2783 | .bpc = 8, |
| 2784 | .size = { |
| 2785 | .width = 246, |
| 2786 | .height = 184, |
| 2787 | }, |
| 2788 | .bus_format = MEDIA_BUS_FMT_RGB888_1X7X4_SPWG, |
Laurent Pinchart | 9a2654c | 2019-09-04 16:28:03 +0300 | [diff] [blame] | 2789 | .connector_type = DRM_MODE_CONNECTOR_LVDS, |
Lucas Stach | 8def22e | 2015-12-02 19:41:11 +0100 | [diff] [blame] | 2790 | }; |
| 2791 | |
Paul Kocialkowski | 27abdd8 | 2018-11-07 19:18:41 +0100 | [diff] [blame] | 2792 | static const struct drm_display_mode lemaker_bl035_rgb_002_mode = { |
| 2793 | .clock = 7000, |
| 2794 | .hdisplay = 320, |
| 2795 | .hsync_start = 320 + 20, |
| 2796 | .hsync_end = 320 + 20 + 30, |
| 2797 | .htotal = 320 + 20 + 30 + 38, |
| 2798 | .vdisplay = 240, |
| 2799 | .vsync_start = 240 + 4, |
| 2800 | .vsync_end = 240 + 4 + 3, |
| 2801 | .vtotal = 240 + 4 + 3 + 15, |
Paul Kocialkowski | 27abdd8 | 2018-11-07 19:18:41 +0100 | [diff] [blame] | 2802 | }; |
| 2803 | |
| 2804 | static const struct panel_desc lemaker_bl035_rgb_002 = { |
| 2805 | .modes = &lemaker_bl035_rgb_002_mode, |
| 2806 | .num_modes = 1, |
| 2807 | .size = { |
| 2808 | .width = 70, |
| 2809 | .height = 52, |
| 2810 | }, |
| 2811 | .bus_format = MEDIA_BUS_FMT_RGB888_1X24, |
| 2812 | .bus_flags = DRM_BUS_FLAG_DE_LOW, |
| 2813 | }; |
| 2814 | |
Heiko Schocher | dd01500 | 2015-05-22 10:25:57 +0200 | [diff] [blame] | 2815 | static const struct drm_display_mode lg_lb070wv8_mode = { |
| 2816 | .clock = 33246, |
| 2817 | .hdisplay = 800, |
| 2818 | .hsync_start = 800 + 88, |
| 2819 | .hsync_end = 800 + 88 + 80, |
| 2820 | .htotal = 800 + 88 + 80 + 88, |
| 2821 | .vdisplay = 480, |
| 2822 | .vsync_start = 480 + 10, |
| 2823 | .vsync_end = 480 + 10 + 25, |
| 2824 | .vtotal = 480 + 10 + 25 + 10, |
Heiko Schocher | dd01500 | 2015-05-22 10:25:57 +0200 | [diff] [blame] | 2825 | }; |
| 2826 | |
| 2827 | static const struct panel_desc lg_lb070wv8 = { |
| 2828 | .modes = &lg_lb070wv8_mode, |
| 2829 | .num_modes = 1, |
Laurent Pinchart | a6ae2fe | 2020-07-12 01:53:17 +0300 | [diff] [blame] | 2830 | .bpc = 8, |
Heiko Schocher | dd01500 | 2015-05-22 10:25:57 +0200 | [diff] [blame] | 2831 | .size = { |
| 2832 | .width = 151, |
| 2833 | .height = 91, |
| 2834 | }, |
| 2835 | .bus_format = MEDIA_BUS_FMT_RGB888_1X7X4_SPWG, |
Laurent Pinchart | 9a2654c | 2019-09-04 16:28:03 +0300 | [diff] [blame] | 2836 | .connector_type = DRM_MODE_CONNECTOR_LVDS, |
Heiko Schocher | dd01500 | 2015-05-22 10:25:57 +0200 | [diff] [blame] | 2837 | }; |
| 2838 | |
Yakir Yang | c5ece40 | 2016-06-28 12:51:15 +0800 | [diff] [blame] | 2839 | static const struct drm_display_mode lg_lp079qx1_sp0v_mode = { |
| 2840 | .clock = 200000, |
| 2841 | .hdisplay = 1536, |
| 2842 | .hsync_start = 1536 + 12, |
| 2843 | .hsync_end = 1536 + 12 + 16, |
| 2844 | .htotal = 1536 + 12 + 16 + 48, |
| 2845 | .vdisplay = 2048, |
| 2846 | .vsync_start = 2048 + 8, |
| 2847 | .vsync_end = 2048 + 8 + 4, |
| 2848 | .vtotal = 2048 + 8 + 4 + 8, |
Yakir Yang | c5ece40 | 2016-06-28 12:51:15 +0800 | [diff] [blame] | 2849 | .flags = DRM_MODE_FLAG_NVSYNC | DRM_MODE_FLAG_NHSYNC, |
| 2850 | }; |
| 2851 | |
| 2852 | static const struct panel_desc lg_lp079qx1_sp0v = { |
| 2853 | .modes = &lg_lp079qx1_sp0v_mode, |
| 2854 | .num_modes = 1, |
| 2855 | .size = { |
| 2856 | .width = 129, |
| 2857 | .height = 171, |
| 2858 | }, |
| 2859 | }; |
| 2860 | |
Yakir Yang | 0355dde | 2016-06-12 10:56:02 +0800 | [diff] [blame] | 2861 | static const struct drm_display_mode lg_lp097qx1_spa1_mode = { |
| 2862 | .clock = 205210, |
| 2863 | .hdisplay = 2048, |
| 2864 | .hsync_start = 2048 + 150, |
| 2865 | .hsync_end = 2048 + 150 + 5, |
| 2866 | .htotal = 2048 + 150 + 5 + 5, |
| 2867 | .vdisplay = 1536, |
| 2868 | .vsync_start = 1536 + 3, |
| 2869 | .vsync_end = 1536 + 3 + 1, |
| 2870 | .vtotal = 1536 + 3 + 1 + 9, |
Yakir Yang | 0355dde | 2016-06-12 10:56:02 +0800 | [diff] [blame] | 2871 | }; |
| 2872 | |
| 2873 | static const struct panel_desc lg_lp097qx1_spa1 = { |
| 2874 | .modes = &lg_lp097qx1_spa1_mode, |
| 2875 | .num_modes = 1, |
| 2876 | .size = { |
| 2877 | .width = 208, |
| 2878 | .height = 147, |
| 2879 | }, |
| 2880 | }; |
| 2881 | |
Jitao Shi | 690d8fa | 2016-02-22 19:01:44 +0800 | [diff] [blame] | 2882 | static const struct drm_display_mode lg_lp120up1_mode = { |
| 2883 | .clock = 162300, |
| 2884 | .hdisplay = 1920, |
| 2885 | .hsync_start = 1920 + 40, |
| 2886 | .hsync_end = 1920 + 40 + 40, |
| 2887 | .htotal = 1920 + 40 + 40+ 80, |
| 2888 | .vdisplay = 1280, |
| 2889 | .vsync_start = 1280 + 4, |
| 2890 | .vsync_end = 1280 + 4 + 4, |
| 2891 | .vtotal = 1280 + 4 + 4 + 12, |
Jitao Shi | 690d8fa | 2016-02-22 19:01:44 +0800 | [diff] [blame] | 2892 | }; |
| 2893 | |
| 2894 | static const struct panel_desc lg_lp120up1 = { |
| 2895 | .modes = &lg_lp120up1_mode, |
| 2896 | .num_modes = 1, |
| 2897 | .bpc = 8, |
| 2898 | .size = { |
| 2899 | .width = 267, |
| 2900 | .height = 183, |
| 2901 | }, |
Enric Balletbo i Serra | d53139b | 2020-04-16 18:44:03 +0200 | [diff] [blame] | 2902 | .connector_type = DRM_MODE_CONNECTOR_eDP, |
Jitao Shi | 690d8fa | 2016-02-22 19:01:44 +0800 | [diff] [blame] | 2903 | }; |
| 2904 | |
Thierry Reding | ec7c565 | 2013-11-15 15:59:32 +0100 | [diff] [blame] | 2905 | static const struct drm_display_mode lg_lp129qe_mode = { |
| 2906 | .clock = 285250, |
| 2907 | .hdisplay = 2560, |
| 2908 | .hsync_start = 2560 + 48, |
| 2909 | .hsync_end = 2560 + 48 + 32, |
| 2910 | .htotal = 2560 + 48 + 32 + 80, |
| 2911 | .vdisplay = 1700, |
| 2912 | .vsync_start = 1700 + 3, |
| 2913 | .vsync_end = 1700 + 3 + 10, |
| 2914 | .vtotal = 1700 + 3 + 10 + 36, |
Thierry Reding | ec7c565 | 2013-11-15 15:59:32 +0100 | [diff] [blame] | 2915 | }; |
| 2916 | |
| 2917 | static const struct panel_desc lg_lp129qe = { |
| 2918 | .modes = &lg_lp129qe_mode, |
| 2919 | .num_modes = 1, |
Stéphane Marchesin | 0208d51 | 2014-06-19 18:18:28 -0700 | [diff] [blame] | 2920 | .bpc = 8, |
Thierry Reding | ec7c565 | 2013-11-15 15:59:32 +0100 | [diff] [blame] | 2921 | .size = { |
| 2922 | .width = 272, |
| 2923 | .height = 181, |
| 2924 | }, |
| 2925 | }; |
| 2926 | |
Marcel Ziswiler | 5728fe7 | 2020-01-20 09:01:00 +0100 | [diff] [blame] | 2927 | static const struct display_timing logictechno_lt161010_2nh_timing = { |
| 2928 | .pixelclock = { 26400000, 33300000, 46800000 }, |
| 2929 | .hactive = { 800, 800, 800 }, |
| 2930 | .hfront_porch = { 16, 210, 354 }, |
| 2931 | .hback_porch = { 46, 46, 46 }, |
| 2932 | .hsync_len = { 1, 20, 40 }, |
| 2933 | .vactive = { 480, 480, 480 }, |
| 2934 | .vfront_porch = { 7, 22, 147 }, |
| 2935 | .vback_porch = { 23, 23, 23 }, |
| 2936 | .vsync_len = { 1, 10, 20 }, |
| 2937 | .flags = DISPLAY_FLAGS_HSYNC_LOW | DISPLAY_FLAGS_VSYNC_LOW | |
| 2938 | DISPLAY_FLAGS_DE_HIGH | DISPLAY_FLAGS_PIXDATA_POSEDGE | |
| 2939 | DISPLAY_FLAGS_SYNC_POSEDGE, |
| 2940 | }; |
| 2941 | |
| 2942 | static const struct panel_desc logictechno_lt161010_2nh = { |
| 2943 | .timings = &logictechno_lt161010_2nh_timing, |
| 2944 | .num_timings = 1, |
| 2945 | .size = { |
| 2946 | .width = 154, |
| 2947 | .height = 86, |
| 2948 | }, |
| 2949 | .bus_format = MEDIA_BUS_FMT_RGB666_1X18, |
| 2950 | .bus_flags = DRM_BUS_FLAG_DE_HIGH | |
| 2951 | DRM_BUS_FLAG_PIXDATA_SAMPLE_NEGEDGE | |
| 2952 | DRM_BUS_FLAG_SYNC_SAMPLE_NEGEDGE, |
| 2953 | .connector_type = DRM_MODE_CONNECTOR_DPI, |
| 2954 | }; |
| 2955 | |
| 2956 | static const struct display_timing logictechno_lt170410_2whc_timing = { |
| 2957 | .pixelclock = { 68900000, 71100000, 73400000 }, |
| 2958 | .hactive = { 1280, 1280, 1280 }, |
| 2959 | .hfront_porch = { 23, 60, 71 }, |
| 2960 | .hback_porch = { 23, 60, 71 }, |
| 2961 | .hsync_len = { 15, 40, 47 }, |
| 2962 | .vactive = { 800, 800, 800 }, |
| 2963 | .vfront_porch = { 5, 7, 10 }, |
| 2964 | .vback_porch = { 5, 7, 10 }, |
| 2965 | .vsync_len = { 6, 9, 12 }, |
| 2966 | .flags = DISPLAY_FLAGS_HSYNC_LOW | DISPLAY_FLAGS_VSYNC_LOW | |
| 2967 | DISPLAY_FLAGS_DE_HIGH | DISPLAY_FLAGS_PIXDATA_POSEDGE | |
| 2968 | DISPLAY_FLAGS_SYNC_POSEDGE, |
| 2969 | }; |
| 2970 | |
| 2971 | static const struct panel_desc logictechno_lt170410_2whc = { |
| 2972 | .timings = &logictechno_lt170410_2whc_timing, |
| 2973 | .num_timings = 1, |
| 2974 | .size = { |
| 2975 | .width = 217, |
| 2976 | .height = 136, |
| 2977 | }, |
| 2978 | .bus_format = MEDIA_BUS_FMT_RGB888_1X7X4_SPWG, |
Laurent Pinchart | c471583 | 2020-06-30 02:33:19 +0300 | [diff] [blame] | 2979 | .bus_flags = DRM_BUS_FLAG_DE_HIGH, |
Marcel Ziswiler | 5728fe7 | 2020-01-20 09:01:00 +0100 | [diff] [blame] | 2980 | .connector_type = DRM_MODE_CONNECTOR_LVDS, |
| 2981 | }; |
| 2982 | |
Lukasz Majewski | 65c766c | 2017-10-21 00:18:37 +0200 | [diff] [blame] | 2983 | static const struct drm_display_mode mitsubishi_aa070mc01_mode = { |
| 2984 | .clock = 30400, |
| 2985 | .hdisplay = 800, |
| 2986 | .hsync_start = 800 + 0, |
| 2987 | .hsync_end = 800 + 1, |
| 2988 | .htotal = 800 + 0 + 1 + 160, |
| 2989 | .vdisplay = 480, |
| 2990 | .vsync_start = 480 + 0, |
| 2991 | .vsync_end = 480 + 48 + 1, |
| 2992 | .vtotal = 480 + 48 + 1 + 0, |
Lukasz Majewski | 65c766c | 2017-10-21 00:18:37 +0200 | [diff] [blame] | 2993 | .flags = DRM_MODE_FLAG_NHSYNC | DRM_MODE_FLAG_NVSYNC, |
| 2994 | }; |
| 2995 | |
Adam Ford | 0d35408 | 2019-10-16 08:51:45 -0500 | [diff] [blame] | 2996 | static const struct drm_display_mode logicpd_type_28_mode = { |
Ville Syrjälä | f873c5d | 2020-03-02 22:34:40 +0200 | [diff] [blame] | 2997 | .clock = 9107, |
Adam Ford | 0d35408 | 2019-10-16 08:51:45 -0500 | [diff] [blame] | 2998 | .hdisplay = 480, |
| 2999 | .hsync_start = 480 + 3, |
| 3000 | .hsync_end = 480 + 3 + 42, |
| 3001 | .htotal = 480 + 3 + 42 + 2, |
| 3002 | |
| 3003 | .vdisplay = 272, |
| 3004 | .vsync_start = 272 + 2, |
| 3005 | .vsync_end = 272 + 2 + 11, |
| 3006 | .vtotal = 272 + 2 + 11 + 3, |
Adam Ford | 0d35408 | 2019-10-16 08:51:45 -0500 | [diff] [blame] | 3007 | .flags = DRM_MODE_FLAG_PHSYNC | DRM_MODE_FLAG_PVSYNC, |
| 3008 | }; |
| 3009 | |
| 3010 | static const struct panel_desc logicpd_type_28 = { |
| 3011 | .modes = &logicpd_type_28_mode, |
| 3012 | .num_modes = 1, |
| 3013 | .bpc = 8, |
| 3014 | .size = { |
| 3015 | .width = 105, |
| 3016 | .height = 67, |
| 3017 | }, |
| 3018 | .delay = { |
| 3019 | .prepare = 200, |
| 3020 | .enable = 200, |
| 3021 | .unprepare = 200, |
| 3022 | .disable = 200, |
| 3023 | }, |
| 3024 | .bus_format = MEDIA_BUS_FMT_RGB888_1X24, |
| 3025 | .bus_flags = DRM_BUS_FLAG_DE_HIGH | DRM_BUS_FLAG_PIXDATA_DRIVE_POSEDGE | |
| 3026 | DRM_BUS_FLAG_SYNC_DRIVE_NEGEDGE, |
Adam Ford | efb9479 | 2020-06-15 08:19:34 -0500 | [diff] [blame] | 3027 | .connector_type = DRM_MODE_CONNECTOR_DPI, |
Adam Ford | 0d35408 | 2019-10-16 08:51:45 -0500 | [diff] [blame] | 3028 | }; |
| 3029 | |
Lukasz Majewski | 65c766c | 2017-10-21 00:18:37 +0200 | [diff] [blame] | 3030 | static const struct panel_desc mitsubishi_aa070mc01 = { |
| 3031 | .modes = &mitsubishi_aa070mc01_mode, |
| 3032 | .num_modes = 1, |
| 3033 | .bpc = 8, |
| 3034 | .size = { |
| 3035 | .width = 152, |
| 3036 | .height = 91, |
| 3037 | }, |
| 3038 | |
| 3039 | .delay = { |
| 3040 | .enable = 200, |
| 3041 | .unprepare = 200, |
| 3042 | .disable = 400, |
| 3043 | }, |
| 3044 | .bus_format = MEDIA_BUS_FMT_RGB888_1X7X4_SPWG, |
Laurent Pinchart | 9a2654c | 2019-09-04 16:28:03 +0300 | [diff] [blame] | 3045 | .connector_type = DRM_MODE_CONNECTOR_LVDS, |
Lukasz Majewski | 65c766c | 2017-10-21 00:18:37 +0200 | [diff] [blame] | 3046 | .bus_flags = DRM_BUS_FLAG_DE_HIGH, |
| 3047 | }; |
| 3048 | |
Lucas Stach | 01bacc13 | 2017-06-08 20:07:55 +0200 | [diff] [blame] | 3049 | static const struct display_timing nec_nl12880bc20_05_timing = { |
| 3050 | .pixelclock = { 67000000, 71000000, 75000000 }, |
| 3051 | .hactive = { 1280, 1280, 1280 }, |
| 3052 | .hfront_porch = { 2, 30, 30 }, |
| 3053 | .hback_porch = { 6, 100, 100 }, |
| 3054 | .hsync_len = { 2, 30, 30 }, |
| 3055 | .vactive = { 800, 800, 800 }, |
| 3056 | .vfront_porch = { 5, 5, 5 }, |
| 3057 | .vback_porch = { 11, 11, 11 }, |
| 3058 | .vsync_len = { 7, 7, 7 }, |
| 3059 | }; |
| 3060 | |
| 3061 | static const struct panel_desc nec_nl12880bc20_05 = { |
| 3062 | .timings = &nec_nl12880bc20_05_timing, |
| 3063 | .num_timings = 1, |
| 3064 | .bpc = 8, |
| 3065 | .size = { |
| 3066 | .width = 261, |
| 3067 | .height = 163, |
| 3068 | }, |
| 3069 | .delay = { |
| 3070 | .enable = 50, |
| 3071 | .disable = 50, |
| 3072 | }, |
| 3073 | .bus_format = MEDIA_BUS_FMT_RGB888_1X7X4_SPWG, |
Laurent Pinchart | 9a2654c | 2019-09-04 16:28:03 +0300 | [diff] [blame] | 3074 | .connector_type = DRM_MODE_CONNECTOR_LVDS, |
Lucas Stach | 01bacc13 | 2017-06-08 20:07:55 +0200 | [diff] [blame] | 3075 | }; |
| 3076 | |
jianwei wang | c6e87f9 | 2015-07-29 16:30:02 +0800 | [diff] [blame] | 3077 | static const struct drm_display_mode nec_nl4827hc19_05b_mode = { |
| 3078 | .clock = 10870, |
| 3079 | .hdisplay = 480, |
| 3080 | .hsync_start = 480 + 2, |
| 3081 | .hsync_end = 480 + 2 + 41, |
| 3082 | .htotal = 480 + 2 + 41 + 2, |
| 3083 | .vdisplay = 272, |
| 3084 | .vsync_start = 272 + 2, |
| 3085 | .vsync_end = 272 + 2 + 4, |
| 3086 | .vtotal = 272 + 2 + 4 + 2, |
Stefan Agner | 4bc390c | 2015-11-17 19:10:29 -0800 | [diff] [blame] | 3087 | .flags = DRM_MODE_FLAG_NVSYNC | DRM_MODE_FLAG_NHSYNC, |
jianwei wang | c6e87f9 | 2015-07-29 16:30:02 +0800 | [diff] [blame] | 3088 | }; |
| 3089 | |
| 3090 | static const struct panel_desc nec_nl4827hc19_05b = { |
| 3091 | .modes = &nec_nl4827hc19_05b_mode, |
| 3092 | .num_modes = 1, |
| 3093 | .bpc = 8, |
| 3094 | .size = { |
| 3095 | .width = 95, |
| 3096 | .height = 54, |
| 3097 | }, |
Stefan Agner | 2c80661 | 2016-02-08 12:50:13 -0800 | [diff] [blame] | 3098 | .bus_format = MEDIA_BUS_FMT_RGB888_1X24, |
Laurent Pinchart | 88bc417 | 2018-09-22 15:02:42 +0300 | [diff] [blame] | 3099 | .bus_flags = DRM_BUS_FLAG_PIXDATA_DRIVE_POSEDGE, |
jianwei wang | c6e87f9 | 2015-07-29 16:30:02 +0800 | [diff] [blame] | 3100 | }; |
| 3101 | |
Maxime Ripard | e6c2f06 | 2016-09-06 16:46:17 +0200 | [diff] [blame] | 3102 | static const struct drm_display_mode netron_dy_e231732_mode = { |
| 3103 | .clock = 66000, |
| 3104 | .hdisplay = 1024, |
| 3105 | .hsync_start = 1024 + 160, |
| 3106 | .hsync_end = 1024 + 160 + 70, |
| 3107 | .htotal = 1024 + 160 + 70 + 90, |
| 3108 | .vdisplay = 600, |
| 3109 | .vsync_start = 600 + 127, |
| 3110 | .vsync_end = 600 + 127 + 20, |
| 3111 | .vtotal = 600 + 127 + 20 + 3, |
Maxime Ripard | e6c2f06 | 2016-09-06 16:46:17 +0200 | [diff] [blame] | 3112 | }; |
| 3113 | |
| 3114 | static const struct panel_desc netron_dy_e231732 = { |
| 3115 | .modes = &netron_dy_e231732_mode, |
| 3116 | .num_modes = 1, |
| 3117 | .size = { |
| 3118 | .width = 154, |
| 3119 | .height = 87, |
| 3120 | }, |
| 3121 | .bus_format = MEDIA_BUS_FMT_RGB666_1X18, |
| 3122 | }; |
| 3123 | |
Vasily Khoruzhick | 258145e | 2020-02-26 00:10:10 -0800 | [diff] [blame] | 3124 | static const struct drm_display_mode neweast_wjfh116008a_modes[] = { |
| 3125 | { |
| 3126 | .clock = 138500, |
| 3127 | .hdisplay = 1920, |
| 3128 | .hsync_start = 1920 + 48, |
| 3129 | .hsync_end = 1920 + 48 + 32, |
| 3130 | .htotal = 1920 + 48 + 32 + 80, |
| 3131 | .vdisplay = 1080, |
| 3132 | .vsync_start = 1080 + 3, |
| 3133 | .vsync_end = 1080 + 3 + 5, |
| 3134 | .vtotal = 1080 + 3 + 5 + 23, |
Vasily Khoruzhick | 258145e | 2020-02-26 00:10:10 -0800 | [diff] [blame] | 3135 | .flags = DRM_MODE_FLAG_NVSYNC | DRM_MODE_FLAG_NHSYNC, |
| 3136 | }, { |
| 3137 | .clock = 110920, |
| 3138 | .hdisplay = 1920, |
| 3139 | .hsync_start = 1920 + 48, |
| 3140 | .hsync_end = 1920 + 48 + 32, |
| 3141 | .htotal = 1920 + 48 + 32 + 80, |
| 3142 | .vdisplay = 1080, |
| 3143 | .vsync_start = 1080 + 3, |
| 3144 | .vsync_end = 1080 + 3 + 5, |
| 3145 | .vtotal = 1080 + 3 + 5 + 23, |
Vasily Khoruzhick | 258145e | 2020-02-26 00:10:10 -0800 | [diff] [blame] | 3146 | .flags = DRM_MODE_FLAG_NVSYNC | DRM_MODE_FLAG_NHSYNC, |
| 3147 | } |
| 3148 | }; |
| 3149 | |
| 3150 | static const struct panel_desc neweast_wjfh116008a = { |
| 3151 | .modes = neweast_wjfh116008a_modes, |
| 3152 | .num_modes = 2, |
| 3153 | .bpc = 6, |
| 3154 | .size = { |
| 3155 | .width = 260, |
| 3156 | .height = 150, |
| 3157 | }, |
| 3158 | .delay = { |
| 3159 | .prepare = 110, |
| 3160 | .enable = 20, |
| 3161 | .unprepare = 500, |
| 3162 | }, |
| 3163 | .bus_format = MEDIA_BUS_FMT_RGB666_1X18, |
| 3164 | .connector_type = DRM_MODE_CONNECTOR_eDP, |
| 3165 | }; |
| 3166 | |
Tomi Valkeinen | 3b39ad7 | 2018-06-18 16:22:40 +0300 | [diff] [blame] | 3167 | static const struct drm_display_mode newhaven_nhd_43_480272ef_atxl_mode = { |
| 3168 | .clock = 9000, |
| 3169 | .hdisplay = 480, |
| 3170 | .hsync_start = 480 + 2, |
| 3171 | .hsync_end = 480 + 2 + 41, |
| 3172 | .htotal = 480 + 2 + 41 + 2, |
| 3173 | .vdisplay = 272, |
| 3174 | .vsync_start = 272 + 2, |
| 3175 | .vsync_end = 272 + 2 + 10, |
| 3176 | .vtotal = 272 + 2 + 10 + 2, |
Tomi Valkeinen | 3b39ad7 | 2018-06-18 16:22:40 +0300 | [diff] [blame] | 3177 | .flags = DRM_MODE_FLAG_NVSYNC | DRM_MODE_FLAG_NHSYNC, |
| 3178 | }; |
| 3179 | |
| 3180 | static const struct panel_desc newhaven_nhd_43_480272ef_atxl = { |
| 3181 | .modes = &newhaven_nhd_43_480272ef_atxl_mode, |
| 3182 | .num_modes = 1, |
| 3183 | .bpc = 8, |
| 3184 | .size = { |
| 3185 | .width = 95, |
| 3186 | .height = 54, |
| 3187 | }, |
| 3188 | .bus_format = MEDIA_BUS_FMT_RGB888_1X24, |
Laurent Pinchart | 88bc417 | 2018-09-22 15:02:42 +0300 | [diff] [blame] | 3189 | .bus_flags = DRM_BUS_FLAG_DE_HIGH | DRM_BUS_FLAG_PIXDATA_DRIVE_POSEDGE | |
| 3190 | DRM_BUS_FLAG_SYNC_DRIVE_POSEDGE, |
Tomi Valkeinen | 8a4f5e1 | 2020-06-09 13:28:09 +0300 | [diff] [blame] | 3191 | .connector_type = DRM_MODE_CONNECTOR_DPI, |
Tomi Valkeinen | 3b39ad7 | 2018-06-18 16:22:40 +0300 | [diff] [blame] | 3192 | }; |
| 3193 | |
Lucas Stach | 4177fa6 | 2017-06-08 20:07:57 +0200 | [diff] [blame] | 3194 | static const struct display_timing nlt_nl192108ac18_02d_timing = { |
| 3195 | .pixelclock = { 130000000, 148350000, 163000000 }, |
| 3196 | .hactive = { 1920, 1920, 1920 }, |
| 3197 | .hfront_porch = { 80, 100, 100 }, |
| 3198 | .hback_porch = { 100, 120, 120 }, |
| 3199 | .hsync_len = { 50, 60, 60 }, |
| 3200 | .vactive = { 1080, 1080, 1080 }, |
| 3201 | .vfront_porch = { 12, 30, 30 }, |
| 3202 | .vback_porch = { 4, 10, 10 }, |
| 3203 | .vsync_len = { 4, 5, 5 }, |
| 3204 | }; |
| 3205 | |
| 3206 | static const struct panel_desc nlt_nl192108ac18_02d = { |
| 3207 | .timings = &nlt_nl192108ac18_02d_timing, |
| 3208 | .num_timings = 1, |
| 3209 | .bpc = 8, |
| 3210 | .size = { |
| 3211 | .width = 344, |
| 3212 | .height = 194, |
| 3213 | }, |
| 3214 | .delay = { |
| 3215 | .unprepare = 500, |
| 3216 | }, |
| 3217 | .bus_format = MEDIA_BUS_FMT_RGB888_1X7X4_SPWG, |
Laurent Pinchart | 9a2654c | 2019-09-04 16:28:03 +0300 | [diff] [blame] | 3218 | .connector_type = DRM_MODE_CONNECTOR_LVDS, |
Lucas Stach | 4177fa6 | 2017-06-08 20:07:57 +0200 | [diff] [blame] | 3219 | }; |
| 3220 | |
Fabien Lahoudere | 05ec0e4 | 2016-10-17 11:38:01 +0200 | [diff] [blame] | 3221 | static const struct drm_display_mode nvd_9128_mode = { |
| 3222 | .clock = 29500, |
| 3223 | .hdisplay = 800, |
| 3224 | .hsync_start = 800 + 130, |
| 3225 | .hsync_end = 800 + 130 + 98, |
| 3226 | .htotal = 800 + 0 + 130 + 98, |
| 3227 | .vdisplay = 480, |
| 3228 | .vsync_start = 480 + 10, |
| 3229 | .vsync_end = 480 + 10 + 50, |
| 3230 | .vtotal = 480 + 0 + 10 + 50, |
| 3231 | }; |
| 3232 | |
| 3233 | static const struct panel_desc nvd_9128 = { |
| 3234 | .modes = &nvd_9128_mode, |
| 3235 | .num_modes = 1, |
| 3236 | .bpc = 8, |
| 3237 | .size = { |
| 3238 | .width = 156, |
| 3239 | .height = 88, |
| 3240 | }, |
| 3241 | .bus_format = MEDIA_BUS_FMT_RGB888_1X7X4_SPWG, |
Laurent Pinchart | 9a2654c | 2019-09-04 16:28:03 +0300 | [diff] [blame] | 3242 | .connector_type = DRM_MODE_CONNECTOR_LVDS, |
Fabien Lahoudere | 05ec0e4 | 2016-10-17 11:38:01 +0200 | [diff] [blame] | 3243 | }; |
| 3244 | |
Gary Bisson | a99fb62 | 2015-06-10 18:44:23 +0200 | [diff] [blame] | 3245 | static const struct display_timing okaya_rs800480t_7x0gp_timing = { |
| 3246 | .pixelclock = { 30000000, 30000000, 40000000 }, |
| 3247 | .hactive = { 800, 800, 800 }, |
| 3248 | .hfront_porch = { 40, 40, 40 }, |
| 3249 | .hback_porch = { 40, 40, 40 }, |
| 3250 | .hsync_len = { 1, 48, 48 }, |
| 3251 | .vactive = { 480, 480, 480 }, |
| 3252 | .vfront_porch = { 13, 13, 13 }, |
| 3253 | .vback_porch = { 29, 29, 29 }, |
| 3254 | .vsync_len = { 3, 3, 3 }, |
| 3255 | .flags = DISPLAY_FLAGS_DE_HIGH, |
| 3256 | }; |
| 3257 | |
| 3258 | static const struct panel_desc okaya_rs800480t_7x0gp = { |
| 3259 | .timings = &okaya_rs800480t_7x0gp_timing, |
| 3260 | .num_timings = 1, |
| 3261 | .bpc = 6, |
| 3262 | .size = { |
| 3263 | .width = 154, |
| 3264 | .height = 87, |
| 3265 | }, |
| 3266 | .delay = { |
| 3267 | .prepare = 41, |
| 3268 | .enable = 50, |
| 3269 | .unprepare = 41, |
| 3270 | .disable = 50, |
| 3271 | }, |
| 3272 | .bus_format = MEDIA_BUS_FMT_RGB666_1X18, |
| 3273 | }; |
| 3274 | |
Maxime Ripard | cf5c9e6 | 2016-03-23 17:38:34 +0100 | [diff] [blame] | 3275 | static const struct drm_display_mode olimex_lcd_olinuxino_43ts_mode = { |
| 3276 | .clock = 9000, |
| 3277 | .hdisplay = 480, |
| 3278 | .hsync_start = 480 + 5, |
| 3279 | .hsync_end = 480 + 5 + 30, |
| 3280 | .htotal = 480 + 5 + 30 + 10, |
| 3281 | .vdisplay = 272, |
| 3282 | .vsync_start = 272 + 8, |
| 3283 | .vsync_end = 272 + 8 + 5, |
| 3284 | .vtotal = 272 + 8 + 5 + 3, |
Maxime Ripard | cf5c9e6 | 2016-03-23 17:38:34 +0100 | [diff] [blame] | 3285 | }; |
| 3286 | |
| 3287 | static const struct panel_desc olimex_lcd_olinuxino_43ts = { |
| 3288 | .modes = &olimex_lcd_olinuxino_43ts_mode, |
| 3289 | .num_modes = 1, |
| 3290 | .size = { |
Jonathan Liu | 30c6d7ab9 | 2017-07-20 20:29:43 +1000 | [diff] [blame] | 3291 | .width = 95, |
| 3292 | .height = 54, |
Maxime Ripard | cf5c9e6 | 2016-03-23 17:38:34 +0100 | [diff] [blame] | 3293 | }, |
Jonathan Liu | 5c2a7c6 | 2016-09-11 20:46:55 +1000 | [diff] [blame] | 3294 | .bus_format = MEDIA_BUS_FMT_RGB888_1X24, |
Maxime Ripard | cf5c9e6 | 2016-03-23 17:38:34 +0100 | [diff] [blame] | 3295 | }; |
| 3296 | |
Eric Anholt | e8b6f56 | 2016-03-24 17:23:48 -0700 | [diff] [blame] | 3297 | /* |
| 3298 | * 800x480 CVT. The panel appears to be quite accepting, at least as far as |
| 3299 | * pixel clocks, but this is the timing that was being used in the Adafruit |
| 3300 | * installation instructions. |
| 3301 | */ |
| 3302 | static const struct drm_display_mode ontat_yx700wv03_mode = { |
| 3303 | .clock = 29500, |
| 3304 | .hdisplay = 800, |
| 3305 | .hsync_start = 824, |
| 3306 | .hsync_end = 896, |
| 3307 | .htotal = 992, |
| 3308 | .vdisplay = 480, |
| 3309 | .vsync_start = 483, |
| 3310 | .vsync_end = 493, |
| 3311 | .vtotal = 500, |
Eric Anholt | e8b6f56 | 2016-03-24 17:23:48 -0700 | [diff] [blame] | 3312 | .flags = DRM_MODE_FLAG_NVSYNC | DRM_MODE_FLAG_NHSYNC, |
| 3313 | }; |
| 3314 | |
| 3315 | /* |
| 3316 | * Specification at: |
| 3317 | * https://www.adafruit.com/images/product-files/2406/c3163.pdf |
| 3318 | */ |
| 3319 | static const struct panel_desc ontat_yx700wv03 = { |
| 3320 | .modes = &ontat_yx700wv03_mode, |
| 3321 | .num_modes = 1, |
| 3322 | .bpc = 8, |
| 3323 | .size = { |
| 3324 | .width = 154, |
| 3325 | .height = 83, |
| 3326 | }, |
Eric Anholt | 5651e5e | 2018-03-09 15:33:32 -0800 | [diff] [blame] | 3327 | .bus_format = MEDIA_BUS_FMT_RGB666_1X18, |
Eric Anholt | e8b6f56 | 2016-03-24 17:23:48 -0700 | [diff] [blame] | 3328 | }; |
| 3329 | |
H. Nikolaus Schaller | 9c31dcb | 2019-06-07 13:11:08 +0200 | [diff] [blame] | 3330 | static const struct drm_display_mode ortustech_com37h3m_mode = { |
H. Nikolaus Schaller | 855e764 | 2020-03-10 08:43:19 +0100 | [diff] [blame] | 3331 | .clock = 22230, |
H. Nikolaus Schaller | 9c31dcb | 2019-06-07 13:11:08 +0200 | [diff] [blame] | 3332 | .hdisplay = 480, |
H. Nikolaus Schaller | 855e764 | 2020-03-10 08:43:19 +0100 | [diff] [blame] | 3333 | .hsync_start = 480 + 40, |
| 3334 | .hsync_end = 480 + 40 + 10, |
| 3335 | .htotal = 480 + 40 + 10 + 40, |
H. Nikolaus Schaller | 9c31dcb | 2019-06-07 13:11:08 +0200 | [diff] [blame] | 3336 | .vdisplay = 640, |
| 3337 | .vsync_start = 640 + 4, |
H. Nikolaus Schaller | 855e764 | 2020-03-10 08:43:19 +0100 | [diff] [blame] | 3338 | .vsync_end = 640 + 4 + 2, |
| 3339 | .vtotal = 640 + 4 + 2 + 4, |
H. Nikolaus Schaller | 9c31dcb | 2019-06-07 13:11:08 +0200 | [diff] [blame] | 3340 | .flags = DRM_MODE_FLAG_NVSYNC | DRM_MODE_FLAG_NHSYNC, |
| 3341 | }; |
| 3342 | |
| 3343 | static const struct panel_desc ortustech_com37h3m = { |
| 3344 | .modes = &ortustech_com37h3m_mode, |
| 3345 | .num_modes = 1, |
| 3346 | .bpc = 8, |
| 3347 | .size = { |
| 3348 | .width = 56, /* 56.16mm */ |
| 3349 | .height = 75, /* 74.88mm */ |
| 3350 | }, |
| 3351 | .bus_format = MEDIA_BUS_FMT_RGB888_1X24, |
Sam Ravnborg | f5436f7 | 2020-06-30 20:05:43 +0200 | [diff] [blame] | 3352 | .bus_flags = DRM_BUS_FLAG_DE_HIGH | DRM_BUS_FLAG_PIXDATA_SAMPLE_NEGEDGE | |
H. Nikolaus Schaller | 9c31dcb | 2019-06-07 13:11:08 +0200 | [diff] [blame] | 3353 | DRM_BUS_FLAG_SYNC_DRIVE_POSEDGE, |
| 3354 | }; |
| 3355 | |
Philipp Zabel | 725c9d4 | 2015-02-11 18:50:11 +0100 | [diff] [blame] | 3356 | static const struct drm_display_mode ortustech_com43h4m85ulc_mode = { |
| 3357 | .clock = 25000, |
| 3358 | .hdisplay = 480, |
| 3359 | .hsync_start = 480 + 10, |
| 3360 | .hsync_end = 480 + 10 + 10, |
| 3361 | .htotal = 480 + 10 + 10 + 15, |
| 3362 | .vdisplay = 800, |
| 3363 | .vsync_start = 800 + 3, |
| 3364 | .vsync_end = 800 + 3 + 3, |
| 3365 | .vtotal = 800 + 3 + 3 + 3, |
Philipp Zabel | 725c9d4 | 2015-02-11 18:50:11 +0100 | [diff] [blame] | 3366 | }; |
| 3367 | |
| 3368 | static const struct panel_desc ortustech_com43h4m85ulc = { |
| 3369 | .modes = &ortustech_com43h4m85ulc_mode, |
| 3370 | .num_modes = 1, |
Laurent Pinchart | 3b80951 | 2020-08-24 03:32:54 +0300 | [diff] [blame] | 3371 | .bpc = 6, |
Philipp Zabel | 725c9d4 | 2015-02-11 18:50:11 +0100 | [diff] [blame] | 3372 | .size = { |
| 3373 | .width = 56, |
| 3374 | .height = 93, |
| 3375 | }, |
Laurent Pinchart | f098f16 | 2020-08-13 01:02:44 +0300 | [diff] [blame] | 3376 | .bus_format = MEDIA_BUS_FMT_RGB666_1X18, |
Laurent Pinchart | 88bc417 | 2018-09-22 15:02:42 +0300 | [diff] [blame] | 3377 | .bus_flags = DRM_BUS_FLAG_DE_HIGH | DRM_BUS_FLAG_PIXDATA_DRIVE_POSEDGE, |
Laurent Pinchart | 2ccedf4 | 2020-03-09 20:42:10 +0200 | [diff] [blame] | 3378 | .connector_type = DRM_MODE_CONNECTOR_DPI, |
Philipp Zabel | 725c9d4 | 2015-02-11 18:50:11 +0100 | [diff] [blame] | 3379 | }; |
| 3380 | |
Laurent Pinchart | 163f7a3 | 2018-12-07 22:13:44 +0200 | [diff] [blame] | 3381 | static const struct drm_display_mode osddisplays_osd070t1718_19ts_mode = { |
| 3382 | .clock = 33000, |
| 3383 | .hdisplay = 800, |
| 3384 | .hsync_start = 800 + 210, |
| 3385 | .hsync_end = 800 + 210 + 30, |
| 3386 | .htotal = 800 + 210 + 30 + 16, |
| 3387 | .vdisplay = 480, |
| 3388 | .vsync_start = 480 + 22, |
| 3389 | .vsync_end = 480 + 22 + 13, |
| 3390 | .vtotal = 480 + 22 + 13 + 10, |
Laurent Pinchart | 163f7a3 | 2018-12-07 22:13:44 +0200 | [diff] [blame] | 3391 | .flags = DRM_MODE_FLAG_NVSYNC | DRM_MODE_FLAG_NHSYNC, |
| 3392 | }; |
| 3393 | |
| 3394 | static const struct panel_desc osddisplays_osd070t1718_19ts = { |
| 3395 | .modes = &osddisplays_osd070t1718_19ts_mode, |
| 3396 | .num_modes = 1, |
| 3397 | .bpc = 8, |
| 3398 | .size = { |
| 3399 | .width = 152, |
| 3400 | .height = 91, |
| 3401 | }, |
| 3402 | .bus_format = MEDIA_BUS_FMT_RGB888_1X24, |
Tomi Valkeinen | fb0629e | 2019-11-14 11:39:50 +0200 | [diff] [blame] | 3403 | .bus_flags = DRM_BUS_FLAG_DE_HIGH | DRM_BUS_FLAG_PIXDATA_DRIVE_POSEDGE | |
| 3404 | DRM_BUS_FLAG_SYNC_DRIVE_POSEDGE, |
Laurent Pinchart | a793f0e | 2019-09-04 16:37:23 +0300 | [diff] [blame] | 3405 | .connector_type = DRM_MODE_CONNECTOR_DPI, |
Laurent Pinchart | 163f7a3 | 2018-12-07 22:13:44 +0200 | [diff] [blame] | 3406 | }; |
| 3407 | |
Eugen Hristev | 4ba3e56 | 2019-01-14 09:43:31 +0000 | [diff] [blame] | 3408 | static const struct drm_display_mode pda_91_00156_a0_mode = { |
| 3409 | .clock = 33300, |
| 3410 | .hdisplay = 800, |
| 3411 | .hsync_start = 800 + 1, |
| 3412 | .hsync_end = 800 + 1 + 64, |
| 3413 | .htotal = 800 + 1 + 64 + 64, |
| 3414 | .vdisplay = 480, |
| 3415 | .vsync_start = 480 + 1, |
| 3416 | .vsync_end = 480 + 1 + 23, |
| 3417 | .vtotal = 480 + 1 + 23 + 22, |
Eugen Hristev | 4ba3e56 | 2019-01-14 09:43:31 +0000 | [diff] [blame] | 3418 | }; |
| 3419 | |
| 3420 | static const struct panel_desc pda_91_00156_a0 = { |
| 3421 | .modes = &pda_91_00156_a0_mode, |
| 3422 | .num_modes = 1, |
| 3423 | .size = { |
| 3424 | .width = 152, |
| 3425 | .height = 91, |
| 3426 | }, |
| 3427 | .bus_format = MEDIA_BUS_FMT_RGB888_1X24, |
| 3428 | }; |
| 3429 | |
Marek Vasut | d69de69 | 2020-07-28 14:12:46 +0200 | [diff] [blame] | 3430 | static const struct drm_display_mode powertip_ph800480t013_idf02_mode = { |
| 3431 | .clock = 24750, |
| 3432 | .hdisplay = 800, |
| 3433 | .hsync_start = 800 + 54, |
| 3434 | .hsync_end = 800 + 54 + 2, |
| 3435 | .htotal = 800 + 54 + 2 + 44, |
| 3436 | .vdisplay = 480, |
| 3437 | .vsync_start = 480 + 49, |
| 3438 | .vsync_end = 480 + 49 + 2, |
| 3439 | .vtotal = 480 + 49 + 2 + 22, |
| 3440 | }; |
| 3441 | |
| 3442 | static const struct panel_desc powertip_ph800480t013_idf02 = { |
| 3443 | .modes = &powertip_ph800480t013_idf02_mode, |
| 3444 | .num_modes = 1, |
| 3445 | .size = { |
| 3446 | .width = 152, |
| 3447 | .height = 91, |
| 3448 | }, |
| 3449 | .bus_flags = DRM_BUS_FLAG_DE_HIGH | |
| 3450 | DRM_BUS_FLAG_PIXDATA_SAMPLE_NEGEDGE | |
| 3451 | DRM_BUS_FLAG_SYNC_SAMPLE_NEGEDGE, |
| 3452 | .bus_format = MEDIA_BUS_FMT_RGB888_1X24, |
| 3453 | .connector_type = DRM_MODE_CONNECTOR_DPI, |
| 3454 | }; |
Eugen Hristev | 4ba3e56 | 2019-01-14 09:43:31 +0000 | [diff] [blame] | 3455 | |
Josh Wu | d2a6f0f | 2015-10-08 17:42:41 +0200 | [diff] [blame] | 3456 | static const struct drm_display_mode qd43003c0_40_mode = { |
| 3457 | .clock = 9000, |
| 3458 | .hdisplay = 480, |
| 3459 | .hsync_start = 480 + 8, |
| 3460 | .hsync_end = 480 + 8 + 4, |
| 3461 | .htotal = 480 + 8 + 4 + 39, |
| 3462 | .vdisplay = 272, |
| 3463 | .vsync_start = 272 + 4, |
| 3464 | .vsync_end = 272 + 4 + 10, |
| 3465 | .vtotal = 272 + 4 + 10 + 2, |
Josh Wu | d2a6f0f | 2015-10-08 17:42:41 +0200 | [diff] [blame] | 3466 | }; |
| 3467 | |
| 3468 | static const struct panel_desc qd43003c0_40 = { |
| 3469 | .modes = &qd43003c0_40_mode, |
| 3470 | .num_modes = 1, |
| 3471 | .bpc = 8, |
| 3472 | .size = { |
| 3473 | .width = 95, |
| 3474 | .height = 53, |
| 3475 | }, |
| 3476 | .bus_format = MEDIA_BUS_FMT_RGB888_1X24, |
| 3477 | }; |
| 3478 | |
Jagan Teki | 23167fa | 2018-06-07 19:16:48 +0530 | [diff] [blame] | 3479 | static const struct display_timing rocktech_rk070er9427_timing = { |
| 3480 | .pixelclock = { 26400000, 33300000, 46800000 }, |
| 3481 | .hactive = { 800, 800, 800 }, |
| 3482 | .hfront_porch = { 16, 210, 354 }, |
| 3483 | .hback_porch = { 46, 46, 46 }, |
| 3484 | .hsync_len = { 1, 1, 1 }, |
| 3485 | .vactive = { 480, 480, 480 }, |
| 3486 | .vfront_porch = { 7, 22, 147 }, |
| 3487 | .vback_porch = { 23, 23, 23 }, |
| 3488 | .vsync_len = { 1, 1, 1 }, |
| 3489 | .flags = DISPLAY_FLAGS_DE_HIGH, |
| 3490 | }; |
| 3491 | |
| 3492 | static const struct panel_desc rocktech_rk070er9427 = { |
| 3493 | .timings = &rocktech_rk070er9427_timing, |
| 3494 | .num_timings = 1, |
| 3495 | .bpc = 6, |
| 3496 | .size = { |
| 3497 | .width = 154, |
| 3498 | .height = 86, |
| 3499 | }, |
| 3500 | .delay = { |
| 3501 | .prepare = 41, |
| 3502 | .enable = 50, |
| 3503 | .unprepare = 41, |
| 3504 | .disable = 50, |
| 3505 | }, |
| 3506 | .bus_format = MEDIA_BUS_FMT_RGB666_1X18, |
| 3507 | }; |
| 3508 | |
Jyri Sarha | f305047 | 2020-02-11 14:17:18 +0200 | [diff] [blame] | 3509 | static const struct drm_display_mode rocktech_rk101ii01d_ct_mode = { |
| 3510 | .clock = 71100, |
| 3511 | .hdisplay = 1280, |
| 3512 | .hsync_start = 1280 + 48, |
| 3513 | .hsync_end = 1280 + 48 + 32, |
| 3514 | .htotal = 1280 + 48 + 32 + 80, |
| 3515 | .vdisplay = 800, |
| 3516 | .vsync_start = 800 + 2, |
| 3517 | .vsync_end = 800 + 2 + 5, |
| 3518 | .vtotal = 800 + 2 + 5 + 16, |
Jyri Sarha | f305047 | 2020-02-11 14:17:18 +0200 | [diff] [blame] | 3519 | }; |
| 3520 | |
| 3521 | static const struct panel_desc rocktech_rk101ii01d_ct = { |
| 3522 | .modes = &rocktech_rk101ii01d_ct_mode, |
| 3523 | .num_modes = 1, |
| 3524 | .size = { |
| 3525 | .width = 217, |
| 3526 | .height = 136, |
| 3527 | }, |
| 3528 | .delay = { |
| 3529 | .prepare = 50, |
| 3530 | .disable = 50, |
| 3531 | }, |
| 3532 | .bus_flags = DRM_BUS_FLAG_DE_HIGH, |
| 3533 | .bus_format = MEDIA_BUS_FMT_RGB888_1X7X4_SPWG, |
| 3534 | .connector_type = DRM_MODE_CONNECTOR_LVDS, |
| 3535 | }; |
| 3536 | |
Yakir Yang | 0330eaf | 2016-06-12 10:56:13 +0800 | [diff] [blame] | 3537 | static const struct drm_display_mode samsung_lsn122dl01_c01_mode = { |
| 3538 | .clock = 271560, |
| 3539 | .hdisplay = 2560, |
| 3540 | .hsync_start = 2560 + 48, |
| 3541 | .hsync_end = 2560 + 48 + 32, |
| 3542 | .htotal = 2560 + 48 + 32 + 80, |
| 3543 | .vdisplay = 1600, |
| 3544 | .vsync_start = 1600 + 2, |
| 3545 | .vsync_end = 1600 + 2 + 5, |
| 3546 | .vtotal = 1600 + 2 + 5 + 57, |
Yakir Yang | 0330eaf | 2016-06-12 10:56:13 +0800 | [diff] [blame] | 3547 | }; |
| 3548 | |
| 3549 | static const struct panel_desc samsung_lsn122dl01_c01 = { |
| 3550 | .modes = &samsung_lsn122dl01_c01_mode, |
| 3551 | .num_modes = 1, |
| 3552 | .size = { |
| 3553 | .width = 263, |
| 3554 | .height = 164, |
| 3555 | }, |
| 3556 | }; |
| 3557 | |
Marc Dietrich | 6d54e3d | 2013-12-21 21:38:12 +0100 | [diff] [blame] | 3558 | static const struct drm_display_mode samsung_ltn101nt05_mode = { |
| 3559 | .clock = 54030, |
| 3560 | .hdisplay = 1024, |
| 3561 | .hsync_start = 1024 + 24, |
| 3562 | .hsync_end = 1024 + 24 + 136, |
| 3563 | .htotal = 1024 + 24 + 136 + 160, |
| 3564 | .vdisplay = 600, |
| 3565 | .vsync_start = 600 + 3, |
| 3566 | .vsync_end = 600 + 3 + 6, |
| 3567 | .vtotal = 600 + 3 + 6 + 61, |
Marc Dietrich | 6d54e3d | 2013-12-21 21:38:12 +0100 | [diff] [blame] | 3568 | }; |
| 3569 | |
| 3570 | static const struct panel_desc samsung_ltn101nt05 = { |
| 3571 | .modes = &samsung_ltn101nt05_mode, |
| 3572 | .num_modes = 1, |
Stéphane Marchesin | 0208d51 | 2014-06-19 18:18:28 -0700 | [diff] [blame] | 3573 | .bpc = 6, |
Marc Dietrich | 6d54e3d | 2013-12-21 21:38:12 +0100 | [diff] [blame] | 3574 | .size = { |
Thierry Reding | 8159884 | 2016-06-10 15:33:13 +0200 | [diff] [blame] | 3575 | .width = 223, |
| 3576 | .height = 125, |
Marc Dietrich | 6d54e3d | 2013-12-21 21:38:12 +0100 | [diff] [blame] | 3577 | }, |
Dmitry Osipenko | 8556082 | 2020-06-22 01:27:42 +0300 | [diff] [blame] | 3578 | .bus_format = MEDIA_BUS_FMT_RGB666_1X7X3_SPWG, |
Laurent Pinchart | c471583 | 2020-06-30 02:33:19 +0300 | [diff] [blame] | 3579 | .bus_flags = DRM_BUS_FLAG_DE_HIGH, |
Dmitry Osipenko | 94f0791 | 2020-06-18 01:27:03 +0300 | [diff] [blame] | 3580 | .connector_type = DRM_MODE_CONNECTOR_LVDS, |
Marc Dietrich | 6d54e3d | 2013-12-21 21:38:12 +0100 | [diff] [blame] | 3581 | }; |
| 3582 | |
Stéphane Marchesin | 0c93430 | 2015-03-18 10:52:18 +0100 | [diff] [blame] | 3583 | static const struct drm_display_mode samsung_ltn140at29_301_mode = { |
| 3584 | .clock = 76300, |
| 3585 | .hdisplay = 1366, |
| 3586 | .hsync_start = 1366 + 64, |
| 3587 | .hsync_end = 1366 + 64 + 48, |
| 3588 | .htotal = 1366 + 64 + 48 + 128, |
| 3589 | .vdisplay = 768, |
| 3590 | .vsync_start = 768 + 2, |
| 3591 | .vsync_end = 768 + 2 + 5, |
| 3592 | .vtotal = 768 + 2 + 5 + 17, |
Stéphane Marchesin | 0c93430 | 2015-03-18 10:52:18 +0100 | [diff] [blame] | 3593 | }; |
| 3594 | |
| 3595 | static const struct panel_desc samsung_ltn140at29_301 = { |
| 3596 | .modes = &samsung_ltn140at29_301_mode, |
| 3597 | .num_modes = 1, |
| 3598 | .bpc = 6, |
| 3599 | .size = { |
| 3600 | .width = 320, |
| 3601 | .height = 187, |
| 3602 | }, |
| 3603 | }; |
| 3604 | |
Miquel Raynal | 44c58c5 | 2020-01-09 19:40:37 +0100 | [diff] [blame] | 3605 | static const struct display_timing satoz_sat050at40h12r2_timing = { |
| 3606 | .pixelclock = {33300000, 33300000, 50000000}, |
| 3607 | .hactive = {800, 800, 800}, |
| 3608 | .hfront_porch = {16, 210, 354}, |
| 3609 | .hback_porch = {46, 46, 46}, |
| 3610 | .hsync_len = {1, 1, 40}, |
| 3611 | .vactive = {480, 480, 480}, |
| 3612 | .vfront_porch = {7, 22, 147}, |
| 3613 | .vback_porch = {23, 23, 23}, |
| 3614 | .vsync_len = {1, 1, 20}, |
| 3615 | }; |
| 3616 | |
| 3617 | static const struct panel_desc satoz_sat050at40h12r2 = { |
| 3618 | .timings = &satoz_sat050at40h12r2_timing, |
| 3619 | .num_timings = 1, |
| 3620 | .bpc = 8, |
| 3621 | .size = { |
| 3622 | .width = 108, |
| 3623 | .height = 65, |
| 3624 | }, |
Laurent Pinchart | 34ca6b5 | 2020-06-30 02:33:18 +0300 | [diff] [blame] | 3625 | .bus_format = MEDIA_BUS_FMT_RGB888_1X7X4_SPWG, |
Miquel Raynal | 44c58c5 | 2020-01-09 19:40:37 +0100 | [diff] [blame] | 3626 | .connector_type = DRM_MODE_CONNECTOR_LVDS, |
| 3627 | }; |
| 3628 | |
Jeffrey Hugo | cd5e1cb | 2019-07-08 09:58:11 -0700 | [diff] [blame] | 3629 | static const struct drm_display_mode sharp_ld_d5116z01b_mode = { |
| 3630 | .clock = 168480, |
| 3631 | .hdisplay = 1920, |
| 3632 | .hsync_start = 1920 + 48, |
| 3633 | .hsync_end = 1920 + 48 + 32, |
| 3634 | .htotal = 1920 + 48 + 32 + 80, |
| 3635 | .vdisplay = 1280, |
| 3636 | .vsync_start = 1280 + 3, |
| 3637 | .vsync_end = 1280 + 3 + 10, |
| 3638 | .vtotal = 1280 + 3 + 10 + 57, |
Jeffrey Hugo | cd5e1cb | 2019-07-08 09:58:11 -0700 | [diff] [blame] | 3639 | .flags = DRM_MODE_FLAG_PHSYNC | DRM_MODE_FLAG_PVSYNC, |
| 3640 | }; |
| 3641 | |
| 3642 | static const struct panel_desc sharp_ld_d5116z01b = { |
| 3643 | .modes = &sharp_ld_d5116z01b_mode, |
| 3644 | .num_modes = 1, |
| 3645 | .bpc = 8, |
| 3646 | .size = { |
| 3647 | .width = 260, |
| 3648 | .height = 120, |
| 3649 | }, |
| 3650 | .bus_format = MEDIA_BUS_FMT_RGB888_1X24, |
| 3651 | .bus_flags = DRM_BUS_FLAG_DATA_MSB_TO_LSB, |
| 3652 | }; |
| 3653 | |
H. Nikolaus Schaller | dda0e4b | 2019-06-07 13:11:07 +0200 | [diff] [blame] | 3654 | static const struct drm_display_mode sharp_lq070y3dg3b_mode = { |
| 3655 | .clock = 33260, |
| 3656 | .hdisplay = 800, |
| 3657 | .hsync_start = 800 + 64, |
| 3658 | .hsync_end = 800 + 64 + 128, |
| 3659 | .htotal = 800 + 64 + 128 + 64, |
| 3660 | .vdisplay = 480, |
| 3661 | .vsync_start = 480 + 8, |
| 3662 | .vsync_end = 480 + 8 + 2, |
| 3663 | .vtotal = 480 + 8 + 2 + 35, |
H. Nikolaus Schaller | dda0e4b | 2019-06-07 13:11:07 +0200 | [diff] [blame] | 3664 | .flags = DISPLAY_FLAGS_PIXDATA_POSEDGE, |
| 3665 | }; |
| 3666 | |
| 3667 | static const struct panel_desc sharp_lq070y3dg3b = { |
| 3668 | .modes = &sharp_lq070y3dg3b_mode, |
| 3669 | .num_modes = 1, |
| 3670 | .bpc = 8, |
| 3671 | .size = { |
| 3672 | .width = 152, /* 152.4mm */ |
| 3673 | .height = 91, /* 91.4mm */ |
| 3674 | }, |
| 3675 | .bus_format = MEDIA_BUS_FMT_RGB888_1X24, |
Sam Ravnborg | f5436f7 | 2020-06-30 20:05:43 +0200 | [diff] [blame] | 3676 | .bus_flags = DRM_BUS_FLAG_DE_HIGH | DRM_BUS_FLAG_PIXDATA_SAMPLE_NEGEDGE | |
H. Nikolaus Schaller | dda0e4b | 2019-06-07 13:11:07 +0200 | [diff] [blame] | 3677 | DRM_BUS_FLAG_SYNC_DRIVE_POSEDGE, |
| 3678 | }; |
| 3679 | |
Vladimir Zapolskiy | 03e3ec9 | 2018-07-06 21:51:01 +0300 | [diff] [blame] | 3680 | static const struct drm_display_mode sharp_lq035q7db03_mode = { |
| 3681 | .clock = 5500, |
| 3682 | .hdisplay = 240, |
| 3683 | .hsync_start = 240 + 16, |
| 3684 | .hsync_end = 240 + 16 + 7, |
| 3685 | .htotal = 240 + 16 + 7 + 5, |
| 3686 | .vdisplay = 320, |
| 3687 | .vsync_start = 320 + 9, |
| 3688 | .vsync_end = 320 + 9 + 1, |
| 3689 | .vtotal = 320 + 9 + 1 + 7, |
Vladimir Zapolskiy | 03e3ec9 | 2018-07-06 21:51:01 +0300 | [diff] [blame] | 3690 | }; |
| 3691 | |
| 3692 | static const struct panel_desc sharp_lq035q7db03 = { |
| 3693 | .modes = &sharp_lq035q7db03_mode, |
| 3694 | .num_modes = 1, |
| 3695 | .bpc = 6, |
| 3696 | .size = { |
| 3697 | .width = 54, |
| 3698 | .height = 72, |
| 3699 | }, |
| 3700 | .bus_format = MEDIA_BUS_FMT_RGB666_1X18, |
| 3701 | }; |
| 3702 | |
Joshua Clayton | 592aa02 | 2016-07-06 15:59:16 -0700 | [diff] [blame] | 3703 | static const struct display_timing sharp_lq101k1ly04_timing = { |
| 3704 | .pixelclock = { 60000000, 65000000, 80000000 }, |
| 3705 | .hactive = { 1280, 1280, 1280 }, |
| 3706 | .hfront_porch = { 20, 20, 20 }, |
| 3707 | .hback_porch = { 20, 20, 20 }, |
| 3708 | .hsync_len = { 10, 10, 10 }, |
| 3709 | .vactive = { 800, 800, 800 }, |
| 3710 | .vfront_porch = { 4, 4, 4 }, |
| 3711 | .vback_porch = { 4, 4, 4 }, |
| 3712 | .vsync_len = { 4, 4, 4 }, |
| 3713 | .flags = DISPLAY_FLAGS_PIXDATA_POSEDGE, |
| 3714 | }; |
| 3715 | |
| 3716 | static const struct panel_desc sharp_lq101k1ly04 = { |
| 3717 | .timings = &sharp_lq101k1ly04_timing, |
| 3718 | .num_timings = 1, |
| 3719 | .bpc = 8, |
| 3720 | .size = { |
| 3721 | .width = 217, |
| 3722 | .height = 136, |
| 3723 | }, |
| 3724 | .bus_format = MEDIA_BUS_FMT_RGB888_1X7X4_JEIDA, |
Laurent Pinchart | 9a2654c | 2019-09-04 16:28:03 +0300 | [diff] [blame] | 3725 | .connector_type = DRM_MODE_CONNECTOR_LVDS, |
Joshua Clayton | 592aa02 | 2016-07-06 15:59:16 -0700 | [diff] [blame] | 3726 | }; |
| 3727 | |
Sean Paul | 9f7bae2 | 2018-02-08 12:48:52 -0500 | [diff] [blame] | 3728 | static const struct display_timing sharp_lq123p1jx31_timing = { |
| 3729 | .pixelclock = { 252750000, 252750000, 266604720 }, |
| 3730 | .hactive = { 2400, 2400, 2400 }, |
| 3731 | .hfront_porch = { 48, 48, 48 }, |
| 3732 | .hback_porch = { 80, 80, 84 }, |
| 3733 | .hsync_len = { 32, 32, 32 }, |
| 3734 | .vactive = { 1600, 1600, 1600 }, |
| 3735 | .vfront_porch = { 3, 3, 3 }, |
| 3736 | .vback_porch = { 33, 33, 120 }, |
| 3737 | .vsync_len = { 10, 10, 10 }, |
| 3738 | .flags = DISPLAY_FLAGS_VSYNC_LOW | DISPLAY_FLAGS_HSYNC_LOW, |
Yakir Yang | 739c7de | 2016-06-12 10:56:35 +0800 | [diff] [blame] | 3739 | }; |
| 3740 | |
| 3741 | static const struct panel_desc sharp_lq123p1jx31 = { |
Sean Paul | 9f7bae2 | 2018-02-08 12:48:52 -0500 | [diff] [blame] | 3742 | .timings = &sharp_lq123p1jx31_timing, |
| 3743 | .num_timings = 1, |
zain wang | 5466a63 | 2016-11-19 10:27:16 +0800 | [diff] [blame] | 3744 | .bpc = 8, |
Yakir Yang | 739c7de | 2016-06-12 10:56:35 +0800 | [diff] [blame] | 3745 | .size = { |
| 3746 | .width = 259, |
| 3747 | .height = 173, |
| 3748 | }, |
Yakir Yang | a42f6e3 | 2016-07-21 21:14:34 +0800 | [diff] [blame] | 3749 | .delay = { |
| 3750 | .prepare = 110, |
| 3751 | .enable = 50, |
| 3752 | .unprepare = 550, |
| 3753 | }, |
Yakir Yang | 739c7de | 2016-06-12 10:56:35 +0800 | [diff] [blame] | 3754 | }; |
| 3755 | |
Paul Cercueil | 656b759 | 2020-08-11 02:22:38 +0200 | [diff] [blame] | 3756 | static const struct drm_display_mode sharp_ls020b1dd01d_modes[] = { |
Paul Cercueil | e6c21e6 | 2020-08-11 02:22:40 +0200 | [diff] [blame] | 3757 | { /* 50 Hz */ |
| 3758 | .clock = 3000, |
| 3759 | .hdisplay = 240, |
| 3760 | .hsync_start = 240 + 58, |
| 3761 | .hsync_end = 240 + 58 + 1, |
| 3762 | .htotal = 240 + 58 + 1 + 1, |
| 3763 | .vdisplay = 160, |
| 3764 | .vsync_start = 160 + 24, |
| 3765 | .vsync_end = 160 + 24 + 10, |
| 3766 | .vtotal = 160 + 24 + 10 + 6, |
| 3767 | .flags = DRM_MODE_FLAG_PHSYNC | DRM_MODE_FLAG_NVSYNC, |
| 3768 | }, |
Paul Cercueil | 656b759 | 2020-08-11 02:22:38 +0200 | [diff] [blame] | 3769 | { /* 60 Hz */ |
Paul Cercueil | c1bd32b | 2020-08-11 02:22:39 +0200 | [diff] [blame] | 3770 | .clock = 3000, |
Paul Cercueil | 656b759 | 2020-08-11 02:22:38 +0200 | [diff] [blame] | 3771 | .hdisplay = 240, |
Paul Cercueil | c1bd32b | 2020-08-11 02:22:39 +0200 | [diff] [blame] | 3772 | .hsync_start = 240 + 8, |
| 3773 | .hsync_end = 240 + 8 + 1, |
| 3774 | .htotal = 240 + 8 + 1 + 1, |
Paul Cercueil | 656b759 | 2020-08-11 02:22:38 +0200 | [diff] [blame] | 3775 | .vdisplay = 160, |
Paul Cercueil | c1bd32b | 2020-08-11 02:22:39 +0200 | [diff] [blame] | 3776 | .vsync_start = 160 + 24, |
| 3777 | .vsync_end = 160 + 24 + 10, |
| 3778 | .vtotal = 160 + 24 + 10 + 6, |
Paul Cercueil | 656b759 | 2020-08-11 02:22:38 +0200 | [diff] [blame] | 3779 | .flags = DRM_MODE_FLAG_PHSYNC | DRM_MODE_FLAG_NVSYNC, |
| 3780 | }, |
Paul Cercueil | f1bd37f | 2019-06-03 17:31:20 +0200 | [diff] [blame] | 3781 | }; |
| 3782 | |
| 3783 | static const struct panel_desc sharp_ls020b1dd01d = { |
Paul Cercueil | 656b759 | 2020-08-11 02:22:38 +0200 | [diff] [blame] | 3784 | .modes = sharp_ls020b1dd01d_modes, |
| 3785 | .num_modes = ARRAY_SIZE(sharp_ls020b1dd01d_modes), |
Paul Cercueil | f1bd37f | 2019-06-03 17:31:20 +0200 | [diff] [blame] | 3786 | .bpc = 6, |
| 3787 | .size = { |
| 3788 | .width = 42, |
| 3789 | .height = 28, |
| 3790 | }, |
| 3791 | .bus_format = MEDIA_BUS_FMT_RGB565_1X16, |
| 3792 | .bus_flags = DRM_BUS_FLAG_DE_HIGH |
Sam Ravnborg | f5436f7 | 2020-06-30 20:05:43 +0200 | [diff] [blame] | 3793 | | DRM_BUS_FLAG_PIXDATA_SAMPLE_POSEDGE |
Paul Cercueil | f1bd37f | 2019-06-03 17:31:20 +0200 | [diff] [blame] | 3794 | | DRM_BUS_FLAG_SHARP_SIGNALS, |
| 3795 | }; |
| 3796 | |
Boris BREZILLON | 9c6615b | 2015-03-19 14:43:00 +0100 | [diff] [blame] | 3797 | static const struct drm_display_mode shelly_sca07010_bfn_lnn_mode = { |
| 3798 | .clock = 33300, |
| 3799 | .hdisplay = 800, |
| 3800 | .hsync_start = 800 + 1, |
| 3801 | .hsync_end = 800 + 1 + 64, |
| 3802 | .htotal = 800 + 1 + 64 + 64, |
| 3803 | .vdisplay = 480, |
| 3804 | .vsync_start = 480 + 1, |
| 3805 | .vsync_end = 480 + 1 + 23, |
| 3806 | .vtotal = 480 + 1 + 23 + 22, |
Boris BREZILLON | 9c6615b | 2015-03-19 14:43:00 +0100 | [diff] [blame] | 3807 | }; |
| 3808 | |
| 3809 | static const struct panel_desc shelly_sca07010_bfn_lnn = { |
| 3810 | .modes = &shelly_sca07010_bfn_lnn_mode, |
| 3811 | .num_modes = 1, |
| 3812 | .size = { |
| 3813 | .width = 152, |
| 3814 | .height = 91, |
| 3815 | }, |
| 3816 | .bus_format = MEDIA_BUS_FMT_RGB666_1X18, |
| 3817 | }; |
| 3818 | |
Pascal Roeleven | 105235e | 2020-03-20 12:21:33 +0100 | [diff] [blame] | 3819 | static const struct drm_display_mode starry_kr070pe2t_mode = { |
| 3820 | .clock = 33000, |
| 3821 | .hdisplay = 800, |
| 3822 | .hsync_start = 800 + 209, |
| 3823 | .hsync_end = 800 + 209 + 1, |
| 3824 | .htotal = 800 + 209 + 1 + 45, |
| 3825 | .vdisplay = 480, |
| 3826 | .vsync_start = 480 + 22, |
| 3827 | .vsync_end = 480 + 22 + 1, |
| 3828 | .vtotal = 480 + 22 + 1 + 22, |
Pascal Roeleven | 105235e | 2020-03-20 12:21:33 +0100 | [diff] [blame] | 3829 | }; |
| 3830 | |
| 3831 | static const struct panel_desc starry_kr070pe2t = { |
| 3832 | .modes = &starry_kr070pe2t_mode, |
| 3833 | .num_modes = 1, |
| 3834 | .bpc = 8, |
| 3835 | .size = { |
| 3836 | .width = 152, |
| 3837 | .height = 86, |
| 3838 | }, |
| 3839 | .bus_format = MEDIA_BUS_FMT_RGB888_1X24, |
| 3840 | .bus_flags = DRM_BUS_FLAG_DE_HIGH | DRM_BUS_FLAG_PIXDATA_DRIVE_NEGEDGE, |
Laurent Pinchart | 41fad30 | 2020-06-30 02:33:17 +0300 | [diff] [blame] | 3841 | .connector_type = DRM_MODE_CONNECTOR_DPI, |
Pascal Roeleven | 105235e | 2020-03-20 12:21:33 +0100 | [diff] [blame] | 3842 | }; |
| 3843 | |
Douglas Anderson | 9bb34c4 | 2016-06-10 10:02:07 -0700 | [diff] [blame] | 3844 | static const struct drm_display_mode starry_kr122ea0sra_mode = { |
| 3845 | .clock = 147000, |
| 3846 | .hdisplay = 1920, |
| 3847 | .hsync_start = 1920 + 16, |
| 3848 | .hsync_end = 1920 + 16 + 16, |
| 3849 | .htotal = 1920 + 16 + 16 + 32, |
| 3850 | .vdisplay = 1200, |
| 3851 | .vsync_start = 1200 + 15, |
| 3852 | .vsync_end = 1200 + 15 + 2, |
| 3853 | .vtotal = 1200 + 15 + 2 + 18, |
Douglas Anderson | 9bb34c4 | 2016-06-10 10:02:07 -0700 | [diff] [blame] | 3854 | .flags = DRM_MODE_FLAG_NVSYNC | DRM_MODE_FLAG_NHSYNC, |
| 3855 | }; |
| 3856 | |
| 3857 | static const struct panel_desc starry_kr122ea0sra = { |
| 3858 | .modes = &starry_kr122ea0sra_mode, |
| 3859 | .num_modes = 1, |
| 3860 | .size = { |
| 3861 | .width = 263, |
| 3862 | .height = 164, |
| 3863 | }, |
Brian Norris | c46b924 | 2016-08-26 14:32:14 -0700 | [diff] [blame] | 3864 | .delay = { |
| 3865 | .prepare = 10 + 200, |
| 3866 | .enable = 50, |
| 3867 | .unprepare = 10 + 500, |
| 3868 | }, |
Douglas Anderson | 9bb34c4 | 2016-06-10 10:02:07 -0700 | [diff] [blame] | 3869 | }; |
| 3870 | |
Jyri Sarha | 4216153 | 2019-03-22 10:33:36 +0200 | [diff] [blame] | 3871 | static const struct drm_display_mode tfc_s9700rtwv43tr_01b_mode = { |
| 3872 | .clock = 30000, |
| 3873 | .hdisplay = 800, |
| 3874 | .hsync_start = 800 + 39, |
| 3875 | .hsync_end = 800 + 39 + 47, |
| 3876 | .htotal = 800 + 39 + 47 + 39, |
| 3877 | .vdisplay = 480, |
| 3878 | .vsync_start = 480 + 13, |
| 3879 | .vsync_end = 480 + 13 + 2, |
| 3880 | .vtotal = 480 + 13 + 2 + 29, |
Jyri Sarha | 4216153 | 2019-03-22 10:33:36 +0200 | [diff] [blame] | 3881 | }; |
| 3882 | |
| 3883 | static const struct panel_desc tfc_s9700rtwv43tr_01b = { |
| 3884 | .modes = &tfc_s9700rtwv43tr_01b_mode, |
| 3885 | .num_modes = 1, |
| 3886 | .bpc = 8, |
| 3887 | .size = { |
| 3888 | .width = 155, |
| 3889 | .height = 90, |
| 3890 | }, |
| 3891 | .bus_format = MEDIA_BUS_FMT_RGB888_1X24, |
Sam Ravnborg | f5436f7 | 2020-06-30 20:05:43 +0200 | [diff] [blame] | 3892 | .bus_flags = DRM_BUS_FLAG_DE_HIGH | DRM_BUS_FLAG_PIXDATA_SAMPLE_NEGEDGE, |
Jyri Sarha | 4216153 | 2019-03-22 10:33:36 +0200 | [diff] [blame] | 3893 | }; |
| 3894 | |
Gary Bisson | adb973e | 2016-12-02 09:52:08 +0100 | [diff] [blame] | 3895 | static const struct display_timing tianma_tm070jdhg30_timing = { |
| 3896 | .pixelclock = { 62600000, 68200000, 78100000 }, |
| 3897 | .hactive = { 1280, 1280, 1280 }, |
| 3898 | .hfront_porch = { 15, 64, 159 }, |
| 3899 | .hback_porch = { 5, 5, 5 }, |
| 3900 | .hsync_len = { 1, 1, 256 }, |
| 3901 | .vactive = { 800, 800, 800 }, |
| 3902 | .vfront_porch = { 3, 40, 99 }, |
| 3903 | .vback_porch = { 2, 2, 2 }, |
| 3904 | .vsync_len = { 1, 1, 128 }, |
| 3905 | .flags = DISPLAY_FLAGS_DE_HIGH, |
| 3906 | }; |
| 3907 | |
| 3908 | static const struct panel_desc tianma_tm070jdhg30 = { |
| 3909 | .timings = &tianma_tm070jdhg30_timing, |
| 3910 | .num_timings = 1, |
| 3911 | .bpc = 8, |
| 3912 | .size = { |
| 3913 | .width = 151, |
| 3914 | .height = 95, |
| 3915 | }, |
| 3916 | .bus_format = MEDIA_BUS_FMT_RGB888_1X7X4_SPWG, |
Laurent Pinchart | 9a2654c | 2019-09-04 16:28:03 +0300 | [diff] [blame] | 3917 | .connector_type = DRM_MODE_CONNECTOR_LVDS, |
Gary Bisson | adb973e | 2016-12-02 09:52:08 +0100 | [diff] [blame] | 3918 | }; |
| 3919 | |
Max Merchel | b3bfcdf | 2020-06-12 09:22:19 +0200 | [diff] [blame] | 3920 | static const struct panel_desc tianma_tm070jvhg33 = { |
| 3921 | .timings = &tianma_tm070jdhg30_timing, |
| 3922 | .num_timings = 1, |
| 3923 | .bpc = 8, |
| 3924 | .size = { |
| 3925 | .width = 150, |
| 3926 | .height = 94, |
| 3927 | }, |
| 3928 | .bus_format = MEDIA_BUS_FMT_RGB888_1X7X4_SPWG, |
| 3929 | .connector_type = DRM_MODE_CONNECTOR_LVDS, |
| 3930 | }; |
| 3931 | |
Lukasz Majewski | 870a0b1 | 2017-11-07 16:30:58 +0100 | [diff] [blame] | 3932 | static const struct display_timing tianma_tm070rvhg71_timing = { |
| 3933 | .pixelclock = { 27700000, 29200000, 39600000 }, |
| 3934 | .hactive = { 800, 800, 800 }, |
| 3935 | .hfront_porch = { 12, 40, 212 }, |
| 3936 | .hback_porch = { 88, 88, 88 }, |
| 3937 | .hsync_len = { 1, 1, 40 }, |
| 3938 | .vactive = { 480, 480, 480 }, |
| 3939 | .vfront_porch = { 1, 13, 88 }, |
| 3940 | .vback_porch = { 32, 32, 32 }, |
| 3941 | .vsync_len = { 1, 1, 3 }, |
| 3942 | .flags = DISPLAY_FLAGS_DE_HIGH, |
| 3943 | }; |
| 3944 | |
| 3945 | static const struct panel_desc tianma_tm070rvhg71 = { |
| 3946 | .timings = &tianma_tm070rvhg71_timing, |
| 3947 | .num_timings = 1, |
| 3948 | .bpc = 8, |
| 3949 | .size = { |
| 3950 | .width = 154, |
| 3951 | .height = 86, |
| 3952 | }, |
| 3953 | .bus_format = MEDIA_BUS_FMT_RGB888_1X7X4_SPWG, |
Laurent Pinchart | 9a2654c | 2019-09-04 16:28:03 +0300 | [diff] [blame] | 3954 | .connector_type = DRM_MODE_CONNECTOR_LVDS, |
Lukasz Majewski | 870a0b1 | 2017-11-07 16:30:58 +0100 | [diff] [blame] | 3955 | }; |
| 3956 | |
Linus Walleij | d8a0d6a | 2019-08-05 10:58:46 +0200 | [diff] [blame] | 3957 | static const struct drm_display_mode ti_nspire_cx_lcd_mode[] = { |
| 3958 | { |
| 3959 | .clock = 10000, |
| 3960 | .hdisplay = 320, |
| 3961 | .hsync_start = 320 + 50, |
| 3962 | .hsync_end = 320 + 50 + 6, |
| 3963 | .htotal = 320 + 50 + 6 + 38, |
| 3964 | .vdisplay = 240, |
| 3965 | .vsync_start = 240 + 3, |
| 3966 | .vsync_end = 240 + 3 + 1, |
| 3967 | .vtotal = 240 + 3 + 1 + 17, |
Linus Walleij | d8a0d6a | 2019-08-05 10:58:46 +0200 | [diff] [blame] | 3968 | .flags = DRM_MODE_FLAG_NVSYNC | DRM_MODE_FLAG_NHSYNC, |
| 3969 | }, |
| 3970 | }; |
| 3971 | |
| 3972 | static const struct panel_desc ti_nspire_cx_lcd_panel = { |
| 3973 | .modes = ti_nspire_cx_lcd_mode, |
| 3974 | .num_modes = 1, |
| 3975 | .bpc = 8, |
| 3976 | .size = { |
| 3977 | .width = 65, |
| 3978 | .height = 49, |
| 3979 | }, |
| 3980 | .bus_format = MEDIA_BUS_FMT_RGB888_1X24, |
Sam Ravnborg | f5436f7 | 2020-06-30 20:05:43 +0200 | [diff] [blame] | 3981 | .bus_flags = DRM_BUS_FLAG_PIXDATA_SAMPLE_POSEDGE, |
Linus Walleij | d8a0d6a | 2019-08-05 10:58:46 +0200 | [diff] [blame] | 3982 | }; |
| 3983 | |
| 3984 | static const struct drm_display_mode ti_nspire_classic_lcd_mode[] = { |
| 3985 | { |
| 3986 | .clock = 10000, |
| 3987 | .hdisplay = 320, |
| 3988 | .hsync_start = 320 + 6, |
| 3989 | .hsync_end = 320 + 6 + 6, |
| 3990 | .htotal = 320 + 6 + 6 + 6, |
| 3991 | .vdisplay = 240, |
| 3992 | .vsync_start = 240 + 0, |
| 3993 | .vsync_end = 240 + 0 + 1, |
| 3994 | .vtotal = 240 + 0 + 1 + 0, |
Linus Walleij | d8a0d6a | 2019-08-05 10:58:46 +0200 | [diff] [blame] | 3995 | .flags = DRM_MODE_FLAG_PHSYNC | DRM_MODE_FLAG_PVSYNC, |
| 3996 | }, |
| 3997 | }; |
| 3998 | |
| 3999 | static const struct panel_desc ti_nspire_classic_lcd_panel = { |
| 4000 | .modes = ti_nspire_classic_lcd_mode, |
| 4001 | .num_modes = 1, |
| 4002 | /* The grayscale panel has 8 bit for the color .. Y (black) */ |
| 4003 | .bpc = 8, |
| 4004 | .size = { |
| 4005 | .width = 71, |
| 4006 | .height = 53, |
| 4007 | }, |
| 4008 | /* This is the grayscale bus format */ |
| 4009 | .bus_format = MEDIA_BUS_FMT_Y8_1X8, |
Sam Ravnborg | f5436f7 | 2020-06-30 20:05:43 +0200 | [diff] [blame] | 4010 | .bus_flags = DRM_BUS_FLAG_PIXDATA_SAMPLE_NEGEDGE, |
Linus Walleij | d8a0d6a | 2019-08-05 10:58:46 +0200 | [diff] [blame] | 4011 | }; |
| 4012 | |
Lucas Stach | 06e733e | 2017-10-18 19:22:40 +0200 | [diff] [blame] | 4013 | static const struct drm_display_mode toshiba_lt089ac29000_mode = { |
| 4014 | .clock = 79500, |
| 4015 | .hdisplay = 1280, |
| 4016 | .hsync_start = 1280 + 192, |
| 4017 | .hsync_end = 1280 + 192 + 128, |
| 4018 | .htotal = 1280 + 192 + 128 + 64, |
| 4019 | .vdisplay = 768, |
| 4020 | .vsync_start = 768 + 20, |
| 4021 | .vsync_end = 768 + 20 + 7, |
| 4022 | .vtotal = 768 + 20 + 7 + 3, |
Lucas Stach | 06e733e | 2017-10-18 19:22:40 +0200 | [diff] [blame] | 4023 | }; |
| 4024 | |
| 4025 | static const struct panel_desc toshiba_lt089ac29000 = { |
| 4026 | .modes = &toshiba_lt089ac29000_mode, |
| 4027 | .num_modes = 1, |
| 4028 | .size = { |
| 4029 | .width = 194, |
| 4030 | .height = 116, |
| 4031 | }, |
Boris Brezillon | 9781bd1 | 2020-01-28 14:55:13 +0100 | [diff] [blame] | 4032 | .bus_format = MEDIA_BUS_FMT_RGB888_1X7X4_JEIDA, |
Laurent Pinchart | c471583 | 2020-06-30 02:33:19 +0300 | [diff] [blame] | 4033 | .bus_flags = DRM_BUS_FLAG_DE_HIGH, |
Laurent Pinchart | 9a2654c | 2019-09-04 16:28:03 +0300 | [diff] [blame] | 4034 | .connector_type = DRM_MODE_CONNECTOR_LVDS, |
Lucas Stach | 06e733e | 2017-10-18 19:22:40 +0200 | [diff] [blame] | 4035 | }; |
| 4036 | |
Bhuvanchandra DV | 227e4f4 | 2016-05-05 11:47:07 +0530 | [diff] [blame] | 4037 | static const struct drm_display_mode tpk_f07a_0102_mode = { |
| 4038 | .clock = 33260, |
| 4039 | .hdisplay = 800, |
| 4040 | .hsync_start = 800 + 40, |
| 4041 | .hsync_end = 800 + 40 + 128, |
| 4042 | .htotal = 800 + 40 + 128 + 88, |
| 4043 | .vdisplay = 480, |
| 4044 | .vsync_start = 480 + 10, |
| 4045 | .vsync_end = 480 + 10 + 2, |
| 4046 | .vtotal = 480 + 10 + 2 + 33, |
Bhuvanchandra DV | 227e4f4 | 2016-05-05 11:47:07 +0530 | [diff] [blame] | 4047 | }; |
| 4048 | |
| 4049 | static const struct panel_desc tpk_f07a_0102 = { |
| 4050 | .modes = &tpk_f07a_0102_mode, |
| 4051 | .num_modes = 1, |
| 4052 | .size = { |
| 4053 | .width = 152, |
| 4054 | .height = 91, |
| 4055 | }, |
Laurent Pinchart | 88bc417 | 2018-09-22 15:02:42 +0300 | [diff] [blame] | 4056 | .bus_flags = DRM_BUS_FLAG_PIXDATA_DRIVE_POSEDGE, |
Bhuvanchandra DV | 227e4f4 | 2016-05-05 11:47:07 +0530 | [diff] [blame] | 4057 | }; |
| 4058 | |
| 4059 | static const struct drm_display_mode tpk_f10a_0102_mode = { |
| 4060 | .clock = 45000, |
| 4061 | .hdisplay = 1024, |
| 4062 | .hsync_start = 1024 + 176, |
| 4063 | .hsync_end = 1024 + 176 + 5, |
| 4064 | .htotal = 1024 + 176 + 5 + 88, |
| 4065 | .vdisplay = 600, |
| 4066 | .vsync_start = 600 + 20, |
| 4067 | .vsync_end = 600 + 20 + 5, |
| 4068 | .vtotal = 600 + 20 + 5 + 25, |
Bhuvanchandra DV | 227e4f4 | 2016-05-05 11:47:07 +0530 | [diff] [blame] | 4069 | }; |
| 4070 | |
| 4071 | static const struct panel_desc tpk_f10a_0102 = { |
| 4072 | .modes = &tpk_f10a_0102_mode, |
| 4073 | .num_modes = 1, |
| 4074 | .size = { |
| 4075 | .width = 223, |
| 4076 | .height = 125, |
| 4077 | }, |
| 4078 | }; |
| 4079 | |
Maciej S. Szmigiero | 06a9dc6 | 2016-02-13 22:52:03 +0100 | [diff] [blame] | 4080 | static const struct display_timing urt_umsh_8596md_timing = { |
| 4081 | .pixelclock = { 33260000, 33260000, 33260000 }, |
| 4082 | .hactive = { 800, 800, 800 }, |
| 4083 | .hfront_porch = { 41, 41, 41 }, |
| 4084 | .hback_porch = { 216 - 128, 216 - 128, 216 - 128 }, |
| 4085 | .hsync_len = { 71, 128, 128 }, |
| 4086 | .vactive = { 480, 480, 480 }, |
| 4087 | .vfront_porch = { 10, 10, 10 }, |
| 4088 | .vback_porch = { 35 - 2, 35 - 2, 35 - 2 }, |
| 4089 | .vsync_len = { 2, 2, 2 }, |
| 4090 | .flags = DISPLAY_FLAGS_DE_HIGH | DISPLAY_FLAGS_PIXDATA_NEGEDGE | |
| 4091 | DISPLAY_FLAGS_HSYNC_LOW | DISPLAY_FLAGS_VSYNC_LOW, |
| 4092 | }; |
| 4093 | |
| 4094 | static const struct panel_desc urt_umsh_8596md_lvds = { |
| 4095 | .timings = &urt_umsh_8596md_timing, |
| 4096 | .num_timings = 1, |
| 4097 | .bpc = 6, |
| 4098 | .size = { |
| 4099 | .width = 152, |
| 4100 | .height = 91, |
| 4101 | }, |
| 4102 | .bus_format = MEDIA_BUS_FMT_RGB666_1X7X3_SPWG, |
Laurent Pinchart | 9a2654c | 2019-09-04 16:28:03 +0300 | [diff] [blame] | 4103 | .connector_type = DRM_MODE_CONNECTOR_LVDS, |
Maciej S. Szmigiero | 06a9dc6 | 2016-02-13 22:52:03 +0100 | [diff] [blame] | 4104 | }; |
| 4105 | |
| 4106 | static const struct panel_desc urt_umsh_8596md_parallel = { |
| 4107 | .timings = &urt_umsh_8596md_timing, |
| 4108 | .num_timings = 1, |
| 4109 | .bpc = 6, |
| 4110 | .size = { |
| 4111 | .width = 152, |
| 4112 | .height = 91, |
| 4113 | }, |
| 4114 | .bus_format = MEDIA_BUS_FMT_RGB666_1X18, |
| 4115 | }; |
| 4116 | |
Fabio Estevam | 0420618 | 2019-02-18 21:27:06 -0300 | [diff] [blame] | 4117 | static const struct drm_display_mode vl050_8048nt_c01_mode = { |
| 4118 | .clock = 33333, |
| 4119 | .hdisplay = 800, |
| 4120 | .hsync_start = 800 + 210, |
| 4121 | .hsync_end = 800 + 210 + 20, |
| 4122 | .htotal = 800 + 210 + 20 + 46, |
| 4123 | .vdisplay = 480, |
| 4124 | .vsync_start = 480 + 22, |
| 4125 | .vsync_end = 480 + 22 + 10, |
| 4126 | .vtotal = 480 + 22 + 10 + 23, |
Fabio Estevam | 0420618 | 2019-02-18 21:27:06 -0300 | [diff] [blame] | 4127 | .flags = DRM_MODE_FLAG_NHSYNC | DRM_MODE_FLAG_NVSYNC, |
| 4128 | }; |
| 4129 | |
| 4130 | static const struct panel_desc vl050_8048nt_c01 = { |
| 4131 | .modes = &vl050_8048nt_c01_mode, |
| 4132 | .num_modes = 1, |
| 4133 | .bpc = 8, |
| 4134 | .size = { |
| 4135 | .width = 120, |
| 4136 | .height = 76, |
| 4137 | }, |
| 4138 | .bus_format = MEDIA_BUS_FMT_RGB888_1X24, |
Sam Ravnborg | f5436f7 | 2020-06-30 20:05:43 +0200 | [diff] [blame] | 4139 | .bus_flags = DRM_BUS_FLAG_DE_HIGH | DRM_BUS_FLAG_PIXDATA_SAMPLE_NEGEDGE, |
Fabio Estevam | 0420618 | 2019-02-18 21:27:06 -0300 | [diff] [blame] | 4140 | }; |
| 4141 | |
Richard Genoud | e4bac40 | 2017-03-27 12:33:23 +0200 | [diff] [blame] | 4142 | static const struct drm_display_mode winstar_wf35ltiacd_mode = { |
| 4143 | .clock = 6410, |
| 4144 | .hdisplay = 320, |
| 4145 | .hsync_start = 320 + 20, |
| 4146 | .hsync_end = 320 + 20 + 30, |
| 4147 | .htotal = 320 + 20 + 30 + 38, |
| 4148 | .vdisplay = 240, |
| 4149 | .vsync_start = 240 + 4, |
| 4150 | .vsync_end = 240 + 4 + 3, |
| 4151 | .vtotal = 240 + 4 + 3 + 15, |
Richard Genoud | e4bac40 | 2017-03-27 12:33:23 +0200 | [diff] [blame] | 4152 | .flags = DRM_MODE_FLAG_NVSYNC | DRM_MODE_FLAG_NHSYNC, |
| 4153 | }; |
| 4154 | |
| 4155 | static const struct panel_desc winstar_wf35ltiacd = { |
| 4156 | .modes = &winstar_wf35ltiacd_mode, |
| 4157 | .num_modes = 1, |
| 4158 | .bpc = 8, |
| 4159 | .size = { |
| 4160 | .width = 70, |
| 4161 | .height = 53, |
| 4162 | }, |
| 4163 | .bus_format = MEDIA_BUS_FMT_RGB888_1X24, |
| 4164 | }; |
| 4165 | |
Jagan Teki | 7a1f4fa | 2020-09-04 23:38:21 +0530 | [diff] [blame] | 4166 | static const struct drm_display_mode yes_optoelectronics_ytc700tlag_05_201c_mode = { |
| 4167 | .clock = 51200, |
| 4168 | .hdisplay = 1024, |
| 4169 | .hsync_start = 1024 + 100, |
| 4170 | .hsync_end = 1024 + 100 + 100, |
| 4171 | .htotal = 1024 + 100 + 100 + 120, |
| 4172 | .vdisplay = 600, |
| 4173 | .vsync_start = 600 + 10, |
| 4174 | .vsync_end = 600 + 10 + 10, |
| 4175 | .vtotal = 600 + 10 + 10 + 15, |
| 4176 | .flags = DRM_MODE_FLAG_PHSYNC | DRM_MODE_FLAG_PVSYNC, |
| 4177 | }; |
| 4178 | |
| 4179 | static const struct panel_desc yes_optoelectronics_ytc700tlag_05_201c = { |
| 4180 | .modes = &yes_optoelectronics_ytc700tlag_05_201c_mode, |
| 4181 | .num_modes = 1, |
| 4182 | .bpc = 6, |
| 4183 | .size = { |
| 4184 | .width = 154, |
| 4185 | .height = 90, |
| 4186 | }, |
| 4187 | .bus_flags = DRM_BUS_FLAG_DE_HIGH, |
| 4188 | .bus_format = MEDIA_BUS_FMT_RGB888_1X7X4_SPWG, |
| 4189 | .connector_type = DRM_MODE_CONNECTOR_LVDS, |
| 4190 | }; |
| 4191 | |
Linus Walleij | fcec416 | 2018-10-26 13:13:34 +0200 | [diff] [blame] | 4192 | static const struct drm_display_mode arm_rtsm_mode[] = { |
| 4193 | { |
| 4194 | .clock = 65000, |
| 4195 | .hdisplay = 1024, |
| 4196 | .hsync_start = 1024 + 24, |
| 4197 | .hsync_end = 1024 + 24 + 136, |
| 4198 | .htotal = 1024 + 24 + 136 + 160, |
| 4199 | .vdisplay = 768, |
| 4200 | .vsync_start = 768 + 3, |
| 4201 | .vsync_end = 768 + 3 + 6, |
| 4202 | .vtotal = 768 + 3 + 6 + 29, |
Linus Walleij | fcec416 | 2018-10-26 13:13:34 +0200 | [diff] [blame] | 4203 | .flags = DRM_MODE_FLAG_NVSYNC | DRM_MODE_FLAG_NHSYNC, |
| 4204 | }, |
| 4205 | }; |
| 4206 | |
| 4207 | static const struct panel_desc arm_rtsm = { |
| 4208 | .modes = arm_rtsm_mode, |
| 4209 | .num_modes = 1, |
| 4210 | .bpc = 8, |
| 4211 | .size = { |
| 4212 | .width = 400, |
| 4213 | .height = 300, |
| 4214 | }, |
| 4215 | .bus_format = MEDIA_BUS_FMT_RGB888_1X24, |
| 4216 | }; |
| 4217 | |
Thierry Reding | 280921d | 2013-08-30 15:10:14 +0200 | [diff] [blame] | 4218 | static const struct of_device_id platform_of_match[] = { |
| 4219 | { |
Jagan Teki | bca684e | 2020-08-29 22:03:28 +0530 | [diff] [blame] | 4220 | .compatible = "ampire,am-1280800n3tzqw-t00h", |
| 4221 | .data = &ire_am_1280800n3tzqw_t00h, |
| 4222 | }, { |
Yannick Fertre | 966fea7 | 2017-03-28 11:44:49 +0200 | [diff] [blame] | 4223 | .compatible = "ampire,am-480272h3tmqw-t01h", |
| 4224 | .data = &ire_am_480272h3tmqw_t01h, |
| 4225 | }, { |
Philipp Zabel | 1c550fa1 | 2015-02-11 18:50:09 +0100 | [diff] [blame] | 4226 | .compatible = "ampire,am800480r3tmqwa1h", |
| 4227 | .data = &ire_am800480r3tmqwa1h, |
| 4228 | }, { |
Linus Walleij | fcec416 | 2018-10-26 13:13:34 +0200 | [diff] [blame] | 4229 | .compatible = "arm,rtsm-display", |
| 4230 | .data = &arm_rtsm, |
| 4231 | }, { |
Sébastien Szymanski | c479450f | 2019-05-07 17:27:12 +0200 | [diff] [blame] | 4232 | .compatible = "armadeus,st0700-adapt", |
| 4233 | .data = &armadeus_st0700_adapt, |
| 4234 | }, { |
Thierry Reding | 280921d | 2013-08-30 15:10:14 +0200 | [diff] [blame] | 4235 | .compatible = "auo,b101aw03", |
| 4236 | .data = &auo_b101aw03, |
| 4237 | }, { |
Huang Lin | a531bc3 | 2015-02-28 10:18:58 +0800 | [diff] [blame] | 4238 | .compatible = "auo,b101ean01", |
| 4239 | .data = &auo_b101ean01, |
| 4240 | }, { |
Rob Clark | dac746e | 2014-08-01 17:01:06 -0400 | [diff] [blame] | 4241 | .compatible = "auo,b101xtn01", |
| 4242 | .data = &auo_b101xtn01, |
| 4243 | }, { |
Rob Clark | da458286 | 2020-01-08 15:53:56 -0800 | [diff] [blame] | 4244 | .compatible = "auo,b116xa01", |
| 4245 | .data = &auo_b116xak01, |
| 4246 | }, { |
Ajay Kumar | e35e305 | 2014-09-01 15:40:02 +0530 | [diff] [blame] | 4247 | .compatible = "auo,b116xw03", |
| 4248 | .data = &auo_b116xw03, |
| 4249 | }, { |
Ajay Kumar | 3e51d60 | 2014-07-31 23:12:12 +0530 | [diff] [blame] | 4250 | .compatible = "auo,b133htn01", |
| 4251 | .data = &auo_b133htn01, |
| 4252 | }, { |
Stéphane Marchesin | a333f7a | 2014-05-23 19:27:59 -0700 | [diff] [blame] | 4253 | .compatible = "auo,b133xtn01", |
| 4254 | .data = &auo_b133xtn01, |
| 4255 | }, { |
Lukasz Majewski | bccfaff | 2018-05-14 21:08:49 +0200 | [diff] [blame] | 4256 | .compatible = "auo,g070vvn01", |
| 4257 | .data = &auo_g070vvn01, |
| 4258 | }, { |
Alex Gonzalez | 4fb8640 | 2018-10-25 17:09:30 +0200 | [diff] [blame] | 4259 | .compatible = "auo,g101evn010", |
| 4260 | .data = &auo_g101evn010, |
| 4261 | }, { |
Christoph Fritz | 4451c28 | 2017-12-16 14:13:36 +0100 | [diff] [blame] | 4262 | .compatible = "auo,g104sn02", |
| 4263 | .data = &auo_g104sn02, |
| 4264 | }, { |
Sebastian Reichel | 03e909a | 2020-04-15 19:27:25 +0200 | [diff] [blame] | 4265 | .compatible = "auo,g121ean01", |
| 4266 | .data = &auo_g121ean01, |
| 4267 | }, { |
Lucas Stach | 697035c | 2016-11-30 14:09:55 +0100 | [diff] [blame] | 4268 | .compatible = "auo,g133han01", |
| 4269 | .data = &auo_g133han01, |
| 4270 | }, { |
Sebastian Reichel | d9ccd1f | 2020-04-15 19:27:24 +0200 | [diff] [blame] | 4271 | .compatible = "auo,g156xtn01", |
| 4272 | .data = &auo_g156xtn01, |
| 4273 | }, { |
Lucas Stach | 8c31f60 | 2016-11-30 14:09:56 +0100 | [diff] [blame] | 4274 | .compatible = "auo,g185han01", |
| 4275 | .data = &auo_g185han01, |
| 4276 | }, { |
Sebastian Reichel | 2f7b832 | 2020-04-15 19:27:23 +0200 | [diff] [blame] | 4277 | .compatible = "auo,g190ean01", |
| 4278 | .data = &auo_g190ean01, |
| 4279 | }, { |
Lucas Stach | 70c0d5b | 2017-06-08 20:07:58 +0200 | [diff] [blame] | 4280 | .compatible = "auo,p320hvn03", |
| 4281 | .data = &auo_p320hvn03, |
| 4282 | }, { |
Haixia Shi | 7ee933a | 2016-10-11 14:59:16 -0700 | [diff] [blame] | 4283 | .compatible = "auo,t215hvn01", |
| 4284 | .data = &auo_t215hvn01, |
| 4285 | }, { |
Philipp Zabel | d47df63 | 2014-12-18 16:43:43 +0100 | [diff] [blame] | 4286 | .compatible = "avic,tm070ddh03", |
| 4287 | .data = &avic_tm070ddh03, |
| 4288 | }, { |
Chen-Yu Tsai | 7ad8b41 | 2018-09-07 12:19:46 +0800 | [diff] [blame] | 4289 | .compatible = "bananapi,s070wv20-ct16", |
| 4290 | .data = &bananapi_s070wv20_ct16, |
| 4291 | }, { |
Andrzej Hajda | ae8cf41 | 2018-06-19 10:19:26 +0200 | [diff] [blame] | 4292 | .compatible = "boe,hv070wsa-100", |
| 4293 | .data = &boe_hv070wsa |
| 4294 | }, { |
Caesar Wang | cac1a41 | 2016-12-14 11:19:56 +0800 | [diff] [blame] | 4295 | .compatible = "boe,nv101wxmn51", |
| 4296 | .data = &boe_nv101wxmn51, |
| 4297 | }, { |
Douglas Anderson | a96ee0f | 2020-11-09 17:00:58 -0800 | [diff] [blame] | 4298 | .compatible = "boe,nv110wtm-n61", |
| 4299 | .data = &boe_nv110wtm_n61, |
| 4300 | }, { |
Bjorn Andersson | b0c664c | 2020-04-20 14:57:42 -0700 | [diff] [blame] | 4301 | .compatible = "boe,nv133fhm-n61", |
| 4302 | .data = &boe_nv133fhm_n61, |
| 4303 | }, { |
Douglas Anderson | cfe40d0 | 2020-05-08 15:59:02 -0700 | [diff] [blame] | 4304 | .compatible = "boe,nv133fhm-n62", |
| 4305 | .data = &boe_nv133fhm_n61, |
| 4306 | }, { |
Tobias Schramm | a511981 | 2020-01-09 12:29:52 +0100 | [diff] [blame] | 4307 | .compatible = "boe,nv140fhmn49", |
| 4308 | .data = &boe_nv140fhmn49, |
| 4309 | }, { |
Giulio Benetti | e58edce | 2018-07-31 01:11:16 +0200 | [diff] [blame] | 4310 | .compatible = "cdtech,s043wq26h-ct7", |
| 4311 | .data = &cdtech_s043wq26h_ct7, |
| 4312 | }, { |
Michael Krummsdorf | 0e3b67f | 2020-06-12 09:22:18 +0200 | [diff] [blame] | 4313 | .compatible = "cdtech,s070pws19hp-fc21", |
| 4314 | .data = &cdtech_s070pws19hp_fc21, |
| 4315 | }, { |
| 4316 | .compatible = "cdtech,s070swv29hg-dc44", |
| 4317 | .data = &cdtech_s070swv29hg_dc44, |
| 4318 | }, { |
Giulio Benetti | 982f944 | 2018-07-31 01:11:14 +0200 | [diff] [blame] | 4319 | .compatible = "cdtech,s070wv95-ct16", |
| 4320 | .data = &cdtech_s070wv95_ct16, |
| 4321 | }, { |
Marek Vasut | 07c913c | 2020-07-28 22:12:42 +0200 | [diff] [blame] | 4322 | .compatible = "chefree,ch101olhlwh-002", |
| 4323 | .data = &chefree_ch101olhlwh_002, |
| 4324 | }, { |
Randy Li | 2cb35c8 | 2016-09-20 03:02:51 +0800 | [diff] [blame] | 4325 | .compatible = "chunghwa,claa070wp03xg", |
| 4326 | .data = &chunghwa_claa070wp03xg, |
| 4327 | }, { |
Stephen Warren | 4c93075 | 2014-01-07 16:46:26 -0700 | [diff] [blame] | 4328 | .compatible = "chunghwa,claa101wa01a", |
| 4329 | .data = &chunghwa_claa101wa01a |
| 4330 | }, { |
Thierry Reding | 280921d | 2013-08-30 15:10:14 +0200 | [diff] [blame] | 4331 | .compatible = "chunghwa,claa101wb01", |
| 4332 | .data = &chunghwa_claa101wb01 |
| 4333 | }, { |
Michal Vokáč | 97ceb1f | 2018-06-25 14:41:30 +0200 | [diff] [blame] | 4334 | .compatible = "dataimage,scf0700c48ggu18", |
| 4335 | .data = &dataimage_scf0700c48ggu18, |
| 4336 | }, { |
Philipp Zabel | 0ca0c82 | 2018-05-23 11:25:04 +0200 | [diff] [blame] | 4337 | .compatible = "dlc,dlc0700yzg-1", |
| 4338 | .data = &dlc_dlc0700yzg_1, |
| 4339 | }, { |
Marco Felsch | 6cbe7cd | 2018-09-24 17:26:10 +0200 | [diff] [blame] | 4340 | .compatible = "dlc,dlc1010gig", |
| 4341 | .data = &dlc_dlc1010gig, |
| 4342 | }, { |
Andreas Pretzsch | c2d24af | 2019-04-16 12:16:30 +0200 | [diff] [blame] | 4343 | .compatible = "edt,et035012dm6", |
| 4344 | .data = &edt_et035012dm6, |
| 4345 | }, { |
Marian-Cristian Rotariu | 82d57a5 | 2020-01-30 12:08:38 +0000 | [diff] [blame] | 4346 | .compatible = "edt,etm043080dh6gp", |
| 4347 | .data = &edt_etm043080dh6gp, |
| 4348 | }, { |
Marek Vasut | fd819bf | 2019-02-19 15:04:38 +0100 | [diff] [blame] | 4349 | .compatible = "edt,etm0430g0dh6", |
| 4350 | .data = &edt_etm0430g0dh6, |
| 4351 | }, { |
Stefan Agner | 26ab006 | 2014-05-15 11:38:45 +0200 | [diff] [blame] | 4352 | .compatible = "edt,et057090dhu", |
| 4353 | .data = &edt_et057090dhu, |
| 4354 | }, { |
Philipp Zabel | fff5de4 | 2014-05-15 12:25:47 +0200 | [diff] [blame] | 4355 | .compatible = "edt,et070080dh6", |
| 4356 | .data = &edt_etm0700g0dh6, |
| 4357 | }, { |
| 4358 | .compatible = "edt,etm0700g0dh6", |
| 4359 | .data = &edt_etm0700g0dh6, |
| 4360 | }, { |
Jan Tuerk | aa7e645 | 2018-06-19 11:55:44 +0200 | [diff] [blame] | 4361 | .compatible = "edt,etm0700g0bdh6", |
| 4362 | .data = &edt_etm0700g0bdh6, |
| 4363 | }, { |
Jan Tuerk | aad34de | 2018-06-19 11:55:45 +0200 | [diff] [blame] | 4364 | .compatible = "edt,etm0700g0edh6", |
| 4365 | .data = &edt_etm0700g0bdh6, |
| 4366 | }, { |
Marco Felsch | 9158e3c | 2019-04-16 12:06:45 +0200 | [diff] [blame] | 4367 | .compatible = "evervision,vgg804821", |
| 4368 | .data = &evervision_vgg804821, |
| 4369 | }, { |
Boris BREZILLON | 102932b | 2014-06-05 15:53:32 +0200 | [diff] [blame] | 4370 | .compatible = "foxlink,fl500wvr00-a0t", |
| 4371 | .data = &foxlink_fl500wvr00_a0t, |
| 4372 | }, { |
Paul Cercueil | 7b6bd84 | 2020-01-13 13:17:41 -0300 | [diff] [blame] | 4373 | .compatible = "frida,frd350h54004", |
| 4374 | .data = &frida_frd350h54004, |
| 4375 | }, { |
Jagan Teki | 3be2071 | 2019-05-07 18:37:07 +0530 | [diff] [blame] | 4376 | .compatible = "friendlyarm,hd702e", |
| 4377 | .data = &friendlyarm_hd702e, |
| 4378 | }, { |
Philipp Zabel | d435a2a | 2014-11-19 10:29:55 +0100 | [diff] [blame] | 4379 | .compatible = "giantplus,gpg482739qs5", |
| 4380 | .data = &giantplus_gpg482739qs5 |
| 4381 | }, { |
Paul Cercueil | 2c6574a | 2019-06-06 00:22:47 +0200 | [diff] [blame] | 4382 | .compatible = "giantplus,gpm940b0", |
| 4383 | .data = &giantplus_gpm940b0, |
| 4384 | }, { |
Philipp Zabel | a853205 | 2014-10-23 16:31:06 +0200 | [diff] [blame] | 4385 | .compatible = "hannstar,hsd070pww1", |
| 4386 | .data = &hannstar_hsd070pww1, |
| 4387 | }, { |
Eric Nelson | c0d607e | 2015-04-13 15:09:26 -0700 | [diff] [blame] | 4388 | .compatible = "hannstar,hsd100pxn1", |
| 4389 | .data = &hannstar_hsd100pxn1, |
| 4390 | }, { |
Lucas Stach | 61ac0bf | 2014-11-06 17:44:35 +0100 | [diff] [blame] | 4391 | .compatible = "hit,tx23d38vm0caa", |
| 4392 | .data = &hitachi_tx23d38vm0caa |
| 4393 | }, { |
Nicolas Ferre | 41bcceb | 2015-03-19 14:43:01 +0100 | [diff] [blame] | 4394 | .compatible = "innolux,at043tn24", |
| 4395 | .data = &innolux_at043tn24, |
| 4396 | }, { |
Riccardo Bortolato | 4fc24ab | 2016-04-20 15:37:15 +0200 | [diff] [blame] | 4397 | .compatible = "innolux,at070tn92", |
| 4398 | .data = &innolux_at070tn92, |
| 4399 | }, { |
Christoph Fritz | a5d2ade | 2018-06-04 13:16:48 +0200 | [diff] [blame] | 4400 | .compatible = "innolux,g070y2-l01", |
| 4401 | .data = &innolux_g070y2_l01, |
| 4402 | }, { |
| 4403 | .compatible = "innolux,g101ice-l01", |
Michael Olbrich | 1e29b84 | 2016-08-15 14:32:02 +0200 | [diff] [blame] | 4404 | .data = &innolux_g101ice_l01 |
| 4405 | }, { |
Christoph Fritz | a5d2ade | 2018-06-04 13:16:48 +0200 | [diff] [blame] | 4406 | .compatible = "innolux,g121i1-l01", |
Lucas Stach | d731f66 | 2014-11-06 17:44:33 +0100 | [diff] [blame] | 4407 | .data = &innolux_g121i1_l01 |
| 4408 | }, { |
Akshay Bhat | f8fa17b | 2015-11-18 15:57:47 -0500 | [diff] [blame] | 4409 | .compatible = "innolux,g121x1-l03", |
| 4410 | .data = &innolux_g121x1_l03, |
| 4411 | }, { |
Douglas Anderson | 51d3563 | 2021-01-15 14:44:20 -0800 | [diff] [blame] | 4412 | .compatible = "innolux,n116bca-ea1", |
| 4413 | .data = &innolux_n116bca_ea1, |
| 4414 | }, { |
Thierry Reding | 0a2288c | 2014-07-03 14:02:59 +0200 | [diff] [blame] | 4415 | .compatible = "innolux,n116bge", |
| 4416 | .data = &innolux_n116bge, |
| 4417 | }, { |
Lukas F. Hartmann | a14c6b0 | 2020-11-24 18:26:04 +0100 | [diff] [blame] | 4418 | .compatible = "innolux,n125hce-gn1", |
| 4419 | .data = &innolux_n125hce_gn1, |
| 4420 | }, { |
Alban Bedel | ea44739 | 2014-07-22 08:38:55 +0200 | [diff] [blame] | 4421 | .compatible = "innolux,n156bge-l21", |
| 4422 | .data = &innolux_n156bge_l21, |
| 4423 | }, { |
Douglas Anderson | 8f054b6 | 2018-10-25 15:21:34 -0700 | [diff] [blame] | 4424 | .compatible = "innolux,p120zdg-bf1", |
| 4425 | .data = &innolux_p120zdg_bf1, |
spanda@codeaurora.org | da50bd4 | 2018-05-15 11:22:43 +0530 | [diff] [blame] | 4426 | }, { |
Michael Grzeschik | bccac3f | 2015-03-19 12:22:44 +0100 | [diff] [blame] | 4427 | .compatible = "innolux,zj070na-01p", |
| 4428 | .data = &innolux_zj070na_01p, |
| 4429 | }, { |
Bjorn Andersson | e1ca518 | 2020-04-20 14:57:28 -0700 | [diff] [blame] | 4430 | .compatible = "ivo,m133nwf4-r0", |
| 4431 | .data = &ivo_m133nwf4_r0, |
| 4432 | }, { |
Douglas Anderson | fc26a37 | 2020-08-21 08:35:15 -0700 | [diff] [blame] | 4433 | .compatible = "kingdisplay,kd116n21-30nv-a010", |
| 4434 | .data = &kingdisplay_kd116n21_30nv_a010, |
| 4435 | }, { |
Lukasz Majewski | 14bf60c | 2019-05-15 18:06:12 +0200 | [diff] [blame] | 4436 | .compatible = "koe,tx14d24vm1bpa", |
| 4437 | .data = &koe_tx14d24vm1bpa, |
| 4438 | }, { |
Liu Ying | 8a07052 | 2020-06-01 14:11:20 +0800 | [diff] [blame] | 4439 | .compatible = "koe,tx26d202vm0bwa", |
| 4440 | .data = &koe_tx26d202vm0bwa, |
| 4441 | }, { |
Jagan Teki | 8cfe834 | 2018-02-04 23:19:28 +0530 | [diff] [blame] | 4442 | .compatible = "koe,tx31d200vm0baa", |
| 4443 | .data = &koe_tx31d200vm0baa, |
| 4444 | }, { |
Lucas Stach | 8def22e | 2015-12-02 19:41:11 +0100 | [diff] [blame] | 4445 | .compatible = "kyo,tcg121xglp", |
| 4446 | .data = &kyo_tcg121xglp, |
| 4447 | }, { |
Paul Kocialkowski | 27abdd8 | 2018-11-07 19:18:41 +0100 | [diff] [blame] | 4448 | .compatible = "lemaker,bl035-rgb-002", |
| 4449 | .data = &lemaker_bl035_rgb_002, |
| 4450 | }, { |
Heiko Schocher | dd01500 | 2015-05-22 10:25:57 +0200 | [diff] [blame] | 4451 | .compatible = "lg,lb070wv8", |
| 4452 | .data = &lg_lb070wv8, |
| 4453 | }, { |
Yakir Yang | c5ece40 | 2016-06-28 12:51:15 +0800 | [diff] [blame] | 4454 | .compatible = "lg,lp079qx1-sp0v", |
| 4455 | .data = &lg_lp079qx1_sp0v, |
| 4456 | }, { |
Yakir Yang | 0355dde | 2016-06-12 10:56:02 +0800 | [diff] [blame] | 4457 | .compatible = "lg,lp097qx1-spa1", |
| 4458 | .data = &lg_lp097qx1_spa1, |
| 4459 | }, { |
Jitao Shi | 690d8fa | 2016-02-22 19:01:44 +0800 | [diff] [blame] | 4460 | .compatible = "lg,lp120up1", |
| 4461 | .data = &lg_lp120up1, |
| 4462 | }, { |
Thierry Reding | ec7c565 | 2013-11-15 15:59:32 +0100 | [diff] [blame] | 4463 | .compatible = "lg,lp129qe", |
| 4464 | .data = &lg_lp129qe, |
| 4465 | }, { |
Adam Ford | 0d35408 | 2019-10-16 08:51:45 -0500 | [diff] [blame] | 4466 | .compatible = "logicpd,type28", |
| 4467 | .data = &logicpd_type_28, |
| 4468 | }, { |
Marcel Ziswiler | 5728fe7 | 2020-01-20 09:01:00 +0100 | [diff] [blame] | 4469 | .compatible = "logictechno,lt161010-2nhc", |
| 4470 | .data = &logictechno_lt161010_2nh, |
| 4471 | }, { |
| 4472 | .compatible = "logictechno,lt161010-2nhr", |
| 4473 | .data = &logictechno_lt161010_2nh, |
| 4474 | }, { |
| 4475 | .compatible = "logictechno,lt170410-2whc", |
| 4476 | .data = &logictechno_lt170410_2whc, |
| 4477 | }, { |
Lukasz Majewski | 65c766c | 2017-10-21 00:18:37 +0200 | [diff] [blame] | 4478 | .compatible = "mitsubishi,aa070mc01-ca1", |
| 4479 | .data = &mitsubishi_aa070mc01, |
| 4480 | }, { |
Lucas Stach | 01bacc13 | 2017-06-08 20:07:55 +0200 | [diff] [blame] | 4481 | .compatible = "nec,nl12880bc20-05", |
| 4482 | .data = &nec_nl12880bc20_05, |
| 4483 | }, { |
jianwei wang | c6e87f9 | 2015-07-29 16:30:02 +0800 | [diff] [blame] | 4484 | .compatible = "nec,nl4827hc19-05b", |
| 4485 | .data = &nec_nl4827hc19_05b, |
| 4486 | }, { |
Maxime Ripard | e6c2f06 | 2016-09-06 16:46:17 +0200 | [diff] [blame] | 4487 | .compatible = "netron-dy,e231732", |
| 4488 | .data = &netron_dy_e231732, |
| 4489 | }, { |
Vasily Khoruzhick | 258145e | 2020-02-26 00:10:10 -0800 | [diff] [blame] | 4490 | .compatible = "neweast,wjfh116008a", |
| 4491 | .data = &neweast_wjfh116008a, |
| 4492 | }, { |
Tomi Valkeinen | 3b39ad7 | 2018-06-18 16:22:40 +0300 | [diff] [blame] | 4493 | .compatible = "newhaven,nhd-4.3-480272ef-atxl", |
| 4494 | .data = &newhaven_nhd_43_480272ef_atxl, |
| 4495 | }, { |
Lucas Stach | 4177fa6 | 2017-06-08 20:07:57 +0200 | [diff] [blame] | 4496 | .compatible = "nlt,nl192108ac18-02d", |
| 4497 | .data = &nlt_nl192108ac18_02d, |
| 4498 | }, { |
Fabien Lahoudere | 05ec0e4 | 2016-10-17 11:38:01 +0200 | [diff] [blame] | 4499 | .compatible = "nvd,9128", |
| 4500 | .data = &nvd_9128, |
| 4501 | }, { |
Gary Bisson | a99fb62 | 2015-06-10 18:44:23 +0200 | [diff] [blame] | 4502 | .compatible = "okaya,rs800480t-7x0gp", |
| 4503 | .data = &okaya_rs800480t_7x0gp, |
| 4504 | }, { |
Maxime Ripard | cf5c9e6 | 2016-03-23 17:38:34 +0100 | [diff] [blame] | 4505 | .compatible = "olimex,lcd-olinuxino-43-ts", |
| 4506 | .data = &olimex_lcd_olinuxino_43ts, |
| 4507 | }, { |
Eric Anholt | e8b6f56 | 2016-03-24 17:23:48 -0700 | [diff] [blame] | 4508 | .compatible = "ontat,yx700wv03", |
| 4509 | .data = &ontat_yx700wv03, |
| 4510 | }, { |
H. Nikolaus Schaller | 9c31dcb | 2019-06-07 13:11:08 +0200 | [diff] [blame] | 4511 | .compatible = "ortustech,com37h3m05dtc", |
| 4512 | .data = &ortustech_com37h3m, |
| 4513 | }, { |
| 4514 | .compatible = "ortustech,com37h3m99dtc", |
| 4515 | .data = &ortustech_com37h3m, |
| 4516 | }, { |
Philipp Zabel | 725c9d4 | 2015-02-11 18:50:11 +0100 | [diff] [blame] | 4517 | .compatible = "ortustech,com43h4m85ulc", |
| 4518 | .data = &ortustech_com43h4m85ulc, |
| 4519 | }, { |
Laurent Pinchart | 163f7a3 | 2018-12-07 22:13:44 +0200 | [diff] [blame] | 4520 | .compatible = "osddisplays,osd070t1718-19ts", |
| 4521 | .data = &osddisplays_osd070t1718_19ts, |
| 4522 | }, { |
Eugen Hristev | 4ba3e56 | 2019-01-14 09:43:31 +0000 | [diff] [blame] | 4523 | .compatible = "pda,91-00156-a0", |
| 4524 | .data = &pda_91_00156_a0, |
| 4525 | }, { |
Marek Vasut | d69de69 | 2020-07-28 14:12:46 +0200 | [diff] [blame] | 4526 | .compatible = "powertip,ph800480t013-idf02", |
| 4527 | .data = &powertip_ph800480t013_idf02, |
| 4528 | }, { |
Josh Wu | d2a6f0f | 2015-10-08 17:42:41 +0200 | [diff] [blame] | 4529 | .compatible = "qiaodian,qd43003c0-40", |
| 4530 | .data = &qd43003c0_40, |
| 4531 | }, { |
Jagan Teki | 23167fa | 2018-06-07 19:16:48 +0530 | [diff] [blame] | 4532 | .compatible = "rocktech,rk070er9427", |
| 4533 | .data = &rocktech_rk070er9427, |
| 4534 | }, { |
Jyri Sarha | f305047 | 2020-02-11 14:17:18 +0200 | [diff] [blame] | 4535 | .compatible = "rocktech,rk101ii01d-ct", |
| 4536 | .data = &rocktech_rk101ii01d_ct, |
| 4537 | }, { |
Yakir Yang | 0330eaf | 2016-06-12 10:56:13 +0800 | [diff] [blame] | 4538 | .compatible = "samsung,lsn122dl01-c01", |
| 4539 | .data = &samsung_lsn122dl01_c01, |
| 4540 | }, { |
Marc Dietrich | 6d54e3d | 2013-12-21 21:38:12 +0100 | [diff] [blame] | 4541 | .compatible = "samsung,ltn101nt05", |
| 4542 | .data = &samsung_ltn101nt05, |
| 4543 | }, { |
Stéphane Marchesin | 0c93430 | 2015-03-18 10:52:18 +0100 | [diff] [blame] | 4544 | .compatible = "samsung,ltn140at29-301", |
| 4545 | .data = &samsung_ltn140at29_301, |
| 4546 | }, { |
Miquel Raynal | 44c58c5 | 2020-01-09 19:40:37 +0100 | [diff] [blame] | 4547 | .compatible = "satoz,sat050at40h12r2", |
| 4548 | .data = &satoz_sat050at40h12r2, |
| 4549 | }, { |
Jeffrey Hugo | cd5e1cb | 2019-07-08 09:58:11 -0700 | [diff] [blame] | 4550 | .compatible = "sharp,ld-d5116z01b", |
| 4551 | .data = &sharp_ld_d5116z01b, |
| 4552 | }, { |
Vladimir Zapolskiy | 03e3ec9 | 2018-07-06 21:51:01 +0300 | [diff] [blame] | 4553 | .compatible = "sharp,lq035q7db03", |
| 4554 | .data = &sharp_lq035q7db03, |
| 4555 | }, { |
H. Nikolaus Schaller | dda0e4b | 2019-06-07 13:11:07 +0200 | [diff] [blame] | 4556 | .compatible = "sharp,lq070y3dg3b", |
| 4557 | .data = &sharp_lq070y3dg3b, |
| 4558 | }, { |
Joshua Clayton | 592aa02 | 2016-07-06 15:59:16 -0700 | [diff] [blame] | 4559 | .compatible = "sharp,lq101k1ly04", |
| 4560 | .data = &sharp_lq101k1ly04, |
| 4561 | }, { |
Yakir Yang | 739c7de | 2016-06-12 10:56:35 +0800 | [diff] [blame] | 4562 | .compatible = "sharp,lq123p1jx31", |
| 4563 | .data = &sharp_lq123p1jx31, |
| 4564 | }, { |
Paul Cercueil | f1bd37f | 2019-06-03 17:31:20 +0200 | [diff] [blame] | 4565 | .compatible = "sharp,ls020b1dd01d", |
| 4566 | .data = &sharp_ls020b1dd01d, |
| 4567 | }, { |
Boris BREZILLON | 9c6615b | 2015-03-19 14:43:00 +0100 | [diff] [blame] | 4568 | .compatible = "shelly,sca07010-bfn-lnn", |
| 4569 | .data = &shelly_sca07010_bfn_lnn, |
| 4570 | }, { |
Pascal Roeleven | 105235e | 2020-03-20 12:21:33 +0100 | [diff] [blame] | 4571 | .compatible = "starry,kr070pe2t", |
| 4572 | .data = &starry_kr070pe2t, |
| 4573 | }, { |
Douglas Anderson | 9bb34c4 | 2016-06-10 10:02:07 -0700 | [diff] [blame] | 4574 | .compatible = "starry,kr122ea0sra", |
| 4575 | .data = &starry_kr122ea0sra, |
| 4576 | }, { |
Jyri Sarha | 4216153 | 2019-03-22 10:33:36 +0200 | [diff] [blame] | 4577 | .compatible = "tfc,s9700rtwv43tr-01b", |
| 4578 | .data = &tfc_s9700rtwv43tr_01b, |
| 4579 | }, { |
Gary Bisson | adb973e | 2016-12-02 09:52:08 +0100 | [diff] [blame] | 4580 | .compatible = "tianma,tm070jdhg30", |
| 4581 | .data = &tianma_tm070jdhg30, |
| 4582 | }, { |
Max Merchel | b3bfcdf | 2020-06-12 09:22:19 +0200 | [diff] [blame] | 4583 | .compatible = "tianma,tm070jvhg33", |
| 4584 | .data = &tianma_tm070jvhg33, |
| 4585 | }, { |
Lukasz Majewski | 870a0b1 | 2017-11-07 16:30:58 +0100 | [diff] [blame] | 4586 | .compatible = "tianma,tm070rvhg71", |
| 4587 | .data = &tianma_tm070rvhg71, |
| 4588 | }, { |
Linus Walleij | d8a0d6a | 2019-08-05 10:58:46 +0200 | [diff] [blame] | 4589 | .compatible = "ti,nspire-cx-lcd-panel", |
| 4590 | .data = &ti_nspire_cx_lcd_panel, |
| 4591 | }, { |
| 4592 | .compatible = "ti,nspire-classic-lcd-panel", |
| 4593 | .data = &ti_nspire_classic_lcd_panel, |
| 4594 | }, { |
Lucas Stach | 06e733e | 2017-10-18 19:22:40 +0200 | [diff] [blame] | 4595 | .compatible = "toshiba,lt089ac29000", |
| 4596 | .data = &toshiba_lt089ac29000, |
| 4597 | }, { |
Bhuvanchandra DV | 227e4f4 | 2016-05-05 11:47:07 +0530 | [diff] [blame] | 4598 | .compatible = "tpk,f07a-0102", |
| 4599 | .data = &tpk_f07a_0102, |
| 4600 | }, { |
| 4601 | .compatible = "tpk,f10a-0102", |
| 4602 | .data = &tpk_f10a_0102, |
| 4603 | }, { |
Maciej S. Szmigiero | 06a9dc6 | 2016-02-13 22:52:03 +0100 | [diff] [blame] | 4604 | .compatible = "urt,umsh-8596md-t", |
| 4605 | .data = &urt_umsh_8596md_parallel, |
| 4606 | }, { |
| 4607 | .compatible = "urt,umsh-8596md-1t", |
| 4608 | .data = &urt_umsh_8596md_parallel, |
| 4609 | }, { |
| 4610 | .compatible = "urt,umsh-8596md-7t", |
| 4611 | .data = &urt_umsh_8596md_parallel, |
| 4612 | }, { |
| 4613 | .compatible = "urt,umsh-8596md-11t", |
| 4614 | .data = &urt_umsh_8596md_lvds, |
| 4615 | }, { |
| 4616 | .compatible = "urt,umsh-8596md-19t", |
| 4617 | .data = &urt_umsh_8596md_lvds, |
| 4618 | }, { |
| 4619 | .compatible = "urt,umsh-8596md-20t", |
| 4620 | .data = &urt_umsh_8596md_parallel, |
| 4621 | }, { |
Fabio Estevam | 0420618 | 2019-02-18 21:27:06 -0300 | [diff] [blame] | 4622 | .compatible = "vxt,vl050-8048nt-c01", |
| 4623 | .data = &vl050_8048nt_c01, |
| 4624 | }, { |
Richard Genoud | e4bac40 | 2017-03-27 12:33:23 +0200 | [diff] [blame] | 4625 | .compatible = "winstar,wf35ltiacd", |
| 4626 | .data = &winstar_wf35ltiacd, |
| 4627 | }, { |
Jagan Teki | 7a1f4fa | 2020-09-04 23:38:21 +0530 | [diff] [blame] | 4628 | .compatible = "yes-optoelectronics,ytc700tlag-05-201c", |
| 4629 | .data = &yes_optoelectronics_ytc700tlag_05_201c, |
| 4630 | }, { |
Sam Ravnborg | 4a1d0db | 2020-02-16 19:15:13 +0100 | [diff] [blame] | 4631 | /* Must be the last entry */ |
| 4632 | .compatible = "panel-dpi", |
| 4633 | .data = &panel_dpi, |
| 4634 | }, { |
Thierry Reding | 280921d | 2013-08-30 15:10:14 +0200 | [diff] [blame] | 4635 | /* sentinel */ |
| 4636 | } |
| 4637 | }; |
| 4638 | MODULE_DEVICE_TABLE(of, platform_of_match); |
| 4639 | |
| 4640 | static int panel_simple_platform_probe(struct platform_device *pdev) |
| 4641 | { |
| 4642 | const struct of_device_id *id; |
| 4643 | |
| 4644 | id = of_match_node(platform_of_match, pdev->dev.of_node); |
| 4645 | if (!id) |
| 4646 | return -ENODEV; |
| 4647 | |
Douglas Anderson | cc5a3fc | 2021-06-11 10:17:42 -0700 | [diff] [blame] | 4648 | return panel_simple_probe(&pdev->dev, id->data, NULL); |
Thierry Reding | 280921d | 2013-08-30 15:10:14 +0200 | [diff] [blame] | 4649 | } |
| 4650 | |
| 4651 | static int panel_simple_platform_remove(struct platform_device *pdev) |
| 4652 | { |
| 4653 | return panel_simple_remove(&pdev->dev); |
| 4654 | } |
| 4655 | |
Thierry Reding | d02fd93 | 2014-04-29 17:21:21 +0200 | [diff] [blame] | 4656 | static void panel_simple_platform_shutdown(struct platform_device *pdev) |
| 4657 | { |
| 4658 | panel_simple_shutdown(&pdev->dev); |
| 4659 | } |
| 4660 | |
Douglas Anderson | 3235b0f | 2021-04-16 15:39:30 -0700 | [diff] [blame] | 4661 | static const struct dev_pm_ops panel_simple_pm_ops = { |
| 4662 | SET_RUNTIME_PM_OPS(panel_simple_suspend, panel_simple_resume, NULL) |
| 4663 | SET_SYSTEM_SLEEP_PM_OPS(pm_runtime_force_suspend, |
| 4664 | pm_runtime_force_resume) |
| 4665 | }; |
| 4666 | |
Thierry Reding | 280921d | 2013-08-30 15:10:14 +0200 | [diff] [blame] | 4667 | static struct platform_driver panel_simple_platform_driver = { |
| 4668 | .driver = { |
| 4669 | .name = "panel-simple", |
Thierry Reding | 280921d | 2013-08-30 15:10:14 +0200 | [diff] [blame] | 4670 | .of_match_table = platform_of_match, |
Douglas Anderson | 3235b0f | 2021-04-16 15:39:30 -0700 | [diff] [blame] | 4671 | .pm = &panel_simple_pm_ops, |
Thierry Reding | 280921d | 2013-08-30 15:10:14 +0200 | [diff] [blame] | 4672 | }, |
| 4673 | .probe = panel_simple_platform_probe, |
| 4674 | .remove = panel_simple_platform_remove, |
Thierry Reding | d02fd93 | 2014-04-29 17:21:21 +0200 | [diff] [blame] | 4675 | .shutdown = panel_simple_platform_shutdown, |
Thierry Reding | 280921d | 2013-08-30 15:10:14 +0200 | [diff] [blame] | 4676 | }; |
| 4677 | |
Thierry Reding | 210fcd9 | 2013-11-22 19:27:11 +0100 | [diff] [blame] | 4678 | struct panel_desc_dsi { |
| 4679 | struct panel_desc desc; |
| 4680 | |
Thierry Reding | 462658b | 2014-03-14 11:24:57 +0100 | [diff] [blame] | 4681 | unsigned long flags; |
Thierry Reding | 210fcd9 | 2013-11-22 19:27:11 +0100 | [diff] [blame] | 4682 | enum mipi_dsi_pixel_format format; |
| 4683 | unsigned int lanes; |
| 4684 | }; |
| 4685 | |
Thierry Reding | d718d79 | 2015-04-08 16:52:33 +0200 | [diff] [blame] | 4686 | static const struct drm_display_mode auo_b080uan01_mode = { |
| 4687 | .clock = 154500, |
| 4688 | .hdisplay = 1200, |
| 4689 | .hsync_start = 1200 + 62, |
| 4690 | .hsync_end = 1200 + 62 + 4, |
| 4691 | .htotal = 1200 + 62 + 4 + 62, |
| 4692 | .vdisplay = 1920, |
| 4693 | .vsync_start = 1920 + 9, |
| 4694 | .vsync_end = 1920 + 9 + 2, |
| 4695 | .vtotal = 1920 + 9 + 2 + 8, |
Thierry Reding | d718d79 | 2015-04-08 16:52:33 +0200 | [diff] [blame] | 4696 | }; |
| 4697 | |
| 4698 | static const struct panel_desc_dsi auo_b080uan01 = { |
| 4699 | .desc = { |
| 4700 | .modes = &auo_b080uan01_mode, |
| 4701 | .num_modes = 1, |
| 4702 | .bpc = 8, |
| 4703 | .size = { |
| 4704 | .width = 108, |
| 4705 | .height = 272, |
| 4706 | }, |
Laurent Pinchart | cb62cde | 2020-06-02 20:12:40 +0300 | [diff] [blame] | 4707 | .connector_type = DRM_MODE_CONNECTOR_DSI, |
Thierry Reding | d718d79 | 2015-04-08 16:52:33 +0200 | [diff] [blame] | 4708 | }, |
| 4709 | .flags = MIPI_DSI_MODE_VIDEO | MIPI_DSI_CLOCK_NON_CONTINUOUS, |
| 4710 | .format = MIPI_DSI_FMT_RGB888, |
| 4711 | .lanes = 4, |
| 4712 | }; |
| 4713 | |
Chris Zhong | c852196 | 2015-11-20 16:15:37 +0800 | [diff] [blame] | 4714 | static const struct drm_display_mode boe_tv080wum_nl0_mode = { |
| 4715 | .clock = 160000, |
| 4716 | .hdisplay = 1200, |
| 4717 | .hsync_start = 1200 + 120, |
| 4718 | .hsync_end = 1200 + 120 + 20, |
| 4719 | .htotal = 1200 + 120 + 20 + 21, |
| 4720 | .vdisplay = 1920, |
| 4721 | .vsync_start = 1920 + 21, |
| 4722 | .vsync_end = 1920 + 21 + 3, |
| 4723 | .vtotal = 1920 + 21 + 3 + 18, |
Chris Zhong | c852196 | 2015-11-20 16:15:37 +0800 | [diff] [blame] | 4724 | .flags = DRM_MODE_FLAG_NVSYNC | DRM_MODE_FLAG_NHSYNC, |
| 4725 | }; |
| 4726 | |
| 4727 | static const struct panel_desc_dsi boe_tv080wum_nl0 = { |
| 4728 | .desc = { |
| 4729 | .modes = &boe_tv080wum_nl0_mode, |
| 4730 | .num_modes = 1, |
| 4731 | .size = { |
| 4732 | .width = 107, |
| 4733 | .height = 172, |
| 4734 | }, |
Laurent Pinchart | cb62cde | 2020-06-02 20:12:40 +0300 | [diff] [blame] | 4735 | .connector_type = DRM_MODE_CONNECTOR_DSI, |
Chris Zhong | c852196 | 2015-11-20 16:15:37 +0800 | [diff] [blame] | 4736 | }, |
| 4737 | .flags = MIPI_DSI_MODE_VIDEO | |
| 4738 | MIPI_DSI_MODE_VIDEO_BURST | |
| 4739 | MIPI_DSI_MODE_VIDEO_SYNC_PULSE, |
| 4740 | .format = MIPI_DSI_FMT_RGB888, |
| 4741 | .lanes = 4, |
| 4742 | }; |
| 4743 | |
Alexandre Courbot | 712ac1b | 2014-01-21 18:57:10 +0900 | [diff] [blame] | 4744 | static const struct drm_display_mode lg_ld070wx3_sl01_mode = { |
| 4745 | .clock = 71000, |
| 4746 | .hdisplay = 800, |
| 4747 | .hsync_start = 800 + 32, |
| 4748 | .hsync_end = 800 + 32 + 1, |
| 4749 | .htotal = 800 + 32 + 1 + 57, |
| 4750 | .vdisplay = 1280, |
| 4751 | .vsync_start = 1280 + 28, |
| 4752 | .vsync_end = 1280 + 28 + 1, |
| 4753 | .vtotal = 1280 + 28 + 1 + 14, |
Alexandre Courbot | 712ac1b | 2014-01-21 18:57:10 +0900 | [diff] [blame] | 4754 | }; |
| 4755 | |
| 4756 | static const struct panel_desc_dsi lg_ld070wx3_sl01 = { |
| 4757 | .desc = { |
| 4758 | .modes = &lg_ld070wx3_sl01_mode, |
| 4759 | .num_modes = 1, |
Thierry Reding | d7a839c | 2014-11-06 10:11:01 +0100 | [diff] [blame] | 4760 | .bpc = 8, |
Alexandre Courbot | 712ac1b | 2014-01-21 18:57:10 +0900 | [diff] [blame] | 4761 | .size = { |
| 4762 | .width = 94, |
| 4763 | .height = 151, |
| 4764 | }, |
Laurent Pinchart | cb62cde | 2020-06-02 20:12:40 +0300 | [diff] [blame] | 4765 | .connector_type = DRM_MODE_CONNECTOR_DSI, |
Alexandre Courbot | 712ac1b | 2014-01-21 18:57:10 +0900 | [diff] [blame] | 4766 | }, |
Alexandre Courbot | 5e4cc27 | 2014-07-08 21:32:12 +0900 | [diff] [blame] | 4767 | .flags = MIPI_DSI_MODE_VIDEO | MIPI_DSI_CLOCK_NON_CONTINUOUS, |
Alexandre Courbot | 712ac1b | 2014-01-21 18:57:10 +0900 | [diff] [blame] | 4768 | .format = MIPI_DSI_FMT_RGB888, |
| 4769 | .lanes = 4, |
| 4770 | }; |
| 4771 | |
Alexandre Courbot | 499ce85 | 2014-01-21 18:57:09 +0900 | [diff] [blame] | 4772 | static const struct drm_display_mode lg_lh500wx1_sd03_mode = { |
| 4773 | .clock = 67000, |
| 4774 | .hdisplay = 720, |
| 4775 | .hsync_start = 720 + 12, |
| 4776 | .hsync_end = 720 + 12 + 4, |
| 4777 | .htotal = 720 + 12 + 4 + 112, |
| 4778 | .vdisplay = 1280, |
| 4779 | .vsync_start = 1280 + 8, |
| 4780 | .vsync_end = 1280 + 8 + 4, |
| 4781 | .vtotal = 1280 + 8 + 4 + 12, |
Alexandre Courbot | 499ce85 | 2014-01-21 18:57:09 +0900 | [diff] [blame] | 4782 | }; |
| 4783 | |
| 4784 | static const struct panel_desc_dsi lg_lh500wx1_sd03 = { |
| 4785 | .desc = { |
| 4786 | .modes = &lg_lh500wx1_sd03_mode, |
| 4787 | .num_modes = 1, |
Thierry Reding | d7a839c | 2014-11-06 10:11:01 +0100 | [diff] [blame] | 4788 | .bpc = 8, |
Alexandre Courbot | 499ce85 | 2014-01-21 18:57:09 +0900 | [diff] [blame] | 4789 | .size = { |
| 4790 | .width = 62, |
| 4791 | .height = 110, |
| 4792 | }, |
Laurent Pinchart | cb62cde | 2020-06-02 20:12:40 +0300 | [diff] [blame] | 4793 | .connector_type = DRM_MODE_CONNECTOR_DSI, |
Alexandre Courbot | 499ce85 | 2014-01-21 18:57:09 +0900 | [diff] [blame] | 4794 | }, |
| 4795 | .flags = MIPI_DSI_MODE_VIDEO, |
| 4796 | .format = MIPI_DSI_FMT_RGB888, |
| 4797 | .lanes = 4, |
| 4798 | }; |
| 4799 | |
Thierry Reding | 280921d | 2013-08-30 15:10:14 +0200 | [diff] [blame] | 4800 | static const struct drm_display_mode panasonic_vvx10f004b00_mode = { |
| 4801 | .clock = 157200, |
| 4802 | .hdisplay = 1920, |
| 4803 | .hsync_start = 1920 + 154, |
| 4804 | .hsync_end = 1920 + 154 + 16, |
| 4805 | .htotal = 1920 + 154 + 16 + 32, |
| 4806 | .vdisplay = 1200, |
| 4807 | .vsync_start = 1200 + 17, |
| 4808 | .vsync_end = 1200 + 17 + 2, |
| 4809 | .vtotal = 1200 + 17 + 2 + 16, |
Thierry Reding | 280921d | 2013-08-30 15:10:14 +0200 | [diff] [blame] | 4810 | }; |
| 4811 | |
Thierry Reding | 210fcd9 | 2013-11-22 19:27:11 +0100 | [diff] [blame] | 4812 | static const struct panel_desc_dsi panasonic_vvx10f004b00 = { |
| 4813 | .desc = { |
| 4814 | .modes = &panasonic_vvx10f004b00_mode, |
| 4815 | .num_modes = 1, |
Thierry Reding | d7a839c | 2014-11-06 10:11:01 +0100 | [diff] [blame] | 4816 | .bpc = 8, |
Thierry Reding | 210fcd9 | 2013-11-22 19:27:11 +0100 | [diff] [blame] | 4817 | .size = { |
| 4818 | .width = 217, |
| 4819 | .height = 136, |
| 4820 | }, |
Laurent Pinchart | cb62cde | 2020-06-02 20:12:40 +0300 | [diff] [blame] | 4821 | .connector_type = DRM_MODE_CONNECTOR_DSI, |
Thierry Reding | 280921d | 2013-08-30 15:10:14 +0200 | [diff] [blame] | 4822 | }, |
Alexandre Courbot | 5e4cc27 | 2014-07-08 21:32:12 +0900 | [diff] [blame] | 4823 | .flags = MIPI_DSI_MODE_VIDEO | MIPI_DSI_MODE_VIDEO_SYNC_PULSE | |
| 4824 | MIPI_DSI_CLOCK_NON_CONTINUOUS, |
Thierry Reding | 210fcd9 | 2013-11-22 19:27:11 +0100 | [diff] [blame] | 4825 | .format = MIPI_DSI_FMT_RGB888, |
| 4826 | .lanes = 4, |
| 4827 | }; |
| 4828 | |
Jonathan Marek | debcd8f | 2018-11-24 15:06:28 -0500 | [diff] [blame] | 4829 | static const struct drm_display_mode lg_acx467akm_7_mode = { |
| 4830 | .clock = 150000, |
| 4831 | .hdisplay = 1080, |
| 4832 | .hsync_start = 1080 + 2, |
| 4833 | .hsync_end = 1080 + 2 + 2, |
| 4834 | .htotal = 1080 + 2 + 2 + 2, |
| 4835 | .vdisplay = 1920, |
| 4836 | .vsync_start = 1920 + 2, |
| 4837 | .vsync_end = 1920 + 2 + 2, |
| 4838 | .vtotal = 1920 + 2 + 2 + 2, |
Jonathan Marek | debcd8f | 2018-11-24 15:06:28 -0500 | [diff] [blame] | 4839 | }; |
| 4840 | |
| 4841 | static const struct panel_desc_dsi lg_acx467akm_7 = { |
| 4842 | .desc = { |
| 4843 | .modes = &lg_acx467akm_7_mode, |
| 4844 | .num_modes = 1, |
| 4845 | .bpc = 8, |
| 4846 | .size = { |
| 4847 | .width = 62, |
| 4848 | .height = 110, |
| 4849 | }, |
Laurent Pinchart | cb62cde | 2020-06-02 20:12:40 +0300 | [diff] [blame] | 4850 | .connector_type = DRM_MODE_CONNECTOR_DSI, |
Jonathan Marek | debcd8f | 2018-11-24 15:06:28 -0500 | [diff] [blame] | 4851 | }, |
| 4852 | .flags = 0, |
| 4853 | .format = MIPI_DSI_FMT_RGB888, |
| 4854 | .lanes = 4, |
| 4855 | }; |
| 4856 | |
Peter Ujfalusi | 6296723 | 2019-02-26 09:55:21 +0200 | [diff] [blame] | 4857 | static const struct drm_display_mode osd101t2045_53ts_mode = { |
| 4858 | .clock = 154500, |
| 4859 | .hdisplay = 1920, |
| 4860 | .hsync_start = 1920 + 112, |
| 4861 | .hsync_end = 1920 + 112 + 16, |
| 4862 | .htotal = 1920 + 112 + 16 + 32, |
| 4863 | .vdisplay = 1200, |
| 4864 | .vsync_start = 1200 + 16, |
| 4865 | .vsync_end = 1200 + 16 + 2, |
| 4866 | .vtotal = 1200 + 16 + 2 + 16, |
Peter Ujfalusi | 6296723 | 2019-02-26 09:55:21 +0200 | [diff] [blame] | 4867 | .flags = DRM_MODE_FLAG_NHSYNC | DRM_MODE_FLAG_NVSYNC, |
| 4868 | }; |
| 4869 | |
| 4870 | static const struct panel_desc_dsi osd101t2045_53ts = { |
| 4871 | .desc = { |
| 4872 | .modes = &osd101t2045_53ts_mode, |
| 4873 | .num_modes = 1, |
| 4874 | .bpc = 8, |
| 4875 | .size = { |
| 4876 | .width = 217, |
| 4877 | .height = 136, |
| 4878 | }, |
Laurent Pinchart | cb62cde | 2020-06-02 20:12:40 +0300 | [diff] [blame] | 4879 | .connector_type = DRM_MODE_CONNECTOR_DSI, |
Peter Ujfalusi | 6296723 | 2019-02-26 09:55:21 +0200 | [diff] [blame] | 4880 | }, |
| 4881 | .flags = MIPI_DSI_MODE_VIDEO | MIPI_DSI_MODE_VIDEO_BURST | |
| 4882 | MIPI_DSI_MODE_VIDEO_SYNC_PULSE | |
| 4883 | MIPI_DSI_MODE_EOT_PACKET, |
| 4884 | .format = MIPI_DSI_FMT_RGB888, |
| 4885 | .lanes = 4, |
| 4886 | }; |
| 4887 | |
Thierry Reding | 210fcd9 | 2013-11-22 19:27:11 +0100 | [diff] [blame] | 4888 | static const struct of_device_id dsi_of_match[] = { |
| 4889 | { |
Thierry Reding | d718d79 | 2015-04-08 16:52:33 +0200 | [diff] [blame] | 4890 | .compatible = "auo,b080uan01", |
| 4891 | .data = &auo_b080uan01 |
| 4892 | }, { |
Chris Zhong | c852196 | 2015-11-20 16:15:37 +0800 | [diff] [blame] | 4893 | .compatible = "boe,tv080wum-nl0", |
| 4894 | .data = &boe_tv080wum_nl0 |
| 4895 | }, { |
Alexandre Courbot | 712ac1b | 2014-01-21 18:57:10 +0900 | [diff] [blame] | 4896 | .compatible = "lg,ld070wx3-sl01", |
| 4897 | .data = &lg_ld070wx3_sl01 |
| 4898 | }, { |
Alexandre Courbot | 499ce85 | 2014-01-21 18:57:09 +0900 | [diff] [blame] | 4899 | .compatible = "lg,lh500wx1-sd03", |
| 4900 | .data = &lg_lh500wx1_sd03 |
| 4901 | }, { |
Thierry Reding | 210fcd9 | 2013-11-22 19:27:11 +0100 | [diff] [blame] | 4902 | .compatible = "panasonic,vvx10f004b00", |
| 4903 | .data = &panasonic_vvx10f004b00 |
| 4904 | }, { |
Jonathan Marek | debcd8f | 2018-11-24 15:06:28 -0500 | [diff] [blame] | 4905 | .compatible = "lg,acx467akm-7", |
| 4906 | .data = &lg_acx467akm_7 |
| 4907 | }, { |
Peter Ujfalusi | 6296723 | 2019-02-26 09:55:21 +0200 | [diff] [blame] | 4908 | .compatible = "osddisplays,osd101t2045-53ts", |
| 4909 | .data = &osd101t2045_53ts |
| 4910 | }, { |
Thierry Reding | 210fcd9 | 2013-11-22 19:27:11 +0100 | [diff] [blame] | 4911 | /* sentinel */ |
| 4912 | } |
| 4913 | }; |
| 4914 | MODULE_DEVICE_TABLE(of, dsi_of_match); |
| 4915 | |
| 4916 | static int panel_simple_dsi_probe(struct mipi_dsi_device *dsi) |
| 4917 | { |
| 4918 | const struct panel_desc_dsi *desc; |
| 4919 | const struct of_device_id *id; |
| 4920 | int err; |
| 4921 | |
| 4922 | id = of_match_node(dsi_of_match, dsi->dev.of_node); |
| 4923 | if (!id) |
| 4924 | return -ENODEV; |
| 4925 | |
| 4926 | desc = id->data; |
| 4927 | |
Douglas Anderson | cc5a3fc | 2021-06-11 10:17:42 -0700 | [diff] [blame] | 4928 | err = panel_simple_probe(&dsi->dev, &desc->desc, NULL); |
Thierry Reding | 210fcd9 | 2013-11-22 19:27:11 +0100 | [diff] [blame] | 4929 | if (err < 0) |
| 4930 | return err; |
| 4931 | |
Thierry Reding | 462658b | 2014-03-14 11:24:57 +0100 | [diff] [blame] | 4932 | dsi->mode_flags = desc->flags; |
Thierry Reding | 210fcd9 | 2013-11-22 19:27:11 +0100 | [diff] [blame] | 4933 | dsi->format = desc->format; |
| 4934 | dsi->lanes = desc->lanes; |
| 4935 | |
Peter Ujfalusi | 7ad9db6 | 2019-02-26 10:11:53 +0200 | [diff] [blame] | 4936 | err = mipi_dsi_attach(dsi); |
| 4937 | if (err) { |
Julia Lawall | 5dd331d | 2021-02-09 22:13:04 +0100 | [diff] [blame] | 4938 | struct panel_simple *panel = mipi_dsi_get_drvdata(dsi); |
Peter Ujfalusi | 7ad9db6 | 2019-02-26 10:11:53 +0200 | [diff] [blame] | 4939 | |
| 4940 | drm_panel_remove(&panel->base); |
| 4941 | } |
| 4942 | |
| 4943 | return err; |
Thierry Reding | 210fcd9 | 2013-11-22 19:27:11 +0100 | [diff] [blame] | 4944 | } |
| 4945 | |
| 4946 | static int panel_simple_dsi_remove(struct mipi_dsi_device *dsi) |
| 4947 | { |
| 4948 | int err; |
| 4949 | |
| 4950 | err = mipi_dsi_detach(dsi); |
| 4951 | if (err < 0) |
| 4952 | dev_err(&dsi->dev, "failed to detach from DSI host: %d\n", err); |
| 4953 | |
| 4954 | return panel_simple_remove(&dsi->dev); |
| 4955 | } |
| 4956 | |
Thierry Reding | d02fd93 | 2014-04-29 17:21:21 +0200 | [diff] [blame] | 4957 | static void panel_simple_dsi_shutdown(struct mipi_dsi_device *dsi) |
| 4958 | { |
| 4959 | panel_simple_shutdown(&dsi->dev); |
| 4960 | } |
| 4961 | |
Thierry Reding | 210fcd9 | 2013-11-22 19:27:11 +0100 | [diff] [blame] | 4962 | static struct mipi_dsi_driver panel_simple_dsi_driver = { |
| 4963 | .driver = { |
| 4964 | .name = "panel-simple-dsi", |
Thierry Reding | 210fcd9 | 2013-11-22 19:27:11 +0100 | [diff] [blame] | 4965 | .of_match_table = dsi_of_match, |
Douglas Anderson | 3235b0f | 2021-04-16 15:39:30 -0700 | [diff] [blame] | 4966 | .pm = &panel_simple_pm_ops, |
Thierry Reding | 210fcd9 | 2013-11-22 19:27:11 +0100 | [diff] [blame] | 4967 | }, |
| 4968 | .probe = panel_simple_dsi_probe, |
| 4969 | .remove = panel_simple_dsi_remove, |
Thierry Reding | d02fd93 | 2014-04-29 17:21:21 +0200 | [diff] [blame] | 4970 | .shutdown = panel_simple_dsi_shutdown, |
Thierry Reding | 280921d | 2013-08-30 15:10:14 +0200 | [diff] [blame] | 4971 | }; |
| 4972 | |
Douglas Anderson | 74c06c2 | 2021-06-11 10:17:41 -0700 | [diff] [blame] | 4973 | static int panel_simple_dp_aux_ep_probe(struct dp_aux_ep_device *aux_ep) |
| 4974 | { |
| 4975 | const struct of_device_id *id; |
| 4976 | |
| 4977 | id = of_match_node(platform_of_match, aux_ep->dev.of_node); |
| 4978 | if (!id) |
| 4979 | return -ENODEV; |
| 4980 | |
Douglas Anderson | cc5a3fc | 2021-06-11 10:17:42 -0700 | [diff] [blame] | 4981 | return panel_simple_probe(&aux_ep->dev, id->data, aux_ep->aux); |
Douglas Anderson | 74c06c2 | 2021-06-11 10:17:41 -0700 | [diff] [blame] | 4982 | } |
| 4983 | |
| 4984 | static void panel_simple_dp_aux_ep_remove(struct dp_aux_ep_device *aux_ep) |
| 4985 | { |
| 4986 | panel_simple_remove(&aux_ep->dev); |
| 4987 | } |
| 4988 | |
| 4989 | static void panel_simple_dp_aux_ep_shutdown(struct dp_aux_ep_device *aux_ep) |
| 4990 | { |
| 4991 | panel_simple_shutdown(&aux_ep->dev); |
| 4992 | } |
| 4993 | |
| 4994 | static struct dp_aux_ep_driver panel_simple_dp_aux_ep_driver = { |
| 4995 | .driver = { |
| 4996 | .name = "panel-simple-dp-aux", |
| 4997 | .of_match_table = platform_of_match, /* Same as platform one! */ |
| 4998 | .pm = &panel_simple_pm_ops, |
| 4999 | }, |
| 5000 | .probe = panel_simple_dp_aux_ep_probe, |
| 5001 | .remove = panel_simple_dp_aux_ep_remove, |
| 5002 | .shutdown = panel_simple_dp_aux_ep_shutdown, |
| 5003 | }; |
| 5004 | |
Thierry Reding | 280921d | 2013-08-30 15:10:14 +0200 | [diff] [blame] | 5005 | static int __init panel_simple_init(void) |
| 5006 | { |
Thierry Reding | 210fcd9 | 2013-11-22 19:27:11 +0100 | [diff] [blame] | 5007 | int err; |
| 5008 | |
| 5009 | err = platform_driver_register(&panel_simple_platform_driver); |
| 5010 | if (err < 0) |
| 5011 | return err; |
| 5012 | |
Douglas Anderson | 74c06c2 | 2021-06-11 10:17:41 -0700 | [diff] [blame] | 5013 | err = dp_aux_dp_driver_register(&panel_simple_dp_aux_ep_driver); |
| 5014 | if (err < 0) |
| 5015 | goto err_did_platform_register; |
| 5016 | |
Thierry Reding | 210fcd9 | 2013-11-22 19:27:11 +0100 | [diff] [blame] | 5017 | if (IS_ENABLED(CONFIG_DRM_MIPI_DSI)) { |
| 5018 | err = mipi_dsi_driver_register(&panel_simple_dsi_driver); |
Douglas Anderson | 74c06c2 | 2021-06-11 10:17:41 -0700 | [diff] [blame] | 5019 | if (err < 0) |
| 5020 | goto err_did_aux_ep_register; |
Thierry Reding | 210fcd9 | 2013-11-22 19:27:11 +0100 | [diff] [blame] | 5021 | } |
| 5022 | |
| 5023 | return 0; |
Douglas Anderson | 74c06c2 | 2021-06-11 10:17:41 -0700 | [diff] [blame] | 5024 | |
| 5025 | err_did_aux_ep_register: |
| 5026 | dp_aux_dp_driver_unregister(&panel_simple_dp_aux_ep_driver); |
| 5027 | |
| 5028 | err_did_platform_register: |
| 5029 | platform_driver_unregister(&panel_simple_platform_driver); |
| 5030 | |
| 5031 | return err; |
Thierry Reding | 280921d | 2013-08-30 15:10:14 +0200 | [diff] [blame] | 5032 | } |
| 5033 | module_init(panel_simple_init); |
| 5034 | |
| 5035 | static void __exit panel_simple_exit(void) |
| 5036 | { |
Thierry Reding | 210fcd9 | 2013-11-22 19:27:11 +0100 | [diff] [blame] | 5037 | if (IS_ENABLED(CONFIG_DRM_MIPI_DSI)) |
| 5038 | mipi_dsi_driver_unregister(&panel_simple_dsi_driver); |
| 5039 | |
Douglas Anderson | 74c06c2 | 2021-06-11 10:17:41 -0700 | [diff] [blame] | 5040 | dp_aux_dp_driver_unregister(&panel_simple_dp_aux_ep_driver); |
Thierry Reding | 280921d | 2013-08-30 15:10:14 +0200 | [diff] [blame] | 5041 | platform_driver_unregister(&panel_simple_platform_driver); |
| 5042 | } |
| 5043 | module_exit(panel_simple_exit); |
| 5044 | |
| 5045 | MODULE_AUTHOR("Thierry Reding <treding@nvidia.com>"); |
| 5046 | MODULE_DESCRIPTION("DRM Driver for Simple Panels"); |
| 5047 | MODULE_LICENSE("GPL and additional rights"); |