diff mbox

dma/mic_x100_dma: IS_ERR() vs PTR_ERR() typo

Message ID 20160229095107.GA32061@mwanda (mailing list archive)
State Accepted
Headers show

Commit Message

Dan Carpenter Feb. 29, 2016, 9:51 a.m. UTC
This is harmless because the caller only cares about zero vs non-zero
but we should be returning PTR_ERR() here.

Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>

--
To unsubscribe from this list: send the line "unsubscribe dmaengine" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Comments

Vinod Koul March 3, 2016, 3:43 p.m. UTC | #1
On Mon, Feb 29, 2016 at 12:51:07PM +0300, Dan Carpenter wrote:
> This is harmless because the caller only cares about zero vs non-zero
> but we should be returning PTR_ERR() here.

Applied thanks
diff mbox

Patch

diff --git a/drivers/dma/mic_x100_dma.c b/drivers/dma/mic_x100_dma.c
index 068e920..1502b24 100644
--- a/drivers/dma/mic_x100_dma.c
+++ b/drivers/dma/mic_x100_dma.c
@@ -483,7 +483,7 @@  static int mic_dma_setup_irq(struct mic_dma_chan *ch)
 			mic_dma_intr_handler, mic_dma_thread_fn,
 			"mic dma_channel", ch, ch->ch_num);
 	if (IS_ERR(ch->cookie))
-		return IS_ERR(ch->cookie);
+		return PTR_ERR(ch->cookie);
 	return 0;
 }