Message ID | 1377150323-12546-1-git-send-email-sachin.kamat@linaro.org (mailing list archive) |
---|---|
State | New, archived |
Headers | show |
Hi Sachin, Could you rebase your patch set to the below patch series? [PATCH 0/3] drm/exynos: fimd: get signal polarities from device tree Your patch set is conflicted. Thanks, Inki Dae > -----Original Message----- > From: Sachin Kamat [mailto:sachin.kamat@linaro.org] > Sent: Thursday, August 22, 2013 2:45 PM > To: dri-devel@lists.freedesktop.org > Cc: inki.dae@samsung.com; jy0922.shim@samsung.com; sw0312.kim@samsung.com; > sachin.kamat@linaro.org; patches@linaro.org > Subject: [PATCH 1/6] drm/exynos: Remove non-DT support in exynos_drm_fimd > > Since commit 383ffda2fa ("ARM: EXYNOS: no more support non-DT > for EXYNOS SoCs"), Exynos platform is DT only. Hence remove > all the conditional macros and make the driver DT only. > > Signed-off-by: Sachin Kamat <sachin.kamat@linaro.org> > --- > drivers/gpu/drm/exynos/exynos_drm_fimd.c | 54 +++++++------------------- > ---- > 1 file changed, 13 insertions(+), 41 deletions(-) > > diff --git a/drivers/gpu/drm/exynos/exynos_drm_fimd.c > b/drivers/gpu/drm/exynos/exynos_drm_fimd.c > index f8889d2..90da9ef 100644 > --- a/drivers/gpu/drm/exynos/exynos_drm_fimd.c > +++ b/drivers/gpu/drm/exynos/exynos_drm_fimd.c > @@ -123,7 +123,6 @@ struct fimd_context { > struct fimd_driver_data *driver_data; > }; > > -#ifdef CONFIG_OF > static const struct of_device_id fimd_driver_dt_match[] = { > { .compatible = "samsung,s3c6400-fimd", > .data = &s3c64xx_fimd_driver_data }, > @@ -133,21 +132,14 @@ static const struct of_device_id > fimd_driver_dt_match[] = { > .data = &exynos5_fimd_driver_data }, > {}, > }; > -#endif > > static inline struct fimd_driver_data *drm_fimd_get_driver_data( > struct platform_device *pdev) > { > -#ifdef CONFIG_OF > const struct of_device_id *of_id = > of_match_device(fimd_driver_dt_match, &pdev->dev); > > - if (of_id) > - return (struct fimd_driver_data *)of_id->data; > -#endif > - > - return (struct fimd_driver_data *) > - platform_get_device_id(pdev)->driver_data; > + return (struct fimd_driver_data *)of_id->data; > } > > static bool fimd_display_is_connected(struct device *dev) > @@ -891,23 +883,18 @@ static int fimd_probe(struct platform_device *pdev) > int win; > int ret = -EINVAL; > > - if (dev->of_node) { > - pdata = devm_kzalloc(dev, sizeof(*pdata), GFP_KERNEL); > - if (!pdata) > - return -ENOMEM; > + if (!dev->of_node) > + return -ENODEV; > > - ret = of_get_fb_videomode(dev->of_node, &pdata->panel.timing, > - OF_USE_NATIVE_MODE); > - if (ret) { > - DRM_ERROR("failed: of_get_fb_videomode() : %d\n", ret); > - return ret; > - } > - } else { > - pdata = dev->platform_data; > - if (!pdata) { > - DRM_ERROR("no platform data specified\n"); > - return -EINVAL; > - } > + pdata = devm_kzalloc(dev, sizeof(*pdata), GFP_KERNEL); > + if (!pdata) > + return -ENOMEM; > + > + ret = of_get_fb_videomode(dev->of_node, &pdata->panel.timing, > + OF_USE_NATIVE_MODE); > + if (ret) { > + DRM_ERROR("failed: of_get_fb_videomode() : %d\n", ret); > + return ret; > } > > panel = &pdata->panel; > @@ -1069,20 +1056,6 @@ static int fimd_runtime_resume(struct device *dev) > } > #endif > > -static struct platform_device_id fimd_driver_ids[] = { > - { > - .name = "s3c64xx-fb", > - .driver_data = (unsigned long)&s3c64xx_fimd_driver_data, > - }, { > - .name = "exynos4-fb", > - .driver_data = (unsigned long)&exynos4_fimd_driver_data, > - }, { > - .name = "exynos5-fb", > - .driver_data = (unsigned long)&exynos5_fimd_driver_data, > - }, > - {}, > -}; > - > 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) > @@ -1091,11 +1064,10 @@ static const struct dev_pm_ops fimd_pm_ops = { > struct platform_driver fimd_driver = { > .probe = fimd_probe, > .remove = fimd_remove, > - .id_table = fimd_driver_ids, > .driver = { > .name = "exynos4-fb", > .owner = THIS_MODULE, > .pm = &fimd_pm_ops, > - .of_match_table = of_match_ptr(fimd_driver_dt_match), > + .of_match_table = fimd_driver_dt_match, > }, > }; > -- > 1.7.9.5
Hi Inki, Sure, I will rebase and send tomorrow. Thanks On 27 August 2013 08:18, Inki Dae <inki.dae@samsung.com> wrote: > Hi Sachin, > > Could you rebase your patch set to the below patch series? > [PATCH 0/3] drm/exynos: fimd: get signal polarities from device tree > > Your patch set is conflicted. > > Thanks, > Inki Dae > >> -----Original Message----- >> From: Sachin Kamat [mailto:sachin.kamat@linaro.org] >> Sent: Thursday, August 22, 2013 2:45 PM >> To: dri-devel@lists.freedesktop.org >> Cc: inki.dae@samsung.com; jy0922.shim@samsung.com; sw0312.kim@samsung.com; >> sachin.kamat@linaro.org; patches@linaro.org >> Subject: [PATCH 1/6] drm/exynos: Remove non-DT support in exynos_drm_fimd >> >> Since commit 383ffda2fa ("ARM: EXYNOS: no more support non-DT >> for EXYNOS SoCs"), Exynos platform is DT only. Hence remove >> all the conditional macros and make the driver DT only. >> >> Signed-off-by: Sachin Kamat <sachin.kamat@linaro.org> >> --- >> drivers/gpu/drm/exynos/exynos_drm_fimd.c | 54 > +++++++------------------- >> ---- >> 1 file changed, 13 insertions(+), 41 deletions(-) >> >> diff --git a/drivers/gpu/drm/exynos/exynos_drm_fimd.c >> b/drivers/gpu/drm/exynos/exynos_drm_fimd.c >> index f8889d2..90da9ef 100644 >> --- a/drivers/gpu/drm/exynos/exynos_drm_fimd.c >> +++ b/drivers/gpu/drm/exynos/exynos_drm_fimd.c >> @@ -123,7 +123,6 @@ struct fimd_context { >> struct fimd_driver_data *driver_data; >> }; >> >> -#ifdef CONFIG_OF >> static const struct of_device_id fimd_driver_dt_match[] = { >> { .compatible = "samsung,s3c6400-fimd", >> .data = &s3c64xx_fimd_driver_data }, >> @@ -133,21 +132,14 @@ static const struct of_device_id >> fimd_driver_dt_match[] = { >> .data = &exynos5_fimd_driver_data }, >> {}, >> }; >> -#endif >> >> static inline struct fimd_driver_data *drm_fimd_get_driver_data( >> struct platform_device *pdev) >> { >> -#ifdef CONFIG_OF >> const struct of_device_id *of_id = >> of_match_device(fimd_driver_dt_match, &pdev->dev); >> >> - if (of_id) >> - return (struct fimd_driver_data *)of_id->data; >> -#endif >> - >> - return (struct fimd_driver_data *) >> - platform_get_device_id(pdev)->driver_data; >> + return (struct fimd_driver_data *)of_id->data; >> } >> >> static bool fimd_display_is_connected(struct device *dev) >> @@ -891,23 +883,18 @@ static int fimd_probe(struct platform_device *pdev) >> int win; >> int ret = -EINVAL; >> >> - if (dev->of_node) { >> - pdata = devm_kzalloc(dev, sizeof(*pdata), GFP_KERNEL); >> - if (!pdata) >> - return -ENOMEM; >> + if (!dev->of_node) >> + return -ENODEV; >> >> - ret = of_get_fb_videomode(dev->of_node, > &pdata->panel.timing, >> - OF_USE_NATIVE_MODE); >> - if (ret) { >> - DRM_ERROR("failed: of_get_fb_videomode() : %d\n", > ret); >> - return ret; >> - } >> - } else { >> - pdata = dev->platform_data; >> - if (!pdata) { >> - DRM_ERROR("no platform data specified\n"); >> - return -EINVAL; >> - } >> + pdata = devm_kzalloc(dev, sizeof(*pdata), GFP_KERNEL); >> + if (!pdata) >> + return -ENOMEM; >> + >> + ret = of_get_fb_videomode(dev->of_node, &pdata->panel.timing, >> + OF_USE_NATIVE_MODE); >> + if (ret) { >> + DRM_ERROR("failed: of_get_fb_videomode() : %d\n", ret); >> + return ret; >> } >> >> panel = &pdata->panel; >> @@ -1069,20 +1056,6 @@ static int fimd_runtime_resume(struct device *dev) >> } >> #endif >> >> -static struct platform_device_id fimd_driver_ids[] = { >> - { >> - .name = "s3c64xx-fb", >> - .driver_data = (unsigned long)&s3c64xx_fimd_driver_data, >> - }, { >> - .name = "exynos4-fb", >> - .driver_data = (unsigned long)&exynos4_fimd_driver_data, >> - }, { >> - .name = "exynos5-fb", >> - .driver_data = (unsigned long)&exynos5_fimd_driver_data, >> - }, >> - {}, >> -}; >> - >> 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) >> @@ -1091,11 +1064,10 @@ static const struct dev_pm_ops fimd_pm_ops = { >> struct platform_driver fimd_driver = { >> .probe = fimd_probe, >> .remove = fimd_remove, >> - .id_table = fimd_driver_ids, >> .driver = { >> .name = "exynos4-fb", >> .owner = THIS_MODULE, >> .pm = &fimd_pm_ops, >> - .of_match_table = of_match_ptr(fimd_driver_dt_match), >> + .of_match_table = fimd_driver_dt_match, >> }, >> }; >> -- >> 1.7.9.5 >
diff --git a/drivers/gpu/drm/exynos/exynos_drm_fimd.c b/drivers/gpu/drm/exynos/exynos_drm_fimd.c index f8889d2..90da9ef 100644 --- a/drivers/gpu/drm/exynos/exynos_drm_fimd.c +++ b/drivers/gpu/drm/exynos/exynos_drm_fimd.c @@ -123,7 +123,6 @@ struct fimd_context { struct fimd_driver_data *driver_data; }; -#ifdef CONFIG_OF static const struct of_device_id fimd_driver_dt_match[] = { { .compatible = "samsung,s3c6400-fimd", .data = &s3c64xx_fimd_driver_data }, @@ -133,21 +132,14 @@ static const struct of_device_id fimd_driver_dt_match[] = { .data = &exynos5_fimd_driver_data }, {}, }; -#endif static inline struct fimd_driver_data *drm_fimd_get_driver_data( struct platform_device *pdev) { -#ifdef CONFIG_OF const struct of_device_id *of_id = of_match_device(fimd_driver_dt_match, &pdev->dev); - if (of_id) - return (struct fimd_driver_data *)of_id->data; -#endif - - return (struct fimd_driver_data *) - platform_get_device_id(pdev)->driver_data; + return (struct fimd_driver_data *)of_id->data; } static bool fimd_display_is_connected(struct device *dev) @@ -891,23 +883,18 @@ static int fimd_probe(struct platform_device *pdev) int win; int ret = -EINVAL; - if (dev->of_node) { - pdata = devm_kzalloc(dev, sizeof(*pdata), GFP_KERNEL); - if (!pdata) - return -ENOMEM; + if (!dev->of_node) + return -ENODEV; - ret = of_get_fb_videomode(dev->of_node, &pdata->panel.timing, - OF_USE_NATIVE_MODE); - if (ret) { - DRM_ERROR("failed: of_get_fb_videomode() : %d\n", ret); - return ret; - } - } else { - pdata = dev->platform_data; - if (!pdata) { - DRM_ERROR("no platform data specified\n"); - return -EINVAL; - } + pdata = devm_kzalloc(dev, sizeof(*pdata), GFP_KERNEL); + if (!pdata) + return -ENOMEM; + + ret = of_get_fb_videomode(dev->of_node, &pdata->panel.timing, + OF_USE_NATIVE_MODE); + if (ret) { + DRM_ERROR("failed: of_get_fb_videomode() : %d\n", ret); + return ret; } panel = &pdata->panel; @@ -1069,20 +1056,6 @@ static int fimd_runtime_resume(struct device *dev) } #endif -static struct platform_device_id fimd_driver_ids[] = { - { - .name = "s3c64xx-fb", - .driver_data = (unsigned long)&s3c64xx_fimd_driver_data, - }, { - .name = "exynos4-fb", - .driver_data = (unsigned long)&exynos4_fimd_driver_data, - }, { - .name = "exynos5-fb", - .driver_data = (unsigned long)&exynos5_fimd_driver_data, - }, - {}, -}; - 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) @@ -1091,11 +1064,10 @@ static const struct dev_pm_ops fimd_pm_ops = { struct platform_driver fimd_driver = { .probe = fimd_probe, .remove = fimd_remove, - .id_table = fimd_driver_ids, .driver = { .name = "exynos4-fb", .owner = THIS_MODULE, .pm = &fimd_pm_ops, - .of_match_table = of_match_ptr(fimd_driver_dt_match), + .of_match_table = fimd_driver_dt_match, }, };
Since commit 383ffda2fa ("ARM: EXYNOS: no more support non-DT for EXYNOS SoCs"), Exynos platform is DT only. Hence remove all the conditional macros and make the driver DT only. Signed-off-by: Sachin Kamat <sachin.kamat@linaro.org> --- drivers/gpu/drm/exynos/exynos_drm_fimd.c | 54 +++++++----------------------- 1 file changed, 13 insertions(+), 41 deletions(-)