Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
iio: core: Fix an error pointer vs NULL bug in devm_iio_device_alloc()
The devm_iio_device_alloc() function is supposed to return NULL and not error pointers. Returning an error pointer will lead to a crash in the callers. Fixes: cf5724e ("iio: core: simplify some devm functions") Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com> Reviewed-by: Alexandru Ardelean <ardeleanalex@gmail.com> Link: https://lore.kernel.org/r/YJ+a1yaMu2QNATgt@mwanda Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
- Loading branch information