Message ID | 20230615182938.18487-6-tanure@linux.com (mailing list archive) |
---|---|
State | Superseded |
Headers | show |
Series | Add Amlogic A311D2 and Khadas Vim4 Board Support | expand |
Hi Lucas: On 19:29 Thu 15 Jun , Lucas Tanure wrote: > Make UART driver compatible with T7 SOC UART. > > Signed-off-by: Lucas Tanure <tanure@linux.com> > --- > drivers/tty/serial/meson_uart.c | 4 ++++ > 1 file changed, 4 insertions(+) > > diff --git a/drivers/tty/serial/meson_uart.c b/drivers/tty/serial/meson_uart.c > index 2501db5a7aaf..0208f9a6ba7e 100644 > --- a/drivers/tty/serial/meson_uart.c > +++ b/drivers/tty/serial/meson_uart.c > @@ -796,6 +796,10 @@ static const struct of_device_id meson_uart_dt_match[] = { > .compatible = "amlogic,meson-s4-uart", > .data = (void *)&meson_g12a_uart_data, > }, > + { > + .compatible = "amlogic,meson-t7-uart", > + .data = (void *)&meson_g12a_uart_data, I think you are trying to follow previous s4 scheme - to introduce a new compatible string, while I think it's not necessary or even wrong, this will just make the dt_match_list longer but without obvious benefits.. as Conor already raised this question in previous dt-binding patch[4/6], how about just using 'amlogic,meson-g12a-uart' which is the first compatible introduced. if people agree, we could also drop 'amlogic,meson-s4-uart' since it use same compatible data as gl12a, anyway it should be separated into another patch.. > + }, > { /* sentinel */ }, > }; > MODULE_DEVICE_TABLE(of, meson_uart_dt_match); > -- > 2.41.0 > > > _______________________________________________ > linux-amlogic mailing list > linux-amlogic@lists.infradead.org > http://lists.infradead.org/mailman/listinfo/linux-amlogic
On Fri, Jun 16, 2023 at 12:31 AM Yixun Lan <dlan@gentoo.org> wrote: > > Hi Lucas: > > On 19:29 Thu 15 Jun , Lucas Tanure wrote: > > Make UART driver compatible with T7 SOC UART. > > > > Signed-off-by: Lucas Tanure <tanure@linux.com> > > --- > > drivers/tty/serial/meson_uart.c | 4 ++++ > > 1 file changed, 4 insertions(+) > > > > diff --git a/drivers/tty/serial/meson_uart.c b/drivers/tty/serial/meson_uart.c > > index 2501db5a7aaf..0208f9a6ba7e 100644 > > --- a/drivers/tty/serial/meson_uart.c > > +++ b/drivers/tty/serial/meson_uart.c > > @@ -796,6 +796,10 @@ static const struct of_device_id meson_uart_dt_match[] = { > > .compatible = "amlogic,meson-s4-uart", > > .data = (void *)&meson_g12a_uart_data, > > }, > > + { > > + .compatible = "amlogic,meson-t7-uart", > > + .data = (void *)&meson_g12a_uart_data, > I think you are trying to follow previous s4 scheme - to introduce a new > compatible string, while I think it's not necessary or even wrong, this will just > make the dt_match_list longer but without obvious benefits.. > > as Conor already raised this question in previous dt-binding patch[4/6], > how about just using 'amlogic,meson-g12a-uart' which is the first compatible > introduced. > > if people agree, we could also drop 'amlogic,meson-s4-uart' since it use same > compatible data as gl12a, anyway it should be separated into another patch.. > > > + }, > > { /* sentinel */ }, > > > > }; > > MODULE_DEVICE_TABLE(of, meson_uart_dt_match); > > -- > > 2.41.0 > > > > > > _______________________________________________ > > linux-amlogic mailing list > > linux-amlogic@lists.infradead.org > > http://lists.infradead.org/mailman/listinfo/linux-amlogic > > -- > Yixun Lan (dlan) > Gentoo Linux Developer > GPG Key ID AABEFD55 Yes, I am dropping this patch and using s4 and g12a compatible lines.
On Sun, Jun 18, 2023 at 06:40:12PM +0100, Lucas Tanure wrote: > On Fri, Jun 16, 2023 at 12:31 AM Yixun Lan <dlan@gentoo.org> wrote: > > > > Hi Lucas: > > > > On 19:29 Thu 15 Jun , Lucas Tanure wrote: > > > Make UART driver compatible with T7 SOC UART. > > > > > > Signed-off-by: Lucas Tanure <tanure@linux.com> > > > --- > > > drivers/tty/serial/meson_uart.c | 4 ++++ > > > 1 file changed, 4 insertions(+) > > > > > > diff --git a/drivers/tty/serial/meson_uart.c b/drivers/tty/serial/meson_uart.c > > > index 2501db5a7aaf..0208f9a6ba7e 100644 > > > --- a/drivers/tty/serial/meson_uart.c > > > +++ b/drivers/tty/serial/meson_uart.c > > > @@ -796,6 +796,10 @@ static const struct of_device_id meson_uart_dt_match[] = { > > > .compatible = "amlogic,meson-s4-uart", > > > .data = (void *)&meson_g12a_uart_data, > > > }, > > > + { > > > + .compatible = "amlogic,meson-t7-uart", > > > + .data = (void *)&meson_g12a_uart_data, > > I think you are trying to follow previous s4 scheme - to introduce a new > > compatible string, while I think it's not necessary or even wrong, this will just > > make the dt_match_list longer but without obvious benefits.. > > > > as Conor already raised this question in previous dt-binding patch[4/6], > > how about just using 'amlogic,meson-g12a-uart' which is the first compatible > > introduced. > > > > if people agree, we could also drop 'amlogic,meson-s4-uart' since it use same > > compatible data as gl12a, anyway it should be separated into another patch.. > Yes, I am dropping this patch and using s4 and g12a compatible lines. If you drop the "amlogic,meson-s4-uart" from here it will break backwards compatibility, because the binding permits "amlogic,meson-s4-uart" in isolation. Please do not make that change. When you introduce the new compatible for the t7, it can fall back to the s4 (or g12a), doesn't really matter, but the existing one for the s4 should not be touched. Cheers, Conor.
diff --git a/drivers/tty/serial/meson_uart.c b/drivers/tty/serial/meson_uart.c index 2501db5a7aaf..0208f9a6ba7e 100644 --- a/drivers/tty/serial/meson_uart.c +++ b/drivers/tty/serial/meson_uart.c @@ -796,6 +796,10 @@ static const struct of_device_id meson_uart_dt_match[] = { .compatible = "amlogic,meson-s4-uart", .data = (void *)&meson_g12a_uart_data, }, + { + .compatible = "amlogic,meson-t7-uart", + .data = (void *)&meson_g12a_uart_data, + }, { /* sentinel */ }, }; MODULE_DEVICE_TABLE(of, meson_uart_dt_match);
Make UART driver compatible with T7 SOC UART. Signed-off-by: Lucas Tanure <tanure@linux.com> --- drivers/tty/serial/meson_uart.c | 4 ++++ 1 file changed, 4 insertions(+) -- 2.41.0