Hi, On Fri, Jul 6, 2012 at 5:28 AM, Leela Krishna Amudala <l.krishna at samsung.com> wrote: > > Add device tree based discovery support for DRM-FIMD driver. > > Signed-off-by: Leela Krishna Amudala <l.krishna at samsung.com>
This also needs to be sent to devicetree-discuss at lists.ozlabs.org, and the device tree bindings need to be documented under Documentation/devicetree/bindings. I'll hold off comments on the bindings until the documentation piece is available. A couple of other nits: > > diff --git a/drivers/gpu/drm/exynos/exynos_drm_fimd.c > b/drivers/gpu/drm/exynos/exynos_drm_fimd.c > index 29fdbfe..37769cf 100644 > --- a/drivers/gpu/drm/exynos/exynos_drm_fimd.c > +++ b/drivers/gpu/drm/exynos/exynos_drm_fimd.c [...] > + of_property_read_u32(np, "samsung, defalut-window", &pd->default_win); Two typos in one property. [...] > @@ -1006,6 +1083,15 @@ static int fimd_runtime_resume(struct device *dev) > } > #endif > > +#ifdef CONFIG_OF > +static const struct of_device_id drm_fimd_dt_match[] = { > + { .compatible = "samsung,exynos5-fb", > + .data = (void *)NULL }, No need to initialize data here. > + {}, > +}; > +MODULE_DEVICE_TABLE(of, drm_fimd_dt_match); > +#endif > + > static const struct dev_pm_ops fimd_pm_ops = { > SET_SYSTEM_SLEEP_PM_OPS(fimd_suspend, fimd_resume) > SET_RUNTIME_PM_OPS(fimd_runtime_suspend, fimd_runtime_resume, NULL) > @@ -1018,5 +1104,6 @@ struct platform_driver fimd_driver = { > .name = "exynos4-fb", > .owner = THIS_MODULE, > .pm = &fimd_pm_ops, > + .of_match_table = of_match_ptr(drm_fimd_dt_match), > }, > }; > diff --git a/include/drm/exynos_drm.h b/include/drm/exynos_drm.h > index 6873358..fecaee8 100644 > --- a/include/drm/exynos_drm.h > +++ b/include/drm/exynos_drm.h > @@ -224,6 +224,11 @@ struct exynos_drm_panel_info { > u32 height_mm; > }; > > +enum disp_panel_type { > + MIPI_LCD, > + DP_LCD > +}; > + > /** > * Platform Specific Structure for DRM based FIMD. > * > @@ -237,6 +242,7 @@ struct exynos_drm_fimd_pdata { > u32 vidcon1; > unsigned int default_win; > unsigned int bpp; > + enum disp_panel_type panel_type; > }; This seems unrelated? -Olof