Re: [PATCH] serial: 8250_hub6: Fix double definition for hub6_match_port()
From: Uwe Kleine-König
Date: Fri Jul 31 2026 - 09:37:11 EST
Heyho,
On Thu, Jul 30, 2026 at 04:15:16PM -0400, Hugo Villeneuve wrote:
> On Thu, 30 Jul 2026 21:57:01 +0200
> Uwe Kleine-König <u.kleine-koenig@xxxxxxxxxxxx> wrote:
>
> > On Thu, Jul 30, 2026 at 04:49:45PM +0200, Greg Kroah-Hartman wrote:
> > > On Wed, Jul 29, 2026 at 03:30:57PM +0200, Uwe Kleine-König wrote:
> > > > I think the real fix would be to just copy uart_match_port() into the
> > > > two drivers that actually use it (and remove the then dead code paths).
> > > > Then it would be drivers/tty/serial/8250/8250_core.c using
> > > > hub6_match_port() only and that can be handled by a proper dependency.
> > >
> > > I'm totally confused, so I'll drop this patch from my review queue and
> > > wait for you all to figure it out :)
> >
> > Does my suggestion make sense for you? Do you intend to work on this to
> > unconfuse Greg?
>
> I am not sure to fully understand what you suggest. Copying the same
> function code to two drivers seems like a waisted opportunity for code
> reuse?
FTR, I prepared a patch for what I had in mind, see
https://lore.kernel.org/linux-serial/cover.1785489518.git.ukleinek@xxxxxxxxxx/
Best regards
Uwe
Attachment:
signature.asc
Description: PGP signature