Re: [PATCH v1 2/2] arm64: dts: qcom: qcs6490-rb3gen2: Enable CAN bus controller

From: Marc Kleine-Budde

Date: Thu Mar 12 2026 - 03:52:03 EST


On 12.03.2026 12:04:47, Viken Dadhaniya wrote:
> I measured the standby pin voltage with only XSTBYEN=1 set
> (TRIS0 left at reset default of 1 = input): the pin is HIGH
> (~3.3V), meaning the transceiver remains in standby.
>
> The root cause is that after reset TRIS0=1 (input direction),
> so the pin is not driven. XSTBYEN=1 alone has no effect while
> the pin is configured as input.
>
> Clearing TRIS0=0 (output) atomically with XSTBYEN=1 fixes this:
>
> regmap_update_bits(priv->map_reg, MCP251XFD_REG_IOCON,
> MCP251XFD_REG_IOCON_XSTBYEN |
> MCP251XFD_REG_IOCON_TRIS0 |
> MCP251XFD_REG_IOCON_LAT0,
> MCP251XFD_REG_IOCON_XSTBYEN);
>
> After the above change: pin is LOW (~0V), IOCON = 0x03020042,
> transceiver active, CAN communication works. Verified on RB3
> Gen2 with PCAN-USB FD.
>
> Should I send a patch implementing this, gated on a DT property
> such as "microchip,xstbyen"?

Sounds good, make it so.

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 |

Attachment: signature.asc
Description: PGP signature