diff options
author | Martin Kaiser <martin@kaiser.cx> | 2020-11-01 18:18:07 +0100 |
---|---|---|
committer | Wolfram Sang <wsa@kernel.org> | 2020-11-03 22:18:04 +0100 |
commit | 5df324b5f4baa3a51990f078fa445800197dfba3 (patch) | |
tree | c5ec306dc7cc38feba7c3ab4de45e39e45b62dd7 /drivers/i2c/busses/i2c-exynos5.c | |
parent | 40af583d16465aae2a570e469fc72a5d24438a20 (diff) | |
download | linux-5df324b5f4baa3a51990f078fa445800197dfba3.tar.bz2 |
i2c: exynos5: don't check for irq 0
platform_get_irq never returns 0. Don't check for this. Make it clear that
the error path always returns a negative error code.
Signed-off-by: Martin Kaiser <martin@kaiser.cx>
Reviewed-by: Krzysztof Kozlowski <krzk@kernel.org>
Signed-off-by: Wolfram Sang <wsa@kernel.org>
Diffstat (limited to 'drivers/i2c/busses/i2c-exynos5.c')
-rw-r--r-- | drivers/i2c/busses/i2c-exynos5.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/i2c/busses/i2c-exynos5.c b/drivers/i2c/busses/i2c-exynos5.c index fad1c52857aa..20a9881a0d6c 100644 --- a/drivers/i2c/busses/i2c-exynos5.c +++ b/drivers/i2c/busses/i2c-exynos5.c @@ -778,7 +778,7 @@ static int exynos5_i2c_probe(struct platform_device *pdev) init_completion(&i2c->msg_complete); i2c->irq = ret = platform_get_irq(pdev, 0); - if (ret <= 0) + if (ret < 0) goto err_clk; ret = devm_request_irq(&pdev->dev, i2c->irq, exynos5_i2c_irq, |