提交 af7537d3 编写于 作者: N Nicholas Mc Guire 提交者: Philipp Zabel

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: NNicholas Mc Guire <der.herr@hofr.at>
Signed-off-by: NPhilipp Zabel <p.zabel@pengutronix.de>
上级 5159571c
...@@ -267,7 +267,8 @@ static irqreturn_t dc_irq_handler(int irq, void *dev_id) ...@@ -267,7 +267,8 @@ static irqreturn_t dc_irq_handler(int irq, void *dev_id)
void ipu_dc_disable_channel(struct ipu_dc *dc) void ipu_dc_disable_channel(struct ipu_dc *dc)
{ {
struct ipu_dc_priv *priv = dc->priv; struct ipu_dc_priv *priv = dc->priv;
int irq, ret; int irq;
unsigned long ret;
u32 val; u32 val;
/* TODO: Handle MEM_FG_SYNC differently from MEM_BG_SYNC */ /* TODO: Handle MEM_FG_SYNC differently from MEM_BG_SYNC */
...@@ -282,7 +283,7 @@ void ipu_dc_disable_channel(struct ipu_dc *dc) ...@@ -282,7 +283,7 @@ void ipu_dc_disable_channel(struct ipu_dc *dc)
enable_irq(irq); enable_irq(irq);
ret = wait_for_completion_timeout(&priv->comp, msecs_to_jiffies(50)); ret = wait_for_completion_timeout(&priv->comp, msecs_to_jiffies(50));
disable_irq(irq); disable_irq(irq);
if (ret <= 0) { if (ret == 0) {
dev_warn(priv->dev, "DC stop timeout after 50 ms\n"); dev_warn(priv->dev, "DC stop timeout after 50 ms\n");
val = readl(dc->base + DC_WR_CH_CONF); val = readl(dc->base + DC_WR_CH_CONF);
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册