lkml.org 
[lkml]   [2022]   [Dec]   [14]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH 1/1] i2c: designware: add pinctrl for recovery info as an option
On Wed, Dec 14, 2022 at 10:27:07AM +0000, Hanna Hawa wrote:
> The current implementation of designware recovery mechanism fit for
> specific device (Intel / Altera Cyclone V SOC) which have two separated
> "wired" GPIOs to the i2c bus via the SOC FPGA for the i2c recovery.
>
> This change add ability to get the pinctrl for the i2c recovery in order
> to switch between pin configuration (I2C and GPIO functionality) if the
> pinctrl exists.

...

> + rinfo->pinctrl = devm_pinctrl_get(dev->dev);
> + if (IS_ERR(rinfo->pinctrl)) {
> + if (PTR_ERR(rinfo->pinctrl) == -EPROBE_DEFER)
> + return -EPROBE_DEFER;
> + rinfo->pinctrl = NULL;
> + dev_dbg(dev->dev, "can't get pinctrl for i2c recovery\n");
> + }

Can you explain, why pinctrl_bind_pins() is not enough?

(You may also refer to the ab78029ecc34 ("drivers/pinctrl: grab default handles
from device core") for more details.)

--
With Best Regards,
Andy Shevchenko


\
 
 \ /
  Last update: 2022-12-14 12:45    [W:0.030 / U:0.252 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site