Lines Matching +full:panel +full:- +full:dpi

1 // SPDX-License-Identifier: GPL-2.0-only
3 * LG.Philips LB035Q02 LCD Panel driver
117 struct omap_dss_device *in = ddata->in; in lb035q02_connect()
123 r = in->ops.dpi->connect(in, dssdev); in lb035q02_connect()
127 init_lb035q02_panel(ddata->spi); in lb035q02_connect()
135 struct omap_dss_device *in = ddata->in; in lb035q02_disconnect()
140 in->ops.dpi->disconnect(in, dssdev); in lb035q02_disconnect()
146 struct omap_dss_device *in = ddata->in; in lb035q02_enable()
150 return -ENODEV; in lb035q02_enable()
155 if (ddata->data_lines) in lb035q02_enable()
156 in->ops.dpi->set_data_lines(in, ddata->data_lines); in lb035q02_enable()
157 in->ops.dpi->set_timings(in, &ddata->videomode); in lb035q02_enable()
159 r = in->ops.dpi->enable(in); in lb035q02_enable()
163 if (ddata->enable_gpio) in lb035q02_enable()
164 gpiod_set_value_cansleep(ddata->enable_gpio, 1); in lb035q02_enable()
166 dssdev->state = OMAP_DSS_DISPLAY_ACTIVE; in lb035q02_enable()
174 struct omap_dss_device *in = ddata->in; in lb035q02_disable()
179 if (ddata->enable_gpio) in lb035q02_disable()
180 gpiod_set_value_cansleep(ddata->enable_gpio, 0); in lb035q02_disable()
182 in->ops.dpi->disable(in); in lb035q02_disable()
184 dssdev->state = OMAP_DSS_DISPLAY_DISABLED; in lb035q02_disable()
191 struct omap_dss_device *in = ddata->in; in lb035q02_set_timings()
193 ddata->videomode = *timings; in lb035q02_set_timings()
194 dssdev->panel.timings = *timings; in lb035q02_set_timings()
196 in->ops.dpi->set_timings(in, timings); in lb035q02_set_timings()
204 *timings = ddata->videomode; in lb035q02_get_timings()
211 struct omap_dss_device *in = ddata->in; in lb035q02_check_timings()
213 return in->ops.dpi->check_timings(in, timings); in lb035q02_check_timings()
232 struct device_node *node = spi->dev.of_node; in lb035q02_probe_of()
237 gpio = devm_gpiod_get(&spi->dev, "enable", GPIOD_OUT_LOW); in lb035q02_probe_of()
239 return dev_err_probe(&spi->dev, PTR_ERR(gpio), in lb035q02_probe_of()
242 ddata->enable_gpio = gpio; in lb035q02_probe_of()
246 dev_err(&spi->dev, "failed to find video source\n"); in lb035q02_probe_of()
250 ddata->in = in; in lb035q02_probe_of()
261 if (!spi->dev.of_node) in lb035q02_panel_spi_probe()
262 return -ENODEV; in lb035q02_panel_spi_probe()
264 ddata = devm_kzalloc(&spi->dev, sizeof(*ddata), GFP_KERNEL); in lb035q02_panel_spi_probe()
266 return -ENOMEM; in lb035q02_panel_spi_probe()
270 ddata->spi = spi; in lb035q02_panel_spi_probe()
276 ddata->videomode = lb035q02_timings; in lb035q02_panel_spi_probe()
278 dssdev = &ddata->dssdev; in lb035q02_panel_spi_probe()
279 dssdev->dev = &spi->dev; in lb035q02_panel_spi_probe()
280 dssdev->driver = &lb035q02_ops; in lb035q02_panel_spi_probe()
281 dssdev->type = OMAP_DISPLAY_TYPE_DPI; in lb035q02_panel_spi_probe()
282 dssdev->owner = THIS_MODULE; in lb035q02_panel_spi_probe()
283 dssdev->panel.timings = ddata->videomode; in lb035q02_panel_spi_probe()
284 dssdev->phy.dpi.data_lines = ddata->data_lines; in lb035q02_panel_spi_probe()
288 dev_err(&spi->dev, "Failed to register panel\n"); in lb035q02_panel_spi_probe()
295 omap_dss_put_device(ddata->in); in lb035q02_panel_spi_probe()
302 struct omap_dss_device *dssdev = &ddata->dssdev; in lb035q02_panel_spi_remove()
303 struct omap_dss_device *in = ddata->in; in lb035q02_panel_spi_remove()
334 MODULE_DESCRIPTION("LG.Philips LB035Q02 LCD Panel driver");