Re: [PATCH next] PM: runtime: Fix error checking for kunit_device_register()
From: Brian Norris
Date: Fri Oct 03 2025 - 13:03:10 EST
On Fri, Oct 03, 2025 at 12:29:31PM +0300, Dan Carpenter wrote:
> The kunit_device_register() function never returns NULL, it returns
> error pointers. Update the assertions to use
> KUNIT_ASSERT_NOT_ERR_OR_NULL() instead of checking for NULL.
>
> Fixes: 7f7acd193ba8 ("PM: runtime: Add basic kunit tests for API contracts")
> Signed-off-by: Dan Carpenter <dan.carpenter@xxxxxxxxxx>
Thanks for the catch:
Reviewed-by: Brian Norris <briannorris@xxxxxxxxxxxx>