diff --git a/arch/arm/boot/dts/overlays/README b/arch/arm/boot/dts/overlays/README index 4a5d57bd35c15..ffa95efe74d62 100644 --- a/arch/arm/boot/dts/overlays/README +++ b/arch/arm/boot/dts/overlays/README @@ -6304,6 +6304,7 @@ Params: 3_4_inch_c 3.4" 800x800 2lane 10_1_inch_a_4lane 10.1" 800x1280 4lane 10_1_inch_b 10.1" 720x1280 2lane 10_1_inch_b_4lane 10.1" 720x1280 4lane + 10_1_inch_e_4lane 10.1" 1200x1920 4lane 12_3_inch_a_4lane 12.3" 720x1920 4lane disable_touch Disable the touch controller invx Touchscreen inverted x axis diff --git a/arch/arm/boot/dts/overlays/vc4-kms-dsi-waveshare-panel-v2-overlay.dts b/arch/arm/boot/dts/overlays/vc4-kms-dsi-waveshare-panel-v2-overlay.dts index ceb1b0b324fcb..58c26bbe24a77 100644 --- a/arch/arm/boot/dts/overlays/vc4-kms-dsi-waveshare-panel-v2-overlay.dts +++ b/arch/arm/boot/dts/overlays/vc4-kms-dsi-waveshare-panel-v2-overlay.dts @@ -104,6 +104,7 @@ <&touch>, "touchscreen-inverted-y"; 10_1_inch_b_4lane = <&dsi_panel>, "compatible=waveshare,10.1-dsi-touch-b,4lane", <&touch>, "touchscreen-inverted-y"; + 10_1_inch_e_4lane = <&dsi_panel>, "compatible=waveshare,10.1-dsi-touch-e,4lane"; 12_3_inch_a_4lane = <&dsi_panel>, "compatible=waveshare,12.3-dsi-touch-a,4lane", <&touch>, "touchscreen-swapped-x-y", <&touch>, "touchscreen-inverted-y"; diff --git a/drivers/gpu/drm/panel/panel-waveshare-dsi-v2.c b/drivers/gpu/drm/panel/panel-waveshare-dsi-v2.c index 9038c6b794845..d711ee48f1844 100644 --- a/drivers/gpu/drm/panel/panel-waveshare-dsi-v2.c +++ b/drivers/gpu/drm/panel/panel-waveshare-dsi-v2.c @@ -983,6 +983,14 @@ static const struct panel_init_cmd ws_panel_10_1_b_init[] = { {}, }; +static const struct panel_init_cmd ws_panel_10_1_e_4lane_init[] = { + _INIT_DCS_CMD(0x11), + _INIT_DELAY_CMD(120), + _INIT_DCS_CMD(0x29), + _INIT_DELAY_CMD(50), + {}, +}; + static const struct panel_init_cmd ws_panel_8_8_a_init[] = { _INIT_DCS_CMD(0x11), _INIT_DELAY_CMD(120), @@ -2015,6 +2023,20 @@ static const struct drm_display_mode ws_panel_10_1_b_mode = { .height_mm = 222, }; +static const struct drm_display_mode ws_panel_10_1_e_4lane_mode = { + .clock = 155000, + .hdisplay = 1200, + .hsync_start = 1200 + 28, + .hsync_end = 1200 + 28 + 10, + .htotal = 1200 + 28 + 10 + 30, + .vdisplay = 1920, + .vsync_start = 1920 + 80, + .vsync_end = 1920 + 80 + 4, + .vtotal = 1920 + 80 + 4 + 28, + .width_mm = 135, + .height_mm = 216, +}; + static const struct drm_display_mode ws_panel_9_b_4lane_mode = { .clock = 66000, .hdisplay = 720, @@ -2386,6 +2408,15 @@ static const struct ws_panel_desc ws_panel_10_1_inch_b_desc = { .format = MIPI_DSI_FMT_RGB888, }; +static const struct ws_panel_desc ws_panel_10_1_inch_e_4lane_desc = { + .init = ws_panel_10_1_e_4lane_init, + .mode = &ws_panel_10_1_e_4lane_mode, + .mode_flags = MIPI_DSI_MODE_VIDEO_HSE | MIPI_DSI_MODE_VIDEO | + MIPI_DSI_MODE_LPM | MIPI_DSI_CLOCK_NON_CONTINUOUS, + .lanes = 4, + .format = MIPI_DSI_FMT_RGB888, +}; + static const struct ws_panel_desc ws_panel_9_inch_b_4lane_desc = { .init = ws_panel_10_1_b_4lane_init, .mode = &ws_panel_9_b_4lane_mode, @@ -2523,6 +2554,8 @@ static const struct of_device_id ws_panel_of_match[] = { &ws_panel_10_1_inch_b_4lane_desc }, { .compatible = "waveshare,10.1-dsi-touch-b", &ws_panel_10_1_inch_b_desc }, + { .compatible = "waveshare,10.1-dsi-touch-e,4lane", + &ws_panel_10_1_inch_e_4lane_desc }, { .compatible = "waveshare,9.0-dsi-touch-b,4lane", &ws_panel_9_inch_b_4lane_desc }, { .compatible = "waveshare,9.0-dsi-touch-b", &ws_panel_9_inch_b_desc },