Skip to content

Commit c27ea8e

Browse files
Uwe Kleine-KönigLi Yang
authored andcommitted
soc: fsl: dpio: Suppress duplicated error reporting on device remove
Returning an error code from a fsl_mc_driver's remove callback results in a generic error message, otherwise the value is ignored and the device gets unbound. As the only error path in dpaa2_dpio_remove() already emits an error message, return zero unconditionally to suppress another (less helpful) error report. Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de> Reviewed-by: Ioana Ciornei <ioana.ciornei@nxp.com> Tested-by: Ioana Ciornei <ioana.ciornei@nxp.com> # sanity checks Reviewed-by: Laurentiu Tudor <laurentiu.tudor@nxp.com> Tested-by: Laurentiu Tudor <laurentiu.tudor@nxp.com> Signed-off-by: Li Yang <leoyang.li@nxp.com>
1 parent b313403 commit c27ea8e

1 file changed

Lines changed: 1 addition & 5 deletions

File tree

drivers/soc/fsl/dpio/dpio-driver.c

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -297,14 +297,10 @@ static int dpaa2_dpio_remove(struct fsl_mc_device *dpio_dev)
297297

298298
dpio_close(dpio_dev->mc_io, 0, dpio_dev->mc_handle);
299299

300-
fsl_mc_portal_free(dpio_dev->mc_io);
301-
302-
return 0;
303-
304300
err_open:
305301
fsl_mc_portal_free(dpio_dev->mc_io);
306302

307-
return err;
303+
return 0;
308304
}
309305

310306
static const struct fsl_mc_device_id dpaa2_dpio_match_id_table[] = {

0 commit comments

Comments
 (0)