* [PATCH] drivers/tty/serial: Remove unused function early_mcf_setup
@ 2024-02-19 16:40 Thomas Huth
2024-02-20 5:11 ` Jiri Slaby
0 siblings, 1 reply; 4+ messages in thread
From: Thomas Huth @ 2024-02-19 16:40 UTC (permalink / raw)
To: linux-m68k, Greg Kroah-Hartman, Greg Ungerer, Jiri Slaby,
Geert Uytterhoeven
Cc: linux-kernel, linux-serial
Compiling a kernel for the ColdFire causes a compiler warning:
drivers/tty/serial/mcf.c:473:12: warning: no previous prototype for
‘early_mcf_setup’ [-Wmissing-prototypes]
473 | int __init early_mcf_setup(struct mcf_platform_uart *platp)
| ^~~~~~~~~~~~~~~
This function seems to be completely unused, so let's remove it
to silence the warning.
Signed-off-by: Thomas Huth <thuth@redhat.com>
---
drivers/tty/serial/mcf.c | 27 ---------------------------
1 file changed, 27 deletions(-)
diff --git a/drivers/tty/serial/mcf.c b/drivers/tty/serial/mcf.c
index 8690a45239e09..b0604d6da0257 100644
--- a/drivers/tty/serial/mcf.c
+++ b/drivers/tty/serial/mcf.c
@@ -470,33 +470,6 @@ static struct mcf_uart mcf_ports[4];
#if defined(CONFIG_SERIAL_MCF_CONSOLE)
/****************************************************************************/
-int __init early_mcf_setup(struct mcf_platform_uart *platp)
-{
- struct uart_port *port;
- int i;
-
- for (i = 0; ((i < MCF_MAXPORTS) && (platp[i].mapbase)); i++) {
- port = &mcf_ports[i].port;
-
- port->line = i;
- port->type = PORT_MCF;
- port->mapbase = platp[i].mapbase;
- port->membase = (platp[i].membase) ? platp[i].membase :
- (unsigned char __iomem *) port->mapbase;
- port->iotype = SERIAL_IO_MEM;
- port->irq = platp[i].irq;
- port->uartclk = MCF_BUSCLK;
- port->flags = UPF_BOOT_AUTOCONF;
- port->rs485_config = mcf_config_rs485;
- port->rs485_supported = mcf_rs485_supported;
- port->ops = &mcf_uart_ops;
- }
-
- return 0;
-}
-
-/****************************************************************************/
-
static void mcf_console_putc(struct console *co, const char c)
{
struct uart_port *port = &(mcf_ports + co->index)->port;
--
2.43.2
^ permalink raw reply related [flat|nested] 4+ messages in thread
* Re: [PATCH] drivers/tty/serial: Remove unused function early_mcf_setup
2024-02-19 16:40 [PATCH] drivers/tty/serial: Remove unused function early_mcf_setup Thomas Huth
@ 2024-02-20 5:11 ` Jiri Slaby
2024-02-20 10:23 ` Geert Uytterhoeven
0 siblings, 1 reply; 4+ messages in thread
From: Jiri Slaby @ 2024-02-20 5:11 UTC (permalink / raw)
To: Thomas Huth, linux-m68k, Greg Kroah-Hartman, Greg Ungerer,
Geert Uytterhoeven
Cc: linux-kernel, linux-serial
On 19. 02. 24, 17:40, Thomas Huth wrote:
> Compiling a kernel for the ColdFire causes a compiler warning:
>
> drivers/tty/serial/mcf.c:473:12: warning: no previous prototype for
> ‘early_mcf_setup’ [-Wmissing-prototypes]
> 473 | int __init early_mcf_setup(struct mcf_platform_uart *platp)
> | ^~~~~~~~~~~~~~~
>
> This function seems to be completely unused, so let's remove it
> to silence the warning.
And it seems so since the driver addition in 2007 by:
commit 49aa49bfd40d718095669c1c70c9d167b814e29b
Author: Greg Ungerer <gerg@snapgear.com>
Date: Tue Oct 23 14:37:54 2007 +1000
m68knommu: new style ColdFire UART driver
Reviewed-by: Jiri Slaby <jirislaby@kernel.org>
thanks,
--
js
suse labs
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [PATCH] drivers/tty/serial: Remove unused function early_mcf_setup
2024-02-20 5:11 ` Jiri Slaby
@ 2024-02-20 10:23 ` Geert Uytterhoeven
2024-02-20 13:55 ` Greg Ungerer
0 siblings, 1 reply; 4+ messages in thread
From: Geert Uytterhoeven @ 2024-02-20 10:23 UTC (permalink / raw)
To: Jiri Slaby, Greg Ungerer
Cc: Thomas Huth, linux-m68k, Greg Kroah-Hartman, linux-kernel,
linux-serial
On Tue, Feb 20, 2024 at 6:11 AM Jiri Slaby <jirislaby@kernel.org> wrote:
> On 19. 02. 24, 17:40, Thomas Huth wrote:
> > Compiling a kernel for the ColdFire causes a compiler warning:
> >
> > drivers/tty/serial/mcf.c:473:12: warning: no previous prototype for
> > ‘early_mcf_setup’ [-Wmissing-prototypes]
> > 473 | int __init early_mcf_setup(struct mcf_platform_uart *platp)
> > | ^~~~~~~~~~~~~~~
> >
> > This function seems to be completely unused, so let's remove it
> > to silence the warning.
>
> And it seems so since the driver addition in 2007 by:
> commit 49aa49bfd40d718095669c1c70c9d167b814e29b
> Author: Greg Ungerer <gerg@snapgear.com>
> Date: Tue Oct 23 14:37:54 2007 +1000
>
> m68knommu: new style ColdFire UART driver
Indeed.
Looks like the "changes to the ColdFire based m68knommu systems
to use a platform model at init, and this is used there" from [1]
never materialized on any public mailing list?
Greg: does it still make sense to add them? If not:
Reviewed-by: Geert Uytterhoeven <geert@linux-m68k.org>
[1] https://lore.kernel.org/all/47254BEB.2040609@snapgear.com/
Gr{oetje,eeting}s,
Geert
--
Geert Uytterhoeven -- There's lots of Linux beyond ia32 -- geert@linux-m68k.org
In personal conversations with technical people, I call myself a hacker. But
when I'm talking to journalists I just say "programmer" or something like that.
-- Linus Torvalds
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [PATCH] drivers/tty/serial: Remove unused function early_mcf_setup
2024-02-20 10:23 ` Geert Uytterhoeven
@ 2024-02-20 13:55 ` Greg Ungerer
0 siblings, 0 replies; 4+ messages in thread
From: Greg Ungerer @ 2024-02-20 13:55 UTC (permalink / raw)
To: Geert Uytterhoeven, Jiri Slaby
Cc: Thomas Huth, linux-m68k, Greg Kroah-Hartman, linux-kernel,
linux-serial
On 20/2/24 20:23, Geert Uytterhoeven wrote:
> On Tue, Feb 20, 2024 at 6:11 AM Jiri Slaby <jirislaby@kernel.org> wrote:
>> On 19. 02. 24, 17:40, Thomas Huth wrote:
>>> Compiling a kernel for the ColdFire causes a compiler warning:
>>>
>>> drivers/tty/serial/mcf.c:473:12: warning: no previous prototype for
>>> ‘early_mcf_setup’ [-Wmissing-prototypes]
>>> 473 | int __init early_mcf_setup(struct mcf_platform_uart *platp)
>>> | ^~~~~~~~~~~~~~~
>>>
>>> This function seems to be completely unused, so let's remove it
>>> to silence the warning.
>>
>> And it seems so since the driver addition in 2007 by:
>> commit 49aa49bfd40d718095669c1c70c9d167b814e29b
>> Author: Greg Ungerer <gerg@snapgear.com>
>> Date: Tue Oct 23 14:37:54 2007 +1000
>>
>> m68knommu: new style ColdFire UART driver
>
> Indeed.
>
> Looks like the "changes to the ColdFire based m68knommu systems
> to use a platform model at init, and this is used there" from [1]
> never materialized on any public mailing list?
>
> Greg: does it still make sense to add them?
No, it never really turned out to be useful enough to anyone,
so I never really pushed it out or progressed it any further.
So I am fine with removing this now:
Acked-by: Greg Ungerer <gerg@linux-m68k.org>
I can take it via the m68knommu git tree if no one else wants to
pick it up.
Regards
Greg
> If not:
> Reviewed-by: Geert Uytterhoeven <geert@linux-m68k.org>
>
> [1] https://lore.kernel.org/all/47254BEB.2040609@snapgear.com/
>
> Gr{oetje,eeting}s,
>
> Geert
>
^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2024-02-20 13:55 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2024-02-19 16:40 [PATCH] drivers/tty/serial: Remove unused function early_mcf_setup Thomas Huth
2024-02-20 5:11 ` Jiri Slaby
2024-02-20 10:23 ` Geert Uytterhoeven
2024-02-20 13:55 ` Greg Ungerer
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox