[PATCH 1/5] KPC2000: kpc2000_spi.c: Fix style issues (line length)

Greg KH gregkh at linuxfoundation.org
Fri Oct 11 06:32:19 UTC 2019


On Thu, Oct 10, 2019 at 10:51:51PM -0700, Chandra Annamaneni wrote:
> Resoved: "WARNING: line over 80 characters" from checkpatch.pl

Please put "staging:" in your subject line, makes it easier to sort and
handle.  It should look something like:
	staging: kpc2000_spi: fix line length issues

Looks a lot cleaner, right?

> 
> Signed-off-by: Chandra Annamaneni <chandra627 at gmail.com>
> ---
>  drivers/staging/kpc2000/kpc2000_spi.c | 20 ++++++++++----------
>  1 file changed, 10 insertions(+), 10 deletions(-)
> 
> diff --git a/drivers/staging/kpc2000/kpc2000_spi.c b/drivers/staging/kpc2000/kpc2000_spi.c
> index 3be33c450cab..81d79b116ce0 100644
> --- a/drivers/staging/kpc2000/kpc2000_spi.c
> +++ b/drivers/staging/kpc2000/kpc2000_spi.c
> @@ -30,19 +30,19 @@
>  #include "kpc.h"
>  
>  static struct mtd_partition p2kr0_spi0_parts[] = {
> -	{ .name = "SLOT_0",	.size = 7798784,		.offset = 0,                },
> -	{ .name = "SLOT_1",	.size = 7798784,		.offset = MTDPART_OFS_NXTBLK},
> -	{ .name = "SLOT_2",	.size = 7798784,		.offset = MTDPART_OFS_NXTBLK},
> -	{ .name = "SLOT_3",	.size = 7798784,		.offset = MTDPART_OFS_NXTBLK},
> -	{ .name = "CS0_EXTRA",	.size = MTDPART_SIZ_FULL,	.offset = MTDPART_OFS_NXTBLK},
> +	{ .name = "SLOT_0",  .size = 7798784,  .offset = 0,                },
> +	{ .name = "SLOT_1",  .size = 7798784,  .offset = MTDPART_OFS_NXTBLK},
> +	{ .name = "SLOT_2",  .size = 7798784,  .offset = MTDPART_OFS_NXTBLK},
> +	{ .name = "SLOT_3",  .size = 7798784,  .offset = MTDPART_OFS_NXTBLK},
> +	{ .name = "CS0_EXTRA",  .size = MTDPART_SIZ_FULL,  .offset = MTDPART_OFS_NXTBLK},

Why did you pick 2 spaces here as a random choice of padding?  That's
very odd, please don't.

Either leave this alone (as it lines everything up nicely), or only use
one space.  I would suggest just leaving it alone.

thanks,

greg k-h


More information about the devel mailing list