Re: [PATCH v5 08/14] serial: 8250_mxpcie: speed up TX using memory-mapped FIFO window
Andy Shevchenko <[email protected]> Sun, 2 Aug 2026 12:10:35 +0300
| Newsgroups | gmane.linux.serial,gmane.linux.kernel |
|---|---|
| Message-ID | <CAHp75VdL71oE-E85fOLbz36bhs3EKg1iL_vtNP+TQzek5PNqnQ@mail.gmail.com> |
On Fri, Jul 31, 2026 at 10:49=E2=80=AFAM Crescent Hsieh <[email protected]> wrote: > > The MUEx50 UART provides a memory-mapped TX FIFO data window along with > a TX FIFO level counter. > > Fill the TX FIFO in bulk via the MMIO FIFO window based on available > FIFO space, using uart_port_tx_limited() for the common serial-core TX > handling. ... > +static void mxpcie8250_tx_chars(struct uart_8250_port *up) > +{ > + struct uart_port *port =3D &up->port; > + unsigned int offset =3D 0; > + unsigned char c; > + > + uart_port_tx_limited(port, c, port->fifosize - serial_in(up, MOXA= _PUART_TX_FIFO_CNT), > + true, > + serial_out(up, MOXA_PUART_TX_FIFO_MEM + offs= et++, c), > + ({})); > +} At least three randomly chosen drivers use the empty tx_done, perhaps it's time to have a helper that embeds this ugly piece in it and hides from the driver? --=20 With Best Regards, Andy Shevchenko