Skip to content

Commit

Permalink
Input: cyttsp4 - replace IS_ERR and PTR_ERR with PTR_ERR_OR_ZERO
Browse files Browse the repository at this point in the history
This patch fixes coccinelle error regarding usage of IS_ERR and
PTR_ERR instead of PTR_ERR_OR_ZERO.

Signed-off-by: Duan Jiong <duanj.fnst@cn.fujitsu.com>
Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
  • Loading branch information
Duan Jiong authored and Dmitry Torokhov committed Nov 11, 2013
1 parent acc8466 commit a013781
Showing 1 changed file with 1 addition and 4 deletions.
5 changes: 1 addition & 4 deletions drivers/input/touchscreen/cyttsp4_spi.c
Original file line number Diff line number Diff line change
Expand Up @@ -171,10 +171,7 @@ static int cyttsp4_spi_probe(struct spi_device *spi)
ts = cyttsp4_probe(&cyttsp_spi_bus_ops, &spi->dev, spi->irq,
CY_SPI_DATA_BUF_SIZE);

if (IS_ERR(ts))
return PTR_ERR(ts);

return 0;
return PTR_ERR_OR_ZERO(ts);
}

static int cyttsp4_spi_remove(struct spi_device *spi)
Expand Down

0 comments on commit a013781

Please sign in to comment.