Re: [PATCH] staging: dgnc: Let line have less 80 char

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Sean,

On Thu, Sep 1, 2016 at 5:58 PM, Sean <sean@sean.taipei> wrote:
> This patch fix a minor checkpath warming:
>
> "WARNING: line over 80 characters"

Please don't do patches just because of the sake of checkpatch.pl.
Especially since "line over 80 characters" is only a warning, not an error.
Your changelog fails to explain why your change made the driver better.

> Signed-off-by: Sean Wei <sean@sean.taipei>
> ---
>  drivers/staging/dgnc/dgnc_neo.c | 116 ++++++++++++++++++++++++++++------------
>  1 file changed, 82 insertions(+), 34 deletions(-)
>
> diff --git a/drivers/staging/dgnc/dgnc_neo.c b/drivers/staging/dgnc/dgnc_neo.c
> index ba57e95..37fb556 100644
> --- a/drivers/staging/dgnc/dgnc_neo.c
> +++ b/drivers/staging/dgnc/dgnc_neo.c
> @@ -107,7 +107,7 @@ static inline void neo_set_cts_flow_control(struct channel_t *ch)
>         /* Turn off auto Xon flow control */
>         efr &= ~UART_17158_EFR_IXON;
>
> -       /* Why? Becuz Exar's spec says we have to zero it out before setting it */
> +       /* Becuz Exar's spec says we have to zero it out before setting it */

Okay, removing "Why?" silents checkpatch.pl, but the comment is still
crap/useless.
Same for the next few hunks.

[...]

> -               /* Only use the TXPrint baud rate if the terminal unit is NOT open */
> +               /*
> +                * Only use the TXPrint baud rate
> +                * if the terminal unit is NOT open
> +                */

Adding random new lines make the comment not better.

I'm not saying checkpatch.pl is completely useless, stuff in drivers/staging/
often needs to be adopted to the kernel coding style.
But please don't follow it blindly and try to understand what you can improve.

-- 
Thanks,
//richard
_______________________________________________
devel mailing list
devel@xxxxxxxxxxxxxxxxxxxxxx
http://driverdev.linuxdriverproject.org/mailman/listinfo/driverdev-devel



[Index of Archives]     [Linux Driver Backports]     [DMA Engine]     [Linux GPIO]     [Linux SPI]     [Video for Linux]     [Linux USB Devel]     [Linux Coverity]     [Linux Audio Users]     [Linux Kernel]     [Linux SCSI]     [Yosemite Backpacking]
  Powered by Linux