Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit c499144c authored by Archit Taneja's avatar Archit Taneja
Browse files

OMAPDSS: DPI: Maintain our own timings field in driver data



The DPI driver currently relies on the timings in omap_dss_device struct to
configure the DISPC accordingly. This makes the DPI interface driver dependent
on the omap_dss_device struct.

Make the DPI driver data maintain it's own timings field. The panel driver is
expected to call dpi_set_timings()(renamed to omapdss_dpi_set_timings) to set
these timings before the panel is enabled.

In the set_timings() op, we still ensure that the omap_dss_device timings
(dssdev->panel.timings) are configured. This will later be configured only by
the DPI panel drivers.

Signed-off-by: default avatarArchit Taneja <archit@ti.com>
parent e19d659b
Loading
Loading
Loading
Loading
+3 −1
Original line number Diff line number Diff line
@@ -565,6 +565,8 @@ static int generic_dpi_panel_power_on(struct omap_dss_device *dssdev)
	if (dssdev->state == OMAP_DSS_DISPLAY_ACTIVE)
		return 0;

	omapdss_dpi_set_timings(dssdev, &dssdev->panel.timings);

	r = omapdss_dpi_display_enable(dssdev);
	if (r)
		goto err0;
@@ -726,7 +728,7 @@ static void generic_dpi_panel_set_timings(struct omap_dss_device *dssdev,

	mutex_lock(&drv_data->lock);

	dpi_set_timings(dssdev, timings);
	omapdss_dpi_set_timings(dssdev, timings);

	mutex_unlock(&drv_data->lock);
}
+2 −0
Original line number Diff line number Diff line
@@ -55,6 +55,8 @@ static int lb035q02_panel_power_on(struct omap_dss_device *dssdev)
	if (dssdev->state == OMAP_DSS_DISPLAY_ACTIVE)
		return 0;

	omapdss_dpi_set_timings(dssdev, &dssdev->panel.timings);

	r = omapdss_dpi_display_enable(dssdev);
	if (r)
		goto err0;
+2 −0
Original line number Diff line number Diff line
@@ -175,6 +175,8 @@ static int nec_8048_panel_power_on(struct omap_dss_device *dssdev)
	if (dssdev->state == OMAP_DSS_DISPLAY_ACTIVE)
		return 0;

	omapdss_dpi_set_timings(dssdev, &dssdev->panel.timings);

	r = omapdss_dpi_display_enable(dssdev);
	if (r)
		goto err0;
+3 −0
Original line number Diff line number Diff line
@@ -377,6 +377,9 @@ static int picodlp_panel_power_on(struct omap_dss_device *dssdev)
	 * then only i2c commands can be successfully sent to dpp2600
	 */
	msleep(1000);

	omapdss_dpi_set_timings(dssdev, &dssdev->panel.timings);

	r = omapdss_dpi_display_enable(dssdev);
	if (r) {
		dev_err(&dssdev->dev, "failed to enable DPI\n");
+2 −0
Original line number Diff line number Diff line
@@ -142,6 +142,8 @@ static int sharp_ls_power_on(struct omap_dss_device *dssdev)
	if (dssdev->state == OMAP_DSS_DISPLAY_ACTIVE)
		return 0;

	omapdss_dpi_set_timings(dssdev, &dssdev->panel.timings);

	r = omapdss_dpi_display_enable(dssdev);
	if (r)
		goto err0;
Loading