]> git.baikalelectronics.ru Git - kernel.git/commit
counter: ti-ecap-capture: fix IS_ERR() vs NULL check
authorDan Carpenter <dan.carpenter@oracle.com>
Wed, 12 Oct 2022 14:51:25 +0000 (17:51 +0300)
committerWilliam Breathitt Gray <william.gray@linaro.org>
Mon, 17 Oct 2022 13:51:29 +0000 (09:51 -0400)
commit9d811790d06fdafca56ae2d23611a074634f7087
tree460ea51df32bac0780d3b019d244ca8c0e37541d
parent4d3b5eec895381fd963fb5dbab9ccff25c32ff55
counter: ti-ecap-capture: fix IS_ERR() vs NULL check

The devm_counter_alloc() function returns NULL on error.  It doesn't
return error pointers.

Fixes: fdb9ff815bb5 ("counter: ti-ecap-capture: capture driver support for ECAP")
Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>
Reviewed-by: Julien Panis <jpanis@baylibre.com>
Acked-by: Vignesh Raghavendra <vigneshr@ti.com>
Link: https://lore.kernel.org/r/Y0bUbZvfDJHBG9C6@kili/
Signed-off-by: William Breathitt Gray <william.gray@linaro.org>
drivers/counter/ti-ecap-capture.c