Re: [PATCH v2 1/6] driver: usb: serial: mos7840: fix style warnings

From: Johan Hovold
Date: Tue Feb 11 2025 - 04:20:31 EST


On Fri, Oct 25, 2024 at 02:17:08PM +0800, Tony Chung wrote:
> fix "no space before tabs" coding style warnings.

Perhaps rephrase as:

Replace spaces before tabs, which some editors and pagers
highlight as errors.

Getting rid of those red higlights I see in vim should be motivation
enough here (again, as you're doing other changes to the driver).

> Signed-off-by: Tony Chung <tony467913@xxxxxxxxx>
> ---
> drivers/usb/serial/mos7840.c | 14 +++++++-------
> 1 file changed, 7 insertions(+), 7 deletions(-)
>
> diff --git a/drivers/usb/serial/mos7840.c b/drivers/usb/serial/mos7840.c
> index ca3da79af..dcaed0f26 100644
> --- a/drivers/usb/serial/mos7840.c
> +++ b/drivers/usb/serial/mos7840.c
> @@ -220,7 +220,7 @@ struct moschip_port {
>
> /*
> * mos7840_set_reg_sync
> - * To set the Control register by calling usb_fill_control_urb function
> + * To set the Control register by calling usb_fill_control_urb function
> * by passing usb_sndctrlpipe function as parameter.
> */
>
> @@ -238,7 +238,7 @@ static int mos7840_set_reg_sync(struct usb_serial_port *port, __u16 reg,
>
> /*
> * mos7840_get_reg_sync
> - * To set the Uart register by calling usb_fill_control_urb function by
> + * To set the Uart register by calling usb_fill_control_urb function by
> * passing usb_rcvctrlpipe function as parameter.
> */
>
> @@ -1356,11 +1356,11 @@ static void mos7840_set_termios(struct tty_struct *tty,
> * mos7840_get_lsr_info - get line status register info
> *
> * Purpose: Let user call ioctl() to get info when the UART physically
> - * is emptied. On bus types like RS485, the transmitter must
> - * release the bus after transmitting. This must be done when
> - * the transmit shift register is empty, not be done when the
> - * transmit holding register is empty. This functionality
> - * allows an RS485 driver to be written in user space.
> + * is emptied. On bus types like RS485, the transmitter must
> + * release the bus after transmitting. This must be done when
> + * the transmit shift register is empty, not be done when the
> + * transmit holding register is empty. This functionality
> + * allows an RS485 driver to be written in user space.

But perhaps you should keep the indentation here (all lines are aligned
under "Let") as the author intended.

Johan