From c2e45444ff0f0591a1648b5a511944dac7328133 Mon Sep 17 00:00:00 2001 From: SPRESENSE <41312067+SPRESENSE@users.noreply.github.com> Date: Mon, 11 Apr 2022 20:09:30 +0900 Subject: [PATCH] boards: cxd56xx: Fix an issue i2c tool not working It caused i2c tool not to work due to i2c uninitializing processing. Since this process is not necessary in the normal case, we will move it to the error case. --- boards/arm/cxd56xx/common/src/cxd56_i2cdev.c | 1 + 1 file changed, 1 insertion(+) diff --git a/boards/arm/cxd56xx/common/src/cxd56_i2cdev.c b/boards/arm/cxd56xx/common/src/cxd56_i2cdev.c index 38eb039564..4d3b1bd294 100644 --- a/boards/arm/cxd56xx/common/src/cxd56_i2cdev.c +++ b/boards/arm/cxd56xx/common/src/cxd56_i2cdev.c @@ -62,6 +62,7 @@ int board_i2cdev_initialize(int port) if (ret < 0) { _err("ERROR: Failed to register i2c%d: %d\n", port, ret); + cxd56_i2cbus_uninitialize(i2c); } return ret;