Message ID | 20240715-flexcan-v2-2-2873014c595a@nxp.com (mailing list archive) |
---|---|
State | Awaiting Upstream |
Delegated to: | Netdev Maintainers |
Headers | show |
Series | can: fsl,flexcan: add fsl,s32v234-flexcan and imx95 wakeup | expand |
Context | Check | Description |
---|---|---|
netdev/tree_selection | success | Series ignored based on subject |
On 15.07.2024 17:27:21, Frank Li wrote: > From: Chircu-Mare Bogdan-Petru <Bogdan.Chircu@freescale.com> > > Add flexcan support for S32V234. > > Signed-off-by: Chircu-Mare Bogdan-Petru <Bogdan.Chircu@freescale.com> > Signed-off-by: Dan Nica <dan.nica@nxp.com> > Signed-off-by: Stefan-Gabriel Mirea <stefan-gabriel.mirea@nxp.com> > Reviewed-by: Li Yang <leoyang.li@nxp.com> > Reviewed-by: Joakim Zhang <qiangqing.zhang@nxp.com> > Reviewed-by: Leonard Crestez <leonard.crestez@nxp.com> > Signed-off-by: Frank Li <Frank.Li@nxp.com> > --- > drivers/net/can/flexcan/flexcan-core.c | 5 +++++ > 1 file changed, 5 insertions(+) > > diff --git a/drivers/net/can/flexcan/flexcan-core.c b/drivers/net/can/flexcan/flexcan-core.c > index 8ea7f2795551b..f6e609c388d55 100644 > --- a/drivers/net/can/flexcan/flexcan-core.c > +++ b/drivers/net/can/flexcan/flexcan-core.c > @@ -378,6 +378,10 @@ static const struct flexcan_devtype_data fsl_lx2160a_r1_devtype_data = { > FLEXCAN_QUIRK_SUPPORT_RX_MAILBOX_RTR, > }; > > +static struct flexcan_devtype_data fsl_s32v234_devtype_data = { > + .quirks = FLEXCAN_QUIRK_DISABLE_RXFG | FLEXCAN_QUIRK_DISABLE_MECR, > +}; - Does the core support CAN-FD? - Does the core generate an error interrupt when going from error warning to error passive? - Are you sure, you don't need to enable FLEXCAN_QUIRK_ENABLE_EACEN_RRS? - You probably want to use the mailboxes instead of the FIFO for the RX-path. regards, Marc
diff --git a/drivers/net/can/flexcan/flexcan-core.c b/drivers/net/can/flexcan/flexcan-core.c index 8ea7f2795551b..f6e609c388d55 100644 --- a/drivers/net/can/flexcan/flexcan-core.c +++ b/drivers/net/can/flexcan/flexcan-core.c @@ -378,6 +378,10 @@ static const struct flexcan_devtype_data fsl_lx2160a_r1_devtype_data = { FLEXCAN_QUIRK_SUPPORT_RX_MAILBOX_RTR, }; +static struct flexcan_devtype_data fsl_s32v234_devtype_data = { + .quirks = FLEXCAN_QUIRK_DISABLE_RXFG | FLEXCAN_QUIRK_DISABLE_MECR, +}; + static const struct can_bittiming_const flexcan_bittiming_const = { .name = DRV_NAME, .tseg1_min = 4, @@ -2018,6 +2022,7 @@ static const struct of_device_id flexcan_of_match[] = { { .compatible = "fsl,vf610-flexcan", .data = &fsl_vf610_devtype_data, }, { .compatible = "fsl,ls1021ar2-flexcan", .data = &fsl_ls1021a_r2_devtype_data, }, { .compatible = "fsl,lx2160ar1-flexcan", .data = &fsl_lx2160a_r1_devtype_data, }, + { .compatible = "fsl,s32v234-flexcan", .data = &fsl_s32v234_devtype_data, }, { /* sentinel */ }, }; MODULE_DEVICE_TABLE(of, flexcan_of_match);