mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Joe Perches <joe@perches.com>
To: Mohammad Jamal <md.jamalmohiuddin@gmail.com>
Cc: arnd@arndb.de, gregkh@linuxfoundation.org,
	michael.hennerich@analog.com, linux-kernel@vger.kernel.org
Subject: Re: [PATCH 1/2] misc:ad525x_dpot: Fix missing blank after declaration coding style issue in ad525x_dpot.c
Date: Tue, 16 Dec 2014 10:00:18 -0800	[thread overview]
Message-ID: <1418752818.14140.1.camel@perches.com> (raw)
In-Reply-To: <1418751336-7295-1-git-send-email-md.jamalmohiuddin@gmail.com>

On Tue, 2014-12-16 at 23:05 +0530, Mohammad Jamal wrote:
> This  is a patch to ad525x_dpot.c file that fixes up a missing blank line after declaration warning found by checkpatch.pl issue

Hello Mohammad.

Thanks for the patch.

Here are some small comments:

Please run your patches through scripts/checkpatch.pl
before sending them.

This submission has an overly long commit message line.
Please limit line lengths to ~70 characters.

The "This  is a patch to <foo> that fixes up " is not useful.
The "found by checkpatch.pl issue" is not particularly useful.

A simpler form might have used:

Subject: [PATCH] ad525x_dpot: Add a blank line after declaration

with a commit log of somthing like:

Use a more common kernel style.

Signed-off-by: Mohammad Jamal <md.jamalmohiuddin@gmail.com>

> Signed-off-by: Mohammad Jamal<md.jamalmohiuddin@gmail.com>

Add a space between your name and the open angle bracket
in the email address too please.

Sometimes, it's good to do all the similar types of changes
at the same time instead of multiple patches for trivial
bits.

Using:

$ ./scripts/checkpatch.pl -f --strict --types=line_spacing,braces --fix-inplace drivers/misc/ad525x_dpot.c

produces this:

diff --git a/drivers/misc/ad525x_dpot.c b/drivers/misc/ad525x_dpot.c
index a43053d..ddfe38f 100644
--- a/drivers/misc/ad525x_dpot.c
+++ b/drivers/misc/ad525x_dpot.c
@@ -176,6 +176,7 @@ static s32 dpot_read_i2c(struct dpot_data *dpot, u8 reg)
 {
 	int value;
 	unsigned ctrl = 0;
+
 	switch (dpot->uid) {
 	case DPOT_UID(AD5246_ID):
 	case DPOT_UID(AD5247_ID):
@@ -427,7 +428,6 @@ static ssize_t sysfs_show_reg(struct device *dev,
 			test_bit(DPOT_RDAC_MASK & reg, data->otp_en_mask) ?
 			"enabled" : "disabled");
 
-
 	mutex_lock(&data->update_lock);
 	value = dpot_read(data, reg);
 	mutex_unlock(&data->update_lock);
@@ -763,7 +763,6 @@ int ad_dpot_remove(struct device *dev)
 }
 EXPORT_SYMBOL(ad_dpot_remove);
 
-
 MODULE_AUTHOR("Chris Verges <chrisv@cyberswitching.com>, "
 	      "Michael Hennerich <hennerich@blackfin.uclinux.org>");
 MODULE_DESCRIPTION("Digital potentiometer driver");

This could be submitted with some commit message like:

Subject: [PATCH] ad525x_dpot: Add & remove blank lines

Use a more common kernel style.

Signed-off-by: <you>

cheers, Joe



      parent reply	other threads:[~2014-12-16 18:00 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-12-16 17:35 Mohammad Jamal
2014-12-16 17:36 ` [PATCH 2/2] misc: ad52x_dpot: fix break is not useful after a goto or return " Mohammad Jamal
2014-12-16 18:00 ` Joe Perches [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1418752818.14140.1.camel@perches.com \
    --to=joe@perches.com \
    --cc=arnd@arndb.de \
    --cc=gregkh@linuxfoundation.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=md.jamalmohiuddin@gmail.com \
    --cc=michael.hennerich@analog.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®