From: Jorge Ramirez-Ortiz Date: Mon, 15 Aug 2022 14:52:10 +0000 (+0200) Subject: i2c: stm32f7: fix clearing the control register X-Git-Url: http://git.dujemihanovic.xyz/%22/img/sics.gif/%22/static/git-favicon.png?a=commitdiff_plain;h=9ef530f196b78875d4048f2bdb9c6d33ce860088;p=u-boot.git i2c: stm32f7: fix clearing the control register Bits should be set to 0, not 1. Signed-off-by: Jorge Ramirez-Ortiz Reviewed-by: Patrice Chotard Reviewed-by: Patrick Delaunay --- diff --git a/drivers/i2c/stm32f7_i2c.c b/drivers/i2c/stm32f7_i2c.c index bf2a6c9b4b..3a727e68ac 100644 --- a/drivers/i2c/stm32f7_i2c.c +++ b/drivers/i2c/stm32f7_i2c.c @@ -413,7 +413,7 @@ static int stm32_i2c_check_end_of_message(struct stm32_i2c_priv *i2c_priv) setbits_le32(®s->icr, STM32_I2C_ICR_STOPCF); /* Clear control register 2 */ - setbits_le32(®s->cr2, STM32_I2C_CR2_RESET_MASK); + clrbits_le32(®s->cr2, STM32_I2C_CR2_RESET_MASK); } return ret;