Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1686603 > unrolled thread

[PATCH] [media] staging/atomisp: fix minor coding style warnings

Started bysmklearn <smklearn@gmail.com>
First post2017-07-13 17:10 +0200
Last post2017-07-17 06:20 +0200
Articles 6 — 4 participants

Back to article view | Back to linux.kernel


Contents

  [PATCH] [media] staging/atomisp: fix minor coding style warnings smklearn <smklearn@gmail.com> - 2017-07-13 17:10 +0200
    Re: [PATCH] [media] staging/atomisp: fix minor coding style warnings Greg KH <gregkh@linuxfoundation.org> - 2017-07-13 17:20 +0200
      [PATCH 1/2] [media] staging/atomisp: fixed trivial coding style warning Shy More <smklearn@gmail.com> - 2017-07-17 01:40 +0200
      [PATCH 2/2] [media] staging/atomisp: fixed trivial coding style issue Shy More <smklearn@gmail.com> - 2017-07-17 01:40 +0200
        Re: [PATCH 2/2] [media] staging/atomisp: fixed trivial coding style  issue Joe Perches <joe@perches.com> - 2017-07-17 02:00 +0200
          [PATCH v2] [media] staging/atomisp: fixed trivial coding style issue Shy More <smklearn@gmail.com> - 2017-07-17 06:20 +0200

#1686603 — [PATCH] [media] staging/atomisp: fix minor coding style warnings

Fromsmklearn <smklearn@gmail.com>
Date2017-07-13 17:10 +0200
Subject[PATCH] [media] staging/atomisp: fix minor coding style warnings
Message-ID<u2NUC-7ez-5@gated-at.bofh.it>
Below were the minor issues flagged by checkpatch.pl:
- WARNING: Block comments use * on subsequent lines
- ERROR: space prohibited after that open parenthesis '('

Signed-off-by: Shy More <smklearn@gmail.com>
---
 .../css2400/runtime/isys/src/ibuf_ctrl_rmgr.c      | 26 +++++++++++-----------
 1 file changed, 13 insertions(+), 13 deletions(-)

diff --git a/drivers/staging/media/atomisp/pci/atomisp2/css2400/runtime/isys/src/ibuf_ctrl_rmgr.c b/drivers/staging/media/atomisp/pci/atomisp2/css2400/runtime/isys/src/ibuf_ctrl_rmgr.c
index 76d9142..856fb6e 100644
--- a/drivers/staging/media/atomisp/pci/atomisp2/css2400/runtime/isys/src/ibuf_ctrl_rmgr.c
+++ b/drivers/staging/media/atomisp/pci/atomisp2/css2400/runtime/isys/src/ibuf_ctrl_rmgr.c
@@ -14,18 +14,18 @@
  */
 #else
 /**
-Support for Intel Camera Imaging ISP subsystem.
-Copyright (c) 2010 - 2015, Intel Corporation.
-
-This program is free software; you can redistribute it and/or modify it
-under the terms and conditions of the GNU General Public License,
-version 2, as published by the Free Software Foundation.
-
-This program is distributed in the hope it will be useful, but WITHOUT
-ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
-FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License for
-more details.
-*/
+ * Support for Intel Camera Imaging ISP subsystem.
+ * Copyright (c) 2010 - 2015, Intel Corporation.
+
+ * This program is free software; you can redistribute it and/or modify it
+ * under the terms and conditions of the GNU General Public License,
+ * version 2, as published by the Free Software Foundation.
+
+ * This program is distributed in the hope it will be useful, but WITHOUT
+ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
+ * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License for
+ * more details.
+ */
 #endif
 
 #include "system_global.h"
@@ -131,7 +131,7 @@ void ia_css_isys_ibuf_rmgr_release(
 	for (i = 0; i < ibuf_rsrc.num_allocated; i++) {
 		handle = getHandle(i);
 		if ((handle->start_addr == *start_addr)
-		    && ( true == handle->active)) {
+		    && (true == handle->active)) {
 			handle->active = false;
 			ibuf_rsrc.num_active--;
 			break;
-- 
1.9.1

[toc] | [next] | [standalone]


#1686616

FromGreg KH <gregkh@linuxfoundation.org>
Date2017-07-13 17:20 +0200
Message-ID<u2O4i-7hE-15@gated-at.bofh.it>
In reply to#1686603
On Thu, Jul 13, 2017 at 08:06:21AM -0700, smklearn wrote:
> Below were the minor issues flagged by checkpatch.pl:
> - WARNING: Block comments use * on subsequent lines
> - ERROR: space prohibited after that open parenthesis '('

Don't do multiple things in the same patch please, this should be
multiple patches.

> Signed-off-by: Shy More <smklearn@gmail.com>

This name doesn't match your "From:" name in the email :(

thanks,

greg k-h

[toc] | [prev] | [next] | [standalone]


#1688562 — [PATCH 1/2] [media] staging/atomisp: fixed trivial coding style warning

FromShy More <smklearn@gmail.com>
Date2017-07-17 01:40 +0200
Subject[PATCH 1/2] [media] staging/atomisp: fixed trivial coding style warning
Message-ID<u41iO-5EP-17@gated-at.bofh.it>
In reply to#1686616
Below was the trivial wanrning flagged by checkpatch.pl
WARNING: Block comments use * on subsequent lines

Signed-off-by: Shy More <smklearn@gmail.com>
---
 .../css2400/runtime/isys/src/ibuf_ctrl_rmgr.c      | 24 +++++++++++-----------
 1 file changed, 12 insertions(+), 12 deletions(-)

diff --git a/drivers/staging/media/atomisp/pci/atomisp2/css2400/runtime/isys/src/ibuf_ctrl_rmgr.c b/drivers/staging/media/atomisp/pci/atomisp2/css2400/runtime/isys/src/ibuf_ctrl_rmgr.c
index 76d9142..bb9f5cd 100644
--- a/drivers/staging/media/atomisp/pci/atomisp2/css2400/runtime/isys/src/ibuf_ctrl_rmgr.c
+++ b/drivers/staging/media/atomisp/pci/atomisp2/css2400/runtime/isys/src/ibuf_ctrl_rmgr.c
@@ -14,18 +14,18 @@
  */
 #else
 /**
-Support for Intel Camera Imaging ISP subsystem.
-Copyright (c) 2010 - 2015, Intel Corporation.
-
-This program is free software; you can redistribute it and/or modify it
-under the terms and conditions of the GNU General Public License,
-version 2, as published by the Free Software Foundation.
-
-This program is distributed in the hope it will be useful, but WITHOUT
-ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
-FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License for
-more details.
-*/
+ * Support for Intel Camera Imaging ISP subsystem.
+ * Copyright (c) 2010 - 2015, Intel Corporation.
+ *
+ * This program is free software; you can redistribute it and/or modify it
+ * under the terms and conditions of the GNU General Public License,
+ * version 2, as published by the Free Software Foundation.
+ *
+ * This program is distributed in the hope it will be useful, but WITHOUT
+ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
+ * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License for
+ * more details.
+ */
 #endif
 
 #include "system_global.h"
-- 
1.9.1

[toc] | [prev] | [next] | [standalone]


#1688567 — [PATCH 2/2] [media] staging/atomisp: fixed trivial coding style issue

FromShy More <smklearn@gmail.com>
Date2017-07-17 01:40 +0200
Subject[PATCH 2/2] [media] staging/atomisp: fixed trivial coding style issue
Message-ID<u41iP-5EP-43@gated-at.bofh.it>
In reply to#1686616
Below was the trival error flagged by checkpatch.pl:
ERROR: space prohibited after that open parenthesis '('

Signed-off-by: Shy More <smklearn@gmail.com>
---
 .../atomisp/pci/atomisp2/css2400/runtime/isys/src/ibuf_ctrl_rmgr.c      | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/staging/media/atomisp/pci/atomisp2/css2400/runtime/isys/src/ibuf_ctrl_rmgr.c b/drivers/staging/media/atomisp/pci/atomisp2/css2400/runtime/isys/src/ibuf_ctrl_rmgr.c
index bb9f5cd..99edb81 100644
--- a/drivers/staging/media/atomisp/pci/atomisp2/css2400/runtime/isys/src/ibuf_ctrl_rmgr.c
+++ b/drivers/staging/media/atomisp/pci/atomisp2/css2400/runtime/isys/src/ibuf_ctrl_rmgr.c
@@ -131,7 +131,7 @@ void ia_css_isys_ibuf_rmgr_release(
 	for (i = 0; i < ibuf_rsrc.num_allocated; i++) {
 		handle = getHandle(i);
 		if ((handle->start_addr == *start_addr)
-		    && ( true == handle->active)) {
+		    && (true == handle->active)) {
 			handle->active = false;
 			ibuf_rsrc.num_active--;
 			break;
-- 
1.9.1

[toc] | [prev] | [next] | [standalone]


#1688568 — Re: [PATCH 2/2] [media] staging/atomisp: fixed trivial coding style issue

FromJoe Perches <joe@perches.com>
Date2017-07-17 02:00 +0200
SubjectRe: [PATCH 2/2] [media] staging/atomisp: fixed trivial coding style issue
Message-ID<u41C9-5Ly-3@gated-at.bofh.it>
In reply to#1688567
On Sun, 2017-07-16 at 16:38 -0700, Shy More wrote:
> Below was the trival error flagged by checkpatch.pl:
> ERROR: space prohibited after that open parenthesis '('
[]
> diff --git a/drivers/staging/media/atomisp/pci/atomisp2/css2400/runtime/isys/src/ibuf_ctrl_rmgr.c b/drivers/staging/media/atomisp/pci/atomisp2/css2400/runtime/isys/src/ibuf_ctrl_rmgr.c
[]
> @@ -131,7 +131,7 @@ void ia_css_isys_ibuf_rmgr_release(
>  	for (i = 0; i < ibuf_rsrc.num_allocated; i++) {
>  		handle = getHandle(i);
>  		if ((handle->start_addr == *start_addr)
> -		    && ( true == handle->active)) {
> +		    && (true == handle->active)) {
>  			handle->active = false;
>  			ibuf_rsrc.num_active--;
>  			break;

Better would have been to remove the comparison to true

		if (handle->start_addr == *start_addr && handle->active)

but this would probably read better and perhaps be
marginally faster on some processors if written like:

		if (handle->active && handle->start_addr == *start_addr)

[toc] | [prev] | [next] | [standalone]


#1688638 — [PATCH v2] [media] staging/atomisp: fixed trivial coding style issue

FromShy More <smklearn@gmail.com>
Date2017-07-17 06:20 +0200
Subject[PATCH v2] [media] staging/atomisp: fixed trivial coding style issue
Message-ID<u45FL-6o-7@gated-at.bofh.it>
In reply to#1688568
Below was the trival error flagged by checkpatch.pl:
ERROR: space prohibited after that open parenthesis '('

Signed-off-by: Shy More <smklearn@gmail.com>

---
changes in v2:
- made the suggested corrections
---
 .../atomisp/pci/atomisp2/css2400/runtime/isys/src/ibuf_ctrl_rmgr.c     | 3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)

diff --git a/drivers/staging/media/atomisp/pci/atomisp2/css2400/runtime/isys/src/ibuf_ctrl_rmgr.c b/drivers/staging/media/atomisp/pci/atomisp2/css2400/runtime/isys/src/ibuf_ctrl_rmgr.c
index bb9f5cd..faef976 100644
--- a/drivers/staging/media/atomisp/pci/atomisp2/css2400/runtime/isys/src/ibuf_ctrl_rmgr.c
+++ b/drivers/staging/media/atomisp/pci/atomisp2/css2400/runtime/isys/src/ibuf_ctrl_rmgr.c
@@ -130,8 +130,7 @@ void ia_css_isys_ibuf_rmgr_release(
 
 	for (i = 0; i < ibuf_rsrc.num_allocated; i++) {
 		handle = getHandle(i);
-		if ((handle->start_addr == *start_addr)
-		    && ( true == handle->active)) {
+		if (handle->active && handle->start_addr == *start_addr) {
 			handle->active = false;
 			ibuf_rsrc.num_active--;
 			break;
-- 
1.9.1

[toc] | [prev] | [standalone]


Back to top | Article view | linux.kernel


csiph-web