]> www.infradead.org Git - users/jedix/linux-maple.git/commit
i2c: iproc: Refactor prototype and remove redundant error checks
authorWentao Liang <vulab@iscas.ac.cn>
Tue, 21 Jan 2025 08:48:18 +0000 (16:48 +0800)
committerAndi Shyti <andi.shyti@kernel.org>
Sat, 22 Mar 2025 12:11:53 +0000 (13:11 +0100)
commit39f8d63804505222dccf265797c2d03de7f2d5b3
tree67da26396e8885a462385fd2bb162ca9fde2153f
parenta815975cbaeb4ab29f45312ef23be2871b2e8b82
i2c: iproc: Refactor prototype and remove redundant error checks

The bcm_iproc_i2c_init() always returns 0. As a result, there
is no need to check its return value or handle errors.

This patch changes the prototype of bcm_iproc_i2c_init() to
return void and removes the redundant error handling code after
calls to bcm_iproc_i2c_init() in both the bcm_iproc_i2c_probe()
and bcm_iproc_i2c_resume().

Signed-off-by: Wentao Liang <vulab@iscas.ac.cn>
Acked-by: Uwe Kleine-König <u.kleine-koenig@baylibre.com>
Acked-by: Ray Jui <ray.jui@broadcom.com>
Link: https://lore.kernel.org/r/20250121084818.2719-1-vulab@iscas.ac.cn
Signed-off-by: Andi Shyti <andi.shyti@kernel.org>
drivers/i2c/busses/i2c-bcm-iproc.c