lkml.org 
[lkml]   [2022]   [Jan]   [11]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH v2] counter: fix an IS_ERR() vs NULL bug
On Tue, Jan 11, 2022 at 08:32:43PM +0300, Dan Carpenter wrote:
> There are 8 callers for devm_counter_alloc() and they all check for NULL
> instead of error pointers. I think NULL is the better thing to return
> for allocation functions so update counter_alloc() and devm_counter_alloc()
> to return NULL instead of error pointers.
>
> Fixes: c18e2760308e ("counter: Provide alternative counter registration functions")
> Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>

Acked-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>

Thanks
Uwe

--
Pengutronix e.K. | Uwe Kleine-König |
Industrial Linux Solutions | https://www.pengutronix.de/ |
[unhandled content-type:application/pgp-signature]
\
 
 \ /
  Last update: 2022-01-11 21:35    [W:0.030 / U:0.204 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site