diff options
| author | Peter Ujfalusi <peter.ujfalusi@ti.com> | 2016-05-26 09:38:56 -0400 |
|---|---|---|
| committer | Peter Ujfalusi <peter.ujfalusi@ti.com> | 2016-06-03 09:06:26 -0400 |
| commit | b55753bed57b2b45199eeac08c5f3b3613ca1bed (patch) | |
| tree | d249368fea50dd9c017c670a850393224d433f6d /drivers/video/fbdev/omap2/omapfb | |
| parent | 5996a5ae4855a8b1f149820b4f62fde88283913d (diff) | |
omapfb: encoder-tfp410: 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/encoder-tfp410.c | 44 |
1 files changed, 6 insertions, 38 deletions
diff --git a/drivers/video/fbdev/omap2/omapfb/displays/encoder-tfp410.c b/drivers/video/fbdev/omap2/omapfb/displays/encoder-tfp410.c index d9048b3df495..778e3b384c2f 100644 --- a/drivers/video/fbdev/omap2/omapfb/displays/encoder-tfp410.c +++ b/drivers/video/fbdev/omap2/omapfb/displays/encoder-tfp410.c | |||
| @@ -16,7 +16,6 @@ | |||
| 16 | #include <linux/of_gpio.h> | 16 | #include <linux/of_gpio.h> |
| 17 | 17 | ||
| 18 | #include <video/omapdss.h> | 18 | #include <video/omapdss.h> |
| 19 | #include <video/omap-panel-data.h> | ||
| 20 | 19 | ||
| 21 | struct panel_drv_data { | 20 | struct panel_drv_data { |
| 22 | struct omap_dss_device dssdev; | 21 | struct omap_dss_device dssdev; |
| @@ -166,32 +165,6 @@ static const struct omapdss_dvi_ops tfp410_dvi_ops = { | |||
| 166 | .get_timings = tfp410_get_timings, | 165 | .get_timings = tfp410_get_timings, |
| 167 | }; | 166 | }; |
| 168 | 167 | ||
| 169 | static int tfp410_probe_pdata(struct platform_device *pdev) | ||
| 170 | { | ||
| 171 | struct panel_drv_data *ddata = platform_get_drvdata(pdev); | ||
| 172 | struct encoder_tfp410_platform_data *pdata; | ||
| 173 | struct omap_dss_device *dssdev, *in; | ||
| 174 | |||
| 175 | pdata = dev_get_platdata(&pdev->dev); | ||
| 176 | |||
| 177 | ddata->pd_gpio = pdata->power_down_gpio; | ||
| 178 | |||
| 179 | ddata->data_lines = pdata->data_lines; | ||
| 180 | |||
| 181 | in = omap_dss_find_output(pdata->source); | ||
| 182 | if (in == NULL) { | ||
| 183 | dev_err(&pdev->dev, "Failed to find video source\n"); | ||
| 184 | return -ENODEV; | ||
| 185 | } | ||
| 186 | |||
| 187 | ddata->in = in; | ||
| 188 | |||
| 189 | dssdev = &ddata->dssdev; | ||
| 190 | dssdev->name = pdata->name; | ||
| 191 | |||
| 192 | return 0; | ||
| 193 | } | ||
| 194 | |||
| 195 | static int tfp410_probe_of(struct platform_device *pdev) | 168 | static int tfp410_probe_of(struct platform_device *pdev) |
| 196 | { | 169 | { |
| 197 | struct panel_drv_data *ddata = platform_get_drvdata(pdev); | 170 | struct panel_drv_data *ddata = platform_get_drvdata(pdev); |
| @@ -225,23 +198,18 @@ static int tfp410_probe(struct platform_device *pdev) | |||
| 225 | struct omap_dss_device *dssdev; | 198 | struct omap_dss_device *dssdev; |
| 226 | int r; | 199 | int r; |
| 227 | 200 | ||
| 201 | if (!pdev->dev.of_node) | ||
| 202 | return -ENODEV; | ||
| 203 | |||
| 228 | ddata = devm_kzalloc(&pdev->dev, sizeof(*ddata), GFP_KERNEL); | 204 | ddata = devm_kzalloc(&pdev->dev, sizeof(*ddata), GFP_KERNEL); |
| 229 | if (!ddata) | 205 | if (!ddata) |
| 230 | return -ENOMEM; | 206 | return -ENOMEM; |
| 231 | 207 | ||
| 232 | platform_set_drvdata(pdev, ddata); | 208 | platform_set_drvdata(pdev, ddata); |
| 233 | 209 | ||
| 234 | if (dev_get_platdata(&pdev->dev)) { | 210 | r = tfp410_probe_of(pdev); |
| 235 | r = tfp410_probe_pdata(pdev); | 211 | if (r) |
| 236 | if (r) | 212 | return r; |
| 237 | return r; | ||
| 238 | } else if (pdev->dev.of_node) { | ||
| 239 | r = tfp410_probe_of(pdev); | ||
| 240 | if (r) | ||
| 241 | return r; | ||
| 242 | } else { | ||
| 243 | return -ENODEV; | ||
| 244 | } | ||
| 245 | 213 | ||
| 246 | if (gpio_is_valid(ddata->pd_gpio)) { | 214 | if (gpio_is_valid(ddata->pd_gpio)) { |
| 247 | r = devm_gpio_request_one(&pdev->dev, ddata->pd_gpio, | 215 | r = devm_gpio_request_one(&pdev->dev, ddata->pd_gpio, |
