Re: [PATCH] can: tcan4x5x: put tcan into sleep when removing driver
Sean Nyekjaer <[email protected]> Mon, 27 Jul 2026 10:34:06 +0000
| Newsgroups | org.kernel.vger.linux-can,org.kernel.vger.linux-kernel |
|---|---|
| Message-ID | <79jbRkghpsRXohQwvs2lpvzMHo7eTeLspkjBRCa2Mlc02VkFu1jP8j0xJZP86-teeiqJroLBaM5D2PgvneSZs5iiWJGQPsXu9u7xGm41WTk=@geanix.com> |
Hi, On Monday, 27 July 2026 at 12:22, Marc Kleine-Budde <[email protected]> wrote: > On 27.07.2026 11:48:59, Sean Nyekjaer wrote: > > Put the tcan4x5x transceiver into sleep mode when the driver is > > Ah, the device has an internal transceiver. > > > removed, instead of leaving it in its current operating mode. > > This reduces power consumption(3mA@12V) once the driver is > > no longer bound to the device. > > > > Note that the reset pin is needed to bring the device out of sleep > > and back into standby mode again. > > Please add a comment, that the reset pin is needed and maybe refer to > "8.4.3 Sleep Mode" of https://www.ti.com/lit/gpn/tcan4550 Will do. > > Does it still work, if you move the regmap_update_bits() to > tcan4x5x_power_enable()? In our use-case, we don't have control over Vsup. It's directly wired to 12V from the car. But toggling Vsup will get the tcan4x5x into standby mode again. Maybe: if (priv->reset_gpio && priv->power == NULL) ? > > > Signed-off-by: Sean Nyekjaer <[email protected]> > > --- > > I havn't come across any drivers that leaves the devices in the lowest > > power mode when unbinded. But we need this to enter our lowest power > > mode in suspend. > > If it doesn't fit in, I'm happy to carry this out of tree... > > The mcp251xfd driver puts the device into sleep mode. > > regards, > 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 | > /Sean