Thread (17 messages) 17 messages, 5 authors, 2025-09-22

Re: [PATCH v6 5/9] phy: phy-can-transceiver: Propagate return value of gpiod_set_value_cansleep

From: Peng Fan <hidden>
Date: 2025-09-22 03:32:47
Also in: imx, linux-can, linux-devicetree, linux-phy, lkml

On Fri, Sep 19, 2025 at 09:18:21PM +0200, Marc Kleine-Budde wrote:
On 09.09.2025 13:40:15, Peng Fan wrote:
quoted
gpiod_set_value_cansleep might return failure, propagate the return value
of gpiod_set_value_cansleep to parent.
Are there any expectations of the phy framework from the driver if the
switch on or off fails? Do you have to roll back any changes in case of
an error?
The phy framework expects return value, so if on or off fails, the
phy framework will record and handle properly, but if one of GPIO settings
fail, the driver itself should handle it and need to roll back. I will update
in V7.

Thanks,
Peng
Marc

-- 
Pengutronix e.K.                 | Marc Kleine-Budde          |
Embedded Linux                   | https://www.pengutronix.de |
Vertretung N??rnberg              | Phone: +49-5121-206917-129 |
Amtsgericht Hildesheim, HRA 2686 | Fax:   +49-5121-206917-9   |

Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help