Re: [Patch v2] i2c: imx: implement bus recovery

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Tue, Sep 8, 2015 at 10:22 PM, Uwe Kleine-König
<u.kleine-koenig@xxxxxxxxxxxxxx> wrote:
> [Me]
>> I don't understand. What does "manually" mean in this context?
>> Code examples for "manual" and "automatic"?
>
> Normally i2c operations are done using the i2c core in the SoC and using
> the i2c function of the respective pins. Recovery
> however must be done (manually) by configuring the lines as GPIO and
> using a sequence of calls to gpio_[gs]et_value.
>
> The sleep state of the i2c bus device (usually?) configures the i2c
> lines as GPIO. Is it ok to (ab)use the sleep state to prepare for the
> recovery procedure or should we better introduce a dedicated gpio mode
> pinctrl?

OK now I understand (I think).

I think it's OK to use tyhe sleep state as long as there are comments
in the code explaining what is going on. It is something extraordinary
after all.

I guess this means that you're using GPIO orthogonally to I2C,
and thus the pin controller does not have the .strict property
set. There should be a comment in the struct pinmux_ops of
the driver saying that this pin controller cannot be used as
strict. Need to keep the information there so people don't get
confused.

Yours,
Linus Walleij
--
To unsubscribe from this list: send the line "unsubscribe linux-i2c" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html



[Index of Archives]     [Linux GPIO]     [Linux SPI]     [Linux Hardward Monitoring]     [LM Sensors]     [Linux USB Devel]     [Linux Media]     [Video for Linux]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux