@@ -199,12 +199,6 @@ static int omap_dss_probe(struct platform_device *pdev)
goto err_dpi;
}
- r = dispc_init();
- if (r) {
- DSSERR("Failed to initialize dispc\n");
- goto err_dispc;
- }
-
r = venc_init(pdev);
if (r) {
DSSERR("Failed to initialize venc\n");
@@ -262,8 +256,6 @@ err_dsi:
err_sdi:
venc_exit();
err_venc:
- dispc_exit();
-err_dispc:
dpi_exit();
err_dpi:
@@ -278,7 +270,6 @@ static int omap_dss_remove(struct platform_device *pdev)
dss_uninitialize_debugfs();
venc_exit();
- dispc_exit();
dpi_exit();
if (cpu_is_omap34xx()) {
dsi_exit();
@@ -156,6 +156,7 @@ struct dispc_irq_stats {
};
static struct {
+ struct platform_device *pdev;
void __iomem *base;
u32 fifo_size[3];
@@ -189,11 +190,22 @@ static inline u32 dispc_read_reg(const struct dispc_reg idx)
/* DISPC HW IP initialisation */
static int omap_dispchw_probe(struct platform_device *pdev)
{
- return 0;
+ int r;
+ dispc.pdev = pdev;
+
+ r = dispc_init();
+ if (r) {
+ DSSERR("Failed to initialize dispc\n");
+ goto err_dispc;
+ }
+
+err_dispc:
+ return r;
}
static int omap_dispchw_remove(struct platform_device *pdev)
{
+ dispc_exit();
return 0;
}