[PATCH 2/3] can: rockchip: add RK3588 CAN-FD support

💫.220 1579567540 at qq.com
Wed Jul 1 05:29:22 PDT 2026


Hi Heiko, Marc,

thanks for the review.

> please use a real name, not an alias.

I will use my real name in future revisions.

> Funnily enough, we seem to have worked on the same topic
> at the same time :-)
>
> https://lore.kernel.org/lkml/20260630164336.3444550-1-heiko@sntech.de/

I missed Heiko's series before sending mine, sorry for the noise.
(But it really is a very interesting coincidence.)
Since the series overlap, I am happy to base further work on Heiko's
series, or to let Heiko fold the RK3588 RX_FIFO_CNT bitfield change into
his v2 if that is preferred.

> Here I could reproduce erratum 6 though:
> https://lore.kernel.org/lkml/20260630164336.3444550-4-heiko@sntech.de/

Thanks for pointing this out. My local test setup did not reproduce it,
but given Heiko's result I agree that RK3588v2 should keep the erratum 6
workaround enabled. If I respin this series, I will remove the "not
reproduced" statement and enable RKCANFD_QUIRK_RK3568_ERRATUM_6 for
RK3588v2.

> The "Rockchip RK3588 TRM V1.0-Part1-20220309.pdf" datasheet says bits
> "7:5" are RX_FIFO_FRAME_CNT, while bit "6" is marked as reserved.

For RX_FIFO_CNT, I found the bitfield difference by reading Rockchip's
vendor kernel 6.1 driver and comparing the CAN support for RK3568 and
RK3588. The vendor driver uses different RX FIFO count bitfields for the
two SoCs, and my testing on RK3588v2 also indicates that bits 7:5 are
needed. I can add a short note about this in the commit message or
code comment.

One more question about RKCANFD_QUIRK_CANFD_BROKEN: in my RK3588v2 test
setup the two known CAN-FD trigger frames did not cause an Error
Interrupt or Error-Warning. I also ran a 12 hour CAN-FD stress test with
can0/can1 directly connected, 200 MHz CAN clock, 500 kbit/s nominal
bitrate and 1 Mbit/s data bitrate. That test included periodic
transmission of the two CANFD_BROKEN frames, variable DLC CAN-FD frames,
CAN-FD+BRS+EFF load, and a canfdtest run with 19,417,129 frames without
data mismatch.

Would it make sense to leave RKCANFD_QUIRK_CANFD_BROKEN disabled for
RK3588v2, or have you seen this issue on RK3588 as well?

Thanks,
Cunhao Lu


More information about the linux-arm-kernel mailing list