[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20220314101337.4x2cu3nvg2vg7ulh@pengutronix.de>
Date: Mon, 14 Mar 2022 11:13:37 +0100
From: Uwe Kleine-König <u.kleine-koenig@...gutronix.de>
To: Ian Dannapel <iansdannapel@...il.com>
Cc: linux@...pel-privat.de, Erik.Schumacher@...s-sensing.com,
shawnguo@...nel.org, s.hauer@...gutronix.de,
linux-kernel@...r.kernel.org, Michael.Glembotzki@...s-sensing.com,
linux-imx@....com, kernel@...gutronix.de, festevam@...il.com,
linux-arm-kernel@...ts.infradead.org, linux-i2c@...r.kernel.org
Subject: Re: [PATCH] i2c: imx: remove unnecessary delay at startup
Hello,
On Mon, Mar 14, 2022 at 10:59:18AM +0100, Ian Dannapel wrote:
> diff --git a/drivers/i2c/busses/i2c-imx.c b/drivers/i2c/busses/i2c-imx.c
> index 3576b63a6c03..019dda5301df 100644
> --- a/drivers/i2c/busses/i2c-imx.c
> +++ b/drivers/i2c/busses/i2c-imx.c
> @@ -602,12 +602,6 @@ static int i2c_imx_start(struct imx_i2c_struct *i2c_imx, bool atomic)
> imx_i2c_write_reg(i2c_imx->hwdata->i2sr_clr_opcode, i2c_imx, IMX_I2C_I2SR);
> imx_i2c_write_reg(i2c_imx->hwdata->i2cr_ien_opcode, i2c_imx, IMX_I2C_I2CR);
>
> - /* Wait controller to be stable */
> - if (atomic)
> - udelay(50);
> - else
> - usleep_range(50, 150);
> -
> /* Start I2C transaction */
> temp = imx_i2c_read_reg(i2c_imx, IMX_I2C_I2CR);
> temp |= I2CR_MSTA;
This contradicts statements made in
43309f3b521302bb66c4c9e66704dd3675e4d725.
Maybe the sleep/delay should be done conditionally on the busy bit?
Best regards
Uwe
--
Pengutronix e.K. | Uwe Kleine-König |
Industrial Linux Solutions | https://www.pengutronix.de/ |
Download attachment "signature.asc" of type "application/pgp-signature" (489 bytes)
Powered by blists - more mailing lists