Skip to content

Commit 3d0bedd

Browse files
Waveshare_Teampopcornmix
authored andcommitted
drm: panel: Added waveshare 7.0inch h dsi screen support
Signed-off-by: Waveshare_Team <support@waveshare.com>
1 parent 1705fe0 commit 3d0bedd

File tree

1 file changed

+24
-0
lines changed

1 file changed

+24
-0
lines changed

drivers/gpu/drm/panel/panel-waveshare-dsi.c

Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -303,6 +303,27 @@ static const struct ws_panel_data ws_panel_13_3_2lane_data = {
303303
.mode_flags = MIPI_DSI_MODE_VIDEO | MIPI_DSI_MODE_LPM,
304304
};
305305

306+
/* 7.0inch 1280x720
307+
* https://www.waveshare.com/7inch-dsi-lcd-h.htm
308+
*/
309+
static const struct drm_display_mode ws_panel_7_0_h_mode = {
310+
.clock = 83333,
311+
.hdisplay = 1280,
312+
.hsync_start = 1280 + 64,
313+
.hsync_end = 1280 + 64 + 64,
314+
.htotal = 1280 + 64 + 64 + 64,
315+
.vdisplay = 720,
316+
.vsync_start = 720 + 64,
317+
.vsync_end = 720 + 64 + 64,
318+
.vtotal = 720 + 64 + 64 + 64,
319+
};
320+
321+
static const struct ws_panel_data ws_panel_7_0_h_data = {
322+
.mode = &ws_panel_7_0_h_mode,
323+
.lanes = 2,
324+
.mode_flags = MIPI_DSI_MODE_VIDEO_HSE | MIPI_DSI_MODE_VIDEO | MIPI_DSI_CLOCK_NON_CONTINUOUS,
325+
};
326+
306327
static struct ws_panel *panel_to_ts(struct drm_panel *panel)
307328
{
308329
return container_of(panel, struct ws_panel, base);
@@ -587,6 +608,9 @@ static const struct of_device_id ws_panel_of_ids[] = {
587608
}, {
588609
.compatible = "waveshare,13.3inch-2lane-panel",
589610
.data = &ws_panel_13_3_2lane_data,
611+
}, {
612+
.compatible = "waveshare,7.0inch-h-panel",
613+
.data = &ws_panel_7_0_h_data,
590614
}, {
591615
/* sentinel */
592616
}

0 commit comments

Comments
 (0)