Messages in this thread | | | Date | Mon, 24 Apr 2023 12:06:28 +0200 | From | Marc Kleine-Budde <> | Subject | Re: [PATCH 4/4] can: bxcan: add support for single peripheral configuration |
| |
On 24.04.2023 08:56:03, Dario Binacchi wrote: > > This probably works. Can we do better, i.e. without this additional code? > > > > If you add a syscon node for the single instance CAN, too, you don't > > need a code change here, right? > > I think so. > > I have only one doubt about it. This implementation allows, > implicitly, to distinguish if the peripheral is in single > configuration (without handle to the gcan node) or in double > configuration (with handle to the gcan node). For example, in single > configuration the peripheral has 14 filter banks, while in double > configuration there are 26 shared banks. Without code changes, this > kind of information is lost. Is it better then, for future > developments, to add a new boolean property to the can node of the dts > (e.g. single-conf)?
The DT ist not yet mainline, so we can still change it. Another option is to have "st,can-primary" and "st,can-secondary" for the shared peripherals and nothing for the single instance.
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 | [unhandled content-type:application/pgp-signature] | |