Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 294303
b: refs/heads/master
c: e6b0f88
h: refs/heads/master
i:
  294301: 1a84eb1
  294299: df8440e
  294295: 168e005
  294287: 4bbeebd
  294271: 5676b3e
v: v3
  • Loading branch information
Tomi Valkeinen committed Jan 25, 2012
1 parent 7fc0c85 commit c721474
Show file tree
Hide file tree
Showing 12 changed files with 245 additions and 169 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 6e2a14d2c59f6208310eeb6b031e9d1c22b38c6a
refs/heads/master: e6b0f884520e604408ebda3b60605cabe0a8d162
21 changes: 15 additions & 6 deletions trunk/drivers/video/omap2/dss/dispc.c
Original file line number Diff line number Diff line change
Expand Up @@ -1054,6 +1054,11 @@ void dispc_ovl_set_fifo_threshold(enum omap_plane plane, u32 low, u32 high)

void dispc_enable_fifomerge(bool enable)
{
if (!dss_has_feature(FEAT_FIFO_MERGE)) {
WARN_ON(enable);
return;
}

DSSDBG("FIFO merge %s\n", enable ? "enabled" : "disabled");
REG_FLD_MOD(DISPC_CONFIG, enable ? 1 : 0, 14, 14);
}
Expand Down Expand Up @@ -3322,8 +3327,7 @@ static int omap_dispchw_probe(struct platform_device *pdev)
r = -EINVAL;
goto err_ioremap;
}
dispc.base = devm_ioremap(&pdev->dev, dispc_mem->start,
resource_size(dispc_mem));
dispc.base = ioremap(dispc_mem->start, resource_size(dispc_mem));
if (!dispc.base) {
DSSERR("can't ioremap DISPC\n");
r = -ENOMEM;
Expand All @@ -3333,14 +3337,14 @@ static int omap_dispchw_probe(struct platform_device *pdev)
if (dispc.irq < 0) {
DSSERR("platform_get_irq failed\n");
r = -ENODEV;
goto err_ioremap;
goto err_irq;
}

r = devm_request_irq(&pdev->dev, dispc.irq, omap_dispc_irq_handler,
IRQF_SHARED, "OMAP DISPC", dispc.pdev);
r = request_irq(dispc.irq, omap_dispc_irq_handler, IRQF_SHARED,
"OMAP DISPC", dispc.pdev);
if (r < 0) {
DSSERR("request_irq failed\n");
goto err_ioremap;
goto err_irq;
}

pm_runtime_enable(&pdev->dev);
Expand All @@ -3363,6 +3367,9 @@ static int omap_dispchw_probe(struct platform_device *pdev)

err_runtime_get:
pm_runtime_disable(&pdev->dev);
free_irq(dispc.irq, dispc.pdev);
err_irq:
iounmap(dispc.base);
err_ioremap:
clk_put(dispc.dss_clk);
err_get_clk:
Expand All @@ -3375,6 +3382,8 @@ static int omap_dispchw_remove(struct platform_device *pdev)

clk_put(dispc.dss_clk);

free_irq(dispc.irq, dispc.pdev);
iounmap(dispc.base);
return 0;
}

Expand Down
28 changes: 19 additions & 9 deletions trunk/drivers/video/omap2/dss/dsi.c
Original file line number Diff line number Diff line change
Expand Up @@ -4695,7 +4695,7 @@ static int omap_dsihw_probe(struct platform_device *dsidev)
struct resource *dsi_mem;
struct dsi_data *dsi;

dsi = devm_kzalloc(&dsidev->dev, sizeof(*dsi), GFP_KERNEL);
dsi = kzalloc(sizeof(*dsi), GFP_KERNEL);
if (!dsi) {
r = -ENOMEM;
goto err_alloc;
Expand Down Expand Up @@ -4724,7 +4724,7 @@ static int omap_dsihw_probe(struct platform_device *dsidev)

r = dsi_get_clocks(dsidev);
if (r)
goto err_alloc;
goto err_get_clk;

pm_runtime_enable(&dsidev->dev);

Expand All @@ -4742,8 +4742,7 @@ static int omap_dsihw_probe(struct platform_device *dsidev)
r = -EINVAL;
goto err_ioremap;
}
dsi->base = devm_ioremap(&dsidev->dev, dsi_mem->start,
resource_size(dsi_mem));
dsi->base = ioremap(dsi_mem->start, resource_size(dsi_mem));
if (!dsi->base) {
DSSERR("can't ioremap DSI\n");
r = -ENOMEM;
Expand All @@ -4753,14 +4752,14 @@ static int omap_dsihw_probe(struct platform_device *dsidev)
if (dsi->irq < 0) {
DSSERR("platform_get_irq failed\n");
r = -ENODEV;
goto err_ioremap;
goto err_get_irq;
}

r = devm_request_irq(&dsidev->dev, dsi->irq, omap_dsi_irq_handler,
IRQF_SHARED, dev_name(&dsidev->dev), dsi->pdev);
r = request_irq(dsi->irq, omap_dsi_irq_handler, IRQF_SHARED,
dev_name(&dsidev->dev), dsi->pdev);
if (r < 0) {
DSSERR("request_irq failed\n");
goto err_ioremap;
goto err_get_irq;
}

/* DSI VCs initialization */
Expand All @@ -4774,7 +4773,7 @@ static int omap_dsihw_probe(struct platform_device *dsidev)

r = dsi_runtime_get(dsidev);
if (r)
goto err_ioremap;
goto err_get_dsi;

rev = dsi_read_reg(dsidev, DSI_REVISION);
dev_dbg(&dsidev->dev, "OMAP DSI rev %d.%d\n",
Expand All @@ -4792,8 +4791,14 @@ static int omap_dsihw_probe(struct platform_device *dsidev)

return 0;

err_get_dsi:
free_irq(dsi->irq, dsi->pdev);
err_get_irq:
iounmap(dsi->base);
err_ioremap:
pm_runtime_disable(&dsidev->dev);
err_get_clk:
kfree(dsi);
err_alloc:
return r;
}
Expand All @@ -4818,6 +4823,11 @@ static int omap_dsihw_remove(struct platform_device *dsidev)
dsi->vdds_dsi_reg = NULL;
}

free_irq(dsi->irq, dsi->pdev);
iounmap(dsi->base);

kfree(dsi);

return 0;
}

Expand Down
9 changes: 6 additions & 3 deletions trunk/drivers/video/omap2/dss/dss.c
Original file line number Diff line number Diff line change
Expand Up @@ -751,8 +751,7 @@ static int omap_dsshw_probe(struct platform_device *pdev)
r = -EINVAL;
goto err_ioremap;
}
dss.base = devm_ioremap(&pdev->dev, dss_mem->start,
resource_size(dss_mem));
dss.base = ioremap(dss_mem->start, resource_size(dss_mem));
if (!dss.base) {
DSSERR("can't ioremap DSS\n");
r = -ENOMEM;
Expand All @@ -761,7 +760,7 @@ static int omap_dsshw_probe(struct platform_device *pdev)

r = dss_get_clocks();
if (r)
goto err_ioremap;
goto err_clocks;

pm_runtime_enable(&pdev->dev);

Expand Down Expand Up @@ -809,6 +808,8 @@ static int omap_dsshw_probe(struct platform_device *pdev)
err_runtime_get:
pm_runtime_disable(&pdev->dev);
dss_put_clocks();
err_clocks:
iounmap(dss.base);
err_ioremap:
return r;
}
Expand All @@ -818,6 +819,8 @@ static int omap_dsshw_remove(struct platform_device *pdev)
dpi_exit();
sdi_exit();

iounmap(dss.base);

pm_runtime_disable(&pdev->dev);

dss_put_clocks();
Expand Down
9 changes: 5 additions & 4 deletions trunk/drivers/video/omap2/dss/dss_features.c
Original file line number Diff line number Diff line change
Expand Up @@ -370,7 +370,7 @@ static const struct omap_dss_features omap3430_dss_features = {
FEAT_LINEBUFFERSPLIT | FEAT_RESIZECONF |
FEAT_DSI_PLL_FREQSEL | FEAT_DSI_REVERSE_TXCLKESC |
FEAT_VENC_REQUIRES_TV_DAC_CLK | FEAT_CPR | FEAT_PRELOAD |
FEAT_FIR_COEF_V | FEAT_ALPHA_FIXED_ZORDER,
FEAT_FIR_COEF_V | FEAT_ALPHA_FIXED_ZORDER | FEAT_FIFO_MERGE,

.num_mgrs = 2,
.num_ovls = 3,
Expand All @@ -394,7 +394,7 @@ static const struct omap_dss_features omap3630_dss_features = {
FEAT_ROWREPEATENABLE | FEAT_LINEBUFFERSPLIT |
FEAT_RESIZECONF | FEAT_DSI_PLL_PWR_BUG |
FEAT_DSI_PLL_FREQSEL | FEAT_CPR | FEAT_PRELOAD |
FEAT_FIR_COEF_V | FEAT_ALPHA_FIXED_ZORDER,
FEAT_FIR_COEF_V | FEAT_ALPHA_FIXED_ZORDER | FEAT_FIFO_MERGE,

.num_mgrs = 2,
.num_ovls = 3,
Expand All @@ -419,7 +419,7 @@ static const struct omap_dss_features omap4430_es1_0_dss_features = {
FEAT_DSI_DCS_CMD_CONFIG_VC | FEAT_DSI_VC_OCP_WIDTH |
FEAT_DSI_GNQ | FEAT_HANDLE_UV_SEPARATE | FEAT_ATTR2 |
FEAT_CPR | FEAT_PRELOAD | FEAT_FIR_COEF_V |
FEAT_ALPHA_FREE_ZORDER,
FEAT_ALPHA_FREE_ZORDER | FEAT_FIFO_MERGE,

.num_mgrs = 3,
.num_ovls = 4,
Expand All @@ -443,7 +443,8 @@ static const struct omap_dss_features omap4_dss_features = {
FEAT_DSI_DCS_CMD_CONFIG_VC | FEAT_DSI_VC_OCP_WIDTH |
FEAT_DSI_GNQ | FEAT_HDMI_CTS_SWMODE |
FEAT_HANDLE_UV_SEPARATE | FEAT_ATTR2 | FEAT_CPR |
FEAT_PRELOAD | FEAT_FIR_COEF_V | FEAT_ALPHA_FREE_ZORDER,
FEAT_PRELOAD | FEAT_FIR_COEF_V | FEAT_ALPHA_FREE_ZORDER |
FEAT_FIFO_MERGE,

.num_mgrs = 3,
.num_ovls = 4,
Expand Down
1 change: 1 addition & 0 deletions trunk/drivers/video/omap2/dss/dss_features.h
Original file line number Diff line number Diff line change
Expand Up @@ -58,6 +58,7 @@ enum dss_feat_id {
FEAT_FIR_COEF_V = 1 << 25,
FEAT_ALPHA_FIXED_ZORDER = 1 << 26,
FEAT_ALPHA_FREE_ZORDER = 1 << 27,
FEAT_FIFO_MERGE = 1 << 28,
};

/* DSS register field id */
Expand Down
Loading

0 comments on commit c721474

Please sign in to comment.