Lines Matching +full:avee +full:- +full:supply
1 // SPDX-License-Identifier: GPL-2.0
30 #define MCS_STBCTR 0x12 /* TE1 Output Setting Zig-Zag Connection */
36 #define MCS_SETAVEE 0x29 /* PFM Control for AVEE Output */
45 /* CMD2 P2 commands (GOA Timing Control) - no description in datasheet */
79 struct regulator *supply; member
105 struct mipi_dsi_device *dsi = to_mipi_dsi_device(ctx->dev); in rm68200_dcs_write_buf()
110 dev_err_ratelimited(ctx->dev, "MIPI DSI DCS write buffer failed: %d\n", err); in rm68200_dcs_write_buf()
115 struct mipi_dsi_device *dsi = to_mipi_dsi_device(ctx->dev); in rm68200_dcs_write_cmd()
120 dev_err_ratelimited(ctx->dev, "MIPI DSI DCS write failed: %d\n", err); in rm68200_dcs_write_cmd()
131 * This panel is not able to auto-increment all cmd addresses so for some of
235 struct mipi_dsi_device *dsi = to_mipi_dsi_device(ctx->dev); in rm68200_unprepare()
240 dev_warn(panel->dev, "failed to set display off: %d\n", ret); in rm68200_unprepare()
244 dev_warn(panel->dev, "failed to enter sleep mode: %d\n", ret); in rm68200_unprepare()
248 if (ctx->reset_gpio) { in rm68200_unprepare()
249 gpiod_set_value_cansleep(ctx->reset_gpio, 1); in rm68200_unprepare()
253 regulator_disable(ctx->supply); in rm68200_unprepare()
261 struct mipi_dsi_device *dsi = to_mipi_dsi_device(ctx->dev); in rm68200_prepare()
264 ret = regulator_enable(ctx->supply); in rm68200_prepare()
266 dev_err(ctx->dev, "failed to enable supply: %d\n", ret); in rm68200_prepare()
270 if (ctx->reset_gpio) { in rm68200_prepare()
271 gpiod_set_value_cansleep(ctx->reset_gpio, 1); in rm68200_prepare()
273 gpiod_set_value_cansleep(ctx->reset_gpio, 0); in rm68200_prepare()
299 mode = drm_mode_duplicate(connector->dev, &default_mode); in rm68200_get_modes()
301 dev_err(panel->dev, "failed to add mode %ux%u@%u\n", in rm68200_get_modes()
304 return -ENOMEM; in rm68200_get_modes()
309 mode->type = DRM_MODE_TYPE_DRIVER | DRM_MODE_TYPE_PREFERRED; in rm68200_get_modes()
312 connector->display_info.width_mm = mode->width_mm; in rm68200_get_modes()
313 connector->display_info.height_mm = mode->height_mm; in rm68200_get_modes()
326 struct device *dev = &dsi->dev; in rm68200_probe()
332 return -ENOMEM; in rm68200_probe()
334 ctx->reset_gpio = devm_gpiod_get_optional(dev, "reset", GPIOD_OUT_LOW); in rm68200_probe()
335 if (IS_ERR(ctx->reset_gpio)) { in rm68200_probe()
336 ret = PTR_ERR(ctx->reset_gpio); in rm68200_probe()
341 ctx->supply = devm_regulator_get(dev, "power"); in rm68200_probe()
342 if (IS_ERR(ctx->supply)) { in rm68200_probe()
343 ret = PTR_ERR(ctx->supply); in rm68200_probe()
344 if (ret != -EPROBE_DEFER) in rm68200_probe()
351 ctx->dev = dev; in rm68200_probe()
353 dsi->lanes = 2; in rm68200_probe()
354 dsi->format = MIPI_DSI_FMT_RGB888; in rm68200_probe()
355 dsi->mode_flags = MIPI_DSI_MODE_VIDEO | MIPI_DSI_MODE_VIDEO_BURST | in rm68200_probe()
358 drm_panel_init(&ctx->panel, dev, &rm68200_drm_funcs, in rm68200_probe()
361 ret = drm_panel_of_backlight(&ctx->panel); in rm68200_probe()
365 drm_panel_add(&ctx->panel); in rm68200_probe()
370 drm_panel_remove(&ctx->panel); in rm68200_probe()
382 drm_panel_remove(&ctx->panel); in rm68200_remove()
395 .name = "panel-raydium-rm68200",