aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/video/fbdev/omap2/omapfb
diff options
context:
space:
mode:
authorPeter Ujfalusi <peter.ujfalusi@ti.com>2016-05-26 09:34:42 -0400
committerPeter Ujfalusi <peter.ujfalusi@ti.com>2016-06-03 09:06:24 -0400
commitb0417013d8155cca7b63a71d94c57ae3034cb597 (patch)
treeca13427d1f034265f8a62bddf4f58dcb0093b20a /drivers/video/fbdev/omap2/omapfb
parent0984097c03710960b1dcfd7867abaf0c9edf78f5 (diff)
omapfb: connector-hdmi: Remove legacy boot support
The panel is not used by any legacy board files so the legacy (pdata) boot support can be dropped. Signed-off-by: Peter Ujfalusi <peter.ujfalusi@ti.com>
Diffstat (limited to 'drivers/video/fbdev/omap2/omapfb')
-rw-r--r--drivers/video/fbdev/omap2/omapfb/displays/connector-hdmi.c42
1 files changed, 6 insertions, 36 deletions
diff --git a/drivers/video/fbdev/omap2/omapfb/displays/connector-hdmi.c b/drivers/video/fbdev/omap2/omapfb/displays/connector-hdmi.c
index 6ee4129bc0c0..231b8588a59f 100644
--- a/drivers/video/fbdev/omap2/omapfb/displays/connector-hdmi.c
+++ b/drivers/video/fbdev/omap2/omapfb/displays/connector-hdmi.c
@@ -18,7 +18,6 @@
18#include <drm/drm_edid.h> 18#include <drm/drm_edid.h>
19 19
20#include <video/omapdss.h> 20#include <video/omapdss.h>
21#include <video/omap-panel-data.h>
22 21
23static const struct omap_video_timings hdmic_default_timings = { 22static const struct omap_video_timings hdmic_default_timings = {
24 .x_res = 640, 23 .x_res = 640,
@@ -206,30 +205,6 @@ static struct omap_dss_driver hdmic_driver = {
206 .set_hdmi_infoframe = hdmic_set_infoframe, 205 .set_hdmi_infoframe = hdmic_set_infoframe,
207}; 206};
208 207
209static int hdmic_probe_pdata(struct platform_device *pdev)
210{
211 struct panel_drv_data *ddata = platform_get_drvdata(pdev);
212 struct connector_hdmi_platform_data *pdata;
213 struct omap_dss_device *in, *dssdev;
214
215 pdata = dev_get_platdata(&pdev->dev);
216
217 ddata->hpd_gpio = -ENODEV;
218
219 in = omap_dss_find_output(pdata->source);
220 if (in == NULL) {
221 dev_err(&pdev->dev, "Failed to find video source\n");
222 return -EPROBE_DEFER;
223 }
224
225 ddata->in = in;
226
227 dssdev = &ddata->dssdev;
228 dssdev->name = pdata->name;
229
230 return 0;
231}
232
233static int hdmic_probe_of(struct platform_device *pdev) 208static int hdmic_probe_of(struct platform_device *pdev)
234{ 209{
235 struct panel_drv_data *ddata = platform_get_drvdata(pdev); 210 struct panel_drv_data *ddata = platform_get_drvdata(pdev);
@@ -261,6 +236,9 @@ static int hdmic_probe(struct platform_device *pdev)
261 struct omap_dss_device *dssdev; 236 struct omap_dss_device *dssdev;
262 int r; 237 int r;
263 238
239 if (!pdev->dev.of_node)
240 return -ENODEV;
241
264 ddata = devm_kzalloc(&pdev->dev, sizeof(*ddata), GFP_KERNEL); 242 ddata = devm_kzalloc(&pdev->dev, sizeof(*ddata), GFP_KERNEL);
265 if (!ddata) 243 if (!ddata)
266 return -ENOMEM; 244 return -ENOMEM;
@@ -268,17 +246,9 @@ static int hdmic_probe(struct platform_device *pdev)
268 platform_set_drvdata(pdev, ddata); 246 platform_set_drvdata(pdev, ddata);
269 ddata->dev = &pdev->dev; 247 ddata->dev = &pdev->dev;
270 248
271 if (dev_get_platdata(&pdev->dev)) { 249 r = hdmic_probe_of(pdev);
272 r = hdmic_probe_pdata(pdev); 250 if (r)
273 if (r) 251 return r;
274 return r;
275 } else if (pdev->dev.of_node) {
276 r = hdmic_probe_of(pdev);
277 if (r)
278 return r;
279 } else {
280 return -ENODEV;
281 }
282 252
283 if (gpio_is_valid(ddata->hpd_gpio)) { 253 if (gpio_is_valid(ddata->hpd_gpio)) {
284 r = devm_gpio_request_one(&pdev->dev, ddata->hpd_gpio, 254 r = devm_gpio_request_one(&pdev->dev, ddata->hpd_gpio,