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

Commit 4b6430fc authored by Grazvydas Ignotas's avatar Grazvydas Ignotas Committed by Tomi Valkeinen
Browse files

OMAPDSS: provide default get_timings function for panels



With this we can eliminate some duplicate code in panel drivers.
Also lgphilips-lb035q02, nec-nl8048hl11-01b, picodlp and
tpo-td043mtea1 gain support of reading timings over sysfs.

Signed-off-by: default avatarGrazvydas Ignotas <notasas@gmail.com>
Signed-off-by: default avatarTomi Valkeinen <tomi.valkeinen@ti.com>
parent f3fb3bbc
Loading
Loading
Loading
Loading
+0 −7
Original line number Diff line number Diff line
@@ -738,12 +738,6 @@ static void acx_panel_set_timings(struct omap_dss_device *dssdev,
	}
}

static void acx_panel_get_timings(struct omap_dss_device *dssdev,
		struct omap_video_timings *timings)
{
	*timings = dssdev->panel.timings;
}

static int acx_panel_check_timings(struct omap_dss_device *dssdev,
		struct omap_video_timings *timings)
{
@@ -761,7 +755,6 @@ static struct omap_dss_driver acx_panel_driver = {
	.resume		= acx_panel_resume,

	.set_timings	= acx_panel_set_timings,
	.get_timings	= acx_panel_get_timings,
	.check_timings	= acx_panel_check_timings,

	.get_recommended_bpp = acx_get_recommended_bpp,
+0 −7
Original line number Diff line number Diff line
@@ -549,12 +549,6 @@ static void generic_dpi_panel_set_timings(struct omap_dss_device *dssdev,
	dpi_set_timings(dssdev, timings);
}

static void generic_dpi_panel_get_timings(struct omap_dss_device *dssdev,
		struct omap_video_timings *timings)
{
	*timings = dssdev->panel.timings;
}

static int generic_dpi_panel_check_timings(struct omap_dss_device *dssdev,
		struct omap_video_timings *timings)
{
@@ -571,7 +565,6 @@ static struct omap_dss_driver dpi_driver = {
	.resume		= generic_dpi_panel_resume,

	.set_timings	= generic_dpi_panel_set_timings,
	.get_timings	= generic_dpi_panel_get_timings,
	.check_timings	= generic_dpi_panel_check_timings,

	.driver         = {
+0 −8
Original line number Diff line number Diff line
@@ -610,12 +610,6 @@ static int n8x0_panel_resume(struct omap_dss_device *dssdev)
	return 0;
}

static void n8x0_panel_get_timings(struct omap_dss_device *dssdev,
		struct omap_video_timings *timings)
{
	*timings = dssdev->panel.timings;
}

static void n8x0_panel_get_resolution(struct omap_dss_device *dssdev,
		u16 *xres, u16 *yres)
{
@@ -678,8 +672,6 @@ static struct omap_dss_driver n8x0_panel_driver = {
	.get_resolution	= n8x0_panel_get_resolution,
	.get_recommended_bpp = omapdss_default_get_recommended_bpp,

	.get_timings	= n8x0_panel_get_timings,

	.driver         = {
		.name   = "n8x0_panel",
		.owner  = THIS_MODULE,
+0 −8
Original line number Diff line number Diff line
@@ -507,12 +507,6 @@ static const struct backlight_ops taal_bl_ops = {
	.update_status  = taal_bl_update_status,
};

static void taal_get_timings(struct omap_dss_device *dssdev,
			struct omap_video_timings *timings)
{
	*timings = dssdev->panel.timings;
}

static void taal_get_resolution(struct omap_dss_device *dssdev,
		u16 *xres, u16 *yres)
{
@@ -1807,8 +1801,6 @@ static struct omap_dss_driver taal_driver = {
	.run_test	= taal_run_test,
	.memory_read	= taal_memory_read,

	.get_timings	= taal_get_timings,

	.driver         = {
		.name   = "taal",
		.owner  = THIS_MODULE,
+2 −0
Original line number Diff line number Diff line
@@ -391,6 +391,8 @@ int omap_dss_register_driver(struct omap_dss_driver *dssdriver)
	if (dssdriver->get_recommended_bpp == NULL)
		dssdriver->get_recommended_bpp =
			omapdss_default_get_recommended_bpp;
	if (dssdriver->get_timings == NULL)
		dssdriver->get_timings = omapdss_default_get_timings;

	return driver_register(&dssdriver->driver);
}
Loading