Re: [PATCH] serial: 8250_hub6: Fix double definition for hub6_match_port()

Uwe Kleine-König <[email protected]> Fri, 31 Jul 2026 15:20:46 +0200
Newsgroups org.kernel.vger.linux-serial,org.kernel.vger.linux-kernel
Message-ID <amyg0sR7SafpFuKR@monoceros>
--pot5h2ofhsberfqg
Content-Type: text/plain; protected-headers=v1; charset=iso-8859-1
Content-Disposition: inline
Content-Transfer-Encoding: quoted-printable
Subject: Re: [PATCH] serial: 8250_hub6: Fix double definition for
 hub6_match_port()
MIME-Version: 1.0

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=F6nig <[email protected]> wrote:
>=20
> > 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=F6nig wrote:
> > > > I think the real fix would be to just copy uart_match_port() into t=
he
> > > > two drivers that actually use it (and remove the then dead code pat=
hs).
> > > > Then it would be drivers/tty/serial/8250/8250_core.c using
> > > > hub6_match_port() only and that can be handled by a proper dependen=
cy.
> > >=20
> > > I'm totally confused, so I'll drop this patch from my review queue and
> > > wait for you all to figure it out :)
> >=20
> > Does my suggestion make sense for you? Do you intend to work on this to
> > unconfuse Greg?
>=20
> 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/[email protected]=
rg/

Best regards
Uwe

--pot5h2ofhsberfqg
Content-Type: application/pgp-signature; name="signature.asc"

-----BEGIN PGP SIGNATURE-----

iQEzBAABCgAdFiEEP4GsaTp6HlmJrf7Tj4D7WH0S/k4FAmpsoSQACgkQj4D7WH0S
/k407gf+ONnXFwVuQ95sUG2tDsai/JGUVNwnMXFXs4ev8Jjovw2/XOwcIVWSt1R0
POtFXZGCjSH96US+cUS5zJlTdGg8tzbjvklS3NG+wuwATh3xo9gIi5lBMxcFhyGm
noY7zxaNV7N+Q2NJOasYTICeJZKqCVl9P2GkD3uRQuU8TYlFmihBWjNjM0P2sVNH
0tr1o+ha8lVkSeHbVzKZY937FemhJeHD1h4bgGbgPrn8o7zYPoGbi2s5by1EcUJj
dJ3+nrcrzX/oKi7Q1TGyWpS2AqDgAgF0wiqlzAWKRKUHKqKiZocNBNSYInZ+tjtO
R4UlJ+3btkGxezOHlsJ42jw/AvfVrw==
=nrzM
-----END PGP SIGNATURE-----

--pot5h2ofhsberfqg--