diff options
| author | Nicholas Mc Guire <der.herr@hofr.at> | 2015-01-19 06:38:11 -0500 |
|---|---|---|
| committer | Philipp Zabel <p.zabel@pengutronix.de> | 2015-01-27 09:55:49 -0500 |
| commit | af7537d3c8d0f894f6499376a538e8138ef188ee (patch) | |
| tree | 71266fe3e10ccce64eada236a6d943420ea04b14 | |
| parent | 5159571ceb44eba9bf9f9a34ec625386d421de9c (diff) | |
gpu: ipu-v3: wait_for_completion_timeout does not return negative status
This fixes up the return value handling and the return type.
Signed-off-by: Nicholas Mc Guire <der.herr@hofr.at>
Signed-off-by: Philipp Zabel <p.zabel@pengutronix.de>
| -rw-r--r-- | drivers/gpu/ipu-v3/ipu-dc.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/drivers/gpu/ipu-v3/ipu-dc.c b/drivers/gpu/ipu-v3/ipu-dc.c index 2326c752d89b..508c81d9c344 100644 --- a/drivers/gpu/ipu-v3/ipu-dc.c +++ b/drivers/gpu/ipu-v3/ipu-dc.c | |||
| @@ -267,7 +267,8 @@ static irqreturn_t dc_irq_handler(int irq, void *dev_id) | |||
| 267 | void ipu_dc_disable_channel(struct ipu_dc *dc) | 267 | void ipu_dc_disable_channel(struct ipu_dc *dc) |
| 268 | { | 268 | { |
| 269 | struct ipu_dc_priv *priv = dc->priv; | 269 | struct ipu_dc_priv *priv = dc->priv; |
| 270 | int irq, ret; | 270 | int irq; |
| 271 | unsigned long ret; | ||
| 271 | u32 val; | 272 | u32 val; |
| 272 | 273 | ||
| 273 | /* TODO: Handle MEM_FG_SYNC differently from MEM_BG_SYNC */ | 274 | /* TODO: Handle MEM_FG_SYNC differently from MEM_BG_SYNC */ |
| @@ -282,7 +283,7 @@ void ipu_dc_disable_channel(struct ipu_dc *dc) | |||
| 282 | enable_irq(irq); | 283 | enable_irq(irq); |
| 283 | ret = wait_for_completion_timeout(&priv->comp, msecs_to_jiffies(50)); | 284 | ret = wait_for_completion_timeout(&priv->comp, msecs_to_jiffies(50)); |
| 284 | disable_irq(irq); | 285 | disable_irq(irq); |
| 285 | if (ret <= 0) { | 286 | if (ret == 0) { |
| 286 | dev_warn(priv->dev, "DC stop timeout after 50 ms\n"); | 287 | dev_warn(priv->dev, "DC stop timeout after 50 ms\n"); |
| 287 | 288 | ||
| 288 | val = readl(dc->base + DC_WR_CH_CONF); | 289 | val = readl(dc->base + DC_WR_CH_CONF); |
