Skip to contentSkip to conversation

staging:iio/accel: Fixed checkpatch.pl warnings

PATCH In review Cristina Moraru 2 participants 3 messages Sep 29, 2015 – Oct 1, 2015

Subsystems (3)
lore
Share & tools
lore
#0 lore raw

PATCH 1/1 staging:iio/accel: Fixed checkpatch.pl warnings

'Block comments use a trailing */ on a separate line' Warnings

---
 drivers/staging/iio/accel/lis3l02dq_ring.c | 6 ++++--
 1 file changed, 4 insertions(+), 2 deletions(-)
drivers/staging/iio/accel/lis3l02dq_ring.c +4 -2
index b892f2c..1a0651c 100644
@@ -195,7 +195,8 @@ __lis3l02dq_write_data_ready_config(struct iio_dev *indio_dev, bool state)
 	/* Enable requested */
 	} else if (state && !currentlyset) {
 		/* If not set, enable requested
-		 * first disable all events */
+		 * first disable all events
+		 */
 		ret = lis3l02dq_disable_all_events(indio_dev);
 		if (ret < 0)
 			goto error_ret;
@@ -255,7 +256,8 @@ static int lis3l02dq_trig_try_reen(struct iio_trigger *trig)
 	int i;
 
 	/* If gpio still high (or high again)
-	 * In theory possible we will need to do this several times */
+	 * In theory possible we will need to do this several times
+	 */
 	for (i = 0; i < 5; i++)
 		if (gpio_get_value(st->gpio))
 			lis3l02dq_read_all(indio_dev, NULL);
Signature · 1 line
1.9.1
#1 lore raw

For the subject line, check git log --oneline filename.c to see what is commonly used. For example, I see Staging: iio: accel: or just Staging:
iio:.

For the rest of the subject line, say something more specific to what you did. Checkpatch does a lot of things, and fixing each one should really be a separate patch.

Quoted 1 line · Cristina Moraru

'Block comments use a trailing */ on a separate line' Warnings

The commit message should be in the imperative. In your case, it could be "Move final */ to the next line, in accordance with the suggestion of checkpatch".

julia

Quoted 39 lines
---
 drivers/staging/iio/accel/lis3l02dq_ring.c | 6 ++++--
 1 file changed, 4 insertions(+), 2 deletions(-)
drivers/staging/iio/accel/lis3l02dq_ring.c +4 -2
index b892f2c..1a0651c 100644
@@ -195,7 +195,8 @@ __lis3l02dq_write_data_ready_config(struct iio_dev *indio_dev, bool state)
 	/* Enable requested */
 	} else if (state && !currentlyset) {
 		/* If not set, enable requested
-		 * first disable all events */
+		 * first disable all events
+		 */
 		ret = lis3l02dq_disable_all_events(indio_dev);
 		if (ret < 0)
 			goto error_ret;
@@ -255,7 +256,8 @@ static int lis3l02dq_trig_try_reen(struct iio_trigger *trig)
 	int i;
 
 	/* If gpio still high (or high again)
-	 * In theory possible we will need to do this several times */
+	 * In theory possible we will need to do this several times
+	 */
 	for (i = 0; i < 5; i++)
 		if (gpio_get_value(st->gpio))
 			lis3l02dq_read_all(indio_dev, NULL);
Signature · 8 lines
1.9.1

-- 
You received this message because you are subscribed to the Google Groups "outreachy-kernel" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [email protected].
To post to this group, send email to [email protected].
To view this discussion on the web visit https://groups.google.com/d/msgid/outreachy-kernel/1443562269-42782-1-git-send-email-cristina.moraru09%40gmail.com.
For more options, visit https://groups.google.com/d/optout.
#2 lore raw

I understand. Thank you for the feedback

Cristina

2015-09-30 0:39 GMT+03:00 Julia Lawall <[email protected]>:

Quoted 65 lines

For the subject line, check git log --oneline filename.c to see what is commonly used. For example, I see Staging: iio: accel: or just Staging:
iio:.

For the rest of the subject line, say something more specific to what you did. Checkpatch does a lot of things, and fixing each one should really be a separate patch.

Quoted 1 line · Cristina Moraru

'Block comments use a trailing */ on a separate line' Warnings

The commit message should be in the imperative. In your case, it could be "Move final */ to the next line, in accordance with the suggestion of checkpatch".

julia

Review

Quoted 6 lines
---
 drivers/staging/iio/accel/lis3l02dq_ring.c | 6 ++++--
 1 file changed, 4 insertions(+), 2 deletions(-)
(quoted diff) +0 -0

b/drivers/staging/iio/accel/lis3l02dq_ring.c

drivers/staging/iio/accel/lis3l02dq_ring.c __lis3l02dq_write_data_ready_config(struct iio_dev

Quoted 4 lines

index b892f2c..1a0651c 100644

drivers/staging/iio/accel/lis3l02dq_ring.c +0 -0
@@ -195,7 +195,8 @@ __lis3l02dq_write_data_ready_config(struct iio_dev

*indio_dev, bool state)

drivers/staging/iio/accel/lis3l02dq_ring.c static int lis3l02dq_trig_try_reen(struct

Quoted 10 lines
drivers/staging/iio/accel/lis3l02dq_ring.c +2 -1
      /* Enable requested */
      } else if (state && !currentlyset) {
              /* If not set, enable requested
-              * first disable all events */
+              * first disable all events
+              */
              ret = lis3l02dq_disable_all_events(indio_dev);
              if (ret < 0)
                      goto error_ret;
@@ -255,7 +256,8 @@ static int lis3l02dq_trig_try_reen(struct

iio_trigger *trig)

Quoted 12 lines
drivers/staging/iio/accel/lis3l02dq_ring.c +2 -2
      int i;
 
      /* If gpio still high (or high again)
-      * In theory possible we will need to do this several times */
+      * In theory possible we will need to do this several times
+      */
      for (i = 0; i < 5; i++)
              if (gpio_get_value(st->gpio))
                      lis3l02dq_read_all(indio_dev, NULL);
--

1.9.1

Quoted 2 lines

--
You received this message because you are subscribed to the Google

Groups "outreachy-kernel" group.

Quoted 1 line

To unsubscribe from this group and stop receiving emails from it, send

an email to [email protected].

Quoted 2 lines

To post to this group, send email to [email protected]. To view this discussion on the web visit

https://groups.google.com/d/msgid/outreachy-kernel/1443562269-42782-1-git-send-email-cristina.moraru09%40gmail.com
.

Quoted 2 lines

For more options, visit https://groups.google.com/d/optout.