[PATCH 0/6] Adjustments and Enhancements for MOXA PCI Serial Boards

Crescent Hsieh posted 6 patches 1 year, 8 months ago
drivers/tty/mxser.c                 |  50 ----------
drivers/tty/serial/8250/8250_pci.c  | 139 +++++++++++++++++++++++++++-
drivers/tty/serial/8250/8250_port.c |   8 ++
include/uapi/linux/serial_core.h    |   3 +
4 files changed, 146 insertions(+), 54 deletions(-)
[PATCH 0/6] Adjustments and Enhancements for MOXA PCI Serial Boards
Posted by Crescent Hsieh 1 year, 8 months ago
There are 6 patches within this patch series to make some adjustments
and enhancements for MOXA PCI serial boards, a briefly description is
written below:

- The first patch is an independent bug fix patch.
- The second and third patches migrate some MOXA PCI devices from
  `mxser.c` to `8250_pci.c`.
- The fourth and fifth patches address improvements and adjustments in
  handling the serial interface.
- The sixth patch adds a UART configuration that aligns with the
  hardware capabilities of MOXA PCI serial boards.

Crescent Hsieh (6):
  tty: serial: 8250: Fix the amount of ports doesn't match the device
  tty: serial: 8250: Add 2 ports PCI configuration for 921600 BAR 2
  tty: mxser: serial: 8250: Relocate device IDs from mxser to 8250_pci
  tty: serial: 8250: Add check for setting default serial interface
  tty: serial: 8250: Add support for Moxa PCIe boards to switch
    interface
  tty: serial: 8250: Add support for MUEX50 UART

 drivers/tty/mxser.c                 |  50 ----------
 drivers/tty/serial/8250/8250_pci.c  | 139 +++++++++++++++++++++++++++-
 drivers/tty/serial/8250/8250_port.c |   8 ++
 include/uapi/linux/serial_core.h    |   3 +
 4 files changed, 146 insertions(+), 54 deletions(-)

-- 
2.34.1
Re: [PATCH 0/6] Adjustments and Enhancements for MOXA PCI Serial Boards
Posted by Andy Shevchenko 1 year, 8 months ago
Fri, Jun 07, 2024 at 07:43:30PM +0800, Crescent Hsieh kirjoitti:
> There are 6 patches within this patch series to make some adjustments
> and enhancements for MOXA PCI serial boards, a briefly description is
> written below:
> 
> - The first patch is an independent bug fix patch.
> - The second and third patches migrate some MOXA PCI devices from
>   `mxser.c` to `8250_pci.c`.
> - The fourth and fifth patches address improvements and adjustments in
>   handling the serial interface.
> - The sixth patch adds a UART configuration that aligns with the
>   hardware capabilities of MOXA PCI serial boards.

Everything is fine except one issue. Can we avoid polluting 8250_pci?
What I would expect as a patch 2 is a separation of 8250_moxa from
8250_pci (see examples how it was done in the past: 8250_exar, 8250_lpss,
8250_mid, ...) and then updating code there. Can it be achievable?

-- 
With Best Regards,
Andy Shevchenko
Re: [PATCH 0/6] Adjustments and Enhancements for MOXA PCI Serial Boards
Posted by Crescent CY Hsieh 1 year, 8 months ago
On Sat, Jun 08, 2024 at 12:47:40PM +0300, Andy Shevchenko wrote:
> Fri, Jun 07, 2024 at 07:43:30PM +0800, Crescent Hsieh kirjoitti:
> > There are 6 patches within this patch series to make some adjustments
> > and enhancements for MOXA PCI serial boards, a briefly description is
> > written below:
> > 
> > - The first patch is an independent bug fix patch.
> > - The second and third patches migrate some MOXA PCI devices from
> >   `mxser.c` to `8250_pci.c`.
> > - The fourth and fifth patches address improvements and adjustments in
> >   handling the serial interface.
> > - The sixth patch adds a UART configuration that aligns with the
> >   hardware capabilities of MOXA PCI serial boards.
> 
> Everything is fine except one issue. Can we avoid polluting 8250_pci?
> What I would expect as a patch 2 is a separation of 8250_moxa from
> 8250_pci (see examples how it was done in the past: 8250_exar, 8250_lpss,
> 8250_mid, ...) and then updating code there. Can it be achievable?

Agree, I have been putting too much stuff into `8250_pci.c`.
I will send the bug fix patch first, then create a new patch series to
split the code into `8250_moxa.c`.

---
Sincerely,
Crescent Hsieh