]> git.baikalelectronics.ru Git - kernel.git/commit
iio: magnetometer: ak8974: remove redundant zero timeout check
authorColin Ian King <colin.king@canonical.com>
Wed, 11 Jan 2017 17:49:33 +0000 (17:49 +0000)
committerJonathan Cameron <jic23@kernel.org>
Sat, 14 Jan 2017 13:10:04 +0000 (13:10 +0000)
commitf92a5a241f27694c6da560b3ce434e360530dd10
tree0fbbc6ac24d0f8d424b125fd60b5bbaa4a303e33
parent972e72452324d2fe44595f5e0cb6ac0e4fd8748b
iio: magnetometer: ak8974: remove redundant zero timeout check

At the end of the delay loop timeout will always be zero
and hence the check for !timeout will always be true. Remove
the redundant check and the redundant return 0 at the end of
the function.

Fixes CoverityScan CID#1357168 ("Logically dead code")

Signed-off-by: Colin Ian King <colin.king@canonical.com>
Reviewed-by: Linus Walleij <linus.walleij@linaro.org>
Signed-off-by: Jonathan Cameron <jic23@kernel.org>
drivers/iio/magnetometer/ak8974.c