linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH 00/29] treewide: Convert comma separated statements
@ 2020-08-25  4:55 Joe Perches
  2020-08-25  4:55 ` [PATCH 01/29] coding-style.rst: Avoid comma statements Joe Perches
                   ` (29 more replies)
  0 siblings, 30 replies; 80+ messages in thread
From: Joe Perches @ 2020-08-25  4:55 UTC (permalink / raw)
  To: Jiri Kosina, oprofile-list, linux-ide, drbd-dev, linux-media,
	dri-devel, linaro-mm-sig, intel-gfx, linux-hwmon, linux-input,
	linux-bcache, netdev, linuxppc-dev, linux-arm-kernel,
	linux-fsdevel, reiserfs-devel, linux-nfs
  Cc: linux-doc, linux-kernel, linux-alpha, linux-ia64, sparclinux,
	linux-block, linux-mtd, linux-s390, linux-scsi, devel,
	linux-fbdev, linux-pm, linux-kselftest

There are many comma separated statements in the kernel.
See:https://lore.kernel.org/lkml/alpine.DEB.2.22.394.2008201856110.2524@hadrien/

Convert the comma separated statements that are in if/do/while blocks
to use braces and semicolons.

Many comma separated statements still exist but those are changes for
another day.

Joe Perches (29):
  coding-style.rst: Avoid comma statements
  alpha: Avoid comma separated statements
  ia64: Avoid comma separated statements
  sparc: Avoid comma separated statements
  ata: Avoid comma separated statements
  drbd: Avoid comma separated statements
  lp: Avoid comma separated statements
  dma-buf: Avoid comma separated statements
  drm/gma500: Avoid comma separated statements
  drm/i915: Avoid comma separated statements
  hwmon: (scmi-hwmon): Avoid comma separated statements
  Input: MT - Avoid comma separated statements
  bcache: Avoid comma separated statements
  media: Avoid comma separated statements
  mtd: Avoid comma separated statements
  8390: Avoid comma separated statements
  fs_enet: Avoid comma separated statements
  wan: sbni: Avoid comma separated statements
  s390/tty3270: Avoid comma separated statements
  scai/arm: Avoid comma separated statements
  media: atomisp: Avoid comma separated statements
  video: fbdev: Avoid comma separated statements
  fuse: Avoid comma separated statements
  reiserfs: Avoid comma separated statements
  lib/zlib: Avoid comma separated statements
  lib: zstd: Avoid comma separated statements
  ipv6: fib6: Avoid comma separated statements
  sunrpc: Avoid comma separated statements
  tools: Avoid comma separated statements

 Documentation/process/coding-style.rst        |  17 +
 arch/alpha/kernel/pci_iommu.c                 |   8 +-
 arch/alpha/oprofile/op_model_ev4.c            |  22 +-
 arch/alpha/oprofile/op_model_ev5.c            |   8 +-
 arch/ia64/kernel/smpboot.c                    |   7 +-
 arch/sparc/kernel/smp_64.c                    |   7 +-
 drivers/ata/pata_icside.c                     |  21 +-
 drivers/block/drbd/drbd_receiver.c            |   6 +-
 drivers/char/lp.c                             |   6 +-
 drivers/dma-buf/st-dma-fence.c                |   7 +-
 drivers/gpu/drm/gma500/mdfld_intel_display.c  |  44 ++-
 drivers/gpu/drm/i915/gt/gen8_ppgtt.c          |   8 +-
 drivers/gpu/drm/i915/gt/intel_gt_requests.c   |   6 +-
 .../gpu/drm/i915/gt/selftest_workarounds.c    |   6 +-
 drivers/gpu/drm/i915/intel_runtime_pm.c       |   6 +-
 drivers/hwmon/scmi-hwmon.c                    |   6 +-
 drivers/input/input-mt.c                      |  11 +-
 drivers/md/bcache/bset.c                      |  12 +-
 drivers/md/bcache/sysfs.c                     |   6 +-
 drivers/media/i2c/msp3400-kthreads.c          |  12 +-
 drivers/media/pci/bt8xx/bttv-cards.c          |   6 +-
 drivers/media/pci/saa7134/saa7134-video.c     |   7 +-
 drivers/mtd/devices/lart.c                    |  10 +-
 drivers/net/ethernet/8390/axnet_cs.c          |  19 +-
 drivers/net/ethernet/8390/lib8390.c           |  14 +-
 drivers/net/ethernet/8390/pcnet_cs.c          |   6 +-
 .../ethernet/freescale/fs_enet/fs_enet-main.c |  11 +-
 drivers/net/wan/sbni.c                        | 101 +++---
 drivers/s390/char/tty3270.c                   |   6 +-
 drivers/scsi/arm/cumana_2.c                   |  19 +-
 drivers/scsi/arm/eesox.c                      |   9 +-
 drivers/scsi/arm/powertec.c                   |   9 +-
 .../media/atomisp/pci/atomisp_subdev.c        |   6 +-
 drivers/video/fbdev/tgafb.c                   |  12 +-
 fs/fuse/dir.c                                 |  24 +-
 fs/reiserfs/fix_node.c                        |  36 ++-
 lib/zlib_deflate/deftree.c                    |  49 ++-
 lib/zstd/compress.c                           | 120 ++++---
 lib/zstd/fse_compress.c                       |  24 +-
 lib/zstd/huf_compress.c                       |   6 +-
 net/ipv6/ip6_fib.c                            |  12 +-
 net/sunrpc/sysctl.c                           |   6 +-
 tools/lib/subcmd/help.c                       |  10 +-
 tools/power/cpupower/utils/cpufreq-set.c      |  14 +-
 tools/testing/selftests/vm/gup_benchmark.c    |  18 +-
 tools/testing/selftests/vm/userfaultfd.c      | 296 +++++++++++-------
 46 files changed, 694 insertions(+), 382 deletions(-)

-- 
2.26.0


^ permalink raw reply	[flat|nested] 80+ messages in thread

* [PATCH 01/29] coding-style.rst: Avoid comma statements
  2020-08-25  4:55 [PATCH 00/29] treewide: Convert comma separated statements Joe Perches
@ 2020-08-25  4:55 ` Joe Perches
  2021-01-30 18:53   ` Joe Perches
  2020-08-25  4:55 ` [PATCH 02/29] alpha: Avoid comma separated statements Joe Perches
                   ` (28 subsequent siblings)
  29 siblings, 1 reply; 80+ messages in thread
From: Joe Perches @ 2020-08-25  4:55 UTC (permalink / raw)
  To: Jiri Kosina, linux-kernel; +Cc: Jonathan Corbet, linux-doc

Commas are not how statements are terminated.
Always use semicolons and braces if necessary.

Signed-off-by: Joe Perches <joe@perches.com>
---
 Documentation/process/coding-style.rst | 17 +++++++++++++++++
 1 file changed, 17 insertions(+)

diff --git a/Documentation/process/coding-style.rst b/Documentation/process/coding-style.rst
index 98227226c4e5..a1e061149e0d 100644
--- a/Documentation/process/coding-style.rst
+++ b/Documentation/process/coding-style.rst
@@ -69,9 +69,26 @@ something to hide:
 	if (condition) do_this;
 	  do_something_everytime;
 
+Don't use commas to avoid using braces:
+
+.. code-block:: c
+
+	if (condition)
+		do_this(), do_that();
+
+Always uses braces for multiple statements:
+
+.. code-block:: c
+
+	if (condition) {
+		do_this();
+		do_that();
+	}
+
 Don't put multiple assignments on a single line either.  Kernel coding style
 is super simple.  Avoid tricky expressions.
 
+
 Outside of comments, documentation and except in Kconfig, spaces are never
 used for indentation, and the above example is deliberately broken.
 
-- 
2.26.0


^ permalink raw reply related	[flat|nested] 80+ messages in thread

* [PATCH 02/29] alpha: Avoid comma separated statements
  2020-08-25  4:55 [PATCH 00/29] treewide: Convert comma separated statements Joe Perches
  2020-08-25  4:55 ` [PATCH 01/29] coding-style.rst: Avoid comma statements Joe Perches
@ 2020-08-25  4:55 ` Joe Perches
  2020-08-25  6:37   ` Robert Richter
  2021-01-30 18:54   ` Joe Perches
  2020-08-25  4:56 ` [PATCH 03/29] ia64: " Joe Perches
                   ` (27 subsequent siblings)
  29 siblings, 2 replies; 80+ messages in thread
From: Joe Perches @ 2020-08-25  4:55 UTC (permalink / raw)
  To: Jiri Kosina, Robert Richter
  Cc: Richard Henderson, Ivan Kokshaysky, Matt Turner, linux-alpha,
	linux-kernel, oprofile-list

Use semicolons and braces.

Signed-off-by: Joe Perches <joe@perches.com>
---
 arch/alpha/kernel/pci_iommu.c      |  8 +++++---
 arch/alpha/oprofile/op_model_ev4.c | 22 ++++++++++++++--------
 arch/alpha/oprofile/op_model_ev5.c |  8 +++++---
 3 files changed, 24 insertions(+), 14 deletions(-)

diff --git a/arch/alpha/kernel/pci_iommu.c b/arch/alpha/kernel/pci_iommu.c
index 81037907268d..b8af7ad6c607 100644
--- a/arch/alpha/kernel/pci_iommu.c
+++ b/arch/alpha/kernel/pci_iommu.c
@@ -161,10 +161,12 @@ iommu_arena_find_pages(struct device *dev, struct pci_iommu_arena *arena,
 			goto again;
 		}
 
-		if (ptes[p+i])
-			p = ALIGN(p + i + 1, mask + 1), i = 0;
-		else
+		if (ptes[p+i]) {
+			p = ALIGN(p + i + 1, mask + 1);
+			i = 0;
+		} else {
 			i = i + 1;
+		}
 	}
 
 	if (i < n) {
diff --git a/arch/alpha/oprofile/op_model_ev4.c b/arch/alpha/oprofile/op_model_ev4.c
index 086a0d5445c5..004f80a4291f 100644
--- a/arch/alpha/oprofile/op_model_ev4.c
+++ b/arch/alpha/oprofile/op_model_ev4.c
@@ -46,18 +46,24 @@ ev4_reg_setup(struct op_register_config *reg,
 	   map it onto one of the possible values, and write it back.  */
 
 	count = ctr[0].count;
-	if (count <= 4096)
-		count = 4096, hilo = 1;
-	else
-		count = 65536, hilo = 0;
+	if (count <= 4096) {
+		count = 4096;
+		hilo = 1;
+	} else {
+		count = 65536;
+		hilo = 0;
+	}
 	ctr[0].count = count;
 	ctl |= (ctr[0].enabled && hilo) << 3;
 
 	count = ctr[1].count;
-	if (count <= 256)
-		count = 256, hilo = 1;
-	else
-		count = 4096, hilo = 0;
+	if (count <= 256) {
+		count = 256;
+		hilo = 1;
+	} else {
+		count = 4096;
+		hilo = 0;
+	}
 	ctr[1].count = count;
 	ctl |= (ctr[1].enabled && hilo);
 
diff --git a/arch/alpha/oprofile/op_model_ev5.c b/arch/alpha/oprofile/op_model_ev5.c
index c300f5ef3482..6f52244e1181 100644
--- a/arch/alpha/oprofile/op_model_ev5.c
+++ b/arch/alpha/oprofile/op_model_ev5.c
@@ -92,9 +92,11 @@ common_reg_setup(struct op_register_config *reg,
 		if (!ctr[i].enabled)
 			continue;
 
-		if (count <= 256)
-			count = 256, hilo = 3, max = 256;
-		else {
+		if (count <= 256) {
+			max = 256;
+			hilo = 3;
+			count = 256;
+		} else {
 			max = (i == 2 ? 16384 : 65536);
 			hilo = 2;
 			if (count > max)
-- 
2.26.0


^ permalink raw reply related	[flat|nested] 80+ messages in thread

* [PATCH 03/29] ia64: Avoid comma separated statements
  2020-08-25  4:55 [PATCH 00/29] treewide: Convert comma separated statements Joe Perches
  2020-08-25  4:55 ` [PATCH 01/29] coding-style.rst: Avoid comma statements Joe Perches
  2020-08-25  4:55 ` [PATCH 02/29] alpha: Avoid comma separated statements Joe Perches
@ 2020-08-25  4:56 ` Joe Perches
  2021-01-30 18:55   ` Joe Perches
  2020-08-25  4:56 ` [PATCH 04/29] sparc: " Joe Perches
                   ` (26 subsequent siblings)
  29 siblings, 1 reply; 80+ messages in thread
From: Joe Perches @ 2020-08-25  4:56 UTC (permalink / raw)
  To: Jiri Kosina, linux-kernel; +Cc: Tony Luck, Fenghua Yu, linux-ia64

Use semicolons and braces.

Signed-off-by: Joe Perches <joe@perches.com>
---
 arch/ia64/kernel/smpboot.c | 7 +++++--
 1 file changed, 5 insertions(+), 2 deletions(-)

diff --git a/arch/ia64/kernel/smpboot.c b/arch/ia64/kernel/smpboot.c
index c29c600d7967..3311b9d21319 100644
--- a/arch/ia64/kernel/smpboot.c
+++ b/arch/ia64/kernel/smpboot.c
@@ -224,8 +224,11 @@ get_delta (long *rt, long *master)
 		go[SLAVE] = 0;
 		t1 = ia64_get_itc();
 
-		if (t1 - t0 < best_t1 - best_t0)
-			best_t0 = t0, best_t1 = t1, best_tm = tm;
+		if (t1 - t0 < best_t1 - best_t0) {
+			best_t0 = t0;
+			best_t1 = t1;
+			best_tm = tm;
+		}
 	}
 
 	*rt = best_t1 - best_t0;
-- 
2.26.0


^ permalink raw reply related	[flat|nested] 80+ messages in thread

* [PATCH 04/29] sparc: Avoid comma separated statements
  2020-08-25  4:55 [PATCH 00/29] treewide: Convert comma separated statements Joe Perches
                   ` (2 preceding siblings ...)
  2020-08-25  4:56 ` [PATCH 03/29] ia64: " Joe Perches
@ 2020-08-25  4:56 ` Joe Perches
  2021-01-30 18:56   ` Joe Perches
  2020-08-25  4:56 ` [PATCH 05/29] ata: " Joe Perches
                   ` (25 subsequent siblings)
  29 siblings, 1 reply; 80+ messages in thread
From: Joe Perches @ 2020-08-25  4:56 UTC (permalink / raw)
  To: Jiri Kosina, linux-kernel; +Cc: David S. Miller, sparclinux

Use semicolons and braces.

Signed-off-by: Joe Perches <joe@perches.com>
---
 arch/sparc/kernel/smp_64.c | 7 +++++--
 1 file changed, 5 insertions(+), 2 deletions(-)

diff --git a/arch/sparc/kernel/smp_64.c b/arch/sparc/kernel/smp_64.c
index e286e2badc8a..28c11f7871cd 100644
--- a/arch/sparc/kernel/smp_64.c
+++ b/arch/sparc/kernel/smp_64.c
@@ -186,8 +186,11 @@ static inline long get_delta (long *rt, long *master)
 		wmb();
 		t1 = tick_ops->get_tick();
 
-		if (t1 - t0 < best_t1 - best_t0)
-			best_t0 = t0, best_t1 = t1, best_tm = tm;
+		if (t1 - t0 < best_t1 - best_t0) {
+			best_t0 = t0;
+			best_t1 = t1;
+			best_tm = tm;
+		}
 	}
 
 	*rt = best_t1 - best_t0;
-- 
2.26.0


^ permalink raw reply related	[flat|nested] 80+ messages in thread

* [PATCH 05/29] ata: Avoid comma separated statements
  2020-08-25  4:55 [PATCH 00/29] treewide: Convert comma separated statements Joe Perches
                   ` (3 preceding siblings ...)
  2020-08-25  4:56 ` [PATCH 04/29] sparc: " Joe Perches
@ 2020-08-25  4:56 ` Joe Perches
  2021-01-30 18:56   ` Joe Perches
  2020-08-25  4:56 ` [PATCH 06/29] drbd: " Joe Perches
                   ` (24 subsequent siblings)
  29 siblings, 1 reply; 80+ messages in thread
From: Joe Perches @ 2020-08-25  4:56 UTC (permalink / raw)
  To: Jiri Kosina, Bartlomiej Zolnierkiewicz, Jens Axboe
  Cc: linux-ide, linux-kernel

Use semicolons and braces.

Signed-off-by: Joe Perches <joe@perches.com>
---
 drivers/ata/pata_icside.c | 21 +++++++++++++--------
 1 file changed, 13 insertions(+), 8 deletions(-)

diff --git a/drivers/ata/pata_icside.c b/drivers/ata/pata_icside.c
index 08543aeb0093..498383cb6e29 100644
--- a/drivers/ata/pata_icside.c
+++ b/drivers/ata/pata_icside.c
@@ -202,14 +202,19 @@ static void pata_icside_set_dmamode(struct ata_port *ap, struct ata_device *adev
 	 * Choose the IOMD cycle timing which ensure that the interface
 	 * satisfies the measured active, recovery and cycle times.
 	 */
-	if (t.active <= 50 && t.recover <= 375 && t.cycle <= 425)
-		iomd_type = 'D', cycle = 187;
-	else if (t.active <= 125 && t.recover <= 375 && t.cycle <= 500)
-		iomd_type = 'C', cycle = 250;
-	else if (t.active <= 200 && t.recover <= 550 && t.cycle <= 750)
-		iomd_type = 'B', cycle = 437;
-	else
-		iomd_type = 'A', cycle = 562;
+	if (t.active <= 50 && t.recover <= 375 && t.cycle <= 425) {
+		iomd_type = 'D';
+		cycle = 187;
+	} else if (t.active <= 125 && t.recover <= 375 && t.cycle <= 500) {
+		iomd_type = 'C';
+		cycle = 250;
+	} else if (t.active <= 200 && t.recover <= 550 && t.cycle <= 750) {
+		iomd_type = 'B';
+		cycle = 437;
+	} else {
+		iomd_type = 'A';
+		cycle = 562;
+	}
 
 	ata_dev_info(adev, "timings: act %dns rec %dns cyc %dns (%c)\n",
 		     t.active, t.recover, t.cycle, iomd_type);
-- 
2.26.0


^ permalink raw reply related	[flat|nested] 80+ messages in thread

* [PATCH 06/29] drbd: Avoid comma separated statements
  2020-08-25  4:55 [PATCH 00/29] treewide: Convert comma separated statements Joe Perches
                   ` (4 preceding siblings ...)
  2020-08-25  4:56 ` [PATCH 05/29] ata: " Joe Perches
@ 2020-08-25  4:56 ` Joe Perches
  2021-01-30 18:57   ` Joe Perches
  2020-08-25  4:56 ` [PATCH 07/29] lp: " Joe Perches
                   ` (23 subsequent siblings)
  29 siblings, 1 reply; 80+ messages in thread
From: Joe Perches @ 2020-08-25  4:56 UTC (permalink / raw)
  To: Jiri Kosina, Philipp Reisner, Lars Ellenberg
  Cc: Jens Axboe, drbd-dev, linux-block, linux-kernel

Use semicolons and braces.

Signed-off-by: Joe Perches <joe@perches.com>
---
 drivers/block/drbd/drbd_receiver.c | 6 ++++--
 1 file changed, 4 insertions(+), 2 deletions(-)

diff --git a/drivers/block/drbd/drbd_receiver.c b/drivers/block/drbd/drbd_receiver.c
index 422363daa618..87f732fb5456 100644
--- a/drivers/block/drbd/drbd_receiver.c
+++ b/drivers/block/drbd/drbd_receiver.c
@@ -111,8 +111,10 @@ static struct page *page_chain_tail(struct page *page, int *len)
 {
 	struct page *tmp;
 	int i = 1;
-	while ((tmp = page_chain_next(page)))
-		++i, page = tmp;
+	while ((tmp = page_chain_next(page))) {
+		++i;
+		page = tmp;
+	}
 	if (len)
 		*len = i;
 	return page;
-- 
2.26.0


^ permalink raw reply related	[flat|nested] 80+ messages in thread

* [PATCH 07/29] lp: Avoid comma separated statements
  2020-08-25  4:55 [PATCH 00/29] treewide: Convert comma separated statements Joe Perches
                   ` (5 preceding siblings ...)
  2020-08-25  4:56 ` [PATCH 06/29] drbd: " Joe Perches
@ 2020-08-25  4:56 ` Joe Perches
  2020-08-25  4:56 ` [PATCH 08/29] dma-buf: " Joe Perches
                   ` (22 subsequent siblings)
  29 siblings, 0 replies; 80+ messages in thread
From: Joe Perches @ 2020-08-25  4:56 UTC (permalink / raw)
  To: Jiri Kosina, Arnd Bergmann, Greg Kroah-Hartman; +Cc: linux-kernel

Use semicolons and braces.

Signed-off-by: Joe Perches <joe@perches.com>
---
 drivers/char/lp.c | 6 ++++--
 1 file changed, 4 insertions(+), 2 deletions(-)

diff --git a/drivers/char/lp.c b/drivers/char/lp.c
index 45932f05fd67..0ec73917d8dd 100644
--- a/drivers/char/lp.c
+++ b/drivers/char/lp.c
@@ -853,8 +853,10 @@ static void lp_console_write(struct console *co, const char *s,
 			count--;
 			do {
 				written = parport_write(port, crlf, i);
-				if (written > 0)
-					i -= written, crlf += written;
+				if (written > 0) {
+					i -= written;
+					crlf += written;
+				}
 			} while (i > 0 && (CONSOLE_LP_STRICT || written > 0));
 		}
 	} while (count > 0 && (CONSOLE_LP_STRICT || written > 0));
-- 
2.26.0


^ permalink raw reply related	[flat|nested] 80+ messages in thread

* [PATCH 08/29] dma-buf: Avoid comma separated statements
  2020-08-25  4:55 [PATCH 00/29] treewide: Convert comma separated statements Joe Perches
                   ` (6 preceding siblings ...)
  2020-08-25  4:56 ` [PATCH 07/29] lp: " Joe Perches
@ 2020-08-25  4:56 ` Joe Perches
  2020-08-26 15:08   ` Christian König
                     ` (2 more replies)
  2020-08-25  4:56 ` [PATCH 09/29] drm/gma500: " Joe Perches
                   ` (21 subsequent siblings)
  29 siblings, 3 replies; 80+ messages in thread
From: Joe Perches @ 2020-08-25  4:56 UTC (permalink / raw)
  To: Jiri Kosina, Sumit Semwal, Christian König
  Cc: linux-media, dri-devel, linaro-mm-sig, linux-kernel

Use semicolons and braces.

Signed-off-by: Joe Perches <joe@perches.com>
---
 drivers/dma-buf/st-dma-fence.c | 7 +++++--
 1 file changed, 5 insertions(+), 2 deletions(-)

diff --git a/drivers/dma-buf/st-dma-fence.c b/drivers/dma-buf/st-dma-fence.c
index e593064341c8..c8a12d7ad71a 100644
--- a/drivers/dma-buf/st-dma-fence.c
+++ b/drivers/dma-buf/st-dma-fence.c
@@ -471,8 +471,11 @@ static int thread_signal_callback(void *arg)
 			dma_fence_signal(f1);
 
 		smp_store_mb(cb.seen, false);
-		if (!f2 || dma_fence_add_callback(f2, &cb.cb, simple_callback))
-			miss++, cb.seen = true;
+		if (!f2 ||
+		    dma_fence_add_callback(f2, &cb.cb, simple_callback)) {
+			miss++;
+			cb.seen = true;
+		}
 
 		if (!t->before)
 			dma_fence_signal(f1);
-- 
2.26.0


^ permalink raw reply related	[flat|nested] 80+ messages in thread

* [PATCH 09/29] drm/gma500: Avoid comma separated statements
  2020-08-25  4:55 [PATCH 00/29] treewide: Convert comma separated statements Joe Perches
                   ` (7 preceding siblings ...)
  2020-08-25  4:56 ` [PATCH 08/29] dma-buf: " Joe Perches
@ 2020-08-25  4:56 ` Joe Perches
  2021-01-30 18:47   ` Joe Perches
  2020-08-25  4:56 ` [PATCH 10/29] drm/i915: " Joe Perches
                   ` (20 subsequent siblings)
  29 siblings, 1 reply; 80+ messages in thread
From: Joe Perches @ 2020-08-25  4:56 UTC (permalink / raw)
  To: Jiri Kosina, Patrik Jakobsson
  Cc: David Airlie, Daniel Vetter, dri-devel, linux-kernel

Use semicolons and braces.

Signed-off-by: Joe Perches <joe@perches.com>
---
 drivers/gpu/drm/gma500/mdfld_intel_display.c | 44 +++++++++++++-------
 1 file changed, 28 insertions(+), 16 deletions(-)

diff --git a/drivers/gpu/drm/gma500/mdfld_intel_display.c b/drivers/gpu/drm/gma500/mdfld_intel_display.c
index aae2d358364c..bfa330df9443 100644
--- a/drivers/gpu/drm/gma500/mdfld_intel_display.c
+++ b/drivers/gpu/drm/gma500/mdfld_intel_display.c
@@ -824,33 +824,45 @@ static int mdfld_crtc_mode_set(struct drm_crtc *crtc,
 		if ((ksel == KSEL_CRYSTAL_19) || (ksel == KSEL_BYPASS_19)) {
 			refclk = 19200;
 
-			if (is_mipi || is_mipi2)
-				clk_n = 1, clk_p2 = 8;
-			else if (is_hdmi)
-				clk_n = 1, clk_p2 = 10;
+			if (is_mipi || is_mipi2) {
+				clk_n = 1;
+				clk_p2 = 8;
+			} else if (is_hdmi) {
+				clk_n = 1;
+				clk_p2 = 10;
+			}
 		} else if (ksel == KSEL_BYPASS_25) {
 			refclk = 25000;
 
-			if (is_mipi || is_mipi2)
-				clk_n = 1, clk_p2 = 8;
-			else if (is_hdmi)
-				clk_n = 1, clk_p2 = 10;
+			if (is_mipi || is_mipi2) {
+				clk_n = 1;
+				clk_p2 = 8;
+			} else if (is_hdmi) {
+				clk_n = 1;
+				clk_p2 = 10;
+			}
 		} else if ((ksel == KSEL_BYPASS_83_100) &&
 					dev_priv->core_freq == 166) {
 			refclk = 83000;
 
-			if (is_mipi || is_mipi2)
-				clk_n = 4, clk_p2 = 8;
-			else if (is_hdmi)
-				clk_n = 4, clk_p2 = 10;
+			if (is_mipi || is_mipi2) {
+				clk_n = 4;
+				clk_p2 = 8;
+			} else if (is_hdmi) {
+				clk_n = 4;
+				clk_p2 = 10;
+			}
 		} else if ((ksel == KSEL_BYPASS_83_100) &&
 					(dev_priv->core_freq == 100 ||
 					dev_priv->core_freq == 200)) {
 			refclk = 100000;
-			if (is_mipi || is_mipi2)
-				clk_n = 4, clk_p2 = 8;
-			else if (is_hdmi)
-				clk_n = 4, clk_p2 = 10;
+			if (is_mipi || is_mipi2) {
+				clk_n = 4;
+				clk_p2 = 8;
+			} else if (is_hdmi) {
+				clk_n = 4;
+				clk_p2 = 10;
+			}
 		}
 
 		if (is_mipi)
-- 
2.26.0


^ permalink raw reply related	[flat|nested] 80+ messages in thread

* [PATCH 10/29] drm/i915: Avoid comma separated statements
  2020-08-25  4:55 [PATCH 00/29] treewide: Convert comma separated statements Joe Perches
                   ` (8 preceding siblings ...)
  2020-08-25  4:56 ` [PATCH 09/29] drm/gma500: " Joe Perches
@ 2020-08-25  4:56 ` Joe Perches
  2021-01-30 18:47   ` Joe Perches
  2020-08-25  4:56 ` [PATCH 11/29] hwmon: (scmi-hwmon): " Joe Perches
                   ` (19 subsequent siblings)
  29 siblings, 1 reply; 80+ messages in thread
From: Joe Perches @ 2020-08-25  4:56 UTC (permalink / raw)
  To: Jiri Kosina, Jani Nikula, Joonas Lahtinen, Rodrigo Vivi
  Cc: David Airlie, Daniel Vetter, intel-gfx, dri-devel, linux-kernel

Use semicolons and braces.

Signed-off-by: Joe Perches <joe@perches.com>
---
 drivers/gpu/drm/i915/gt/gen8_ppgtt.c           | 8 +++++---
 drivers/gpu/drm/i915/gt/intel_gt_requests.c    | 6 ++++--
 drivers/gpu/drm/i915/gt/selftest_workarounds.c | 6 ++++--
 drivers/gpu/drm/i915/intel_runtime_pm.c        | 6 ++++--
 4 files changed, 17 insertions(+), 9 deletions(-)

diff --git a/drivers/gpu/drm/i915/gt/gen8_ppgtt.c b/drivers/gpu/drm/i915/gt/gen8_ppgtt.c
index 699125928272..114c13285ff1 100644
--- a/drivers/gpu/drm/i915/gt/gen8_ppgtt.c
+++ b/drivers/gpu/drm/i915/gt/gen8_ppgtt.c
@@ -323,10 +323,12 @@ static int __gen8_ppgtt_alloc(struct i915_address_space * const vm,
 			}
 
 			spin_lock(&pd->lock);
-			if (likely(!pd->entry[idx]))
+			if (likely(!pd->entry[idx])) {
 				set_pd_entry(pd, idx, pt);
-			else
-				alloc = pt, pt = pd->entry[idx];
+			} else {
+				alloc = pt;
+				pt = pd->entry[idx];
+			}
 		}
 
 		if (lvl) {
diff --git a/drivers/gpu/drm/i915/gt/intel_gt_requests.c b/drivers/gpu/drm/i915/gt/intel_gt_requests.c
index 66fcbf9d0fdd..54408d0b5e6e 100644
--- a/drivers/gpu/drm/i915/gt/intel_gt_requests.c
+++ b/drivers/gpu/drm/i915/gt/intel_gt_requests.c
@@ -139,8 +139,10 @@ long intel_gt_retire_requests_timeout(struct intel_gt *gt, long timeout)
 	LIST_HEAD(free);
 
 	interruptible = true;
-	if (unlikely(timeout < 0))
-		timeout = -timeout, interruptible = false;
+	if (unlikely(timeout < 0)) {
+		timeout = -timeout;
+		interruptible = false;
+	}
 
 	flush_submission(gt, timeout); /* kick the ksoftirqd tasklets */
 	spin_lock(&timelines->lock);
diff --git a/drivers/gpu/drm/i915/gt/selftest_workarounds.c b/drivers/gpu/drm/i915/gt/selftest_workarounds.c
index febc9e6692ba..3e4cbeed20bd 100644
--- a/drivers/gpu/drm/i915/gt/selftest_workarounds.c
+++ b/drivers/gpu/drm/i915/gt/selftest_workarounds.c
@@ -521,8 +521,10 @@ static int check_dirty_whitelist(struct intel_context *ce)
 
 		srm = MI_STORE_REGISTER_MEM;
 		lrm = MI_LOAD_REGISTER_MEM;
-		if (INTEL_GEN(engine->i915) >= 8)
-			lrm++, srm++;
+		if (INTEL_GEN(engine->i915) >= 8) {
+			lrm++;
+			srm++;
+		}
 
 		pr_debug("%s: Writing garbage to %x\n",
 			 engine->name, reg);
diff --git a/drivers/gpu/drm/i915/intel_runtime_pm.c b/drivers/gpu/drm/i915/intel_runtime_pm.c
index 153ca9e65382..f498f1c80755 100644
--- a/drivers/gpu/drm/i915/intel_runtime_pm.c
+++ b/drivers/gpu/drm/i915/intel_runtime_pm.c
@@ -201,8 +201,10 @@ __print_intel_runtime_pm_wakeref(struct drm_printer *p,
 		unsigned long rep;
 
 		rep = 1;
-		while (i + 1 < dbg->count && dbg->owners[i + 1] == stack)
-			rep++, i++;
+		while (i + 1 < dbg->count && dbg->owners[i + 1] == stack) {
+			rep++;
+			i++;
+		}
 		__print_depot_stack(stack, buf, PAGE_SIZE, 2);
 		drm_printf(p, "Wakeref x%lu taken at:\n%s", rep, buf);
 	}
-- 
2.26.0


^ permalink raw reply related	[flat|nested] 80+ messages in thread

* [PATCH 11/29] hwmon: (scmi-hwmon): Avoid comma separated statements
  2020-08-25  4:55 [PATCH 00/29] treewide: Convert comma separated statements Joe Perches
                   ` (9 preceding siblings ...)
  2020-08-25  4:56 ` [PATCH 10/29] drm/i915: " Joe Perches
@ 2020-08-25  4:56 ` Joe Perches
  2020-08-25 23:33   ` Guenter Roeck
  2020-08-25  4:56 ` [PATCH 12/29] Input: MT - " Joe Perches
                   ` (18 subsequent siblings)
  29 siblings, 1 reply; 80+ messages in thread
From: Joe Perches @ 2020-08-25  4:56 UTC (permalink / raw)
  To: Jiri Kosina, Jean Delvare, Guenter Roeck; +Cc: linux-hwmon, linux-kernel

Use semicolons and braces.

Signed-off-by: Joe Perches <joe@perches.com>
---
 drivers/hwmon/scmi-hwmon.c | 6 ++++--
 1 file changed, 4 insertions(+), 2 deletions(-)

diff --git a/drivers/hwmon/scmi-hwmon.c b/drivers/hwmon/scmi-hwmon.c
index d421e691318b..09ce30cba54b 100644
--- a/drivers/hwmon/scmi-hwmon.c
+++ b/drivers/hwmon/scmi-hwmon.c
@@ -202,8 +202,10 @@ static int scmi_hwmon_probe(struct scmi_device *sdev)
 		}
 	}
 
-	if (nr_count[hwmon_temp])
-		nr_count[hwmon_chip]++, nr_types++;
+	if (nr_count[hwmon_temp]) {
+		nr_count[hwmon_chip]++;
+		nr_types++;
+	}
 
 	scmi_hwmon_chan = devm_kcalloc(dev, nr_types, sizeof(*scmi_hwmon_chan),
 				       GFP_KERNEL);
-- 
2.26.0


^ permalink raw reply related	[flat|nested] 80+ messages in thread

* [PATCH 12/29] Input: MT - Avoid comma separated statements
  2020-08-25  4:55 [PATCH 00/29] treewide: Convert comma separated statements Joe Perches
                   ` (10 preceding siblings ...)
  2020-08-25  4:56 ` [PATCH 11/29] hwmon: (scmi-hwmon): " Joe Perches
@ 2020-08-25  4:56 ` Joe Perches
  2020-08-25 17:07   ` Dmitry Torokhov
  2020-08-25  4:56 ` [PATCH 13/29] bcache: " Joe Perches
                   ` (17 subsequent siblings)
  29 siblings, 1 reply; 80+ messages in thread
From: Joe Perches @ 2020-08-25  4:56 UTC (permalink / raw)
  To: Jiri Kosina, Henrik Rydberg, Dmitry Torokhov; +Cc: linux-input, linux-kernel

Use semicolons and braces.

Signed-off-by: Joe Perches <joe@perches.com>
---
 drivers/input/input-mt.c | 11 +++++++----
 1 file changed, 7 insertions(+), 4 deletions(-)

diff --git a/drivers/input/input-mt.c b/drivers/input/input-mt.c
index f699538bdac4..44fe6f2f063c 100644
--- a/drivers/input/input-mt.c
+++ b/drivers/input/input-mt.c
@@ -323,11 +323,14 @@ static int adjust_dual(int *begin, int step, int *end, int eq, int mu)
 	p = begin + step;
 	s = p == end ? f + 1 : *p;
 
-	for (; p != end; p += step)
-		if (*p < f)
-			s = f, f = *p;
-		else if (*p < s)
+	for (; p != end; p += step) {
+		if (*p < f) {
+			s = f;
+			f = *p;
+		} else if (*p < s) {
 			s = *p;
+		}
+	}
 
 	c = (f + s + 1) / 2;
 	if (c == 0 || (c > mu && (!eq || mu > 0)))
-- 
2.26.0


^ permalink raw reply related	[flat|nested] 80+ messages in thread

* [PATCH 13/29] bcache: Avoid comma separated statements
  2020-08-25  4:55 [PATCH 00/29] treewide: Convert comma separated statements Joe Perches
                   ` (11 preceding siblings ...)
  2020-08-25  4:56 ` [PATCH 12/29] Input: MT - " Joe Perches
@ 2020-08-25  4:56 ` Joe Perches
  2021-01-30 18:59   ` Joe Perches
  2020-08-25  4:56 ` [PATCH 14/29] media: " Joe Perches
                   ` (16 subsequent siblings)
  29 siblings, 1 reply; 80+ messages in thread
From: Joe Perches @ 2020-08-25  4:56 UTC (permalink / raw)
  To: Jiri Kosina, Coly Li, Kent Overstreet; +Cc: linux-bcache, linux-kernel

Use semicolons and braces.

Signed-off-by: Joe Perches <joe@perches.com>
---
 drivers/md/bcache/bset.c  | 12 ++++++++----
 drivers/md/bcache/sysfs.c |  6 ++++--
 2 files changed, 12 insertions(+), 6 deletions(-)

diff --git a/drivers/md/bcache/bset.c b/drivers/md/bcache/bset.c
index 67a2c47f4201..94d38e8a59b3 100644
--- a/drivers/md/bcache/bset.c
+++ b/drivers/md/bcache/bset.c
@@ -712,8 +712,10 @@ void bch_bset_build_written_tree(struct btree_keys *b)
 	for (j = inorder_next(0, t->size);
 	     j;
 	     j = inorder_next(j, t->size)) {
-		while (bkey_to_cacheline(t, k) < cacheline)
-			prev = k, k = bkey_next(k);
+		while (bkey_to_cacheline(t, k) < cacheline) {
+			prev = k;
+			k = bkey_next(k);
+		}
 
 		t->prev[j] = bkey_u64s(prev);
 		t->tree[j].m = bkey_to_cacheline_offset(t, cacheline++, k);
@@ -901,8 +903,10 @@ unsigned int bch_btree_insert_key(struct btree_keys *b, struct bkey *k,
 	status = BTREE_INSERT_STATUS_INSERT;
 
 	while (m != bset_bkey_last(i) &&
-	       bkey_cmp(k, b->ops->is_extents ? &START_KEY(m) : m) > 0)
-		prev = m, m = bkey_next(m);
+	       bkey_cmp(k, b->ops->is_extents ? &START_KEY(m) : m) > 0) {
+		prev = m;
+		m = bkey_next(m);
+	}
 
 	/* prev is in the tree, if we merge we're done */
 	status = BTREE_INSERT_STATUS_BACK_MERGE;
diff --git a/drivers/md/bcache/sysfs.c b/drivers/md/bcache/sysfs.c
index ac06c0bc3c0a..1878c5ee53b6 100644
--- a/drivers/md/bcache/sysfs.c
+++ b/drivers/md/bcache/sysfs.c
@@ -1071,8 +1071,10 @@ SHOW(__bch_cache)
 			--n;
 
 		while (cached < p + n &&
-		       *cached == BTREE_PRIO)
-			cached++, n--;
+		       *cached == BTREE_PRIO) {
+			cached++;
+			n--;
+		}
 
 		for (i = 0; i < n; i++)
 			sum += INITIAL_PRIO - cached[i];
-- 
2.26.0


^ permalink raw reply related	[flat|nested] 80+ messages in thread

* [PATCH 14/29] media: Avoid comma separated statements
  2020-08-25  4:55 [PATCH 00/29] treewide: Convert comma separated statements Joe Perches
                   ` (12 preceding siblings ...)
  2020-08-25  4:56 ` [PATCH 13/29] bcache: " Joe Perches
@ 2020-08-25  4:56 ` Joe Perches
  2020-09-04 11:45   ` Kieran Bingham
  2020-08-25  4:56 ` [PATCH 15/29] mtd: " Joe Perches
                   ` (15 subsequent siblings)
  29 siblings, 1 reply; 80+ messages in thread
From: Joe Perches @ 2020-08-25  4:56 UTC (permalink / raw)
  To: Jiri Kosina, Mauro Carvalho Chehab; +Cc: linux-media, linux-kernel

Use semicolons and braces.

Signed-off-by: Joe Perches <joe@perches.com>
---
 drivers/media/i2c/msp3400-kthreads.c      | 12 ++++++++----
 drivers/media/pci/bt8xx/bttv-cards.c      |  6 ++++--
 drivers/media/pci/saa7134/saa7134-video.c |  7 +++++--
 3 files changed, 17 insertions(+), 8 deletions(-)

diff --git a/drivers/media/i2c/msp3400-kthreads.c b/drivers/media/i2c/msp3400-kthreads.c
index d3b0d1c18efd..ac8752c63266 100644
--- a/drivers/media/i2c/msp3400-kthreads.c
+++ b/drivers/media/i2c/msp3400-kthreads.c
@@ -549,8 +549,10 @@ int msp3400c_thread(void *data)
 			val = msp_read_dsp(client, 0x1b);
 			if (val > 32767)
 				val -= 65536;
-			if (val1 < val)
-				val1 = val, max1 = i;
+			if (val1 < val) {
+				val1 = val;
+				max1 = i;
+			}
 			dev_dbg_lvl(&client->dev, 1, msp_debug,
 				"carrier1 val: %5d / %s\n", val, cd[i].name);
 		}
@@ -586,8 +588,10 @@ int msp3400c_thread(void *data)
 			val = msp_read_dsp(client, 0x1b);
 			if (val > 32767)
 				val -= 65536;
-			if (val2 < val)
-				val2 = val, max2 = i;
+			if (val2 < val) {
+				val2 = val;
+				max2 = i;
+			}
 			dev_dbg_lvl(&client->dev, 1, msp_debug,
 				"carrier2 val: %5d / %s\n", val, cd[i].name);
 		}
diff --git a/drivers/media/pci/bt8xx/bttv-cards.c b/drivers/media/pci/bt8xx/bttv-cards.c
index 16148802dabb..ca20b806e82d 100644
--- a/drivers/media/pci/bt8xx/bttv-cards.c
+++ b/drivers/media/pci/bt8xx/bttv-cards.c
@@ -3934,8 +3934,10 @@ static void osprey_eeprom(struct bttv *btv, const u8 ee[256])
 			if (checksum != ee[21])
 				return;
 			cardid = BTTV_BOARD_OSPREY1x0_848;
-			for (i = 12; i < 21; i++)
-				serial *= 10, serial += ee[i] - '0';
+			for (i = 12; i < 21; i++) {
+				serial *= 10;
+				serial += ee[i] - '0';
+			}
 		}
 	} else {
 		unsigned short type;
diff --git a/drivers/media/pci/saa7134/saa7134-video.c b/drivers/media/pci/saa7134/saa7134-video.c
index a8ac94fadc14..f673cda57f30 100644
--- a/drivers/media/pci/saa7134/saa7134-video.c
+++ b/drivers/media/pci/saa7134/saa7134-video.c
@@ -868,8 +868,11 @@ static int buffer_activate(struct saa7134_dev *dev,
 		lines_uv = dev->height >> dev->fmt->vshift;
 		base2    = base + bpl * dev->height;
 		base3    = base2 + bpl_uv * lines_uv;
-		if (dev->fmt->uvswap)
-			tmp = base2, base2 = base3, base3 = tmp;
+		if (dev->fmt->uvswap) {
+			tmp = base2;
+			base2 = base3;
+			base3 = tmp;
+		}
 		video_dbg("uv: bpl=%ld lines=%ld base2/3=%ld/%ld\n",
 			bpl_uv,lines_uv,base2,base3);
 		if (V4L2_FIELD_HAS_BOTH(dev->field)) {
-- 
2.26.0


^ permalink raw reply related	[flat|nested] 80+ messages in thread

* [PATCH 15/29] mtd: Avoid comma separated statements
  2020-08-25  4:55 [PATCH 00/29] treewide: Convert comma separated statements Joe Perches
                   ` (13 preceding siblings ...)
  2020-08-25  4:56 ` [PATCH 14/29] media: " Joe Perches
@ 2020-08-25  4:56 ` Joe Perches
  2020-09-07  7:34   ` Miquel Raynal
  2020-08-25  4:56 ` [PATCH 16/29] 8390: " Joe Perches
                   ` (14 subsequent siblings)
  29 siblings, 1 reply; 80+ messages in thread
From: Joe Perches @ 2020-08-25  4:56 UTC (permalink / raw)
  To: Jiri Kosina, linux-kernel
  Cc: Miquel Raynal, Richard Weinberger, Vignesh Raghavendra, linux-mtd

Use semicolons and braces.

Signed-off-by: Joe Perches <joe@perches.com>
---
 drivers/mtd/devices/lart.c | 10 ++++++++--
 1 file changed, 8 insertions(+), 2 deletions(-)

diff --git a/drivers/mtd/devices/lart.c b/drivers/mtd/devices/lart.c
index 56f50d27b7fd..aecd441e4183 100644
--- a/drivers/mtd/devices/lart.c
+++ b/drivers/mtd/devices/lart.c
@@ -436,7 +436,10 @@ static int flash_read (struct mtd_info *mtd,loff_t from,size_t len,size_t *retle
 	 {
 		int gap = BUSWIDTH - (from & (BUSWIDTH - 1));
 
-		while (len && gap--) *buf++ = read8 (from++), len--;
+		while (len && gap--) {
+			*buf++ = read8 (from++);
+			len--;
+		}
 	 }
 
    /* now we read dwords until we reach a non-dword boundary */
@@ -518,7 +521,10 @@ static int flash_write (struct mtd_info *mtd,loff_t to,size_t len,size_t *retlen
 		i = n = 0;
 
 		while (gap--) tmp[i++] = 0xFF;
-		while (len && i < BUSWIDTH) tmp[i++] = buf[n++], len--;
+		while (len && i < BUSWIDTH) {
+			tmp[i++] = buf[n++];
+			len--;
+		}
 		while (i < BUSWIDTH) tmp[i++] = 0xFF;
 
 		if (!write_dword (aligned,*((__u32 *) tmp))) return (-EIO);
-- 
2.26.0


^ permalink raw reply related	[flat|nested] 80+ messages in thread

* [PATCH 16/29] 8390: Avoid comma separated statements
  2020-08-25  4:55 [PATCH 00/29] treewide: Convert comma separated statements Joe Perches
                   ` (14 preceding siblings ...)
  2020-08-25  4:56 ` [PATCH 15/29] mtd: " Joe Perches
@ 2020-08-25  4:56 ` Joe Perches
  2020-08-25 14:54   ` David Miller
  2020-08-25  4:56 ` [PATCH 17/29] fs_enet: " Joe Perches
                   ` (13 subsequent siblings)
  29 siblings, 1 reply; 80+ messages in thread
From: Joe Perches @ 2020-08-25  4:56 UTC (permalink / raw)
  To: Jiri Kosina, linux-kernel; +Cc: David S. Miller, Jakub Kicinski, netdev

Use semicolons and braces.

Signed-off-by: Joe Perches <joe@perches.com>
---
 drivers/net/ethernet/8390/axnet_cs.c | 19 ++++++++++++-------
 drivers/net/ethernet/8390/lib8390.c  | 14 +++++++++-----
 drivers/net/ethernet/8390/pcnet_cs.c |  6 ++++--
 3 files changed, 25 insertions(+), 14 deletions(-)

diff --git a/drivers/net/ethernet/8390/axnet_cs.c b/drivers/net/ethernet/8390/axnet_cs.c
index a00b36f91d9f..d041b6dda012 100644
--- a/drivers/net/ethernet/8390/axnet_cs.c
+++ b/drivers/net/ethernet/8390/axnet_cs.c
@@ -657,8 +657,10 @@ static void block_input(struct net_device *dev, int count,
     outb_p(E8390_RREAD+E8390_START, nic_base + AXNET_CMD);
 
     insw(nic_base + AXNET_DATAPORT,buf,count>>1);
-    if (count & 0x01)
-	buf[count-1] = inb(nic_base + AXNET_DATAPORT), xfer_count++;
+    if (count & 0x01) {
+	buf[count-1] = inb(nic_base + AXNET_DATAPORT);
+	xfer_count++;
+    }
 
 }
 
@@ -1270,10 +1272,12 @@ static void ei_tx_intr(struct net_device *dev)
 			ei_local->txing = 1;
 			NS8390_trigger_send(dev, ei_local->tx2, ei_local->tx_start_page + 6);
 			netif_trans_update(dev);
-			ei_local->tx2 = -1,
+			ei_local->tx2 = -1;
 			ei_local->lasttx = 2;
-		}
-		else ei_local->lasttx = 20, ei_local->txing = 0;	
+		} else {
+			ei_local->lasttx = 20;
+			ei_local->txing = 0;
+		}	
 	}
 	else if (ei_local->tx2 < 0) 
 	{
@@ -1289,9 +1293,10 @@ static void ei_tx_intr(struct net_device *dev)
 			netif_trans_update(dev);
 			ei_local->tx1 = -1;
 			ei_local->lasttx = 1;
+		} else {
+			ei_local->lasttx = 10;
+			ei_local->txing = 0;
 		}
-		else
-			ei_local->lasttx = 10, ei_local->txing = 0;
 	}
 //	else
 //		netdev_warn(dev, "unexpected TX-done interrupt, lasttx=%d\n",
diff --git a/drivers/net/ethernet/8390/lib8390.c b/drivers/net/ethernet/8390/lib8390.c
index babc92e2692e..1f48d7f6365c 100644
--- a/drivers/net/ethernet/8390/lib8390.c
+++ b/drivers/net/ethernet/8390/lib8390.c
@@ -597,10 +597,12 @@ static void ei_tx_intr(struct net_device *dev)
 			ei_local->txing = 1;
 			NS8390_trigger_send(dev, ei_local->tx2, ei_local->tx_start_page + 6);
 			netif_trans_update(dev);
-			ei_local->tx2 = -1,
+			ei_local->tx2 = -1;
 			ei_local->lasttx = 2;
-		} else
-			ei_local->lasttx = 20, ei_local->txing = 0;
+		} else {
+			ei_local->lasttx = 20;
+			ei_local->txing = 0;
+		}
 	} else if (ei_local->tx2 < 0) {
 		if (ei_local->lasttx != 2  &&  ei_local->lasttx != -2)
 			pr_err("%s: bogus last_tx_buffer %d, tx2=%d\n",
@@ -612,8 +614,10 @@ static void ei_tx_intr(struct net_device *dev)
 			netif_trans_update(dev);
 			ei_local->tx1 = -1;
 			ei_local->lasttx = 1;
-		} else
-			ei_local->lasttx = 10, ei_local->txing = 0;
+		} else {
+			ei_local->lasttx = 10;
+			ei_local->txing = 0;
+		}
 	} /* else
 		netdev_warn(dev, "unexpected TX-done interrupt, lasttx=%d\n",
 			    ei_local->lasttx);
diff --git a/drivers/net/ethernet/8390/pcnet_cs.c b/drivers/net/ethernet/8390/pcnet_cs.c
index 164c3ed550bf..9d3b1e0e425c 100644
--- a/drivers/net/ethernet/8390/pcnet_cs.c
+++ b/drivers/net/ethernet/8390/pcnet_cs.c
@@ -1178,8 +1178,10 @@ static void dma_block_input(struct net_device *dev, int count,
     outb_p(E8390_RREAD+E8390_START, nic_base + PCNET_CMD);
 
     insw(nic_base + PCNET_DATAPORT,buf,count>>1);
-    if (count & 0x01)
-	buf[count-1] = inb(nic_base + PCNET_DATAPORT), xfer_count++;
+    if (count & 0x01) {
+	buf[count-1] = inb(nic_base + PCNET_DATAPORT);
+	xfer_count++;
+    }
 
     /* This was for the ALPHA version only, but enough people have been
        encountering problems that it is still here. */
-- 
2.26.0


^ permalink raw reply related	[flat|nested] 80+ messages in thread

* [PATCH 17/29] fs_enet: Avoid comma separated statements
  2020-08-25  4:55 [PATCH 00/29] treewide: Convert comma separated statements Joe Perches
                   ` (15 preceding siblings ...)
  2020-08-25  4:56 ` [PATCH 16/29] 8390: " Joe Perches
@ 2020-08-25  4:56 ` Joe Perches
  2020-08-25 14:55   ` David Miller
  2020-08-25  4:56 ` [PATCH 18/29] wan: sbni: " Joe Perches
                   ` (12 subsequent siblings)
  29 siblings, 1 reply; 80+ messages in thread
From: Joe Perches @ 2020-08-25  4:56 UTC (permalink / raw)
  To: Jiri Kosina, Pantelis Antoniou
  Cc: David S. Miller, Jakub Kicinski, linuxppc-dev, netdev, linux-kernel

Use semicolons and braces.

Signed-off-by: Joe Perches <joe@perches.com>
---
 drivers/net/ethernet/freescale/fs_enet/fs_enet-main.c | 11 +++++++----
 1 file changed, 7 insertions(+), 4 deletions(-)

diff --git a/drivers/net/ethernet/freescale/fs_enet/fs_enet-main.c b/drivers/net/ethernet/freescale/fs_enet/fs_enet-main.c
index bf846b42bc74..78e008b81374 100644
--- a/drivers/net/ethernet/freescale/fs_enet/fs_enet-main.c
+++ b/drivers/net/ethernet/freescale/fs_enet/fs_enet-main.c
@@ -562,10 +562,13 @@ fs_enet_start_xmit(struct sk_buff *skb, struct net_device *dev)
 			BD_ENET_TX_TC);
 		CBDS_SC(bdp, BD_ENET_TX_READY);
 
-		if ((CBDR_SC(bdp) & BD_ENET_TX_WRAP) == 0)
-			bdp++, curidx++;
-		else
-			bdp = fep->tx_bd_base, curidx = 0;
+		if ((CBDR_SC(bdp) & BD_ENET_TX_WRAP) == 0) {
+			bdp++;
+			curidx++;
+		} else {
+			bdp = fep->tx_bd_base;
+			curidx = 0;
+		}
 
 		len = skb_frag_size(frag);
 		CBDW_BUFADDR(bdp, skb_frag_dma_map(fep->dev, frag, 0, len,
-- 
2.26.0


^ permalink raw reply related	[flat|nested] 80+ messages in thread

* [PATCH 18/29] wan: sbni: Avoid comma separated statements
  2020-08-25  4:55 [PATCH 00/29] treewide: Convert comma separated statements Joe Perches
                   ` (16 preceding siblings ...)
  2020-08-25  4:56 ` [PATCH 17/29] fs_enet: " Joe Perches
@ 2020-08-25  4:56 ` Joe Perches
  2020-08-25 14:55   ` David Miller
  2020-08-25  4:56 ` [PATCH 19/29] s390/tty3270: " Joe Perches
                   ` (11 subsequent siblings)
  29 siblings, 1 reply; 80+ messages in thread
From: Joe Perches @ 2020-08-25  4:56 UTC (permalink / raw)
  To: Jiri Kosina, linux-kernel; +Cc: David S. Miller, Jakub Kicinski, netdev

Use semicolons and braces.

Signed-off-by: Joe Perches <joe@perches.com>
---
 drivers/net/wan/sbni.c | 101 +++++++++++++++++++++++------------------
 1 file changed, 58 insertions(+), 43 deletions(-)

diff --git a/drivers/net/wan/sbni.c b/drivers/net/wan/sbni.c
index 40c04ea1200a..2fde439543fb 100644
--- a/drivers/net/wan/sbni.c
+++ b/drivers/net/wan/sbni.c
@@ -260,11 +260,12 @@ static int __init sbni_init(struct net_device *dev)
 		return  sbni_isa_probe( dev );
 	/* otherwise we have to perform search our adapter */
 
-	if( io[ num ] != -1 )
-		dev->base_addr	= io[ num ],
+	if( io[ num ] != -1 ) {
+		dev->base_addr	= io[ num ];
 		dev->irq	= irq[ num ];
-	else if( scandone  ||  io[ 0 ] != -1 )
+	} else if( scandone  ||  io[ 0 ] != -1 ) {
 		return  -ENODEV;
+	}
 
 	/* if io[ num ] contains non-zero address, then that is on ISA bus */
 	if( dev->base_addr )
@@ -399,12 +400,13 @@ sbni_probe1( struct net_device  *dev,  unsigned long  ioaddr,  int  irq )
 	nl->maxframe  = DEFAULT_FRAME_LEN;
 	nl->csr1.rate = baud[ num ];
 
-	if( (nl->cur_rxl_index = rxl[ num ]) == -1 )
+	if( (nl->cur_rxl_index = rxl[ num ]) == -1 ) {
 		/* autotune rxl */
-		nl->cur_rxl_index = DEF_RXL,
+		nl->cur_rxl_index = DEF_RXL;
 		nl->delta_rxl = DEF_RXL_DELTA;
-	else
+	} else {
 		nl->delta_rxl = 0;
+	}
 	nl->csr1.rxl  = rxl_tab[ nl->cur_rxl_index ];
 	if( inb( ioaddr + CSR0 ) & 0x01 )
 		nl->state |= FL_SLOW_MODE;
@@ -512,13 +514,15 @@ sbni_interrupt( int  irq,  void  *dev_id )
 
 	do {
 		repeat = 0;
-		if( inb( dev->base_addr + CSR0 ) & (RC_RDY | TR_RDY) )
-			handle_channel( dev ),
+		if( inb( dev->base_addr + CSR0 ) & (RC_RDY | TR_RDY) ) {
+			handle_channel( dev );
 			repeat = 1;
+		}
 		if( nl->second  && 	/* second channel present */
-		    (inb( nl->second->base_addr+CSR0 ) & (RC_RDY | TR_RDY)) )
-			handle_channel( nl->second ),
+		    (inb( nl->second->base_addr+CSR0 ) & (RC_RDY | TR_RDY)) ) {
+			handle_channel( nl->second );
 			repeat = 1;
+		}
 	} while( repeat );
 
 	if( nl->second )
@@ -610,11 +614,12 @@ recv_frame( struct net_device  *dev )
 		nl->state |= FL_PREV_OK;
 		if( framelen > 4 )
 			nl->in_stats.all_rx_number++;
-	} else
-		nl->state &= ~FL_PREV_OK,
-		change_level( dev ),
-		nl->in_stats.all_rx_number++,
+	} else {
+		nl->state &= ~FL_PREV_OK;
+		change_level( dev );
+		nl->in_stats.all_rx_number++;
 		nl->in_stats.bad_rx_number++;
+	}
 
 	return  !frame_ok  ||  framelen > 4;
 }
@@ -689,9 +694,10 @@ download_data( struct net_device  *dev,  u32  *crc_p )
 	*crc_p = calc_crc32( *crc_p, skb->data + nl->outpos, len );
 
 	/* if packet too short we should write some more bytes to pad */
-	for( len = nl->framelen - len;  len--; )
-		outb( 0, dev->base_addr + DAT ),
+	for( len = nl->framelen - len;  len--; ) {
+		outb( 0, dev->base_addr + DAT );
 		*crc_p = CRC32( 0, *crc_p );
+	}
 }
 
 
@@ -703,9 +709,10 @@ upload_data( struct net_device  *dev,  unsigned  framelen,  unsigned  frameno,
 
 	int  frame_ok;
 
-	if( is_first )
-		nl->wait_frameno = frameno,
+	if( is_first ) {
+		nl->wait_frameno = frameno;
 		nl->inppos = 0;
+	}
 
 	if( nl->wait_frameno == frameno ) {
 
@@ -717,33 +724,35 @@ upload_data( struct net_device  *dev,  unsigned  framelen,  unsigned  frameno,
 		 * error was occurred... drop entire packet
 		 */
 		else if( (frame_ok = skip_tail( dev->base_addr, framelen, crc ))
-			 != 0 )
-			nl->wait_frameno = 0,
-			nl->inppos = 0,
+			 != 0 ) {
+			nl->wait_frameno = 0;
+			nl->inppos = 0;
 #ifdef CONFIG_SBNI_MULTILINE
-			nl->master->stats.rx_errors++,
+			nl->master->stats.rx_errors++;
 			nl->master->stats.rx_missed_errors++;
 #else
-		        dev->stats.rx_errors++,
+		        dev->stats.rx_errors++;
 			dev->stats.rx_missed_errors++;
 #endif
+		}
 			/* now skip all frames until is_first != 0 */
 	} else
 		frame_ok = skip_tail( dev->base_addr, framelen, crc );
 
-	if( is_first  &&  !frame_ok )
+	if( is_first  &&  !frame_ok ) {
 		/*
 		 * Frame has been broken, but we had already stored
 		 * is_first... Drop entire packet.
 		 */
-		nl->wait_frameno = 0,
+		nl->wait_frameno = 0;
 #ifdef CONFIG_SBNI_MULTILINE
-		nl->master->stats.rx_errors++,
+		nl->master->stats.rx_errors++;
 		nl->master->stats.rx_crc_errors++;
 #else
-		dev->stats.rx_errors++,
+		dev->stats.rx_errors++;
 		dev->stats.rx_crc_errors++;
 #endif
+	}
 
 	return  frame_ok;
 }
@@ -782,17 +791,18 @@ interpret_ack( struct net_device  *dev,  unsigned  ack )
 		if( nl->state & FL_WAIT_ACK ) {
 			nl->outpos += nl->framelen;
 
-			if( --nl->tx_frameno )
+			if( --nl->tx_frameno ) {
 				nl->framelen = min_t(unsigned int,
 						   nl->maxframe,
 						   nl->tx_buf_p->len - nl->outpos);
-			else
-				send_complete( dev ),
+			} else {
+				send_complete( dev );
 #ifdef CONFIG_SBNI_MULTILINE
 				netif_wake_queue( nl->master );
 #else
 				netif_wake_queue( dev );
 #endif
+			}
 		}
 	}
 
@@ -872,16 +882,17 @@ drop_xmit_queue( struct net_device  *dev )
 {
 	struct net_local  *nl = netdev_priv(dev);
 
-	if( nl->tx_buf_p )
-		dev_kfree_skb_any( nl->tx_buf_p ),
-		nl->tx_buf_p = NULL,
+	if( nl->tx_buf_p ) {
+		dev_kfree_skb_any( nl->tx_buf_p );
+		nl->tx_buf_p = NULL;
 #ifdef CONFIG_SBNI_MULTILINE
-		nl->master->stats.tx_errors++,
+		nl->master->stats.tx_errors++;
 		nl->master->stats.tx_carrier_errors++;
 #else
-		dev->stats.tx_errors++,
+		dev->stats.tx_errors++;
 		dev->stats.tx_carrier_errors++;
 #endif
+	}
 
 	nl->tx_frameno	= 0;
 	nl->framelen	= 0;
@@ -1327,12 +1338,13 @@ sbni_ioctl( struct net_device  *dev,  struct ifreq  *ifr,  int  cmd )
 
 		spin_lock( &nl->lock );
 		flags = *(struct sbni_flags*) &ifr->ifr_ifru;
-		if( flags.fixed_rxl )
-			nl->delta_rxl = 0,
+		if( flags.fixed_rxl ) {
+			nl->delta_rxl = 0;
 			nl->cur_rxl_index = flags.rxl;
-		else
-			nl->delta_rxl = DEF_RXL_DELTA,
+		} else {
+			nl->delta_rxl = DEF_RXL_DELTA;
 			nl->cur_rxl_index = DEF_RXL;
+		}
 
 		nl->csr1.rxl = rxl_tab[ nl->cur_rxl_index ];
 		nl->csr1.rate = flags.rate;
@@ -1526,13 +1538,16 @@ sbni_setup( char  *p )
 		(*dest[ parm ])[ n ] = simple_strtol( p, &p, 0 );
 		if( !*p  ||  *p == ')' )
 			return 1;
-		if( *p == ';' )
-			++p, ++n, parm = 0;
-		else if( *p++ != ',' )
+		if( *p == ';' ) {
+			++p;
+			++n;
+			parm = 0;
+		} else if( *p++ != ',' ) {
 			break;
-		else
+		} else {
 			if( ++parm >= 5 )
 				break;
+		}
 	}
 bad_param:
 	pr_err("Error in sbni kernel parameter!\n");
-- 
2.26.0


^ permalink raw reply related	[flat|nested] 80+ messages in thread

* [PATCH 19/29] s390/tty3270: Avoid comma separated statements
  2020-08-25  4:55 [PATCH 00/29] treewide: Convert comma separated statements Joe Perches
                   ` (17 preceding siblings ...)
  2020-08-25  4:56 ` [PATCH 18/29] wan: sbni: " Joe Perches
@ 2020-08-25  4:56 ` Joe Perches
  2021-01-30 19:01   ` Joe Perches
  2020-08-25  4:56 ` [PATCH 20/29] scai/arm: " Joe Perches
                   ` (10 subsequent siblings)
  29 siblings, 1 reply; 80+ messages in thread
From: Joe Perches @ 2020-08-25  4:56 UTC (permalink / raw)
  To: Jiri Kosina, linux-kernel
  Cc: Heiko Carstens, Vasily Gorbik, Christian Borntraeger, linux-s390

Use semicolons and braces.

Signed-off-by: Joe Perches <joe@perches.com>
---
 drivers/s390/char/tty3270.c | 6 ++++--
 1 file changed, 4 insertions(+), 2 deletions(-)

diff --git a/drivers/s390/char/tty3270.c b/drivers/s390/char/tty3270.c
index aec996de44d9..6acce975df26 100644
--- a/drivers/s390/char/tty3270.c
+++ b/drivers/s390/char/tty3270.c
@@ -424,8 +424,10 @@ tty3270_update(struct timer_list *t)
 			 * last output position matches the start address
 			 * of this line.
 			 */
-			if (s->string[1] == sba[0] && s->string[2] == sba[1])
-				str += 3, len -= 3;
+			if (s->string[1] == sba[0] && s->string[2] == sba[1]) {
+				str += 3;
+				len -= 3;
+			}
 			if (raw3270_request_add_data(wrq, str, len) != 0)
 				break;
 			list_del_init(&s->update);
-- 
2.26.0


^ permalink raw reply related	[flat|nested] 80+ messages in thread

* [PATCH 20/29] scai/arm: Avoid comma separated statements
  2020-08-25  4:55 [PATCH 00/29] treewide: Convert comma separated statements Joe Perches
                   ` (18 preceding siblings ...)
  2020-08-25  4:56 ` [PATCH 19/29] s390/tty3270: " Joe Perches
@ 2020-08-25  4:56 ` Joe Perches
  2020-08-25  4:56 ` [PATCH 21/29] media: atomisp: " Joe Perches
                   ` (9 subsequent siblings)
  29 siblings, 0 replies; 80+ messages in thread
From: Joe Perches @ 2020-08-25  4:56 UTC (permalink / raw)
  To: Jiri Kosina, Russell King
  Cc: James E.J. Bottomley, Martin K. Petersen, linux-arm-kernel,
	linux-scsi, linux-kernel

Use semicolons and braces.

Signed-off-by: Joe Perches <joe@perches.com>
---
 drivers/scsi/arm/cumana_2.c | 19 +++++++++++--------
 drivers/scsi/arm/eesox.c    |  9 +++++----
 drivers/scsi/arm/powertec.c |  9 +++++----
 3 files changed, 21 insertions(+), 16 deletions(-)

diff --git a/drivers/scsi/arm/cumana_2.c b/drivers/scsi/arm/cumana_2.c
index 29294f0ef8a9..9dcd912267e6 100644
--- a/drivers/scsi/arm/cumana_2.c
+++ b/drivers/scsi/arm/cumana_2.c
@@ -166,14 +166,15 @@ cumanascsi_2_dma_setup(struct Scsi_Host *host, struct scsi_pointer *SCp,
 
 		bufs = copy_SCp_to_sg(&info->sg[0], SCp, NR_SG);
 
-		if (direction == DMA_OUT)
-			map_dir = DMA_TO_DEVICE,
-			dma_dir = DMA_MODE_WRITE,
+		if (direction == DMA_OUT) {
+			map_dir = DMA_TO_DEVICE;
+			dma_dir = DMA_MODE_WRITE;
 			alatch_dir = ALATCH_DMA_OUT;
-		else
-			map_dir = DMA_FROM_DEVICE,
-			dma_dir = DMA_MODE_READ,
+		} else {
+			map_dir = DMA_FROM_DEVICE;
+			dma_dir = DMA_MODE_READ;
 			alatch_dir = ALATCH_DMA_IN;
+		}
 
 		dma_map_sg(dev, info->sg, bufs, map_dir);
 
@@ -326,10 +327,12 @@ cumanascsi_2_set_proc_info(struct Scsi_Host *host, char *buffer, int length)
 				cumanascsi_2_terminator_ctl(host, 0);
 			else
 				ret = -EINVAL;
-		} else
+		} else {
 			ret = -EINVAL;
-	} else
+		}
+	} else {
 		ret = -EINVAL;
+	}
 
 	return ret;
 }
diff --git a/drivers/scsi/arm/eesox.c b/drivers/scsi/arm/eesox.c
index 591ae2a6dd74..5eb2415dda9d 100644
--- a/drivers/scsi/arm/eesox.c
+++ b/drivers/scsi/arm/eesox.c
@@ -165,12 +165,13 @@ eesoxscsi_dma_setup(struct Scsi_Host *host, struct scsi_pointer *SCp,
 
 		bufs = copy_SCp_to_sg(&info->sg[0], SCp, NR_SG);
 
-		if (direction == DMA_OUT)
-			map_dir = DMA_TO_DEVICE,
+		if (direction == DMA_OUT) {
+			map_dir = DMA_TO_DEVICE;
 			dma_dir = DMA_MODE_WRITE;
-		else
-			map_dir = DMA_FROM_DEVICE,
+		} else {
+			map_dir = DMA_FROM_DEVICE;
 			dma_dir = DMA_MODE_READ;
+		}
 
 		dma_map_sg(dev, info->sg, bufs, map_dir);
 
diff --git a/drivers/scsi/arm/powertec.c b/drivers/scsi/arm/powertec.c
index d99ef014528e..9cc73da4e876 100644
--- a/drivers/scsi/arm/powertec.c
+++ b/drivers/scsi/arm/powertec.c
@@ -138,12 +138,13 @@ powertecscsi_dma_setup(struct Scsi_Host *host, struct scsi_pointer *SCp,
 
 		bufs = copy_SCp_to_sg(&info->sg[0], SCp, NR_SG);
 
-		if (direction == DMA_OUT)
-			map_dir = DMA_TO_DEVICE,
+		if (direction == DMA_OUT) {
+			map_dir = DMA_TO_DEVICE;
 			dma_dir = DMA_MODE_WRITE;
-		else
-			map_dir = DMA_FROM_DEVICE,
+		} else {
+			map_dir = DMA_FROM_DEVICE;
 			dma_dir = DMA_MODE_READ;
+		}
 
 		dma_map_sg(dev, info->sg, bufs, map_dir);
 
-- 
2.26.0


^ permalink raw reply related	[flat|nested] 80+ messages in thread

* [PATCH 21/29] media: atomisp: Avoid comma separated statements
  2020-08-25  4:55 [PATCH 00/29] treewide: Convert comma separated statements Joe Perches
                   ` (19 preceding siblings ...)
  2020-08-25  4:56 ` [PATCH 20/29] scai/arm: " Joe Perches
@ 2020-08-25  4:56 ` Joe Perches
  2020-09-04 11:46   ` Kieran Bingham
  2020-08-25  4:56 ` [PATCH 22/29] video: fbdev: " Joe Perches
                   ` (8 subsequent siblings)
  29 siblings, 1 reply; 80+ messages in thread
From: Joe Perches @ 2020-08-25  4:56 UTC (permalink / raw)
  To: Jiri Kosina, linux-kernel
  Cc: Mauro Carvalho Chehab, Sakari Ailus, Greg Kroah-Hartman,
	linux-media, devel

Use semicolons and braces.

Signed-off-by: Joe Perches <joe@perches.com>
---
 drivers/staging/media/atomisp/pci/atomisp_subdev.c | 6 ++++--
 1 file changed, 4 insertions(+), 2 deletions(-)

diff --git a/drivers/staging/media/atomisp/pci/atomisp_subdev.c b/drivers/staging/media/atomisp/pci/atomisp_subdev.c
index 6ba817f15655..52b9fb18c87f 100644
--- a/drivers/staging/media/atomisp/pci/atomisp_subdev.c
+++ b/drivers/staging/media/atomisp/pci/atomisp_subdev.c
@@ -410,8 +410,10 @@ int atomisp_subdev_set_selection(struct v4l2_subdev *sd,
 
 		if (atomisp_subdev_format_conversion(isp_sd,
 						     isp_sd->capture_pad)
-		    && crop[pad]->width && crop[pad]->height)
-			crop[pad]->width -= padding_w, crop[pad]->height -= padding_h;
+		    && crop[pad]->width && crop[pad]->height) {
+			crop[pad]->width -= padding_w;
+			crop[pad]->height -= padding_h;
+		}
 
 		/* if subdev type is SOC camera,we do not need to set DVS */
 		if (isp->inputs[isp_sd->input_curr].type == SOC_CAMERA)
-- 
2.26.0


^ permalink raw reply related	[flat|nested] 80+ messages in thread

* [PATCH 22/29] video: fbdev: Avoid comma separated statements
  2020-08-25  4:55 [PATCH 00/29] treewide: Convert comma separated statements Joe Perches
                   ` (20 preceding siblings ...)
  2020-08-25  4:56 ` [PATCH 21/29] media: atomisp: " Joe Perches
@ 2020-08-25  4:56 ` Joe Perches
  2020-09-08 11:37   ` Bartlomiej Zolnierkiewicz
  2020-08-25  4:56 ` [PATCH 23/29] fuse: " Joe Perches
                   ` (7 subsequent siblings)
  29 siblings, 1 reply; 80+ messages in thread
From: Joe Perches @ 2020-08-25  4:56 UTC (permalink / raw)
  To: Jiri Kosina, linux-kernel
  Cc: Bartlomiej Zolnierkiewicz, dri-devel, linux-fbdev

Use semicolons and braces.

Signed-off-by: Joe Perches <joe@perches.com>
---
 drivers/video/fbdev/tgafb.c | 12 ++++++++----
 1 file changed, 8 insertions(+), 4 deletions(-)

diff --git a/drivers/video/fbdev/tgafb.c b/drivers/video/fbdev/tgafb.c
index e9869135d833..666fbe2f671c 100644
--- a/drivers/video/fbdev/tgafb.c
+++ b/drivers/video/fbdev/tgafb.c
@@ -989,8 +989,10 @@ tgafb_fillrect(struct fb_info *info, const struct fb_fillrect *rect)
 	/* We can fill 2k pixels per operation.  Notice blocks that fit
 	   the width of the screen so that we can take advantage of this
 	   and fill more than one line per write.  */
-	if (width == line_length)
-		width *= height, height = 1;
+	if (width == line_length) {
+		width *= height;
+		height = 1;
+	}
 
 	/* The write into the frame buffer must be aligned to 4 bytes,
 	   but we are allowed to encode the offset within the word in
@@ -1171,8 +1173,10 @@ copyarea_8bpp(struct fb_info *info, u32 dx, u32 dy, u32 sx, u32 sy,
 	   More than anything else, these control how we do copies.  */
 	depos = dy * line_length + dx;
 	sepos = sy * line_length + sx;
-	if (backward)
-		depos += width, sepos += width;
+	if (backward) {
+		depos += width;
+		sepos += width;
+	}
 
 	/* Next copy full words at a time.  */
 	n32 = width / 32;
-- 
2.26.0


^ permalink raw reply related	[flat|nested] 80+ messages in thread

* [PATCH 23/29] fuse: Avoid comma separated statements
  2020-08-25  4:55 [PATCH 00/29] treewide: Convert comma separated statements Joe Perches
                   ` (21 preceding siblings ...)
  2020-08-25  4:56 ` [PATCH 22/29] video: fbdev: " Joe Perches
@ 2020-08-25  4:56 ` Joe Perches
  2021-01-30 19:04   ` Joe Perches
  2021-02-01  8:12   ` Miklos Szeredi
  2020-08-25  4:56 ` [PATCH 24/29] reiserfs: " Joe Perches
                   ` (6 subsequent siblings)
  29 siblings, 2 replies; 80+ messages in thread
From: Joe Perches @ 2020-08-25  4:56 UTC (permalink / raw)
  To: Jiri Kosina, Miklos Szeredi; +Cc: linux-fsdevel, linux-kernel

Use semicolons and braces.

Signed-off-by: Joe Perches <joe@perches.com>
---
 fs/fuse/dir.c | 24 ++++++++++++++++--------
 1 file changed, 16 insertions(+), 8 deletions(-)

diff --git a/fs/fuse/dir.c b/fs/fuse/dir.c
index 26f028bc760b..ecb6eed832a0 100644
--- a/fs/fuse/dir.c
+++ b/fs/fuse/dir.c
@@ -1362,14 +1362,22 @@ static void iattr_to_fattr(struct fuse_conn *fc, struct iattr *iattr,
 {
 	unsigned ivalid = iattr->ia_valid;
 
-	if (ivalid & ATTR_MODE)
-		arg->valid |= FATTR_MODE,   arg->mode = iattr->ia_mode;
-	if (ivalid & ATTR_UID)
-		arg->valid |= FATTR_UID,    arg->uid = from_kuid(fc->user_ns, iattr->ia_uid);
-	if (ivalid & ATTR_GID)
-		arg->valid |= FATTR_GID,    arg->gid = from_kgid(fc->user_ns, iattr->ia_gid);
-	if (ivalid & ATTR_SIZE)
-		arg->valid |= FATTR_SIZE,   arg->size = iattr->ia_size;
+	if (ivalid & ATTR_MODE) {
+		arg->valid |= FATTR_MODE;
+		arg->mode = iattr->ia_mode;
+	}
+	if (ivalid & ATTR_UID) {
+		arg->valid |= FATTR_UID;
+		arg->uid = from_kuid(fc->user_ns, iattr->ia_uid);
+	}
+	if (ivalid & ATTR_GID) {
+		arg->valid |= FATTR_GID;
+		arg->gid = from_kgid(fc->user_ns, iattr->ia_gid);
+	}
+	if (ivalid & ATTR_SIZE) {
+		arg->valid |= FATTR_SIZE;
+		arg->size = iattr->ia_size;
+	}
 	if (ivalid & ATTR_ATIME) {
 		arg->valid |= FATTR_ATIME;
 		arg->atime = iattr->ia_atime.tv_sec;
-- 
2.26.0


^ permalink raw reply related	[flat|nested] 80+ messages in thread

* [PATCH 24/29] reiserfs: Avoid comma separated statements
  2020-08-25  4:55 [PATCH 00/29] treewide: Convert comma separated statements Joe Perches
                   ` (22 preceding siblings ...)
  2020-08-25  4:56 ` [PATCH 23/29] fuse: " Joe Perches
@ 2020-08-25  4:56 ` Joe Perches
  2021-01-30 19:04   ` Joe Perches
  2020-08-25  4:56 ` [PATCH 25/29] lib/zlib: " Joe Perches
                   ` (5 subsequent siblings)
  29 siblings, 1 reply; 80+ messages in thread
From: Joe Perches @ 2020-08-25  4:56 UTC (permalink / raw)
  To: Jiri Kosina, linux-kernel; +Cc: reiserfs-devel

Use semicolons and braces.

Signed-off-by: Joe Perches <joe@perches.com>
---
 fs/reiserfs/fix_node.c | 36 ++++++++++++++++++++++++------------
 1 file changed, 24 insertions(+), 12 deletions(-)

diff --git a/fs/reiserfs/fix_node.c b/fs/reiserfs/fix_node.c
index fefe87e1c099..aea63e67a42b 100644
--- a/fs/reiserfs/fix_node.c
+++ b/fs/reiserfs/fix_node.c
@@ -235,8 +235,10 @@ static void check_left(struct tree_balance *tb, int h, int cur_free)
 	d_size = 0, ih_size = IH_SIZE;
 
 	/* first item may be merge with last item in left neighbor */
-	if (vi->vi_type & VI_TYPE_LEFT_MERGEABLE)
-		d_size = -((int)IH_SIZE), ih_size = 0;
+	if (vi->vi_type & VI_TYPE_LEFT_MERGEABLE) {
+		d_size = -((int)IH_SIZE);
+		ih_size = 0;
+	}
 
 	tb->lnum[0] = 0;
 	for (i = 0; i < vn->vn_nr_item;
@@ -321,8 +323,10 @@ static void check_right(struct tree_balance *tb, int h, int cur_free)
 	d_size = 0, ih_size = IH_SIZE;
 
 	/* last item may be merge with first item in right neighbor */
-	if (vi->vi_type & VI_TYPE_RIGHT_MERGEABLE)
-		d_size = -(int)IH_SIZE, ih_size = 0;
+	if (vi->vi_type & VI_TYPE_RIGHT_MERGEABLE) {
+		d_size = -(int)IH_SIZE;
+		ih_size = 0;
+	}
 
 	tb->rnum[0] = 0;
 	for (i = vn->vn_nr_item - 1; i >= 0;
@@ -1534,8 +1538,10 @@ static int ip_check_balance(struct tree_balance *tb, int h)
 			nver1 = get_num_ver(vn->vn_mode, tb, h,
 					    0, -1, 0, -1,
 					    snum012 + NOTHING_SHIFT_FLOW, FLOW);
-			if (nver > nver1)
-				nset = NOTHING_SHIFT_FLOW, nver = nver1;
+			if (nver > nver1) {
+				nset = NOTHING_SHIFT_FLOW;
+				nver = nver1;
+			}
 		}
 
 		/*
@@ -1559,8 +1565,10 @@ static int ip_check_balance(struct tree_balance *tb, int h)
 					     ((tb->lbytes != -1) ? 1 : 0),
 					     tb->lbytes, 0, -1,
 					     snum012 + LEFT_SHIFT_FLOW, FLOW);
-			if (lnver > lnver1)
-				lset = LEFT_SHIFT_FLOW, lnver = lnver1;
+			if (lnver > lnver1) {
+				lset = LEFT_SHIFT_FLOW;
+				lnver = lnver1;
+			}
 		}
 
 		/*
@@ -1590,8 +1598,10 @@ static int ip_check_balance(struct tree_balance *tb, int h)
 					     tb->rbytes,
 					     snum012 + RIGHT_SHIFT_FLOW, FLOW);
 
-			if (rnver > rnver1)
-				rset = RIGHT_SHIFT_FLOW, rnver = rnver1;
+			if (rnver > rnver1) {
+				rset = RIGHT_SHIFT_FLOW;
+				rnver = rnver1;
+			}
 		}
 
 		/*
@@ -1622,8 +1632,10 @@ static int ip_check_balance(struct tree_balance *tb, int h)
 					       ((tb->rbytes != -1) ? 1 : 0)),
 					      tb->rbytes,
 					      snum012 + LR_SHIFT_FLOW, FLOW);
-			if (lrnver > lrnver1)
-				lrset = LR_SHIFT_FLOW, lrnver = lrnver1;
+			if (lrnver > lrnver1) {
+				lrset = LR_SHIFT_FLOW;
+				lrnver = lrnver1;
+			}
 		}
 
 		/*
-- 
2.26.0


^ permalink raw reply related	[flat|nested] 80+ messages in thread

* [PATCH 25/29] lib/zlib: Avoid comma separated statements
  2020-08-25  4:55 [PATCH 00/29] treewide: Convert comma separated statements Joe Perches
                   ` (23 preceding siblings ...)
  2020-08-25  4:56 ` [PATCH 24/29] reiserfs: " Joe Perches
@ 2020-08-25  4:56 ` Joe Perches
  2021-01-30 19:05   ` Joe Perches
  2020-08-25  4:56 ` [PATCH 26/29] lib: zstd: " Joe Perches
                   ` (4 subsequent siblings)
  29 siblings, 1 reply; 80+ messages in thread
From: Joe Perches @ 2020-08-25  4:56 UTC (permalink / raw)
  To: Jiri Kosina, linux-kernel

Use semicolons and braces.

Signed-off-by: Joe Perches <joe@perches.com>
---
 lib/zlib_deflate/deftree.c | 49 +++++++++++++++++++++++++++-----------
 1 file changed, 35 insertions(+), 14 deletions(-)

diff --git a/lib/zlib_deflate/deftree.c b/lib/zlib_deflate/deftree.c
index a4a34da512fe..e358053bdb15 100644
--- a/lib/zlib_deflate/deftree.c
+++ b/lib/zlib_deflate/deftree.c
@@ -217,10 +217,22 @@ static void tr_static_init(void)
     /* Construct the codes of the static literal tree */
     for (bits = 0; bits <= MAX_BITS; bits++) bl_count[bits] = 0;
     n = 0;
-    while (n <= 143) static_ltree[n++].Len = 8, bl_count[8]++;
-    while (n <= 255) static_ltree[n++].Len = 9, bl_count[9]++;
-    while (n <= 279) static_ltree[n++].Len = 7, bl_count[7]++;
-    while (n <= 287) static_ltree[n++].Len = 8, bl_count[8]++;
+    while (n <= 143) {
+        static_ltree[n++].Len = 8;
+	bl_count[8]++;
+    }
+    while (n <= 255) {
+        static_ltree[n++].Len = 9;
+	bl_count[9]++;
+    }
+    while (n <= 279) {
+        static_ltree[n++].Len = 7;
+	bl_count[7]++;
+    }
+    while (n <= 287) {
+        static_ltree[n++].Len = 8;
+	bl_count[8]++;
+    }
     /* Codes 286 and 287 do not exist, but we must include them in the
      * tree construction to get a canonical Huffman tree (longest code
      * all ones)
@@ -378,7 +390,10 @@ static void gen_bitlen(
     for (h = s->heap_max+1; h < HEAP_SIZE; h++) {
         n = s->heap[h];
         bits = tree[tree[n].Dad].Len + 1;
-        if (bits > max_length) bits = max_length, overflow++;
+        if (bits > max_length) {
+            bits = max_length;
+	    overflow++;
+        }
         tree[n].Len = (ush)bits;
         /* We overwrite tree[n].Dad which is no longer needed */
 
@@ -497,7 +512,7 @@ static void build_tree(
      * heap[SMALLEST]. The sons of heap[n] are heap[2*n] and heap[2*n+1].
      * heap[0] is not used.
      */
-    s->heap_len = 0, s->heap_max = HEAP_SIZE;
+    s->heap_len = 0; s->heap_max = HEAP_SIZE;
 
     for (n = 0; n < elems; n++) {
         if (tree[n].Freq != 0) {
@@ -583,7 +598,10 @@ static void scan_tree(
     int max_count = 7;         /* max repeat count */
     int min_count = 4;         /* min repeat count */
 
-    if (nextlen == 0) max_count = 138, min_count = 3;
+    if (nextlen == 0) {
+        max_count = 138;
+	min_count = 3;
+    }
     tree[max_code+1].Len = (ush)0xffff; /* guard */
 
     for (n = 0; n <= max_code; n++) {
@@ -602,11 +620,11 @@ static void scan_tree(
         }
         count = 0; prevlen = curlen;
         if (nextlen == 0) {
-            max_count = 138, min_count = 3;
+            max_count = 138; min_count = 3;
         } else if (curlen == nextlen) {
-            max_count = 6, min_count = 3;
+            max_count = 6; min_count = 3;
         } else {
-            max_count = 7, min_count = 4;
+            max_count = 7; min_count = 4;
         }
     }
 }
@@ -630,7 +648,10 @@ static void send_tree(
     int min_count = 4;         /* min repeat count */
 
     /* tree[max_code+1].Len = -1; */  /* guard already set */
-    if (nextlen == 0) max_count = 138, min_count = 3;
+    if (nextlen == 0) {
+        max_count = 138;
+	min_count = 3;
+    }
 
     for (n = 0; n <= max_code; n++) {
         curlen = nextlen; nextlen = tree[n+1].Len;
@@ -654,11 +675,11 @@ static void send_tree(
         }
         count = 0; prevlen = curlen;
         if (nextlen == 0) {
-            max_count = 138, min_count = 3;
+            max_count = 138; min_count = 3;
         } else if (curlen == nextlen) {
-            max_count = 6, min_count = 3;
+            max_count = 6; min_count = 3;
         } else {
-            max_count = 7, min_count = 4;
+            max_count = 7; min_count = 4;
         }
     }
 }
-- 
2.26.0


^ permalink raw reply related	[flat|nested] 80+ messages in thread

* [PATCH 26/29] lib: zstd: Avoid comma separated statements
  2020-08-25  4:55 [PATCH 00/29] treewide: Convert comma separated statements Joe Perches
                   ` (24 preceding siblings ...)
  2020-08-25  4:56 ` [PATCH 25/29] lib/zlib: " Joe Perches
@ 2020-08-25  4:56 ` Joe Perches
  2021-01-30 19:06   ` Joe Perches
  2020-08-25  4:56 ` [PATCH 27/29] ipv6: fib6: " Joe Perches
                   ` (3 subsequent siblings)
  29 siblings, 1 reply; 80+ messages in thread
From: Joe Perches @ 2020-08-25  4:56 UTC (permalink / raw)
  To: Jiri Kosina, linux-kernel

Use semicolons and braces.

Signed-off-by: Joe Perches <joe@perches.com>
---
 lib/zstd/compress.c     | 120 ++++++++++++++++++++++++++--------------
 lib/zstd/fse_compress.c |  24 +++++---
 lib/zstd/huf_compress.c |   6 +-
 3 files changed, 100 insertions(+), 50 deletions(-)

diff --git a/lib/zstd/compress.c b/lib/zstd/compress.c
index b080264ed3ad..d8587e458665 100644
--- a/lib/zstd/compress.c
+++ b/lib/zstd/compress.c
@@ -629,12 +629,17 @@ ZSTD_STATIC size_t ZSTD_compressSequences_internal(ZSTD_CCtx *zc, void *dst, siz
 	/* Sequences Header */
 	if ((oend - op) < 3 /*max nbSeq Size*/ + 1 /*seqHead */)
 		return ERROR(dstSize_tooSmall);
-	if (nbSeq < 0x7F)
+	if (nbSeq < 0x7F) {
 		*op++ = (BYTE)nbSeq;
-	else if (nbSeq < LONGNBSEQ)
-		op[0] = (BYTE)((nbSeq >> 8) + 0x80), op[1] = (BYTE)nbSeq, op += 2;
-	else
-		op[0] = 0xFF, ZSTD_writeLE16(op + 1, (U16)(nbSeq - LONGNBSEQ)), op += 3;
+	} else if (nbSeq < LONGNBSEQ) {
+		op[0] = (BYTE)((nbSeq >> 8) + 0x80);
+		op[1] = (BYTE)nbSeq;
+		op += 2;
+	} else {
+		op[0] = 0xFF;
+		ZSTD_writeLE16(op + 1, (U16)(nbSeq - LONGNBSEQ));
+		op += 3;
+	}
 	if (nbSeq == 0)
 		return op - ostart;
 
@@ -1025,10 +1030,13 @@ void ZSTD_compressBlock_fast_generic(ZSTD_CCtx *cctx, const void *src, size_t sr
 	ip += (ip == lowest);
 	{
 		U32 const maxRep = (U32)(ip - lowest);
-		if (offset_2 > maxRep)
-			offsetSaved = offset_2, offset_2 = 0;
-		if (offset_1 > maxRep)
-			offsetSaved = offset_1, offset_1 = 0;
+		if (offset_2 > maxRep) {
+			offsetSaved = offset_2;
+			offset_2 = 0;
+		}
+		if (offset_1 > maxRep) {
+			offsetSaved = offset_1; offset_1 = 0;
+		}
 	}
 
 	/* Main Search Loop */
@@ -1273,10 +1281,14 @@ void ZSTD_compressBlock_doubleFast_generic(ZSTD_CCtx *cctx, const void *src, siz
 	ip += (ip == lowest);
 	{
 		U32 const maxRep = (U32)(ip - lowest);
-		if (offset_2 > maxRep)
-			offsetSaved = offset_2, offset_2 = 0;
-		if (offset_1 > maxRep)
-			offsetSaved = offset_1, offset_1 = 0;
+		if (offset_2 > maxRep) {
+			offsetSaved = offset_2;
+			offset_2 = 0;
+		}
+		if (offset_1 > maxRep) {
+			offsetSaved = offset_1;
+			offset_1 = 0;
+		}
 	}
 
 	/* Main Search Loop */
@@ -1686,8 +1698,10 @@ static size_t ZSTD_insertBtAndFindBestMatch(ZSTD_CCtx *zc, const BYTE *const ip,
 		if (matchLength > bestLength) {
 			if (matchLength > matchEndIdx - matchIndex)
 				matchEndIdx = matchIndex + (U32)matchLength;
-			if ((4 * (int)(matchLength - bestLength)) > (int)(ZSTD_highbit32(curr - matchIndex + 1) - ZSTD_highbit32((U32)offsetPtr[0] + 1)))
-				bestLength = matchLength, *offsetPtr = ZSTD_REP_MOVE + curr - matchIndex;
+			if ((4 * (int)(matchLength - bestLength)) > (int)(ZSTD_highbit32(curr - matchIndex + 1) - ZSTD_highbit32((U32)offsetPtr[0] + 1))) {
+				bestLength = matchLength;
+				*offsetPtr = ZSTD_REP_MOVE + curr - matchIndex;
+			}
 			if (ip + matchLength == iend) /* equal : no way to know if inf or sup */
 				break;		      /* drop, to guarantee consistency (miss a little bit of compression) */
 		}
@@ -1916,10 +1930,14 @@ void ZSTD_compressBlock_lazy_generic(ZSTD_CCtx *ctx, const void *src, size_t src
 	ctx->nextToUpdate3 = ctx->nextToUpdate;
 	{
 		U32 const maxRep = (U32)(ip - base);
-		if (offset_2 > maxRep)
-			savedOffset = offset_2, offset_2 = 0;
-		if (offset_1 > maxRep)
-			savedOffset = offset_1, offset_1 = 0;
+		if (offset_2 > maxRep) {
+			savedOffset = offset_2;
+			offset_2 = 0;
+		}
+		if (offset_1 > maxRep) {
+			savedOffset = offset_1;
+			offset_1 = 0;
+		}
 	}
 
 	/* Match Loop */
@@ -1940,8 +1958,11 @@ void ZSTD_compressBlock_lazy_generic(ZSTD_CCtx *ctx, const void *src, size_t src
 		{
 			size_t offsetFound = 99999999;
 			size_t const ml2 = searchMax(ctx, ip, iend, &offsetFound, maxSearches, mls);
-			if (ml2 > matchLength)
-				matchLength = ml2, start = ip, offset = offsetFound;
+			if (ml2 > matchLength) {
+				matchLength = ml2;
+				start = ip;
+				offset = offsetFound;
+			}
 		}
 
 		if (matchLength < EQUAL_READ32) {
@@ -1957,8 +1978,11 @@ void ZSTD_compressBlock_lazy_generic(ZSTD_CCtx *ctx, const void *src, size_t src
 					size_t const mlRep = ZSTD_count(ip + EQUAL_READ32, ip + EQUAL_READ32 - offset_1, iend) + EQUAL_READ32;
 					int const gain2 = (int)(mlRep * 3);
 					int const gain1 = (int)(matchLength * 3 - ZSTD_highbit32((U32)offset + 1) + 1);
-					if ((mlRep >= EQUAL_READ32) && (gain2 > gain1))
-						matchLength = mlRep, offset = 0, start = ip;
+					if ((mlRep >= EQUAL_READ32) && (gain2 > gain1)) {
+						matchLength = mlRep;
+						offset = 0;
+						start = ip;
+					}
 				}
 				{
 					size_t offset2 = 99999999;
@@ -1966,7 +1990,7 @@ void ZSTD_compressBlock_lazy_generic(ZSTD_CCtx *ctx, const void *src, size_t src
 					int const gain2 = (int)(ml2 * 4 - ZSTD_highbit32((U32)offset2 + 1)); /* raw approx */
 					int const gain1 = (int)(matchLength * 4 - ZSTD_highbit32((U32)offset + 1) + 4);
 					if ((ml2 >= EQUAL_READ32) && (gain2 > gain1)) {
-						matchLength = ml2, offset = offset2, start = ip;
+						matchLength = ml2, offset = offset2; start = ip;
 						continue; /* search a better one */
 					}
 				}
@@ -1978,8 +2002,11 @@ void ZSTD_compressBlock_lazy_generic(ZSTD_CCtx *ctx, const void *src, size_t src
 						size_t const ml2 = ZSTD_count(ip + EQUAL_READ32, ip + EQUAL_READ32 - offset_1, iend) + EQUAL_READ32;
 						int const gain2 = (int)(ml2 * 4);
 						int const gain1 = (int)(matchLength * 4 - ZSTD_highbit32((U32)offset + 1) + 1);
-						if ((ml2 >= EQUAL_READ32) && (gain2 > gain1))
-							matchLength = ml2, offset = 0, start = ip;
+						if ((ml2 >= EQUAL_READ32) && (gain2 > gain1)) {
+							matchLength = ml2;
+							offset = 0;
+							start = ip;
+						}
 					}
 					{
 						size_t offset2 = 99999999;
@@ -1987,7 +2014,7 @@ void ZSTD_compressBlock_lazy_generic(ZSTD_CCtx *ctx, const void *src, size_t src
 						int const gain2 = (int)(ml2 * 4 - ZSTD_highbit32((U32)offset2 + 1)); /* raw approx */
 						int const gain1 = (int)(matchLength * 4 - ZSTD_highbit32((U32)offset + 1) + 7);
 						if ((ml2 >= EQUAL_READ32) && (gain2 > gain1)) {
-							matchLength = ml2, offset = offset2, start = ip;
+							matchLength = ml2, offset = offset2; start = ip;
 							continue;
 						}
 					}
@@ -2110,8 +2137,11 @@ void ZSTD_compressBlock_lazy_extDict_generic(ZSTD_CCtx *ctx, const void *src, si
 		{
 			size_t offsetFound = 99999999;
 			size_t const ml2 = searchMax(ctx, ip, iend, &offsetFound, maxSearches, mls);
-			if (ml2 > matchLength)
-				matchLength = ml2, start = ip, offset = offsetFound;
+			if (ml2 > matchLength) {
+				matchLength = ml2;
+				start = ip;
+				offset = offsetFound;
+			}
 		}
 
 		if (matchLength < EQUAL_READ32) {
@@ -2138,8 +2168,11 @@ void ZSTD_compressBlock_lazy_extDict_generic(ZSTD_CCtx *ctx, const void *src, si
 							    EQUAL_READ32;
 							int const gain2 = (int)(repLength * 3);
 							int const gain1 = (int)(matchLength * 3 - ZSTD_highbit32((U32)offset + 1) + 1);
-							if ((repLength >= EQUAL_READ32) && (gain2 > gain1))
-								matchLength = repLength, offset = 0, start = ip;
+							if ((repLength >= EQUAL_READ32) && (gain2 > gain1)) {
+								matchLength = repLength;
+								offset = 0;
+								start = ip;
+							}
 						}
 				}
 
@@ -2150,7 +2183,7 @@ void ZSTD_compressBlock_lazy_extDict_generic(ZSTD_CCtx *ctx, const void *src, si
 					int const gain2 = (int)(ml2 * 4 - ZSTD_highbit32((U32)offset2 + 1)); /* raw approx */
 					int const gain1 = (int)(matchLength * 4 - ZSTD_highbit32((U32)offset + 1) + 4);
 					if ((ml2 >= EQUAL_READ32) && (gain2 > gain1)) {
-						matchLength = ml2, offset = offset2, start = ip;
+						matchLength = ml2, offset = offset2; start = ip;
 						continue; /* search a better one */
 					}
 				}
@@ -2173,8 +2206,11 @@ void ZSTD_compressBlock_lazy_extDict_generic(ZSTD_CCtx *ctx, const void *src, si
 										   EQUAL_READ32;
 								int gain2 = (int)(repLength * 4);
 								int gain1 = (int)(matchLength * 4 - ZSTD_highbit32((U32)offset + 1) + 1);
-								if ((repLength >= EQUAL_READ32) && (gain2 > gain1))
-									matchLength = repLength, offset = 0, start = ip;
+								if ((repLength >= EQUAL_READ32) && (gain2 > gain1)) {
+									matchLength = repLength;
+									offset = 0;
+									start = ip;
+								}
 							}
 					}
 
@@ -2185,7 +2221,7 @@ void ZSTD_compressBlock_lazy_extDict_generic(ZSTD_CCtx *ctx, const void *src, si
 						int const gain2 = (int)(ml2 * 4 - ZSTD_highbit32((U32)offset2 + 1)); /* raw approx */
 						int const gain1 = (int)(matchLength * 4 - ZSTD_highbit32((U32)offset + 1) + 7);
 						if ((ml2 >= EQUAL_READ32) && (gain2 > gain1)) {
-							matchLength = ml2, offset = offset2, start = ip;
+							matchLength = ml2, offset = offset2; start = ip;
 							continue;
 						}
 					}
@@ -3159,10 +3195,12 @@ static size_t ZSTD_compressStream_generic(ZSTD_CStream *zcs, void *dst, size_t *
 				size_t cSize;
 				size_t const iSize = zcs->inBuffPos - zcs->inToCompress;
 				size_t oSize = oend - op;
-				if (oSize >= ZSTD_compressBound(iSize))
+				if (oSize >= ZSTD_compressBound(iSize)) {
 					cDst = op; /* compress directly into output buffer (avoid flush stage) */
-				else
-					cDst = zcs->outBuff, oSize = zcs->outBuffSize;
+				} else {
+					cDst = zcs->outBuff;
+					oSize = zcs->outBuffSize;
+				}
 				cSize = (flush == zsf_end) ? ZSTD_compressEnd(zcs->cctx, cDst, oSize, zcs->inBuff + zcs->inToCompress, iSize)
 							   : ZSTD_compressContinue(zcs->cctx, cDst, oSize, zcs->inBuff + zcs->inToCompress, iSize);
 				if (ZSTD_isError(cSize))
@@ -3171,8 +3209,10 @@ static size_t ZSTD_compressStream_generic(ZSTD_CStream *zcs, void *dst, size_t *
 					zcs->frameEnded = 1;
 				/* prepare next block */
 				zcs->inBuffTarget = zcs->inBuffPos + zcs->blockSize;
-				if (zcs->inBuffTarget > zcs->inBuffSize)
-					zcs->inBuffPos = 0, zcs->inBuffTarget = zcs->blockSize; /* note : inBuffSize >= blockSize */
+				if (zcs->inBuffTarget > zcs->inBuffSize) {
+					zcs->inBuffPos = 0;
+					zcs->inBuffTarget = zcs->blockSize;
+				} /* note : inBuffSize >= blockSize */
 				zcs->inToCompress = zcs->inBuffPos;
 				if (cDst == op) {
 					op += cSize;
diff --git a/lib/zstd/fse_compress.c b/lib/zstd/fse_compress.c
index ef3d1741d532..99a21c35d0ac 100644
--- a/lib/zstd/fse_compress.c
+++ b/lib/zstd/fse_compress.c
@@ -271,8 +271,10 @@ static size_t FSE_writeNCount_generic(void *header, size_t headerBufferSize, con
 			previous0 = (count == 1);
 			if (remaining < 1)
 				return ERROR(GENERIC);
-			while (remaining < threshold)
-				nbBits--, threshold >>= 1;
+			while (remaining < threshold) {
+				nbBits--;
+				threshold >>= 1;
+			}
 		}
 		if (bitCount > 16) {
 			if ((!writeIsSafe) && (out > oend - 2))
@@ -569,8 +571,10 @@ static size_t FSE_normalizeM2(short *norm, U32 tableLog, const unsigned *count,
 		   find max, then give all remaining points to max */
 		U32 maxV = 0, maxC = 0;
 		for (s = 0; s <= maxSymbolValue; s++)
-			if (count[s] > maxC)
-				maxV = s, maxC = count[s];
+			if (count[s] > maxC) {
+				maxV = s;
+				maxC = count[s];
+			}
 		norm[maxV] += (short)ToDistribute;
 		return 0;
 	}
@@ -578,8 +582,10 @@ static size_t FSE_normalizeM2(short *norm, U32 tableLog, const unsigned *count,
 	if (total == 0) {
 		/* all of the symbols were low enough for the lowOne or lowThreshold */
 		for (s = 0; ToDistribute > 0; s = (s + 1) % (maxSymbolValue + 1))
-			if (norm[s] > 0)
-				ToDistribute--, norm[s]++;
+			if (norm[s] > 0) {
+				ToDistribute--;
+				norm[s]++;
+			}
 		return 0;
 	}
 
@@ -644,8 +650,10 @@ size_t FSE_normalizeCount(short *normalizedCounter, unsigned tableLog, const uns
 					U64 restToBeat = vStep * rtbTable[proba];
 					proba += (count[s] * step) - ((U64)proba << scale) > restToBeat;
 				}
-				if (proba > largestP)
-					largestP = proba, largest = s;
+				if (proba > largestP) {
+					largestP = proba;
+					largest = s;
+				}
 				normalizedCounter[s] = proba;
 				stillToDistribute -= proba;
 			}
diff --git a/lib/zstd/huf_compress.c b/lib/zstd/huf_compress.c
index 08b4ae80aed4..ca12ab400086 100644
--- a/lib/zstd/huf_compress.c
+++ b/lib/zstd/huf_compress.c
@@ -404,8 +404,10 @@ static void HUF_sort(nodeElt *huffNode, const U32 *count, U32 maxSymbolValue)
 		U32 const c = count[n];
 		U32 const r = BIT_highbit32(c + 1) + 1;
 		U32 pos = rank[r].curr++;
-		while ((pos > rank[r].base) && (c > huffNode[pos - 1].count))
-			huffNode[pos] = huffNode[pos - 1], pos--;
+		while ((pos > rank[r].base) && (c > huffNode[pos - 1].count)) {
+			huffNode[pos] = huffNode[pos - 1];
+			pos--;
+		}
 		huffNode[pos].count = c;
 		huffNode[pos].byte = (BYTE)n;
 	}
-- 
2.26.0


^ permalink raw reply related	[flat|nested] 80+ messages in thread

* [PATCH 27/29] ipv6: fib6: Avoid comma separated statements
  2020-08-25  4:55 [PATCH 00/29] treewide: Convert comma separated statements Joe Perches
                   ` (25 preceding siblings ...)
  2020-08-25  4:56 ` [PATCH 26/29] lib: zstd: " Joe Perches
@ 2020-08-25  4:56 ` Joe Perches
  2020-08-25 14:55   ` David Miller
  2020-08-25  4:56 ` [PATCH 28/29] sunrpc: " Joe Perches
                   ` (2 subsequent siblings)
  29 siblings, 1 reply; 80+ messages in thread
From: Joe Perches @ 2020-08-25  4:56 UTC (permalink / raw)
  To: Jiri Kosina, David S. Miller, Alexey Kuznetsov, Hideaki YOSHIFUJI
  Cc: Jakub Kicinski, netdev, linux-kernel

Use semicolons and braces.

Signed-off-by: Joe Perches <joe@perches.com>
---
 net/ipv6/ip6_fib.c | 12 ++++++++----
 1 file changed, 8 insertions(+), 4 deletions(-)

diff --git a/net/ipv6/ip6_fib.c b/net/ipv6/ip6_fib.c
index 25a90f3f705c..44d68ed70f24 100644
--- a/net/ipv6/ip6_fib.c
+++ b/net/ipv6/ip6_fib.c
@@ -1812,10 +1812,14 @@ static struct fib6_node *fib6_repair_tree(struct net *net,
 
 		children = 0;
 		child = NULL;
-		if (fn_r)
-			child = fn_r, children |= 1;
-		if (fn_l)
-			child = fn_l, children |= 2;
+		if (fn_r) {
+			child = fn_r;
+			children |= 1;
+		}
+		if (fn_l) {
+			child = fn_l;
+			children |= 2;
+		}
 
 		if (children == 3 || FIB6_SUBTREE(fn)
 #ifdef CONFIG_IPV6_SUBTREES
-- 
2.26.0


^ permalink raw reply related	[flat|nested] 80+ messages in thread

* [PATCH 28/29] sunrpc: Avoid comma separated statements
  2020-08-25  4:55 [PATCH 00/29] treewide: Convert comma separated statements Joe Perches
                   ` (26 preceding siblings ...)
  2020-08-25  4:56 ` [PATCH 27/29] ipv6: fib6: " Joe Perches
@ 2020-08-25  4:56 ` Joe Perches
  2020-08-25 14:55   ` David Miller
  2020-08-25  4:56 ` [PATCH 29/29] tools: " Joe Perches
  2020-09-09  2:09 ` [PATCH 00/29] treewide: Convert " Martin K. Petersen
  29 siblings, 1 reply; 80+ messages in thread
From: Joe Perches @ 2020-08-25  4:56 UTC (permalink / raw)
  To: Jiri Kosina, Trond Myklebust, Anna Schumaker, J. Bruce Fields,
	Chuck Lever
  Cc: David S. Miller, Jakub Kicinski, linux-nfs, netdev, linux-kernel

Use semicolons and braces.

Signed-off-by: Joe Perches <joe@perches.com>
---
 net/sunrpc/sysctl.c | 6 ++++--
 1 file changed, 4 insertions(+), 2 deletions(-)

diff --git a/net/sunrpc/sysctl.c b/net/sunrpc/sysctl.c
index 999eee1ed61c..6c86e2a7d942 100644
--- a/net/sunrpc/sysctl.c
+++ b/net/sunrpc/sysctl.c
@@ -108,8 +108,10 @@ proc_dodebug(struct ctl_table *table, int write, void *buffer, size_t *lenp,
 			left -= (s - tmpbuf);
 			if (left && !isspace(*s))
 				return -EINVAL;
-			while (left && isspace(*s))
-				left--, s++;
+			while (left && isspace(*s)) {
+				left--;
+				s++;
+			}
 		} else
 			left = 0;
 		*(unsigned int *) table->data = value;
-- 
2.26.0


^ permalink raw reply related	[flat|nested] 80+ messages in thread

* [PATCH 29/29] tools: Avoid comma separated statements
  2020-08-25  4:55 [PATCH 00/29] treewide: Convert comma separated statements Joe Perches
                   ` (27 preceding siblings ...)
  2020-08-25  4:56 ` [PATCH 28/29] sunrpc: " Joe Perches
@ 2020-08-25  4:56 ` Joe Perches
  2020-08-26  9:30   ` Thomas Renninger
  2020-09-09  2:09 ` [PATCH 00/29] treewide: Convert " Martin K. Petersen
  29 siblings, 1 reply; 80+ messages in thread
From: Joe Perches @ 2020-08-25  4:56 UTC (permalink / raw)
  To: Jiri Kosina, linux-kernel
  Cc: Thomas Renninger, Shuah Khan, linux-pm, linux-kselftest

Use semicolons and braces.

Signed-off-by: Joe Perches <joe@perches.com>
---
 tools/lib/subcmd/help.c                    |  10 +-
 tools/power/cpupower/utils/cpufreq-set.c   |  14 +-
 tools/testing/selftests/vm/gup_benchmark.c |  18 +-
 tools/testing/selftests/vm/userfaultfd.c   | 296 +++++++++++++--------
 4 files changed, 210 insertions(+), 128 deletions(-)

diff --git a/tools/lib/subcmd/help.c b/tools/lib/subcmd/help.c
index 2859f107abc8..bf02d62a3b2b 100644
--- a/tools/lib/subcmd/help.c
+++ b/tools/lib/subcmd/help.c
@@ -65,12 +65,14 @@ void exclude_cmds(struct cmdnames *cmds, struct cmdnames *excludes)
 	ci = cj = ei = 0;
 	while (ci < cmds->cnt && ei < excludes->cnt) {
 		cmp = strcmp(cmds->names[ci]->name, excludes->names[ei]->name);
-		if (cmp < 0)
+		if (cmp < 0) {
 			cmds->names[cj++] = cmds->names[ci++];
-		else if (cmp == 0)
-			ci++, ei++;
-		else if (cmp > 0)
+		} else if (cmp == 0) {
+			ci++;
 			ei++;
+		} else if (cmp > 0) {
+			ei++;
+		}
 	}
 
 	while (ci < cmds->cnt)
diff --git a/tools/power/cpupower/utils/cpufreq-set.c b/tools/power/cpupower/utils/cpufreq-set.c
index 6ed82fba5aaa..7b2164e07057 100644
--- a/tools/power/cpupower/utils/cpufreq-set.c
+++ b/tools/power/cpupower/utils/cpufreq-set.c
@@ -99,13 +99,17 @@ static unsigned long string_to_frequency(const char *str)
 		continue;
 
 	if (str[cp] == '.') {
-		while (power > -1 && isdigit(str[cp+1]))
-			cp++, power--;
+		while (power > -1 && isdigit(str[cp+1])) {
+			cp++;
+			power--;
+		}
 	}
-	if (power >= -1)	/* not enough => pad */
+	if (power >= -1) {		/* not enough => pad */
 		pad = power + 1;
-	else			/* to much => strip */
-		pad = 0, cp += power + 1;
+	} else {			/* too much => strip */
+		pad = 0;
+		cp += power + 1;
+	}
 	/* check bounds */
 	if (cp <= 0 || cp + pad > NORM_FREQ_LEN - 1)
 		return 0;
diff --git a/tools/testing/selftests/vm/gup_benchmark.c b/tools/testing/selftests/vm/gup_benchmark.c
index 31f8bb086907..1d4359341e44 100644
--- a/tools/testing/selftests/vm/gup_benchmark.c
+++ b/tools/testing/selftests/vm/gup_benchmark.c
@@ -105,12 +105,16 @@ int main(int argc, char **argv)
 		gup.flags |= FOLL_WRITE;
 
 	fd = open("/sys/kernel/debug/gup_benchmark", O_RDWR);
-	if (fd == -1)
-		perror("open"), exit(1);
+	if (fd == -1) {
+		perror("open");
+		exit(1);
+	}
 
 	p = mmap(NULL, size, PROT_READ | PROT_WRITE, flags, filed, 0);
-	if (p == MAP_FAILED)
-		perror("mmap"), exit(1);
+	if (p == MAP_FAILED) {
+		perror("mmap");
+		exit(1);
+	}
 	gup.addr = (unsigned long)p;
 
 	if (thp == 1)
@@ -123,8 +127,10 @@ int main(int argc, char **argv)
 
 	for (i = 0; i < repeats; i++) {
 		gup.size = size;
-		if (ioctl(fd, cmd, &gup))
-			perror("ioctl"), exit(1);
+		if (ioctl(fd, cmd, &gup)) {
+			perror("ioctl");
+			exit(1);
+		}
 
 		printf("Time: get:%lld put:%lld us", gup.get_delta_usec,
 			gup.put_delta_usec);
diff --git a/tools/testing/selftests/vm/userfaultfd.c b/tools/testing/selftests/vm/userfaultfd.c
index 61e5cfeb1350..9b0912a01777 100644
--- a/tools/testing/selftests/vm/userfaultfd.c
+++ b/tools/testing/selftests/vm/userfaultfd.c
@@ -227,8 +227,10 @@ static void hugetlb_allocate_area(void **alloc_area)
 				  huge_fd, *alloc_area == area_src ? 0 :
 				  nr_pages * page_size);
 		if (area_alias == MAP_FAILED) {
-			if (munmap(*alloc_area, nr_pages * page_size) < 0)
-				perror("hugetlb munmap"), exit(1);
+			if (munmap(*alloc_area, nr_pages * page_size) < 0) {
+				perror("hugetlb munmap");
+				exit(1);
+			}
 			*alloc_area = NULL;
 			return;
 		}
@@ -337,9 +339,10 @@ static void wp_range(int ufd, __u64 start, __u64 len, bool wp)
 	/* Undo write-protect, do wakeup after that */
 	prms.mode = wp ? UFFDIO_WRITEPROTECT_MODE_WP : 0;
 
-	if (ioctl(ufd, UFFDIO_WRITEPROTECT, &prms))
-		fprintf(stderr, "clear WP failed for address 0x%Lx\n",
-			start), exit(1);
+	if (ioctl(ufd, UFFDIO_WRITEPROTECT, &prms)) {
+		fprintf(stderr, "clear WP failed for address 0x%Lx\n", start);
+		exit(1);
+	}
 }
 
 static void *locking_thread(void *arg)
@@ -359,8 +362,10 @@ static void *locking_thread(void *arg)
 			seed += cpu;
 		bzero(&rand, sizeof(rand));
 		bzero(&randstate, sizeof(randstate));
-		if (initstate_r(seed, randstate, sizeof(randstate), &rand))
-			fprintf(stderr, "srandom_r error\n"), exit(1);
+		if (initstate_r(seed, randstate, sizeof(randstate), &rand)) {
+			fprintf(stderr, "srandom_r error\n");
+			exit(1);
+		}
 	} else {
 		page_nr = -bounces;
 		if (!(bounces & BOUNCE_RACINGFAULTS))
@@ -369,12 +374,16 @@ static void *locking_thread(void *arg)
 
 	while (!finished) {
 		if (bounces & BOUNCE_RANDOM) {
-			if (random_r(&rand, &rand_nr))
-				fprintf(stderr, "random_r 1 error\n"), exit(1);
+			if (random_r(&rand, &rand_nr)) {
+				fprintf(stderr, "random_r 1 error\n");
+				exit(1);
+			}
 			page_nr = rand_nr;
 			if (sizeof(page_nr) > sizeof(rand_nr)) {
-				if (random_r(&rand, &rand_nr))
-					fprintf(stderr, "random_r 2 error\n"), exit(1);
+				if (random_r(&rand, &rand_nr)) {
+					fprintf(stderr, "random_r 2 error\n");
+					exit(1);
+				}
 				page_nr |= (((unsigned long) rand_nr) << 16) <<
 					   16;
 			}
@@ -385,11 +394,13 @@ static void *locking_thread(void *arg)
 		start = time(NULL);
 		if (bounces & BOUNCE_VERIFY) {
 			count = *area_count(area_dst, page_nr);
-			if (!count)
+			if (!count) {
 				fprintf(stderr,
 					"page_nr %lu wrong count %Lu %Lu\n",
 					page_nr, count,
-					count_verify[page_nr]), exit(1);
+					count_verify[page_nr]);
+				exit(1);
+			}
 
 
 			/*
@@ -401,11 +412,12 @@ static void *locking_thread(void *arg)
 			 */
 #if 1
 			if (!my_bcmp(area_dst + page_nr * page_size, zeropage,
-				     page_size))
+				     page_size)) {
 				fprintf(stderr,
 					"my_bcmp page_nr %lu wrong count %Lu %Lu\n",
-					page_nr, count,
-					count_verify[page_nr]), exit(1);
+					page_nr, count, count_verify[page_nr]);
+				exit(1);
+			}
 #else
 			unsigned long loops;
 
@@ -437,7 +449,7 @@ static void *locking_thread(void *arg)
 			fprintf(stderr,
 				"page_nr %lu memory corruption %Lu %Lu\n",
 				page_nr, count,
-				count_verify[page_nr]), exit(1);
+				count_verify[page_nr]); exit(1);
 		}
 		count++;
 		*area_count(area_dst, page_nr) = count_verify[page_nr] = count;
@@ -461,12 +473,14 @@ static void retry_copy_page(int ufd, struct uffdio_copy *uffdio_copy,
 				     offset);
 	if (ioctl(ufd, UFFDIO_COPY, uffdio_copy)) {
 		/* real retval in ufdio_copy.copy */
-		if (uffdio_copy->copy != -EEXIST)
+		if (uffdio_copy->copy != -EEXIST) {
 			fprintf(stderr, "UFFDIO_COPY retry error %Ld\n",
-				uffdio_copy->copy), exit(1);
+				uffdio_copy->copy);
+			exit(1);
+		}
 	} else {
 		fprintf(stderr,	"UFFDIO_COPY retry unexpected %Ld\n",
-			uffdio_copy->copy), exit(1);
+			uffdio_copy->copy); exit(1);
 	}
 }
 
@@ -474,9 +488,10 @@ static int __copy_page(int ufd, unsigned long offset, bool retry)
 {
 	struct uffdio_copy uffdio_copy;
 
-	if (offset >= nr_pages * page_size)
-		fprintf(stderr, "unexpected offset %lu\n",
-			offset), exit(1);
+	if (offset >= nr_pages * page_size) {
+		fprintf(stderr, "unexpected offset %lu\n", offset);
+		exit(1);
+	}
 	uffdio_copy.dst = (unsigned long) area_dst + offset;
 	uffdio_copy.src = (unsigned long) area_src + offset;
 	uffdio_copy.len = page_size;
@@ -487,12 +502,14 @@ static int __copy_page(int ufd, unsigned long offset, bool retry)
 	uffdio_copy.copy = 0;
 	if (ioctl(ufd, UFFDIO_COPY, &uffdio_copy)) {
 		/* real retval in ufdio_copy.copy */
-		if (uffdio_copy.copy != -EEXIST)
+		if (uffdio_copy.copy != -EEXIST) {
 			fprintf(stderr, "UFFDIO_COPY error %Ld\n",
-				uffdio_copy.copy), exit(1);
+				uffdio_copy.copy);
+			exit(1);
+		}
 	} else if (uffdio_copy.copy != page_size) {
 		fprintf(stderr, "UFFDIO_COPY unexpected copy %Ld\n",
-			uffdio_copy.copy), exit(1);
+			uffdio_copy.copy); exit(1);
 	} else {
 		if (test_uffdio_copy_eexist && retry) {
 			test_uffdio_copy_eexist = false;
@@ -521,11 +538,11 @@ static int uffd_read_msg(int ufd, struct uffd_msg *msg)
 		if (ret < 0) {
 			if (errno == EAGAIN)
 				return 1;
-			else
-				perror("blocking read error"), exit(1);
+			perror("blocking read error");
 		} else {
-			fprintf(stderr, "short read\n"), exit(1);
+			fprintf(stderr, "short read\n");
 		}
+		exit(1);
 	}
 
 	return 0;
@@ -536,9 +553,10 @@ static void uffd_handle_page_fault(struct uffd_msg *msg,
 {
 	unsigned long offset;
 
-	if (msg->event != UFFD_EVENT_PAGEFAULT)
-		fprintf(stderr, "unexpected msg event %u\n",
-			msg->event), exit(1);
+	if (msg->event != UFFD_EVENT_PAGEFAULT) {
+		fprintf(stderr, "unexpected msg event %u\n", msg->event);
+		exit(1);
+	}
 
 	if (msg->arg.pagefault.flags & UFFD_PAGEFAULT_FLAG_WP) {
 		wp_range(uffd, msg->arg.pagefault.address, page_size, false);
@@ -546,8 +564,10 @@ static void uffd_handle_page_fault(struct uffd_msg *msg,
 	} else {
 		/* Missing page faults */
 		if (bounces & BOUNCE_VERIFY &&
-		    msg->arg.pagefault.flags & UFFD_PAGEFAULT_FLAG_WRITE)
-			fprintf(stderr, "unexpected write fault\n"), exit(1);
+		    msg->arg.pagefault.flags & UFFD_PAGEFAULT_FLAG_WRITE) {
+			fprintf(stderr, "unexpected write fault\n");
+			exit(1);
+		}
 
 		offset = (char *)(unsigned long)msg->arg.pagefault.address - area_dst;
 		offset &= ~(page_size-1);
@@ -574,25 +594,32 @@ static void *uffd_poll_thread(void *arg)
 
 	for (;;) {
 		ret = poll(pollfd, 2, -1);
-		if (!ret)
-			fprintf(stderr, "poll error %d\n", ret), exit(1);
-		if (ret < 0)
-			perror("poll"), exit(1);
+		if (!ret) {
+			fprintf(stderr, "poll error %d\n", ret);
+			exit(1);
+		}
+		if (ret < 0) {
+			perror("poll");
+			exit(1);
+		}
 		if (pollfd[1].revents & POLLIN) {
-			if (read(pollfd[1].fd, &tmp_chr, 1) != 1)
-				fprintf(stderr, "read pipefd error\n"),
-					exit(1);
+			if (read(pollfd[1].fd, &tmp_chr, 1) != 1) {
+				fprintf(stderr, "read pipefd error\n");
+				exit(1);
+			}
 			break;
 		}
-		if (!(pollfd[0].revents & POLLIN))
+		if (!(pollfd[0].revents & POLLIN)) {
 			fprintf(stderr, "pollfd[0].revents %d\n",
-				pollfd[0].revents), exit(1);
+				pollfd[0].revents);
+			exit(1);
+		}
 		if (uffd_read_msg(uffd, &msg))
 			continue;
 		switch (msg.event) {
 		default:
 			fprintf(stderr, "unexpected msg event %u\n",
-				msg.event), exit(1);
+				msg.event); exit(1);
 			break;
 		case UFFD_EVENT_PAGEFAULT:
 			uffd_handle_page_fault(&msg, stats);
@@ -606,8 +633,10 @@ static void *uffd_poll_thread(void *arg)
 			uffd_reg.range.start = msg.arg.remove.start;
 			uffd_reg.range.len = msg.arg.remove.end -
 				msg.arg.remove.start;
-			if (ioctl(uffd, UFFDIO_UNREGISTER, &uffd_reg.range))
-				fprintf(stderr, "remove failure\n"), exit(1);
+			if (ioctl(uffd, UFFDIO_UNREGISTER, &uffd_reg.range)) {
+				fprintf(stderr, "remove failure\n");
+				exit(1);
+			}
 			break;
 		case UFFD_EVENT_REMAP:
 			area_dst = (char *)(unsigned long)msg.arg.remap.to;
@@ -879,8 +908,10 @@ static int faulting_process(int signal_test)
 
 	area_dst = mremap(area_dst, nr_pages * page_size,  nr_pages * page_size,
 			  MREMAP_MAYMOVE | MREMAP_FIXED, area_src);
-	if (area_dst == MAP_FAILED)
-		perror("mremap"), exit(1);
+	if (area_dst == MAP_FAILED) {
+		perror("mremap");
+		exit(1);
+	}
 
 	for (; nr < nr_pages; nr++) {
 		count = *area_count(area_dst, nr);
@@ -888,7 +919,7 @@ static int faulting_process(int signal_test)
 			fprintf(stderr,
 				"nr %lu memory corruption %Lu %Lu\n",
 				nr, count,
-				count_verify[nr]), exit(1);
+				count_verify[nr]); exit(1);
 		}
 		/*
 		 * Trigger write protection if there is by writting
@@ -901,8 +932,10 @@ static int faulting_process(int signal_test)
 		return 1;
 
 	for (nr = 0; nr < nr_pages; nr++) {
-		if (my_bcmp(area_dst + nr * page_size, zeropage, page_size))
-			fprintf(stderr, "nr %lu is not zero\n", nr), exit(1);
+		if (my_bcmp(area_dst + nr * page_size, zeropage, page_size)) {
+			fprintf(stderr, "nr %lu is not zero\n", nr);
+			exit(1);
+		}
 	}
 
 	return 0;
@@ -916,12 +949,14 @@ static void retry_uffdio_zeropage(int ufd,
 				     uffdio_zeropage->range.len,
 				     offset);
 	if (ioctl(ufd, UFFDIO_ZEROPAGE, uffdio_zeropage)) {
-		if (uffdio_zeropage->zeropage != -EEXIST)
+		if (uffdio_zeropage->zeropage != -EEXIST) {
 			fprintf(stderr, "UFFDIO_ZEROPAGE retry error %Ld\n",
-				uffdio_zeropage->zeropage), exit(1);
+				uffdio_zeropage->zeropage);
+			exit(1);
+		}
 	} else {
 		fprintf(stderr, "UFFDIO_ZEROPAGE retry unexpected %Ld\n",
-			uffdio_zeropage->zeropage), exit(1);
+			uffdio_zeropage->zeropage); exit(1);
 	}
 }
 
@@ -933,9 +968,10 @@ static int __uffdio_zeropage(int ufd, unsigned long offset, bool retry)
 
 	has_zeropage = uffd_test_ops->expected_ioctls & (1 << _UFFDIO_ZEROPAGE);
 
-	if (offset >= nr_pages * page_size)
-		fprintf(stderr, "unexpected offset %lu\n",
-			offset), exit(1);
+	if (offset >= nr_pages * page_size) {
+		fprintf(stderr, "unexpected offset %lu\n", offset);
+		exit(1);
+	}
 	uffdio_zeropage.range.start = (unsigned long) area_dst + offset;
 	uffdio_zeropage.range.len = page_size;
 	uffdio_zeropage.mode = 0;
@@ -943,22 +979,26 @@ static int __uffdio_zeropage(int ufd, unsigned long offset, bool retry)
 	if (ret) {
 		/* real retval in ufdio_zeropage.zeropage */
 		if (has_zeropage) {
-			if (uffdio_zeropage.zeropage == -EEXIST)
-				fprintf(stderr, "UFFDIO_ZEROPAGE -EEXIST\n"),
-					exit(1);
-			else
+			if (uffdio_zeropage.zeropage == -EEXIST) {
+				fprintf(stderr, "UFFDIO_ZEROPAGE -EEXIST\n");
+				exit(1);
+			} else {
 				fprintf(stderr, "UFFDIO_ZEROPAGE error %Ld\n",
-					uffdio_zeropage.zeropage), exit(1);
+					uffdio_zeropage.zeropage);
+				exit(1);
+			}
 		} else {
-			if (uffdio_zeropage.zeropage != -EINVAL)
+			if (uffdio_zeropage.zeropage != -EINVAL) {
 				fprintf(stderr,
 					"UFFDIO_ZEROPAGE not -EINVAL %Ld\n",
-					uffdio_zeropage.zeropage), exit(1);
+					uffdio_zeropage.zeropage);
+				exit(1);
+			}
 		}
 	} else if (has_zeropage) {
 		if (uffdio_zeropage.zeropage != page_size) {
 			fprintf(stderr, "UFFDIO_ZEROPAGE unexpected %Ld\n",
-				uffdio_zeropage.zeropage), exit(1);
+				uffdio_zeropage.zeropage); exit(1);
 		} else {
 			if (test_uffdio_zeropage_eexist && retry) {
 				test_uffdio_zeropage_eexist = false;
@@ -970,7 +1010,7 @@ static int __uffdio_zeropage(int ufd, unsigned long offset, bool retry)
 	} else {
 		fprintf(stderr,
 			"UFFDIO_ZEROPAGE succeeded %Ld\n",
-			uffdio_zeropage.zeropage), exit(1);
+			uffdio_zeropage.zeropage); exit(1);
 	}
 
 	return 0;
@@ -1000,19 +1040,24 @@ static int userfaultfd_zeropage_test(void)
 	uffdio_register.mode = UFFDIO_REGISTER_MODE_MISSING;
 	if (test_uffdio_wp)
 		uffdio_register.mode |= UFFDIO_REGISTER_MODE_WP;
-	if (ioctl(uffd, UFFDIO_REGISTER, &uffdio_register))
-		fprintf(stderr, "register failure\n"), exit(1);
+	if (ioctl(uffd, UFFDIO_REGISTER, &uffdio_register)) {
+		fprintf(stderr, "register failure\n");
+		exit(1);
+	}
 
 	expected_ioctls = uffd_test_ops->expected_ioctls;
 	if ((uffdio_register.ioctls & expected_ioctls) !=
-	    expected_ioctls)
+	    expected_ioctls) {
 		fprintf(stderr,
-			"unexpected missing ioctl for anon memory\n"),
-			exit(1);
+			"unexpected missing ioctl for anon memory\n");
+		exit(1);
+	}
 
 	if (uffdio_zeropage(uffd, 0)) {
-		if (my_bcmp(area_dst, zeropage, page_size))
-			fprintf(stderr, "zeropage is not zero\n"), exit(1);
+		if (my_bcmp(area_dst, zeropage, page_size)) {
+			fprintf(stderr, "zeropage is not zero\n");
+			exit(1);
+		}
 	}
 
 	close(uffd);
@@ -1047,32 +1092,41 @@ static int userfaultfd_events_test(void)
 	uffdio_register.mode = UFFDIO_REGISTER_MODE_MISSING;
 	if (test_uffdio_wp)
 		uffdio_register.mode |= UFFDIO_REGISTER_MODE_WP;
-	if (ioctl(uffd, UFFDIO_REGISTER, &uffdio_register))
-		fprintf(stderr, "register failure\n"), exit(1);
+	if (ioctl(uffd, UFFDIO_REGISTER, &uffdio_register)) {
+		fprintf(stderr, "register failure\n");
+		exit(1);
+	}
 
 	expected_ioctls = uffd_test_ops->expected_ioctls;
-	if ((uffdio_register.ioctls & expected_ioctls) !=
-	    expected_ioctls)
-		fprintf(stderr,
-			"unexpected missing ioctl for anon memory\n"),
-			exit(1);
+	if ((uffdio_register.ioctls & expected_ioctls) != expected_ioctls) {
+		fprintf(stderr, "unexpected missing ioctl for anon memory\n");
+		exit(1);
+	}
 
-	if (pthread_create(&uffd_mon, &attr, uffd_poll_thread, &stats))
-		perror("uffd_poll_thread create"), exit(1);
+	if (pthread_create(&uffd_mon, &attr, uffd_poll_thread, &stats)) {
+		perror("uffd_poll_thread create");
+		exit(1);
+	}
 
 	pid = fork();
-	if (pid < 0)
-		perror("fork"), exit(1);
+	if (pid < 0) {
+		perror("fork");
+		exit(1);
+	}
 
 	if (!pid)
 		return faulting_process(0);
 
 	waitpid(pid, &err, 0);
-	if (err)
-		fprintf(stderr, "faulting process failed\n"), exit(1);
+	if (err) {
+		fprintf(stderr, "faulting process failed\n");
+		exit(1);
+	}
 
-	if (write(pipefd[1], &c, sizeof(c)) != sizeof(c))
-		perror("pipe write"), exit(1);
+	if (write(pipefd[1], &c, sizeof(c)) != sizeof(c)) {
+		perror("pipe write");
+		exit(1);
+	}
 	if (pthread_join(uffd_mon, NULL))
 		return 1;
 
@@ -1110,38 +1164,49 @@ static int userfaultfd_sig_test(void)
 	uffdio_register.mode = UFFDIO_REGISTER_MODE_MISSING;
 	if (test_uffdio_wp)
 		uffdio_register.mode |= UFFDIO_REGISTER_MODE_WP;
-	if (ioctl(uffd, UFFDIO_REGISTER, &uffdio_register))
-		fprintf(stderr, "register failure\n"), exit(1);
+	if (ioctl(uffd, UFFDIO_REGISTER, &uffdio_register)) {
+		fprintf(stderr, "register failure\n");
+		exit(1);
+	}
 
 	expected_ioctls = uffd_test_ops->expected_ioctls;
-	if ((uffdio_register.ioctls & expected_ioctls) !=
-	    expected_ioctls)
-		fprintf(stderr,
-			"unexpected missing ioctl for anon memory\n"),
-			exit(1);
+	if ((uffdio_register.ioctls & expected_ioctls) != expected_ioctls) {
+		fprintf(stderr, "unexpected missing ioctl for anon memory\n");
+		exit(1);
+	}
 
-	if (faulting_process(1))
-		fprintf(stderr, "faulting process failed\n"), exit(1);
+	if (faulting_process(1)) {
+		fprintf(stderr, "faulting process failed\n");
+		exit(1);
+	}
 
 	if (uffd_test_ops->release_pages(area_dst))
 		return 1;
 
-	if (pthread_create(&uffd_mon, &attr, uffd_poll_thread, &stats))
-		perror("uffd_poll_thread create"), exit(1);
+	if (pthread_create(&uffd_mon, &attr, uffd_poll_thread, &stats)) {
+		perror("uffd_poll_thread create");
+		exit(1);
+	}
 
 	pid = fork();
-	if (pid < 0)
-		perror("fork"), exit(1);
+	if (pid < 0) {
+		perror("fork");
+		exit(1);
+	}
 
 	if (!pid)
 		exit(faulting_process(2));
 
 	waitpid(pid, &err, 0);
-	if (err)
-		fprintf(stderr, "faulting process failed\n"), exit(1);
+	if (err) {
+		fprintf(stderr, "faulting process failed\n");
+		exit(1);
+	}
 
-	if (write(pipefd[1], &c, sizeof(c)) != sizeof(c))
-		perror("pipe write"), exit(1);
+	if (write(pipefd[1], &c, sizeof(c)) != sizeof(c)) {
+		perror("pipe write");
+		exit(1);
+	}
 	if (pthread_join(uffd_mon, (void **)&userfaults))
 		return 1;
 
@@ -1395,7 +1460,7 @@ static void set_test_type(const char *type)
 		test_type = TEST_SHMEM;
 		uffd_test_ops = &shmem_uffd_test_ops;
 	} else {
-		fprintf(stderr, "Unknown test type: %s\n", type), exit(1);
+		fprintf(stderr, "Unknown test type: %s\n", type); exit(1);
 	}
 
 	if (test_type == TEST_HUGETLB)
@@ -1403,12 +1468,15 @@ static void set_test_type(const char *type)
 	else
 		page_size = sysconf(_SC_PAGE_SIZE);
 
-	if (!page_size)
-		fprintf(stderr, "Unable to determine page size\n"),
-				exit(2);
+	if (!page_size) {
+		fprintf(stderr, "Unable to determine page size\n");
+		exit(2);
+	}
 	if ((unsigned long) area_count(NULL, 0) + sizeof(unsigned long long) * 2
-	    > page_size)
-		fprintf(stderr, "Impossible to run this test\n"), exit(2);
+	    > page_size) {
+		fprintf(stderr, "Impossible to run this test\n");
+		exit(2);
+	}
 }
 
 static void sigalrm(int sig)
@@ -1425,8 +1493,10 @@ int main(int argc, char **argv)
 	if (argc < 4)
 		usage();
 
-	if (signal(SIGALRM, sigalrm) == SIG_ERR)
-		fprintf(stderr, "failed to arm SIGALRM"), exit(1);
+	if (signal(SIGALRM, sigalrm) == SIG_ERR) {
+		fprintf(stderr, "failed to arm SIGALRM");
+		exit(1);
+	}
 	alarm(ALARM_INTERVAL_SECS);
 
 	set_test_type(argv[1]);
-- 
2.26.0


^ permalink raw reply related	[flat|nested] 80+ messages in thread

* Re: [PATCH 02/29] alpha: Avoid comma separated statements
  2020-08-25  4:55 ` [PATCH 02/29] alpha: Avoid comma separated statements Joe Perches
@ 2020-08-25  6:37   ` Robert Richter
  2021-01-30 18:54   ` Joe Perches
  1 sibling, 0 replies; 80+ messages in thread
From: Robert Richter @ 2020-08-25  6:37 UTC (permalink / raw)
  To: Joe Perches
  Cc: Jiri Kosina, Richard Henderson, Ivan Kokshaysky, Matt Turner,
	linux-alpha, linux-kernel, oprofile-list

On 24.08.20 21:55:59, Joe Perches wrote:
> Use semicolons and braces.
> 
> Signed-off-by: Joe Perches <joe@perches.com>
> ---
>  arch/alpha/kernel/pci_iommu.c      |  8 +++++---
>  arch/alpha/oprofile/op_model_ev4.c | 22 ++++++++++++++--------
>  arch/alpha/oprofile/op_model_ev5.c |  8 +++++---
>  3 files changed, 24 insertions(+), 14 deletions(-)

For oprofile:

Acked-by: Robert Richter <rric@kernel.org>

^ permalink raw reply	[flat|nested] 80+ messages in thread

* Re: [PATCH 16/29] 8390: Avoid comma separated statements
  2020-08-25  4:56 ` [PATCH 16/29] 8390: " Joe Perches
@ 2020-08-25 14:54   ` David Miller
  0 siblings, 0 replies; 80+ messages in thread
From: David Miller @ 2020-08-25 14:54 UTC (permalink / raw)
  To: joe; +Cc: trivial, linux-kernel, kuba, netdev

From: Joe Perches <joe@perches.com>
Date: Mon, 24 Aug 2020 21:56:13 -0700

> Use semicolons and braces.
> 
> Signed-off-by: Joe Perches <joe@perches.com>

Applied.

^ permalink raw reply	[flat|nested] 80+ messages in thread

* Re: [PATCH 17/29] fs_enet: Avoid comma separated statements
  2020-08-25  4:56 ` [PATCH 17/29] fs_enet: " Joe Perches
@ 2020-08-25 14:55   ` David Miller
  0 siblings, 0 replies; 80+ messages in thread
From: David Miller @ 2020-08-25 14:55 UTC (permalink / raw)
  To: joe; +Cc: trivial, pantelis.antoniou, kuba, linuxppc-dev, netdev, linux-kernel

From: Joe Perches <joe@perches.com>
Date: Mon, 24 Aug 2020 21:56:14 -0700

> Use semicolons and braces.
> 
> Signed-off-by: Joe Perches <joe@perches.com>

Applied.

^ permalink raw reply	[flat|nested] 80+ messages in thread

* Re: [PATCH 18/29] wan: sbni: Avoid comma separated statements
  2020-08-25  4:56 ` [PATCH 18/29] wan: sbni: " Joe Perches
@ 2020-08-25 14:55   ` David Miller
  0 siblings, 0 replies; 80+ messages in thread
From: David Miller @ 2020-08-25 14:55 UTC (permalink / raw)
  To: joe; +Cc: trivial, linux-kernel, kuba, netdev

From: Joe Perches <joe@perches.com>
Date: Mon, 24 Aug 2020 21:56:15 -0700

> Use semicolons and braces.
> 
> Signed-off-by: Joe Perches <joe@perches.com>

Applied.

^ permalink raw reply	[flat|nested] 80+ messages in thread

* Re: [PATCH 27/29] ipv6: fib6: Avoid comma separated statements
  2020-08-25  4:56 ` [PATCH 27/29] ipv6: fib6: " Joe Perches
@ 2020-08-25 14:55   ` David Miller
  0 siblings, 0 replies; 80+ messages in thread
From: David Miller @ 2020-08-25 14:55 UTC (permalink / raw)
  To: joe; +Cc: trivial, kuznet, yoshfuji, kuba, netdev, linux-kernel

From: Joe Perches <joe@perches.com>
Date: Mon, 24 Aug 2020 21:56:24 -0700

> Use semicolons and braces.
> 
> Signed-off-by: Joe Perches <joe@perches.com>

Applied.

^ permalink raw reply	[flat|nested] 80+ messages in thread

* Re: [PATCH 28/29] sunrpc: Avoid comma separated statements
  2020-08-25  4:56 ` [PATCH 28/29] sunrpc: " Joe Perches
@ 2020-08-25 14:55   ` David Miller
  0 siblings, 0 replies; 80+ messages in thread
From: David Miller @ 2020-08-25 14:55 UTC (permalink / raw)
  To: joe
  Cc: trivial, trond.myklebust, anna.schumaker, bfields, chuck.lever,
	kuba, linux-nfs, netdev, linux-kernel

From: Joe Perches <joe@perches.com>
Date: Mon, 24 Aug 2020 21:56:25 -0700

> Use semicolons and braces.
> 
> Signed-off-by: Joe Perches <joe@perches.com>

Applied.

^ permalink raw reply	[flat|nested] 80+ messages in thread

* Re: [PATCH 12/29] Input: MT - Avoid comma separated statements
  2020-08-25  4:56 ` [PATCH 12/29] Input: MT - " Joe Perches
@ 2020-08-25 17:07   ` Dmitry Torokhov
  0 siblings, 0 replies; 80+ messages in thread
From: Dmitry Torokhov @ 2020-08-25 17:07 UTC (permalink / raw)
  To: Joe Perches; +Cc: Jiri Kosina, Henrik Rydberg, linux-input, linux-kernel

On Mon, Aug 24, 2020 at 09:56:09PM -0700, Joe Perches wrote:
> Use semicolons and braces.
> 
> Signed-off-by: Joe Perches <joe@perches.com>

Applied, thank you.

-- 
Dmitry

^ permalink raw reply	[flat|nested] 80+ messages in thread

* Re: [PATCH 11/29] hwmon: (scmi-hwmon): Avoid comma separated statements
  2020-08-25  4:56 ` [PATCH 11/29] hwmon: (scmi-hwmon): " Joe Perches
@ 2020-08-25 23:33   ` Guenter Roeck
  0 siblings, 0 replies; 80+ messages in thread
From: Guenter Roeck @ 2020-08-25 23:33 UTC (permalink / raw)
  To: Joe Perches; +Cc: Jiri Kosina, Jean Delvare, linux-hwmon, linux-kernel

On Mon, Aug 24, 2020 at 09:56:08PM -0700, Joe Perches wrote:
> Use semicolons and braces.
> 
> Signed-off-by: Joe Perches <joe@perches.com>

Applied.

Thanks,
Guenter

> ---
>  drivers/hwmon/scmi-hwmon.c | 6 ++++--
>  1 file changed, 4 insertions(+), 2 deletions(-)
> 
> diff --git a/drivers/hwmon/scmi-hwmon.c b/drivers/hwmon/scmi-hwmon.c
> index d421e691318b..09ce30cba54b 100644
> --- a/drivers/hwmon/scmi-hwmon.c
> +++ b/drivers/hwmon/scmi-hwmon.c
> @@ -202,8 +202,10 @@ static int scmi_hwmon_probe(struct scmi_device *sdev)
>  		}
>  	}
>  
> -	if (nr_count[hwmon_temp])
> -		nr_count[hwmon_chip]++, nr_types++;
> +	if (nr_count[hwmon_temp]) {
> +		nr_count[hwmon_chip]++;
> +		nr_types++;
> +	}
>  
>  	scmi_hwmon_chan = devm_kcalloc(dev, nr_types, sizeof(*scmi_hwmon_chan),
>  				       GFP_KERNEL);

^ permalink raw reply	[flat|nested] 80+ messages in thread

* Re: [PATCH 29/29] tools: Avoid comma separated statements
  2020-08-25  4:56 ` [PATCH 29/29] tools: " Joe Perches
@ 2020-08-26  9:30   ` Thomas Renninger
  2020-08-26 14:45     ` Joe Perches
  0 siblings, 1 reply; 80+ messages in thread
From: Thomas Renninger @ 2020-08-26  9:30 UTC (permalink / raw)
  To: Jiri Kosina, linux-kernel, Joe Perches
  Cc: Shuah Khan, linux-pm, linux-kselftest

Hi,

getting rid of lines with multiple instructions, separated by comma is
certainly a good idea.
One nit pick, though:

Am Dienstag, 25. August 2020, 06:56:26 CEST schrieb Joe Perches:
> Use semicolons and braces.
> 
> Signed-off-by: Joe Perches <joe@perches.com>
> ---
>  tools/lib/subcmd/help.c                    |  10 +-
>  tools/power/cpupower/utils/cpufreq-set.c   |  14 +-
>  tools/testing/selftests/vm/gup_benchmark.c |  18 +-
>  tools/testing/selftests/vm/userfaultfd.c   | 296 +++++++++++++--------
>  4 files changed, 210 insertions(+), 128 deletions(-)
> 
> diff --git a/tools/lib/subcmd/help.c b/tools/lib/subcmd/help.c
> index 2859f107abc8..bf02d62a3b2b 100644
> --- a/tools/lib/subcmd/help.c
> +++ b/tools/lib/subcmd/help.c
> @@ -65,12 +65,14 @@ void exclude_cmds(struct cmdnames *cmds, struct cmdnames
> *excludes) ci = cj = ei = 0;
>  	while (ci < cmds->cnt && ei < excludes->cnt) {
>  		cmp = strcmp(cmds->names[ci]->name, excludes->names[ei]->name);
> -		if (cmp < 0)
> +		if (cmp < 0) {
>  			cmds->names[cj++] = cmds->names[ci++];
> -		else if (cmp == 0)
> -			ci++, ei++;
> -		else if (cmp > 0)
> +		} else if (cmp == 0) {
> +			ci++;
>  			ei++;
> +		} else if (cmp > 0) {
> +			ei++;
> +		}
>  	}

I can remember patches being rejected with one line statements in a condition,
surounded by braces.
I just read up Documentation/process/coding-style.rst, to be sure this still is up-to-date.
It's not a must, but line 180 says:
"Do not unnecessarily use braces where a single statement will do."

So if this is about coding style cleanup, IMO you should remove braces from single line
statements.

I haven't reviewed every line, but I expect you only split up comma separated instructions
into separate lines and added braces?

Afaik there isn't a specific tag, but having:
cleanup only: No functional change

in the changelog would be nice for people looking for fixes to backport.


Otherwise, I think this is a worthful cleanup.

     Thomas



^ permalink raw reply	[flat|nested] 80+ messages in thread

* Re: [PATCH 29/29] tools: Avoid comma separated statements
  2020-08-26  9:30   ` Thomas Renninger
@ 2020-08-26 14:45     ` Joe Perches
  2020-08-26 16:13       ` Thomas Renninger
  0 siblings, 1 reply; 80+ messages in thread
From: Joe Perches @ 2020-08-26 14:45 UTC (permalink / raw)
  To: Thomas Renninger, Jiri Kosina, linux-kernel
  Cc: Shuah Khan, linux-pm, linux-kselftest

On Wed, 2020-08-26 at 11:30 +0200, Thomas Renninger wrote:
> Hi,
> 
> getting rid of lines with multiple instructions, separated by comma is
> certainly a good idea.
> One nit pick, though:
> 
> Am Dienstag, 25. August 2020, 06:56:26 CEST schrieb Joe Perches:
> > Use semicolons and braces.
> > 
> > Signed-off-by: Joe Perches <joe@perches.com>
> > ---
[]
> I can remember patches being rejected with one line statements in a condition,
> surounded by braces.
> I just read up Documentation/process/coding-style.rst, to be sure this still is up-to-date.
> It's not a must, but line 180 says:
> "Do not unnecessarily use braces where a single statement will do."

Read the block immediately below that too:

"This does not apply if only one branch of a conditional statement is a
single statement; in the latter case use braces in both branches:"

> I haven't reviewed every line, but I expect you only split up comma separated instructions
> into separate lines and added braces?

I do not.

While there was a defect using this style though in another patch,
this is a style only change.

> Afaik there isn't a specific tag, but having:
> cleanup only: No functional change
> 
> in the changelog would be nice for people looking for fixes to backport.

This is not a fix, so it's not for backporting.



^ permalink raw reply	[flat|nested] 80+ messages in thread

* Re: [PATCH 08/29] dma-buf: Avoid comma separated statements
  2020-08-25  4:56 ` [PATCH 08/29] dma-buf: " Joe Perches
@ 2020-08-26 15:08   ` Christian König
  2020-09-03 12:21     ` Sumit Semwal
  2020-09-04 11:42   ` Kieran Bingham
  2021-01-30 18:47   ` Joe Perches
  2 siblings, 1 reply; 80+ messages in thread
From: Christian König @ 2020-08-26 15:08 UTC (permalink / raw)
  To: Joe Perches, Jiri Kosina, Sumit Semwal
  Cc: linux-media, dri-devel, linaro-mm-sig, linux-kernel

Am 25.08.20 um 06:56 schrieb Joe Perches:
> Use semicolons and braces.
>
> Signed-off-by: Joe Perches <joe@perches.com>

Acked-by: Christian König <christian.koenig@amd.com>

> ---
>   drivers/dma-buf/st-dma-fence.c | 7 +++++--
>   1 file changed, 5 insertions(+), 2 deletions(-)
>
> diff --git a/drivers/dma-buf/st-dma-fence.c b/drivers/dma-buf/st-dma-fence.c
> index e593064341c8..c8a12d7ad71a 100644
> --- a/drivers/dma-buf/st-dma-fence.c
> +++ b/drivers/dma-buf/st-dma-fence.c
> @@ -471,8 +471,11 @@ static int thread_signal_callback(void *arg)
>   			dma_fence_signal(f1);
>   
>   		smp_store_mb(cb.seen, false);
> -		if (!f2 || dma_fence_add_callback(f2, &cb.cb, simple_callback))
> -			miss++, cb.seen = true;
> +		if (!f2 ||
> +		    dma_fence_add_callback(f2, &cb.cb, simple_callback)) {
> +			miss++;
> +			cb.seen = true;
> +		}
>   
>   		if (!t->before)
>   			dma_fence_signal(f1);


^ permalink raw reply	[flat|nested] 80+ messages in thread

* Re: [PATCH 29/29] tools: Avoid comma separated statements
  2020-08-26 14:45     ` Joe Perches
@ 2020-08-26 16:13       ` Thomas Renninger
  0 siblings, 0 replies; 80+ messages in thread
From: Thomas Renninger @ 2020-08-26 16:13 UTC (permalink / raw)
  To: Jiri Kosina, linux-kernel, Joe Perches
  Cc: Shuah Khan, linux-pm, linux-kselftest

Am Mittwoch, 26. August 2020, 16:45:24 CEST schrieb Joe Perches:
> On Wed, 2020-08-26 at 11:30 +0200, Thomas Renninger wrote:
> > Hi,
> > 

> Read the block immediately below that too:
> 
> "This does not apply if only one branch of a conditional statement is a
> single statement; in the latter case use braces in both branches:"

Then +1 from here.

> > Afaik there isn't a specific tag, but having:
> > cleanup only: No functional change
> > 
> > in the changelog would be nice for people looking for fixes to backport.
> 
> This is not a fix, so it's not for backporting.

Mentioning that in the changelog explicitly or even in the title - cleanup 
only
is nice imho, but should definitely not be the reason for re-posting.

Thanks for doing this,

   Thomas



^ permalink raw reply	[flat|nested] 80+ messages in thread

* Re: [PATCH 08/29] dma-buf: Avoid comma separated statements
  2020-08-26 15:08   ` Christian König
@ 2020-09-03 12:21     ` Sumit Semwal
  0 siblings, 0 replies; 80+ messages in thread
From: Sumit Semwal @ 2020-09-03 12:21 UTC (permalink / raw)
  To: Christian König
  Cc: Joe Perches, Jiri Kosina, open list:DMA BUFFER SHARING FRAMEWORK,
	DRI mailing list, Linaro MM SIG, LKML

Hello Joe,

On Wed, 26 Aug 2020 at 20:38, Christian König <christian.koenig@amd.com> wrote:
>
> Am 25.08.20 um 06:56 schrieb Joe Perches:
> > Use semicolons and braces.
> >
> > Signed-off-by: Joe Perches <joe@perches.com>
>
> Acked-by: Christian König <christian.koenig@amd.com>
FWIW,
Acked-by: Sumit Semwal <sumit.semwal@linaro.org>

>
> > ---
> >   drivers/dma-buf/st-dma-fence.c | 7 +++++--
> >   1 file changed, 5 insertions(+), 2 deletions(-)
> >
> > diff --git a/drivers/dma-buf/st-dma-fence.c b/drivers/dma-buf/st-dma-fence.c
> > index e593064341c8..c8a12d7ad71a 100644
> > --- a/drivers/dma-buf/st-dma-fence.c
> > +++ b/drivers/dma-buf/st-dma-fence.c
> > @@ -471,8 +471,11 @@ static int thread_signal_callback(void *arg)
> >                       dma_fence_signal(f1);
> >
> >               smp_store_mb(cb.seen, false);
> > -             if (!f2 || dma_fence_add_callback(f2, &cb.cb, simple_callback))
> > -                     miss++, cb.seen = true;
> > +             if (!f2 ||
> > +                 dma_fence_add_callback(f2, &cb.cb, simple_callback)) {
> > +                     miss++;
> > +                     cb.seen = true;
> > +             }
> >
> >               if (!t->before)
> >                       dma_fence_signal(f1);
>

^ permalink raw reply	[flat|nested] 80+ messages in thread

* Re: [PATCH 08/29] dma-buf: Avoid comma separated statements
  2020-08-25  4:56 ` [PATCH 08/29] dma-buf: " Joe Perches
  2020-08-26 15:08   ` Christian König
@ 2020-09-04 11:42   ` Kieran Bingham
  2020-09-04 21:33     ` Joe Perches
  2021-01-30 18:47   ` Joe Perches
  2 siblings, 1 reply; 80+ messages in thread
From: Kieran Bingham @ 2020-09-04 11:42 UTC (permalink / raw)
  To: Joe Perches, Jiri Kosina, Sumit Semwal, Christian König
  Cc: linux-media, dri-devel, linaro-mm-sig, linux-kernel

Hi Joe,

Nice, I only see three of these on the linux-media list, so I'll only
look at those, but I'm pleased to see this is treewide ;-)

Definitely prefer this.

On 25/08/2020 05:56, Joe Perches wrote:
> Use semicolons and braces.
> 
> Signed-off-by: Joe Perches <joe@perches.com>

Reviewed-by: Kieran Bingham <kieran.bingham+renesas@ideasonboard.com>

> ---
>  drivers/dma-buf/st-dma-fence.c | 7 +++++--
>  1 file changed, 5 insertions(+), 2 deletions(-)
> 
> diff --git a/drivers/dma-buf/st-dma-fence.c b/drivers/dma-buf/st-dma-fence.c
> index e593064341c8..c8a12d7ad71a 100644
> --- a/drivers/dma-buf/st-dma-fence.c
> +++ b/drivers/dma-buf/st-dma-fence.c
> @@ -471,8 +471,11 @@ static int thread_signal_callback(void *arg)
>  			dma_fence_signal(f1);
>  
>  		smp_store_mb(cb.seen, false);
> -		if (!f2 || dma_fence_add_callback(f2, &cb.cb, simple_callback))
> -			miss++, cb.seen = true;
> +		if (!f2 ||
> +		    dma_fence_add_callback(f2, &cb.cb, simple_callback)) {
> +			miss++;
> +			cb.seen = true;
> +		}
>  
>  		if (!t->before)
>  			dma_fence_signal(f1);
> 


^ permalink raw reply	[flat|nested] 80+ messages in thread

* Re: [PATCH 14/29] media: Avoid comma separated statements
  2020-08-25  4:56 ` [PATCH 14/29] media: " Joe Perches
@ 2020-09-04 11:45   ` Kieran Bingham
  0 siblings, 0 replies; 80+ messages in thread
From: Kieran Bingham @ 2020-09-04 11:45 UTC (permalink / raw)
  To: Joe Perches, Jiri Kosina, Mauro Carvalho Chehab; +Cc: linux-media, linux-kernel

On 25/08/2020 05:56, Joe Perches wrote:
> Use semicolons and braces.
> 
> Signed-off-by: Joe Perches <joe@perches.com>
> ---
>  drivers/media/i2c/msp3400-kthreads.c      | 12 ++++++++----
>  drivers/media/pci/bt8xx/bttv-cards.c      |  6 ++++--
>  drivers/media/pci/saa7134/saa7134-video.c |  7 +++++--
>  3 files changed, 17 insertions(+), 8 deletions(-)
> 
> diff --git a/drivers/media/i2c/msp3400-kthreads.c b/drivers/media/i2c/msp3400-kthreads.c
> index d3b0d1c18efd..ac8752c63266 100644
> --- a/drivers/media/i2c/msp3400-kthreads.c
> +++ b/drivers/media/i2c/msp3400-kthreads.c
> @@ -549,8 +549,10 @@ int msp3400c_thread(void *data)
>  			val = msp_read_dsp(client, 0x1b);
>  			if (val > 32767)
>  				val -= 65536;
> -			if (val1 < val)
> -				val1 = val, max1 = i;
> +			if (val1 < val) {
> +				val1 = val;
> +				max1 = i;
> +			}
>  			dev_dbg_lvl(&client->dev, 1, msp_debug,
>  				"carrier1 val: %5d / %s\n", val, cd[i].name);
>  		}
> @@ -586,8 +588,10 @@ int msp3400c_thread(void *data)
>  			val = msp_read_dsp(client, 0x1b);
>  			if (val > 32767)
>  				val -= 65536;
> -			if (val2 < val)
> -				val2 = val, max2 = i;
> +			if (val2 < val) {
> +				val2 = val;
> +				max2 = i;
> +			}
>  			dev_dbg_lvl(&client->dev, 1, msp_debug,
>  				"carrier2 val: %5d / %s\n", val, cd[i].name);
>  		}
> diff --git a/drivers/media/pci/bt8xx/bttv-cards.c b/drivers/media/pci/bt8xx/bttv-cards.c
> index 16148802dabb..ca20b806e82d 100644
> --- a/drivers/media/pci/bt8xx/bttv-cards.c
> +++ b/drivers/media/pci/bt8xx/bttv-cards.c
> @@ -3934,8 +3934,10 @@ static void osprey_eeprom(struct bttv *btv, const u8 ee[256])
>  			if (checksum != ee[21])
>  				return;
>  			cardid = BTTV_BOARD_OSPREY1x0_848;
> -			for (i = 12; i < 21; i++)
> -				serial *= 10, serial += ee[i] - '0';
> +			for (i = 12; i < 21; i++) {
> +				serial *= 10;
> +				serial += ee[i] - '0';
> +			}
>  		}
>  	} else {
>  		unsigned short type;
> diff --git a/drivers/media/pci/saa7134/saa7134-video.c b/drivers/media/pci/saa7134/saa7134-video.c
> index a8ac94fadc14..f673cda57f30 100644
> --- a/drivers/media/pci/saa7134/saa7134-video.c
> +++ b/drivers/media/pci/saa7134/saa7134-video.c
> @@ -868,8 +868,11 @@ static int buffer_activate(struct saa7134_dev *dev,
>  		lines_uv = dev->height >> dev->fmt->vshift;
>  		base2    = base + bpl * dev->height;
>  		base3    = base2 + bpl_uv * lines_uv;
> -		if (dev->fmt->uvswap)
> -			tmp = base2, base2 = base3, base3 = tmp;
> +		if (dev->fmt->uvswap) {
> +			tmp = base2;
> +			base2 = base3;
> +			base3 = tmp;

Don't we have any swap macro helpers for this?

Anyway, that would be out of scope of this patch series.

Reviewed-by: Kieran Bingham <kieran.bingham+renesas@ideasonboard.com>

> +		}
>  		video_dbg("uv: bpl=%ld lines=%ld base2/3=%ld/%ld\n",
>  			bpl_uv,lines_uv,base2,base3);
>  		if (V4L2_FIELD_HAS_BOTH(dev->field)) {
> 


^ permalink raw reply	[flat|nested] 80+ messages in thread

* Re: [PATCH 21/29] media: atomisp: Avoid comma separated statements
  2020-08-25  4:56 ` [PATCH 21/29] media: atomisp: " Joe Perches
@ 2020-09-04 11:46   ` Kieran Bingham
  0 siblings, 0 replies; 80+ messages in thread
From: Kieran Bingham @ 2020-09-04 11:46 UTC (permalink / raw)
  To: Joe Perches, Jiri Kosina, linux-kernel
  Cc: Mauro Carvalho Chehab, Sakari Ailus, Greg Kroah-Hartman,
	linux-media, devel

On 25/08/2020 05:56, Joe Perches wrote:
> Use semicolons and braces.
> 
> Signed-off-by: Joe Perches <joe@perches.com>

Reviewed-by: Kieran Bingham <kieran.bingham+renesas@ideasonboard.com>

> ---
>  drivers/staging/media/atomisp/pci/atomisp_subdev.c | 6 ++++--
>  1 file changed, 4 insertions(+), 2 deletions(-)
> 
> diff --git a/drivers/staging/media/atomisp/pci/atomisp_subdev.c b/drivers/staging/media/atomisp/pci/atomisp_subdev.c
> index 6ba817f15655..52b9fb18c87f 100644
> --- a/drivers/staging/media/atomisp/pci/atomisp_subdev.c
> +++ b/drivers/staging/media/atomisp/pci/atomisp_subdev.c
> @@ -410,8 +410,10 @@ int atomisp_subdev_set_selection(struct v4l2_subdev *sd,
>  
>  		if (atomisp_subdev_format_conversion(isp_sd,
>  						     isp_sd->capture_pad)
> -		    && crop[pad]->width && crop[pad]->height)
> -			crop[pad]->width -= padding_w, crop[pad]->height -= padding_h;
> +		    && crop[pad]->width && crop[pad]->height) {
> +			crop[pad]->width -= padding_w;
> +			crop[pad]->height -= padding_h;
> +		}
>  
>  		/* if subdev type is SOC camera,we do not need to set DVS */
>  		if (isp->inputs[isp_sd->input_curr].type == SOC_CAMERA)
> 


^ permalink raw reply	[flat|nested] 80+ messages in thread

* Re: [PATCH 08/29] dma-buf: Avoid comma separated statements
  2020-09-04 11:42   ` Kieran Bingham
@ 2020-09-04 21:33     ` Joe Perches
  0 siblings, 0 replies; 80+ messages in thread
From: Joe Perches @ 2020-09-04 21:33 UTC (permalink / raw)
  To: kieran.bingham+renesas, Jiri Kosina, Sumit Semwal, Christian König
  Cc: linux-media, dri-devel, linaro-mm-sig, linux-kernel

On Fri, 2020-09-04 at 12:42 +0100, Kieran Bingham wrote:
> I'm pleased to see this is treewide ;-)
> Definitely prefer this.

These are only the comma uses in if/do/while blocks that
would also need braces as separate statements.

There a multiple dozens more just with single statements
terminated by commas and not semicolons.

See:  https://lore.kernel.org/patchwork/patch/1291033/



^ permalink raw reply	[flat|nested] 80+ messages in thread

* Re: [PATCH 15/29] mtd: Avoid comma separated statements
  2020-08-25  4:56 ` [PATCH 15/29] mtd: " Joe Perches
@ 2020-09-07  7:34   ` Miquel Raynal
  0 siblings, 0 replies; 80+ messages in thread
From: Miquel Raynal @ 2020-09-07  7:34 UTC (permalink / raw)
  To: Joe Perches, Jiri Kosina, linux-kernel
  Cc: Miquel Raynal, Richard Weinberger, linux-mtd, Vignesh Raghavendra

On Tue, 2020-08-25 at 04:56:12 UTC, Joe Perches wrote:
> Use semicolons and braces.
> 
> Signed-off-by: Joe Perches <joe@perches.com>

Applied to https://git.kernel.org/pub/scm/linux/kernel/git/mtd/linux.git mtd/next, thanks.

Miquel

^ permalink raw reply	[flat|nested] 80+ messages in thread

* Re: [PATCH 22/29] video: fbdev: Avoid comma separated statements
  2020-08-25  4:56 ` [PATCH 22/29] video: fbdev: " Joe Perches
@ 2020-09-08 11:37   ` Bartlomiej Zolnierkiewicz
  0 siblings, 0 replies; 80+ messages in thread
From: Bartlomiej Zolnierkiewicz @ 2020-09-08 11:37 UTC (permalink / raw)
  To: Joe Perches; +Cc: Jiri Kosina, linux-kernel, dri-devel, linux-fbdev


On 8/25/20 6:56 AM, Joe Perches wrote:
> Use semicolons and braces.
> 
> Signed-off-by: Joe Perches <joe@perches.com>

Applied to drm-misc-next tree, thanks.

Best regards,
--
Bartlomiej Zolnierkiewicz
Samsung R&D Institute Poland
Samsung Electronics

> ---
>  drivers/video/fbdev/tgafb.c | 12 ++++++++----
>  1 file changed, 8 insertions(+), 4 deletions(-)
> 
> diff --git a/drivers/video/fbdev/tgafb.c b/drivers/video/fbdev/tgafb.c
> index e9869135d833..666fbe2f671c 100644
> --- a/drivers/video/fbdev/tgafb.c
> +++ b/drivers/video/fbdev/tgafb.c
> @@ -989,8 +989,10 @@ tgafb_fillrect(struct fb_info *info, const struct fb_fillrect *rect)
>  	/* We can fill 2k pixels per operation.  Notice blocks that fit
>  	   the width of the screen so that we can take advantage of this
>  	   and fill more than one line per write.  */
> -	if (width == line_length)
> -		width *= height, height = 1;
> +	if (width == line_length) {
> +		width *= height;
> +		height = 1;
> +	}
>  
>  	/* The write into the frame buffer must be aligned to 4 bytes,
>  	   but we are allowed to encode the offset within the word in
> @@ -1171,8 +1173,10 @@ copyarea_8bpp(struct fb_info *info, u32 dx, u32 dy, u32 sx, u32 sy,
>  	   More than anything else, these control how we do copies.  */
>  	depos = dy * line_length + dx;
>  	sepos = sy * line_length + sx;
> -	if (backward)
> -		depos += width, sepos += width;
> +	if (backward) {
> +		depos += width;
> +		sepos += width;
> +	}
>  
>  	/* Next copy full words at a time.  */
>  	n32 = width / 32;
> 

^ permalink raw reply	[flat|nested] 80+ messages in thread

* Re: [PATCH 00/29] treewide: Convert comma separated statements
  2020-08-25  4:55 [PATCH 00/29] treewide: Convert comma separated statements Joe Perches
                   ` (28 preceding siblings ...)
  2020-08-25  4:56 ` [PATCH 29/29] tools: " Joe Perches
@ 2020-09-09  2:09 ` Martin K. Petersen
  29 siblings, 0 replies; 80+ messages in thread
From: Martin K. Petersen @ 2020-09-09  2:09 UTC (permalink / raw)
  To: linuxppc-dev, linux-ide, dri-devel, linux-hwmon, Joe Perches,
	oprofile-list, linux-fsdevel, linux-media, linaro-mm-sig,
	drbd-dev, intel-gfx, linux-arm-kernel, linux-input, linux-nfs,
	netdev, reiserfs-devel, linux-bcache, Jiri Kosina
  Cc: Martin K . Petersen, sparclinux, linux-mtd, linux-s390,
	linux-doc, linux-block, linux-ia64, linux-pm, linux-kselftest,
	linux-fbdev, devel, linux-scsi, linux-alpha, linux-kernel

On Mon, 24 Aug 2020 21:55:57 -0700, Joe Perches wrote:

> There are many comma separated statements in the kernel.
> See:https://lore.kernel.org/lkml/alpine.DEB.2.22.394.2008201856110.2524@hadrien/
> 
> Convert the comma separated statements that are in if/do/while blocks
> to use braces and semicolons.
> 
> Many comma separated statements still exist but those are changes for
> another day.
> 
> [...]

Applied to 5.10/scsi-queue, thanks!

[01/29] coding-style.rst: Avoid comma statements
        (no commit info)
[02/29] alpha: Avoid comma separated statements
        (no commit info)
[03/29] ia64: Avoid comma separated statements
        (no commit info)
[04/29] sparc: Avoid comma separated statements
        (no commit info)
[05/29] ata: Avoid comma separated statements
        (no commit info)
[06/29] drbd: Avoid comma separated statements
        (no commit info)
[07/29] lp: Avoid comma separated statements
        (no commit info)
[08/29] dma-buf: Avoid comma separated statements
        (no commit info)
[09/29] drm/gma500: Avoid comma separated statements
        (no commit info)
[10/29] drm/i915: Avoid comma separated statements
        (no commit info)
[11/29] hwmon: (scmi-hwmon): Avoid comma separated statements
        (no commit info)
[12/29] Input: MT - Avoid comma separated statements
        (no commit info)
[13/29] bcache: Avoid comma separated statements
        (no commit info)
[14/29] media: Avoid comma separated statements
        (no commit info)
[15/29] mtd: Avoid comma separated statements
        (no commit info)
[16/29] 8390: Avoid comma separated statements
        (no commit info)
[17/29] fs_enet: Avoid comma separated statements
        (no commit info)
[18/29] wan: sbni: Avoid comma separated statements
        (no commit info)
[19/29] s390/tty3270: Avoid comma separated statements
        (no commit info)
[20/29] scsi: arm: Avoid comma separated statements
        https://git.kernel.org/mkp/scsi/c/a08a07326510
[21/29] media: atomisp: Avoid comma separated statements
        (no commit info)
[22/29] video: fbdev: Avoid comma separated statements
        (no commit info)
[23/29] fuse: Avoid comma separated statements
        (no commit info)
[24/29] reiserfs: Avoid comma separated statements
        (no commit info)
[25/29] lib/zlib: Avoid comma separated statements
        (no commit info)
[26/29] lib: zstd: Avoid comma separated statements
        (no commit info)
[27/29] ipv6: fib6: Avoid comma separated statements
        (no commit info)
[28/29] sunrpc: Avoid comma separated statements
        (no commit info)
[29/29] tools: Avoid comma separated statements
        (no commit info)

-- 
Martin K. Petersen	Oracle Linux Engineering

^ permalink raw reply	[flat|nested] 80+ messages in thread

* Re: [PATCH 08/29] dma-buf: Avoid comma separated statements
  2020-08-25  4:56 ` [PATCH 08/29] dma-buf: " Joe Perches
  2020-08-26 15:08   ` Christian König
  2020-09-04 11:42   ` Kieran Bingham
@ 2021-01-30 18:47   ` Joe Perches
  2021-02-03 13:26     ` Christian König
  2 siblings, 1 reply; 80+ messages in thread
From: Joe Perches @ 2021-01-30 18:47 UTC (permalink / raw)
  To: Jiri Kosina, Sumit Semwal, Christian König
  Cc: linux-media, dri-devel, linaro-mm-sig, linux-kernel

On Mon, 2020-08-24 at 21:56 -0700, Joe Perches wrote:
> Use semicolons and braces.

Ping?
 
> Signed-off-by: Joe Perches <joe@perches.com>
> ---
>  drivers/dma-buf/st-dma-fence.c | 7 +++++--
>  1 file changed, 5 insertions(+), 2 deletions(-)
> 
> diff --git a/drivers/dma-buf/st-dma-fence.c b/drivers/dma-buf/st-dma-fence.c
> index e593064341c8..c8a12d7ad71a 100644
> --- a/drivers/dma-buf/st-dma-fence.c
> +++ b/drivers/dma-buf/st-dma-fence.c
> @@ -471,8 +471,11 @@ static int thread_signal_callback(void *arg)
>  			dma_fence_signal(f1);
>  
> 
>  		smp_store_mb(cb.seen, false);
> -		if (!f2 || dma_fence_add_callback(f2, &cb.cb, simple_callback))
> -			miss++, cb.seen = true;
> +		if (!f2 ||
> +		    dma_fence_add_callback(f2, &cb.cb, simple_callback)) {
> +			miss++;
> +			cb.seen = true;
> +		}
>  
> 
>  		if (!t->before)
>  			dma_fence_signal(f1);



^ permalink raw reply	[flat|nested] 80+ messages in thread

* Re: [PATCH 09/29] drm/gma500: Avoid comma separated statements
  2020-08-25  4:56 ` [PATCH 09/29] drm/gma500: " Joe Perches
@ 2021-01-30 18:47   ` Joe Perches
  2021-01-30 21:21     ` Patrik Jakobsson
  0 siblings, 1 reply; 80+ messages in thread
From: Joe Perches @ 2021-01-30 18:47 UTC (permalink / raw)
  To: Jiri Kosina, Patrik Jakobsson
  Cc: David Airlie, Daniel Vetter, dri-devel, linux-kernel

On Mon, 2020-08-24 at 21:56 -0700, Joe Perches wrote:
> Use semicolons and braces.

Ping?
 
> Signed-off-by: Joe Perches <joe@perches.com>
> ---
>  drivers/gpu/drm/gma500/mdfld_intel_display.c | 44 +++++++++++++-------
>  1 file changed, 28 insertions(+), 16 deletions(-)
> 
> diff --git a/drivers/gpu/drm/gma500/mdfld_intel_display.c b/drivers/gpu/drm/gma500/mdfld_intel_display.c
> index aae2d358364c..bfa330df9443 100644
> --- a/drivers/gpu/drm/gma500/mdfld_intel_display.c
> +++ b/drivers/gpu/drm/gma500/mdfld_intel_display.c
> @@ -824,33 +824,45 @@ static int mdfld_crtc_mode_set(struct drm_crtc *crtc,
>  		if ((ksel == KSEL_CRYSTAL_19) || (ksel == KSEL_BYPASS_19)) {
>  			refclk = 19200;
>  
> 
> -			if (is_mipi || is_mipi2)
> -				clk_n = 1, clk_p2 = 8;
> -			else if (is_hdmi)
> -				clk_n = 1, clk_p2 = 10;
> +			if (is_mipi || is_mipi2) {
> +				clk_n = 1;
> +				clk_p2 = 8;
> +			} else if (is_hdmi) {
> +				clk_n = 1;
> +				clk_p2 = 10;
> +			}
>  		} else if (ksel == KSEL_BYPASS_25) {
>  			refclk = 25000;
>  
> 
> -			if (is_mipi || is_mipi2)
> -				clk_n = 1, clk_p2 = 8;
> -			else if (is_hdmi)
> -				clk_n = 1, clk_p2 = 10;
> +			if (is_mipi || is_mipi2) {
> +				clk_n = 1;
> +				clk_p2 = 8;
> +			} else if (is_hdmi) {
> +				clk_n = 1;
> +				clk_p2 = 10;
> +			}
>  		} else if ((ksel == KSEL_BYPASS_83_100) &&
>  					dev_priv->core_freq == 166) {
>  			refclk = 83000;
>  
> 
> -			if (is_mipi || is_mipi2)
> -				clk_n = 4, clk_p2 = 8;
> -			else if (is_hdmi)
> -				clk_n = 4, clk_p2 = 10;
> +			if (is_mipi || is_mipi2) {
> +				clk_n = 4;
> +				clk_p2 = 8;
> +			} else if (is_hdmi) {
> +				clk_n = 4;
> +				clk_p2 = 10;
> +			}
>  		} else if ((ksel == KSEL_BYPASS_83_100) &&
>  					(dev_priv->core_freq == 100 ||
>  					dev_priv->core_freq == 200)) {
>  			refclk = 100000;
> -			if (is_mipi || is_mipi2)
> -				clk_n = 4, clk_p2 = 8;
> -			else if (is_hdmi)
> -				clk_n = 4, clk_p2 = 10;
> +			if (is_mipi || is_mipi2) {
> +				clk_n = 4;
> +				clk_p2 = 8;
> +			} else if (is_hdmi) {
> +				clk_n = 4;
> +				clk_p2 = 10;
> +			}
>  		}
>  
> 
>  		if (is_mipi)



^ permalink raw reply	[flat|nested] 80+ messages in thread

* Re: [PATCH 10/29] drm/i915: Avoid comma separated statements
  2020-08-25  4:56 ` [PATCH 10/29] drm/i915: " Joe Perches
@ 2021-01-30 18:47   ` Joe Perches
  2021-02-01  8:41     ` Jani Nikula
  0 siblings, 1 reply; 80+ messages in thread
From: Joe Perches @ 2021-01-30 18:47 UTC (permalink / raw)
  To: Jiri Kosina, Jani Nikula, Joonas Lahtinen, Rodrigo Vivi
  Cc: David Airlie, Daniel Vetter, intel-gfx, dri-devel, linux-kernel

On Mon, 2020-08-24 at 21:56 -0700, Joe Perches wrote:
> Use semicolons and braces.

Ping?

> Signed-off-by: Joe Perches <joe@perches.com>
> ---
>  drivers/gpu/drm/i915/gt/gen8_ppgtt.c           | 8 +++++---
>  drivers/gpu/drm/i915/gt/intel_gt_requests.c    | 6 ++++--
>  drivers/gpu/drm/i915/gt/selftest_workarounds.c | 6 ++++--
>  drivers/gpu/drm/i915/intel_runtime_pm.c        | 6 ++++--
>  4 files changed, 17 insertions(+), 9 deletions(-)
> 
> diff --git a/drivers/gpu/drm/i915/gt/gen8_ppgtt.c b/drivers/gpu/drm/i915/gt/gen8_ppgtt.c
> index 699125928272..114c13285ff1 100644
> --- a/drivers/gpu/drm/i915/gt/gen8_ppgtt.c
> +++ b/drivers/gpu/drm/i915/gt/gen8_ppgtt.c
> @@ -323,10 +323,12 @@ static int __gen8_ppgtt_alloc(struct i915_address_space * const vm,
>  			}
>  
> 
>  			spin_lock(&pd->lock);
> -			if (likely(!pd->entry[idx]))
> +			if (likely(!pd->entry[idx])) {
>  				set_pd_entry(pd, idx, pt);
> -			else
> -				alloc = pt, pt = pd->entry[idx];
> +			} else {
> +				alloc = pt;
> +				pt = pd->entry[idx];
> +			}
>  		}
>  
> 
>  		if (lvl) {
> diff --git a/drivers/gpu/drm/i915/gt/intel_gt_requests.c b/drivers/gpu/drm/i915/gt/intel_gt_requests.c
> index 66fcbf9d0fdd..54408d0b5e6e 100644
> --- a/drivers/gpu/drm/i915/gt/intel_gt_requests.c
> +++ b/drivers/gpu/drm/i915/gt/intel_gt_requests.c
> @@ -139,8 +139,10 @@ long intel_gt_retire_requests_timeout(struct intel_gt *gt, long timeout)
>  	LIST_HEAD(free);
>  
> 
>  	interruptible = true;
> -	if (unlikely(timeout < 0))
> -		timeout = -timeout, interruptible = false;
> +	if (unlikely(timeout < 0)) {
> +		timeout = -timeout;
> +		interruptible = false;
> +	}
>  
> 
>  	flush_submission(gt, timeout); /* kick the ksoftirqd tasklets */
>  	spin_lock(&timelines->lock);
> diff --git a/drivers/gpu/drm/i915/gt/selftest_workarounds.c b/drivers/gpu/drm/i915/gt/selftest_workarounds.c
> index febc9e6692ba..3e4cbeed20bd 100644
> --- a/drivers/gpu/drm/i915/gt/selftest_workarounds.c
> +++ b/drivers/gpu/drm/i915/gt/selftest_workarounds.c
> @@ -521,8 +521,10 @@ static int check_dirty_whitelist(struct intel_context *ce)
>  
> 
>  		srm = MI_STORE_REGISTER_MEM;
>  		lrm = MI_LOAD_REGISTER_MEM;
> -		if (INTEL_GEN(engine->i915) >= 8)
> -			lrm++, srm++;
> +		if (INTEL_GEN(engine->i915) >= 8) {
> +			lrm++;
> +			srm++;
> +		}
>  
> 
>  		pr_debug("%s: Writing garbage to %x\n",
>  			 engine->name, reg);
> diff --git a/drivers/gpu/drm/i915/intel_runtime_pm.c b/drivers/gpu/drm/i915/intel_runtime_pm.c
> index 153ca9e65382..f498f1c80755 100644
> --- a/drivers/gpu/drm/i915/intel_runtime_pm.c
> +++ b/drivers/gpu/drm/i915/intel_runtime_pm.c
> @@ -201,8 +201,10 @@ __print_intel_runtime_pm_wakeref(struct drm_printer *p,
>  		unsigned long rep;
>  
> 
>  		rep = 1;
> -		while (i + 1 < dbg->count && dbg->owners[i + 1] == stack)
> -			rep++, i++;
> +		while (i + 1 < dbg->count && dbg->owners[i + 1] == stack) {
> +			rep++;
> +			i++;
> +		}
>  		__print_depot_stack(stack, buf, PAGE_SIZE, 2);
>  		drm_printf(p, "Wakeref x%lu taken at:\n%s", rep, buf);
>  	}



^ permalink raw reply	[flat|nested] 80+ messages in thread

* Re: [PATCH 01/29] coding-style.rst: Avoid comma statements
  2020-08-25  4:55 ` [PATCH 01/29] coding-style.rst: Avoid comma statements Joe Perches
@ 2021-01-30 18:53   ` Joe Perches
  2021-02-04 21:41     ` Jonathan Corbet
  0 siblings, 1 reply; 80+ messages in thread
From: Joe Perches @ 2021-01-30 18:53 UTC (permalink / raw)
  To: Jiri Kosina, linux-kernel; +Cc: Jonathan Corbet, linux-doc

On Mon, 2020-08-24 at 21:55 -0700, Joe Perches wrote:
> Commas are not how statements are terminated.
> Always use semicolons and braces if necessary.

ping?

> 
> Signed-off-by: Joe Perches <joe@perches.com>
> ---
>  Documentation/process/coding-style.rst | 17 +++++++++++++++++
>  1 file changed, 17 insertions(+)
> 
> diff --git a/Documentation/process/coding-style.rst b/Documentation/process/coding-style.rst
> index 98227226c4e5..a1e061149e0d 100644
> --- a/Documentation/process/coding-style.rst
> +++ b/Documentation/process/coding-style.rst
> @@ -69,9 +69,26 @@ something to hide:
>  	if (condition) do_this;
>  	  do_something_everytime;
>  
> 
> +Don't use commas to avoid using braces:
> +
> +.. code-block:: c
> +
> +	if (condition)
> +		do_this(), do_that();
> +
> +Always uses braces for multiple statements:
> +
> +.. code-block:: c
> +
> +	if (condition) {
> +		do_this();
> +		do_that();
> +	}
> +
>  Don't put multiple assignments on a single line either.  Kernel coding style
>  is super simple.  Avoid tricky expressions.
>  
> 
> +
>  Outside of comments, documentation and except in Kconfig, spaces are never
>  used for indentation, and the above example is deliberately broken.
>  
> 



^ permalink raw reply	[flat|nested] 80+ messages in thread

* Re: [PATCH 02/29] alpha: Avoid comma separated statements
  2020-08-25  4:55 ` [PATCH 02/29] alpha: Avoid comma separated statements Joe Perches
  2020-08-25  6:37   ` Robert Richter
@ 2021-01-30 18:54   ` Joe Perches
  2021-02-16 14:39     ` Robert Richter
  1 sibling, 1 reply; 80+ messages in thread
From: Joe Perches @ 2021-01-30 18:54 UTC (permalink / raw)
  To: Jiri Kosina, Robert Richter
  Cc: Richard Henderson, Ivan Kokshaysky, Matt Turner, linux-alpha,
	linux-kernel, oprofile-list

On Mon, 2020-08-24 at 21:55 -0700, Joe Perches wrote:
> Use semicolons and braces.

ping?

> 
> Signed-off-by: Joe Perches <joe@perches.com>
> ---
>  arch/alpha/kernel/pci_iommu.c      |  8 +++++---
>  arch/alpha/oprofile/op_model_ev4.c | 22 ++++++++++++++--------
>  arch/alpha/oprofile/op_model_ev5.c |  8 +++++---
>  3 files changed, 24 insertions(+), 14 deletions(-)
> 
> diff --git a/arch/alpha/kernel/pci_iommu.c b/arch/alpha/kernel/pci_iommu.c
> index 81037907268d..b8af7ad6c607 100644
> --- a/arch/alpha/kernel/pci_iommu.c
> +++ b/arch/alpha/kernel/pci_iommu.c
> @@ -161,10 +161,12 @@ iommu_arena_find_pages(struct device *dev, struct pci_iommu_arena *arena,
>  			goto again;
>  		}
>  
> 
> -		if (ptes[p+i])
> -			p = ALIGN(p + i + 1, mask + 1), i = 0;
> -		else
> +		if (ptes[p+i]) {
> +			p = ALIGN(p + i + 1, mask + 1);
> +			i = 0;
> +		} else {
>  			i = i + 1;
> +		}
>  	}
>  
> 
>  	if (i < n) {
> diff --git a/arch/alpha/oprofile/op_model_ev4.c b/arch/alpha/oprofile/op_model_ev4.c
> index 086a0d5445c5..004f80a4291f 100644
> --- a/arch/alpha/oprofile/op_model_ev4.c
> +++ b/arch/alpha/oprofile/op_model_ev4.c
> @@ -46,18 +46,24 @@ ev4_reg_setup(struct op_register_config *reg,
>  	   map it onto one of the possible values, and write it back.  */
>  
> 
>  	count = ctr[0].count;
> -	if (count <= 4096)
> -		count = 4096, hilo = 1;
> -	else
> -		count = 65536, hilo = 0;
> +	if (count <= 4096) {
> +		count = 4096;
> +		hilo = 1;
> +	} else {
> +		count = 65536;
> +		hilo = 0;
> +	}
>  	ctr[0].count = count;
>  	ctl |= (ctr[0].enabled && hilo) << 3;
>  
> 
>  	count = ctr[1].count;
> -	if (count <= 256)
> -		count = 256, hilo = 1;
> -	else
> -		count = 4096, hilo = 0;
> +	if (count <= 256) {
> +		count = 256;
> +		hilo = 1;
> +	} else {
> +		count = 4096;
> +		hilo = 0;
> +	}
>  	ctr[1].count = count;
>  	ctl |= (ctr[1].enabled && hilo);
>  
> 
> diff --git a/arch/alpha/oprofile/op_model_ev5.c b/arch/alpha/oprofile/op_model_ev5.c
> index c300f5ef3482..6f52244e1181 100644
> --- a/arch/alpha/oprofile/op_model_ev5.c
> +++ b/arch/alpha/oprofile/op_model_ev5.c
> @@ -92,9 +92,11 @@ common_reg_setup(struct op_register_config *reg,
>  		if (!ctr[i].enabled)
>  			continue;
>  
> 
> -		if (count <= 256)
> -			count = 256, hilo = 3, max = 256;
> -		else {
> +		if (count <= 256) {
> +			max = 256;
> +			hilo = 3;
> +			count = 256;
> +		} else {
>  			max = (i == 2 ? 16384 : 65536);
>  			hilo = 2;
>  			if (count > max)



^ permalink raw reply	[flat|nested] 80+ messages in thread

* Re: [PATCH 03/29] ia64: Avoid comma separated statements
  2020-08-25  4:56 ` [PATCH 03/29] ia64: " Joe Perches
@ 2021-01-30 18:55   ` Joe Perches
  0 siblings, 0 replies; 80+ messages in thread
From: Joe Perches @ 2021-01-30 18:55 UTC (permalink / raw)
  To: Jiri Kosina, linux-kernel; +Cc: Tony Luck, Fenghua Yu, linux-ia64

On Mon, 2020-08-24 at 21:56 -0700, Joe Perches wrote:
> Use semicolons and braces.

ping?


> Signed-off-by: Joe Perches <joe@perches.com>
> ---
>  arch/ia64/kernel/smpboot.c | 7 +++++--
>  1 file changed, 5 insertions(+), 2 deletions(-)
> 
> diff --git a/arch/ia64/kernel/smpboot.c b/arch/ia64/kernel/smpboot.c
> index c29c600d7967..3311b9d21319 100644
> --- a/arch/ia64/kernel/smpboot.c
> +++ b/arch/ia64/kernel/smpboot.c
> @@ -224,8 +224,11 @@ get_delta (long *rt, long *master)
>  		go[SLAVE] = 0;
>  		t1 = ia64_get_itc();
>  
> 
> -		if (t1 - t0 < best_t1 - best_t0)
> -			best_t0 = t0, best_t1 = t1, best_tm = tm;
> +		if (t1 - t0 < best_t1 - best_t0) {
> +			best_t0 = t0;
> +			best_t1 = t1;
> +			best_tm = tm;
> +		}
>  	}
>  
> 
>  	*rt = best_t1 - best_t0;



^ permalink raw reply	[flat|nested] 80+ messages in thread

* Re: [PATCH 04/29] sparc: Avoid comma separated statements
  2020-08-25  4:56 ` [PATCH 04/29] sparc: " Joe Perches
@ 2021-01-30 18:56   ` Joe Perches
  0 siblings, 0 replies; 80+ messages in thread
From: Joe Perches @ 2021-01-30 18:56 UTC (permalink / raw)
  To: Jiri Kosina, linux-kernel; +Cc: David S. Miller, sparclinux

On Mon, 2020-08-24 at 21:56 -0700, Joe Perches wrote:
> Use semicolons and braces.

ping?

> Signed-off-by: Joe Perches <joe@perches.com>
> ---
>  arch/sparc/kernel/smp_64.c | 7 +++++--
>  1 file changed, 5 insertions(+), 2 deletions(-)
> 
> diff --git a/arch/sparc/kernel/smp_64.c b/arch/sparc/kernel/smp_64.c
> index e286e2badc8a..28c11f7871cd 100644
> --- a/arch/sparc/kernel/smp_64.c
> +++ b/arch/sparc/kernel/smp_64.c
> @@ -186,8 +186,11 @@ static inline long get_delta (long *rt, long *master)
>  		wmb();
>  		t1 = tick_ops->get_tick();
>  
> 
> -		if (t1 - t0 < best_t1 - best_t0)
> -			best_t0 = t0, best_t1 = t1, best_tm = tm;
> +		if (t1 - t0 < best_t1 - best_t0) {
> +			best_t0 = t0;
> +			best_t1 = t1;
> +			best_tm = tm;
> +		}
>  	}
>  
> 
>  	*rt = best_t1 - best_t0;



^ permalink raw reply	[flat|nested] 80+ messages in thread

* Re: [PATCH 05/29] ata: Avoid comma separated statements
  2020-08-25  4:56 ` [PATCH 05/29] ata: " Joe Perches
@ 2021-01-30 18:56   ` Joe Perches
  2021-01-31 15:06     ` Jens Axboe
  0 siblings, 1 reply; 80+ messages in thread
From: Joe Perches @ 2021-01-30 18:56 UTC (permalink / raw)
  To: Jiri Kosina, Bartlomiej Zolnierkiewicz, Jens Axboe
  Cc: linux-ide, linux-kernel

On Mon, 2020-08-24 at 21:56 -0700, Joe Perches wrote:
> Use semicolons and braces.

ping?
 
> Signed-off-by: Joe Perches <joe@perches.com>
> ---
>  drivers/ata/pata_icside.c | 21 +++++++++++++--------
>  1 file changed, 13 insertions(+), 8 deletions(-)
> 
> diff --git a/drivers/ata/pata_icside.c b/drivers/ata/pata_icside.c
> index 08543aeb0093..498383cb6e29 100644
> --- a/drivers/ata/pata_icside.c
> +++ b/drivers/ata/pata_icside.c
> @@ -202,14 +202,19 @@ static void pata_icside_set_dmamode(struct ata_port *ap, struct ata_device *adev
>  	 * Choose the IOMD cycle timing which ensure that the interface
>  	 * satisfies the measured active, recovery and cycle times.
>  	 */
> -	if (t.active <= 50 && t.recover <= 375 && t.cycle <= 425)
> -		iomd_type = 'D', cycle = 187;
> -	else if (t.active <= 125 && t.recover <= 375 && t.cycle <= 500)
> -		iomd_type = 'C', cycle = 250;
> -	else if (t.active <= 200 && t.recover <= 550 && t.cycle <= 750)
> -		iomd_type = 'B', cycle = 437;
> -	else
> -		iomd_type = 'A', cycle = 562;
> +	if (t.active <= 50 && t.recover <= 375 && t.cycle <= 425) {
> +		iomd_type = 'D';
> +		cycle = 187;
> +	} else if (t.active <= 125 && t.recover <= 375 && t.cycle <= 500) {
> +		iomd_type = 'C';
> +		cycle = 250;
> +	} else if (t.active <= 200 && t.recover <= 550 && t.cycle <= 750) {
> +		iomd_type = 'B';
> +		cycle = 437;
> +	} else {
> +		iomd_type = 'A';
> +		cycle = 562;
> +	}
>  
> 
>  	ata_dev_info(adev, "timings: act %dns rec %dns cyc %dns (%c)\n",
>  		     t.active, t.recover, t.cycle, iomd_type);



^ permalink raw reply	[flat|nested] 80+ messages in thread

* Re: [PATCH 06/29] drbd: Avoid comma separated statements
  2020-08-25  4:56 ` [PATCH 06/29] drbd: " Joe Perches
@ 2021-01-30 18:57   ` Joe Perches
  2021-01-31 15:06     ` Jens Axboe
  0 siblings, 1 reply; 80+ messages in thread
From: Joe Perches @ 2021-01-30 18:57 UTC (permalink / raw)
  To: Jiri Kosina, Philipp Reisner, Lars Ellenberg
  Cc: Jens Axboe, drbd-dev, linux-block, linux-kernel

On Mon, 2020-08-24 at 21:56 -0700, Joe Perches wrote:
> Use semicolons and braces.

ping?

> Signed-off-by: Joe Perches <joe@perches.com>
> ---
>  drivers/block/drbd/drbd_receiver.c | 6 ++++--
>  1 file changed, 4 insertions(+), 2 deletions(-)
> 
> diff --git a/drivers/block/drbd/drbd_receiver.c b/drivers/block/drbd/drbd_receiver.c
> index 422363daa618..87f732fb5456 100644
> --- a/drivers/block/drbd/drbd_receiver.c
> +++ b/drivers/block/drbd/drbd_receiver.c
> @@ -111,8 +111,10 @@ static struct page *page_chain_tail(struct page *page, int *len)
>  {
>  	struct page *tmp;
>  	int i = 1;
> -	while ((tmp = page_chain_next(page)))
> -		++i, page = tmp;
> +	while ((tmp = page_chain_next(page))) {
> +		++i;
> +		page = tmp;
> +	}
>  	if (len)
>  		*len = i;
>  	return page;



^ permalink raw reply	[flat|nested] 80+ messages in thread

* Re: [PATCH 13/29] bcache: Avoid comma separated statements
  2020-08-25  4:56 ` [PATCH 13/29] bcache: " Joe Perches
@ 2021-01-30 18:59   ` Joe Perches
  2021-01-31 15:58     ` Coly Li
  0 siblings, 1 reply; 80+ messages in thread
From: Joe Perches @ 2021-01-30 18:59 UTC (permalink / raw)
  To: Jiri Kosina, Coly Li, Kent Overstreet; +Cc: linux-bcache, linux-kernel

On Mon, 2020-08-24 at 21:56 -0700, Joe Perches wrote:
> Use semicolons and braces.

ping?

> Signed-off-by: Joe Perches <joe@perches.com>
> ---
>  drivers/md/bcache/bset.c  | 12 ++++++++----
>  drivers/md/bcache/sysfs.c |  6 ++++--
>  2 files changed, 12 insertions(+), 6 deletions(-)
> 
> diff --git a/drivers/md/bcache/bset.c b/drivers/md/bcache/bset.c
> index 67a2c47f4201..94d38e8a59b3 100644
> --- a/drivers/md/bcache/bset.c
> +++ b/drivers/md/bcache/bset.c
> @@ -712,8 +712,10 @@ void bch_bset_build_written_tree(struct btree_keys *b)
>  	for (j = inorder_next(0, t->size);
>  	     j;
>  	     j = inorder_next(j, t->size)) {
> -		while (bkey_to_cacheline(t, k) < cacheline)
> -			prev = k, k = bkey_next(k);
> +		while (bkey_to_cacheline(t, k) < cacheline) {
> +			prev = k;
> +			k = bkey_next(k);
> +		}
>  
> 
>  		t->prev[j] = bkey_u64s(prev);
>  		t->tree[j].m = bkey_to_cacheline_offset(t, cacheline++, k);
> @@ -901,8 +903,10 @@ unsigned int bch_btree_insert_key(struct btree_keys *b, struct bkey *k,
>  	status = BTREE_INSERT_STATUS_INSERT;
>  
> 
>  	while (m != bset_bkey_last(i) &&
> -	       bkey_cmp(k, b->ops->is_extents ? &START_KEY(m) : m) > 0)
> -		prev = m, m = bkey_next(m);
> +	       bkey_cmp(k, b->ops->is_extents ? &START_KEY(m) : m) > 0) {
> +		prev = m;
> +		m = bkey_next(m);
> +	}
>  
> 
>  	/* prev is in the tree, if we merge we're done */
>  	status = BTREE_INSERT_STATUS_BACK_MERGE;
> diff --git a/drivers/md/bcache/sysfs.c b/drivers/md/bcache/sysfs.c
> index ac06c0bc3c0a..1878c5ee53b6 100644
> --- a/drivers/md/bcache/sysfs.c
> +++ b/drivers/md/bcache/sysfs.c
> @@ -1071,8 +1071,10 @@ SHOW(__bch_cache)
>  			--n;
>  
> 
>  		while (cached < p + n &&
> -		       *cached == BTREE_PRIO)
> -			cached++, n--;
> +		       *cached == BTREE_PRIO) {
> +			cached++;
> +			n--;
> +		}
>  
> 
>  		for (i = 0; i < n; i++)
>  			sum += INITIAL_PRIO - cached[i];



^ permalink raw reply	[flat|nested] 80+ messages in thread

* Re: [PATCH 19/29] s390/tty3270: Avoid comma separated statements
  2020-08-25  4:56 ` [PATCH 19/29] s390/tty3270: " Joe Perches
@ 2021-01-30 19:01   ` Joe Perches
  0 siblings, 0 replies; 80+ messages in thread
From: Joe Perches @ 2021-01-30 19:01 UTC (permalink / raw)
  To: Jiri Kosina, linux-kernel
  Cc: Heiko Carstens, Vasily Gorbik, Christian Borntraeger, linux-s390

On Mon, 2020-08-24 at 21:56 -0700, Joe Perches wrote:
> Use semicolons and braces.

ping?

> Signed-off-by: Joe Perches <joe@perches.com>
> ---
>  drivers/s390/char/tty3270.c | 6 ++++--
>  1 file changed, 4 insertions(+), 2 deletions(-)
> 
> diff --git a/drivers/s390/char/tty3270.c b/drivers/s390/char/tty3270.c
> index aec996de44d9..6acce975df26 100644
> --- a/drivers/s390/char/tty3270.c
> +++ b/drivers/s390/char/tty3270.c
> @@ -424,8 +424,10 @@ tty3270_update(struct timer_list *t)
>  			 * last output position matches the start address
>  			 * of this line.
>  			 */
> -			if (s->string[1] == sba[0] && s->string[2] == sba[1])
> -				str += 3, len -= 3;
> +			if (s->string[1] == sba[0] && s->string[2] == sba[1]) {
> +				str += 3;
> +				len -= 3;
> +			}
>  			if (raw3270_request_add_data(wrq, str, len) != 0)
>  				break;
>  			list_del_init(&s->update);



^ permalink raw reply	[flat|nested] 80+ messages in thread

* Re: [PATCH 23/29] fuse: Avoid comma separated statements
  2020-08-25  4:56 ` [PATCH 23/29] fuse: " Joe Perches
@ 2021-01-30 19:04   ` Joe Perches
  2021-02-01  8:12   ` Miklos Szeredi
  1 sibling, 0 replies; 80+ messages in thread
From: Joe Perches @ 2021-01-30 19:04 UTC (permalink / raw)
  To: Jiri Kosina, Miklos Szeredi; +Cc: linux-fsdevel, linux-kernel

On Mon, 2020-08-24 at 21:56 -0700, Joe Perches wrote:
> Use semicolons and braces.

ping?
 
> Signed-off-by: Joe Perches <joe@perches.com>
> ---
>  fs/fuse/dir.c | 24 ++++++++++++++++--------
>  1 file changed, 16 insertions(+), 8 deletions(-)
> 
> diff --git a/fs/fuse/dir.c b/fs/fuse/dir.c
> index 26f028bc760b..ecb6eed832a0 100644
> --- a/fs/fuse/dir.c
> +++ b/fs/fuse/dir.c
> @@ -1362,14 +1362,22 @@ static void iattr_to_fattr(struct fuse_conn *fc, struct iattr *iattr,
>  {
>  	unsigned ivalid = iattr->ia_valid;
>  
> 
> -	if (ivalid & ATTR_MODE)
> -		arg->valid |= FATTR_MODE,   arg->mode = iattr->ia_mode;
> -	if (ivalid & ATTR_UID)
> -		arg->valid |= FATTR_UID,    arg->uid = from_kuid(fc->user_ns, iattr->ia_uid);
> -	if (ivalid & ATTR_GID)
> -		arg->valid |= FATTR_GID,    arg->gid = from_kgid(fc->user_ns, iattr->ia_gid);
> -	if (ivalid & ATTR_SIZE)
> -		arg->valid |= FATTR_SIZE,   arg->size = iattr->ia_size;
> +	if (ivalid & ATTR_MODE) {
> +		arg->valid |= FATTR_MODE;
> +		arg->mode = iattr->ia_mode;
> +	}
> +	if (ivalid & ATTR_UID) {
> +		arg->valid |= FATTR_UID;
> +		arg->uid = from_kuid(fc->user_ns, iattr->ia_uid);
> +	}
> +	if (ivalid & ATTR_GID) {
> +		arg->valid |= FATTR_GID;
> +		arg->gid = from_kgid(fc->user_ns, iattr->ia_gid);
> +	}
> +	if (ivalid & ATTR_SIZE) {
> +		arg->valid |= FATTR_SIZE;
> +		arg->size = iattr->ia_size;
> +	}
>  	if (ivalid & ATTR_ATIME) {
>  		arg->valid |= FATTR_ATIME;
>  		arg->atime = iattr->ia_atime.tv_sec;



^ permalink raw reply	[flat|nested] 80+ messages in thread

* Re: [PATCH 24/29] reiserfs: Avoid comma separated statements
  2020-08-25  4:56 ` [PATCH 24/29] reiserfs: " Joe Perches
@ 2021-01-30 19:04   ` Joe Perches
  0 siblings, 0 replies; 80+ messages in thread
From: Joe Perches @ 2021-01-30 19:04 UTC (permalink / raw)
  To: Jiri Kosina, linux-kernel; +Cc: reiserfs-devel

On Mon, 2020-08-24 at 21:56 -0700, Joe Perches wrote:
> Use semicolons and braces.

ping?

> Signed-off-by: Joe Perches <joe@perches.com>
> ---
>  fs/reiserfs/fix_node.c | 36 ++++++++++++++++++++++++------------
>  1 file changed, 24 insertions(+), 12 deletions(-)
> 
> diff --git a/fs/reiserfs/fix_node.c b/fs/reiserfs/fix_node.c
> index fefe87e1c099..aea63e67a42b 100644
> --- a/fs/reiserfs/fix_node.c
> +++ b/fs/reiserfs/fix_node.c
> @@ -235,8 +235,10 @@ static void check_left(struct tree_balance *tb, int h, int cur_free)
>  	d_size = 0, ih_size = IH_SIZE;
>  
> 
>  	/* first item may be merge with last item in left neighbor */
> -	if (vi->vi_type & VI_TYPE_LEFT_MERGEABLE)
> -		d_size = -((int)IH_SIZE), ih_size = 0;
> +	if (vi->vi_type & VI_TYPE_LEFT_MERGEABLE) {
> +		d_size = -((int)IH_SIZE);
> +		ih_size = 0;
> +	}
>  
> 
>  	tb->lnum[0] = 0;
>  	for (i = 0; i < vn->vn_nr_item;
> @@ -321,8 +323,10 @@ static void check_right(struct tree_balance *tb, int h, int cur_free)
>  	d_size = 0, ih_size = IH_SIZE;
>  
> 
>  	/* last item may be merge with first item in right neighbor */
> -	if (vi->vi_type & VI_TYPE_RIGHT_MERGEABLE)
> -		d_size = -(int)IH_SIZE, ih_size = 0;
> +	if (vi->vi_type & VI_TYPE_RIGHT_MERGEABLE) {
> +		d_size = -(int)IH_SIZE;
> +		ih_size = 0;
> +	}
>  
> 
>  	tb->rnum[0] = 0;
>  	for (i = vn->vn_nr_item - 1; i >= 0;
> @@ -1534,8 +1538,10 @@ static int ip_check_balance(struct tree_balance *tb, int h)
>  			nver1 = get_num_ver(vn->vn_mode, tb, h,
>  					    0, -1, 0, -1,
>  					    snum012 + NOTHING_SHIFT_FLOW, FLOW);
> -			if (nver > nver1)
> -				nset = NOTHING_SHIFT_FLOW, nver = nver1;
> +			if (nver > nver1) {
> +				nset = NOTHING_SHIFT_FLOW;
> +				nver = nver1;
> +			}
>  		}
>  
> 
>  		/*
> @@ -1559,8 +1565,10 @@ static int ip_check_balance(struct tree_balance *tb, int h)
>  					     ((tb->lbytes != -1) ? 1 : 0),
>  					     tb->lbytes, 0, -1,
>  					     snum012 + LEFT_SHIFT_FLOW, FLOW);
> -			if (lnver > lnver1)
> -				lset = LEFT_SHIFT_FLOW, lnver = lnver1;
> +			if (lnver > lnver1) {
> +				lset = LEFT_SHIFT_FLOW;
> +				lnver = lnver1;
> +			}
>  		}
>  
> 
>  		/*
> @@ -1590,8 +1598,10 @@ static int ip_check_balance(struct tree_balance *tb, int h)
>  					     tb->rbytes,
>  					     snum012 + RIGHT_SHIFT_FLOW, FLOW);
>  
> 
> -			if (rnver > rnver1)
> -				rset = RIGHT_SHIFT_FLOW, rnver = rnver1;
> +			if (rnver > rnver1) {
> +				rset = RIGHT_SHIFT_FLOW;
> +				rnver = rnver1;
> +			}
>  		}
>  
> 
>  		/*
> @@ -1622,8 +1632,10 @@ static int ip_check_balance(struct tree_balance *tb, int h)
>  					       ((tb->rbytes != -1) ? 1 : 0)),
>  					      tb->rbytes,
>  					      snum012 + LR_SHIFT_FLOW, FLOW);
> -			if (lrnver > lrnver1)
> -				lrset = LR_SHIFT_FLOW, lrnver = lrnver1;
> +			if (lrnver > lrnver1) {
> +				lrset = LR_SHIFT_FLOW;
> +				lrnver = lrnver1;
> +			}
>  		}
>  
> 
>  		/*



^ permalink raw reply	[flat|nested] 80+ messages in thread

* Re: [PATCH 25/29] lib/zlib: Avoid comma separated statements
  2020-08-25  4:56 ` [PATCH 25/29] lib/zlib: " Joe Perches
@ 2021-01-30 19:05   ` Joe Perches
  0 siblings, 0 replies; 80+ messages in thread
From: Joe Perches @ 2021-01-30 19:05 UTC (permalink / raw)
  To: Jiri Kosina, linux-kernel

On Mon, 2020-08-24 at 21:56 -0700, Joe Perches wrote:
> Use semicolons and braces.

ping?
 
> Signed-off-by: Joe Perches <joe@perches.com>
> ---
>  lib/zlib_deflate/deftree.c | 49 +++++++++++++++++++++++++++-----------
>  1 file changed, 35 insertions(+), 14 deletions(-)
> 
> diff --git a/lib/zlib_deflate/deftree.c b/lib/zlib_deflate/deftree.c
> index a4a34da512fe..e358053bdb15 100644
> --- a/lib/zlib_deflate/deftree.c
> +++ b/lib/zlib_deflate/deftree.c
> @@ -217,10 +217,22 @@ static void tr_static_init(void)
>      /* Construct the codes of the static literal tree */
>      for (bits = 0; bits <= MAX_BITS; bits++) bl_count[bits] = 0;
>      n = 0;
> -    while (n <= 143) static_ltree[n++].Len = 8, bl_count[8]++;
> -    while (n <= 255) static_ltree[n++].Len = 9, bl_count[9]++;
> -    while (n <= 279) static_ltree[n++].Len = 7, bl_count[7]++;
> -    while (n <= 287) static_ltree[n++].Len = 8, bl_count[8]++;
> +    while (n <= 143) {
> +        static_ltree[n++].Len = 8;
> +	bl_count[8]++;
> +    }
> +    while (n <= 255) {
> +        static_ltree[n++].Len = 9;
> +	bl_count[9]++;
> +    }
> +    while (n <= 279) {
> +        static_ltree[n++].Len = 7;
> +	bl_count[7]++;
> +    }
> +    while (n <= 287) {
> +        static_ltree[n++].Len = 8;
> +	bl_count[8]++;
> +    }
>      /* Codes 286 and 287 do not exist, but we must include them in the
>       * tree construction to get a canonical Huffman tree (longest code
>       * all ones)
> @@ -378,7 +390,10 @@ static void gen_bitlen(
>      for (h = s->heap_max+1; h < HEAP_SIZE; h++) {
>          n = s->heap[h];
>          bits = tree[tree[n].Dad].Len + 1;
> -        if (bits > max_length) bits = max_length, overflow++;
> +        if (bits > max_length) {
> +            bits = max_length;
> +	    overflow++;
> +        }
>          tree[n].Len = (ush)bits;
>          /* We overwrite tree[n].Dad which is no longer needed */
>  
> 
> @@ -497,7 +512,7 @@ static void build_tree(
>       * heap[SMALLEST]. The sons of heap[n] are heap[2*n] and heap[2*n+1].
>       * heap[0] is not used.
>       */
> -    s->heap_len = 0, s->heap_max = HEAP_SIZE;
> +    s->heap_len = 0; s->heap_max = HEAP_SIZE;
>  
> 
>      for (n = 0; n < elems; n++) {
>          if (tree[n].Freq != 0) {
> @@ -583,7 +598,10 @@ static void scan_tree(
>      int max_count = 7;         /* max repeat count */
>      int min_count = 4;         /* min repeat count */
>  
> 
> -    if (nextlen == 0) max_count = 138, min_count = 3;
> +    if (nextlen == 0) {
> +        max_count = 138;
> +	min_count = 3;
> +    }
>      tree[max_code+1].Len = (ush)0xffff; /* guard */
>  
> 
>      for (n = 0; n <= max_code; n++) {
> @@ -602,11 +620,11 @@ static void scan_tree(
>          }
>          count = 0; prevlen = curlen;
>          if (nextlen == 0) {
> -            max_count = 138, min_count = 3;
> +            max_count = 138; min_count = 3;
>          } else if (curlen == nextlen) {
> -            max_count = 6, min_count = 3;
> +            max_count = 6; min_count = 3;
>          } else {
> -            max_count = 7, min_count = 4;
> +            max_count = 7; min_count = 4;
>          }
>      }
>  }
> @@ -630,7 +648,10 @@ static void send_tree(
>      int min_count = 4;         /* min repeat count */
>  
> 
>      /* tree[max_code+1].Len = -1; */  /* guard already set */
> -    if (nextlen == 0) max_count = 138, min_count = 3;
> +    if (nextlen == 0) {
> +        max_count = 138;
> +	min_count = 3;
> +    }
>  
> 
>      for (n = 0; n <= max_code; n++) {
>          curlen = nextlen; nextlen = tree[n+1].Len;
> @@ -654,11 +675,11 @@ static void send_tree(
>          }
>          count = 0; prevlen = curlen;
>          if (nextlen == 0) {
> -            max_count = 138, min_count = 3;
> +            max_count = 138; min_count = 3;
>          } else if (curlen == nextlen) {
> -            max_count = 6, min_count = 3;
> +            max_count = 6; min_count = 3;
>          } else {
> -            max_count = 7, min_count = 4;
> +            max_count = 7; min_count = 4;
>          }
>      }
>  }



^ permalink raw reply	[flat|nested] 80+ messages in thread

* Re: [PATCH 26/29] lib: zstd: Avoid comma separated statements
  2020-08-25  4:56 ` [PATCH 26/29] lib: zstd: " Joe Perches
@ 2021-01-30 19:06   ` Joe Perches
  0 siblings, 0 replies; 80+ messages in thread
From: Joe Perches @ 2021-01-30 19:06 UTC (permalink / raw)
  To: Jiri Kosina, linux-kernel

On Mon, 2020-08-24 at 21:56 -0700, Joe Perches wrote:
> Use semicolons and braces.

ping?

> Signed-off-by: Joe Perches <joe@perches.com>
> ---
>  lib/zstd/compress.c     | 120 ++++++++++++++++++++++++++--------------
>  lib/zstd/fse_compress.c |  24 +++++---
>  lib/zstd/huf_compress.c |   6 +-
>  3 files changed, 100 insertions(+), 50 deletions(-)
> 
> diff --git a/lib/zstd/compress.c b/lib/zstd/compress.c
> index b080264ed3ad..d8587e458665 100644
> --- a/lib/zstd/compress.c
> +++ b/lib/zstd/compress.c
> @@ -629,12 +629,17 @@ ZSTD_STATIC size_t ZSTD_compressSequences_internal(ZSTD_CCtx *zc, void *dst, siz
>  	/* Sequences Header */
>  	if ((oend - op) < 3 /*max nbSeq Size*/ + 1 /*seqHead */)
>  		return ERROR(dstSize_tooSmall);
> -	if (nbSeq < 0x7F)
> +	if (nbSeq < 0x7F) {
>  		*op++ = (BYTE)nbSeq;
> -	else if (nbSeq < LONGNBSEQ)
> -		op[0] = (BYTE)((nbSeq >> 8) + 0x80), op[1] = (BYTE)nbSeq, op += 2;
> -	else
> -		op[0] = 0xFF, ZSTD_writeLE16(op + 1, (U16)(nbSeq - LONGNBSEQ)), op += 3;
> +	} else if (nbSeq < LONGNBSEQ) {
> +		op[0] = (BYTE)((nbSeq >> 8) + 0x80);
> +		op[1] = (BYTE)nbSeq;
> +		op += 2;
> +	} else {
> +		op[0] = 0xFF;
> +		ZSTD_writeLE16(op + 1, (U16)(nbSeq - LONGNBSEQ));
> +		op += 3;
> +	}
>  	if (nbSeq == 0)
>  		return op - ostart;
>  
> 
> @@ -1025,10 +1030,13 @@ void ZSTD_compressBlock_fast_generic(ZSTD_CCtx *cctx, const void *src, size_t sr
>  	ip += (ip == lowest);
>  	{
>  		U32 const maxRep = (U32)(ip - lowest);
> -		if (offset_2 > maxRep)
> -			offsetSaved = offset_2, offset_2 = 0;
> -		if (offset_1 > maxRep)
> -			offsetSaved = offset_1, offset_1 = 0;
> +		if (offset_2 > maxRep) {
> +			offsetSaved = offset_2;
> +			offset_2 = 0;
> +		}
> +		if (offset_1 > maxRep) {
> +			offsetSaved = offset_1; offset_1 = 0;
> +		}
>  	}
>  
> 
>  	/* Main Search Loop */
> @@ -1273,10 +1281,14 @@ void ZSTD_compressBlock_doubleFast_generic(ZSTD_CCtx *cctx, const void *src, siz
>  	ip += (ip == lowest);
>  	{
>  		U32 const maxRep = (U32)(ip - lowest);
> -		if (offset_2 > maxRep)
> -			offsetSaved = offset_2, offset_2 = 0;
> -		if (offset_1 > maxRep)
> -			offsetSaved = offset_1, offset_1 = 0;
> +		if (offset_2 > maxRep) {
> +			offsetSaved = offset_2;
> +			offset_2 = 0;
> +		}
> +		if (offset_1 > maxRep) {
> +			offsetSaved = offset_1;
> +			offset_1 = 0;
> +		}
>  	}
>  
> 
>  	/* Main Search Loop */
> @@ -1686,8 +1698,10 @@ static size_t ZSTD_insertBtAndFindBestMatch(ZSTD_CCtx *zc, const BYTE *const ip,
>  		if (matchLength > bestLength) {
>  			if (matchLength > matchEndIdx - matchIndex)
>  				matchEndIdx = matchIndex + (U32)matchLength;
> -			if ((4 * (int)(matchLength - bestLength)) > (int)(ZSTD_highbit32(curr - matchIndex + 1) - ZSTD_highbit32((U32)offsetPtr[0] + 1)))
> -				bestLength = matchLength, *offsetPtr = ZSTD_REP_MOVE + curr - matchIndex;
> +			if ((4 * (int)(matchLength - bestLength)) > (int)(ZSTD_highbit32(curr - matchIndex + 1) - ZSTD_highbit32((U32)offsetPtr[0] + 1))) {
> +				bestLength = matchLength;
> +				*offsetPtr = ZSTD_REP_MOVE + curr - matchIndex;
> +			}
>  			if (ip + matchLength == iend) /* equal : no way to know if inf or sup */
>  				break;		      /* drop, to guarantee consistency (miss a little bit of compression) */
>  		}
> @@ -1916,10 +1930,14 @@ void ZSTD_compressBlock_lazy_generic(ZSTD_CCtx *ctx, const void *src, size_t src
>  	ctx->nextToUpdate3 = ctx->nextToUpdate;
>  	{
>  		U32 const maxRep = (U32)(ip - base);
> -		if (offset_2 > maxRep)
> -			savedOffset = offset_2, offset_2 = 0;
> -		if (offset_1 > maxRep)
> -			savedOffset = offset_1, offset_1 = 0;
> +		if (offset_2 > maxRep) {
> +			savedOffset = offset_2;
> +			offset_2 = 0;
> +		}
> +		if (offset_1 > maxRep) {
> +			savedOffset = offset_1;
> +			offset_1 = 0;
> +		}
>  	}
>  
> 
>  	/* Match Loop */
> @@ -1940,8 +1958,11 @@ void ZSTD_compressBlock_lazy_generic(ZSTD_CCtx *ctx, const void *src, size_t src
>  		{
>  			size_t offsetFound = 99999999;
>  			size_t const ml2 = searchMax(ctx, ip, iend, &offsetFound, maxSearches, mls);
> -			if (ml2 > matchLength)
> -				matchLength = ml2, start = ip, offset = offsetFound;
> +			if (ml2 > matchLength) {
> +				matchLength = ml2;
> +				start = ip;
> +				offset = offsetFound;
> +			}
>  		}
>  
> 
>  		if (matchLength < EQUAL_READ32) {
> @@ -1957,8 +1978,11 @@ void ZSTD_compressBlock_lazy_generic(ZSTD_CCtx *ctx, const void *src, size_t src
>  					size_t const mlRep = ZSTD_count(ip + EQUAL_READ32, ip + EQUAL_READ32 - offset_1, iend) + EQUAL_READ32;
>  					int const gain2 = (int)(mlRep * 3);
>  					int const gain1 = (int)(matchLength * 3 - ZSTD_highbit32((U32)offset + 1) + 1);
> -					if ((mlRep >= EQUAL_READ32) && (gain2 > gain1))
> -						matchLength = mlRep, offset = 0, start = ip;
> +					if ((mlRep >= EQUAL_READ32) && (gain2 > gain1)) {
> +						matchLength = mlRep;
> +						offset = 0;
> +						start = ip;
> +					}
>  				}
>  				{
>  					size_t offset2 = 99999999;
> @@ -1966,7 +1990,7 @@ void ZSTD_compressBlock_lazy_generic(ZSTD_CCtx *ctx, const void *src, size_t src
>  					int const gain2 = (int)(ml2 * 4 - ZSTD_highbit32((U32)offset2 + 1)); /* raw approx */
>  					int const gain1 = (int)(matchLength * 4 - ZSTD_highbit32((U32)offset + 1) + 4);
>  					if ((ml2 >= EQUAL_READ32) && (gain2 > gain1)) {
> -						matchLength = ml2, offset = offset2, start = ip;
> +						matchLength = ml2, offset = offset2; start = ip;
>  						continue; /* search a better one */
>  					}
>  				}
> @@ -1978,8 +2002,11 @@ void ZSTD_compressBlock_lazy_generic(ZSTD_CCtx *ctx, const void *src, size_t src
>  						size_t const ml2 = ZSTD_count(ip + EQUAL_READ32, ip + EQUAL_READ32 - offset_1, iend) + EQUAL_READ32;
>  						int const gain2 = (int)(ml2 * 4);
>  						int const gain1 = (int)(matchLength * 4 - ZSTD_highbit32((U32)offset + 1) + 1);
> -						if ((ml2 >= EQUAL_READ32) && (gain2 > gain1))
> -							matchLength = ml2, offset = 0, start = ip;
> +						if ((ml2 >= EQUAL_READ32) && (gain2 > gain1)) {
> +							matchLength = ml2;
> +							offset = 0;
> +							start = ip;
> +						}
>  					}
>  					{
>  						size_t offset2 = 99999999;
> @@ -1987,7 +2014,7 @@ void ZSTD_compressBlock_lazy_generic(ZSTD_CCtx *ctx, const void *src, size_t src
>  						int const gain2 = (int)(ml2 * 4 - ZSTD_highbit32((U32)offset2 + 1)); /* raw approx */
>  						int const gain1 = (int)(matchLength * 4 - ZSTD_highbit32((U32)offset + 1) + 7);
>  						if ((ml2 >= EQUAL_READ32) && (gain2 > gain1)) {
> -							matchLength = ml2, offset = offset2, start = ip;
> +							matchLength = ml2, offset = offset2; start = ip;
>  							continue;
>  						}
>  					}
> @@ -2110,8 +2137,11 @@ void ZSTD_compressBlock_lazy_extDict_generic(ZSTD_CCtx *ctx, const void *src, si
>  		{
>  			size_t offsetFound = 99999999;
>  			size_t const ml2 = searchMax(ctx, ip, iend, &offsetFound, maxSearches, mls);
> -			if (ml2 > matchLength)
> -				matchLength = ml2, start = ip, offset = offsetFound;
> +			if (ml2 > matchLength) {
> +				matchLength = ml2;
> +				start = ip;
> +				offset = offsetFound;
> +			}
>  		}
>  
> 
>  		if (matchLength < EQUAL_READ32) {
> @@ -2138,8 +2168,11 @@ void ZSTD_compressBlock_lazy_extDict_generic(ZSTD_CCtx *ctx, const void *src, si
>  							    EQUAL_READ32;
>  							int const gain2 = (int)(repLength * 3);
>  							int const gain1 = (int)(matchLength * 3 - ZSTD_highbit32((U32)offset + 1) + 1);
> -							if ((repLength >= EQUAL_READ32) && (gain2 > gain1))
> -								matchLength = repLength, offset = 0, start = ip;
> +							if ((repLength >= EQUAL_READ32) && (gain2 > gain1)) {
> +								matchLength = repLength;
> +								offset = 0;
> +								start = ip;
> +							}
>  						}
>  				}
>  
> 
> @@ -2150,7 +2183,7 @@ void ZSTD_compressBlock_lazy_extDict_generic(ZSTD_CCtx *ctx, const void *src, si
>  					int const gain2 = (int)(ml2 * 4 - ZSTD_highbit32((U32)offset2 + 1)); /* raw approx */
>  					int const gain1 = (int)(matchLength * 4 - ZSTD_highbit32((U32)offset + 1) + 4);
>  					if ((ml2 >= EQUAL_READ32) && (gain2 > gain1)) {
> -						matchLength = ml2, offset = offset2, start = ip;
> +						matchLength = ml2, offset = offset2; start = ip;
>  						continue; /* search a better one */
>  					}
>  				}
> @@ -2173,8 +2206,11 @@ void ZSTD_compressBlock_lazy_extDict_generic(ZSTD_CCtx *ctx, const void *src, si
>  										   EQUAL_READ32;
>  								int gain2 = (int)(repLength * 4);
>  								int gain1 = (int)(matchLength * 4 - ZSTD_highbit32((U32)offset + 1) + 1);
> -								if ((repLength >= EQUAL_READ32) && (gain2 > gain1))
> -									matchLength = repLength, offset = 0, start = ip;
> +								if ((repLength >= EQUAL_READ32) && (gain2 > gain1)) {
> +									matchLength = repLength;
> +									offset = 0;
> +									start = ip;
> +								}
>  							}
>  					}
>  
> 
> @@ -2185,7 +2221,7 @@ void ZSTD_compressBlock_lazy_extDict_generic(ZSTD_CCtx *ctx, const void *src, si
>  						int const gain2 = (int)(ml2 * 4 - ZSTD_highbit32((U32)offset2 + 1)); /* raw approx */
>  						int const gain1 = (int)(matchLength * 4 - ZSTD_highbit32((U32)offset + 1) + 7);
>  						if ((ml2 >= EQUAL_READ32) && (gain2 > gain1)) {
> -							matchLength = ml2, offset = offset2, start = ip;
> +							matchLength = ml2, offset = offset2; start = ip;
>  							continue;
>  						}
>  					}
> @@ -3159,10 +3195,12 @@ static size_t ZSTD_compressStream_generic(ZSTD_CStream *zcs, void *dst, size_t *
>  				size_t cSize;
>  				size_t const iSize = zcs->inBuffPos - zcs->inToCompress;
>  				size_t oSize = oend - op;
> -				if (oSize >= ZSTD_compressBound(iSize))
> +				if (oSize >= ZSTD_compressBound(iSize)) {
>  					cDst = op; /* compress directly into output buffer (avoid flush stage) */
> -				else
> -					cDst = zcs->outBuff, oSize = zcs->outBuffSize;
> +				} else {
> +					cDst = zcs->outBuff;
> +					oSize = zcs->outBuffSize;
> +				}
>  				cSize = (flush == zsf_end) ? ZSTD_compressEnd(zcs->cctx, cDst, oSize, zcs->inBuff + zcs->inToCompress, iSize)
>  							   : ZSTD_compressContinue(zcs->cctx, cDst, oSize, zcs->inBuff + zcs->inToCompress, iSize);
>  				if (ZSTD_isError(cSize))
> @@ -3171,8 +3209,10 @@ static size_t ZSTD_compressStream_generic(ZSTD_CStream *zcs, void *dst, size_t *
>  					zcs->frameEnded = 1;
>  				/* prepare next block */
>  				zcs->inBuffTarget = zcs->inBuffPos + zcs->blockSize;
> -				if (zcs->inBuffTarget > zcs->inBuffSize)
> -					zcs->inBuffPos = 0, zcs->inBuffTarget = zcs->blockSize; /* note : inBuffSize >= blockSize */
> +				if (zcs->inBuffTarget > zcs->inBuffSize) {
> +					zcs->inBuffPos = 0;
> +					zcs->inBuffTarget = zcs->blockSize;
> +				} /* note : inBuffSize >= blockSize */
>  				zcs->inToCompress = zcs->inBuffPos;
>  				if (cDst == op) {
>  					op += cSize;
> diff --git a/lib/zstd/fse_compress.c b/lib/zstd/fse_compress.c
> index ef3d1741d532..99a21c35d0ac 100644
> --- a/lib/zstd/fse_compress.c
> +++ b/lib/zstd/fse_compress.c
> @@ -271,8 +271,10 @@ static size_t FSE_writeNCount_generic(void *header, size_t headerBufferSize, con
>  			previous0 = (count == 1);
>  			if (remaining < 1)
>  				return ERROR(GENERIC);
> -			while (remaining < threshold)
> -				nbBits--, threshold >>= 1;
> +			while (remaining < threshold) {
> +				nbBits--;
> +				threshold >>= 1;
> +			}
>  		}
>  		if (bitCount > 16) {
>  			if ((!writeIsSafe) && (out > oend - 2))
> @@ -569,8 +571,10 @@ static size_t FSE_normalizeM2(short *norm, U32 tableLog, const unsigned *count,
>  		   find max, then give all remaining points to max */
>  		U32 maxV = 0, maxC = 0;
>  		for (s = 0; s <= maxSymbolValue; s++)
> -			if (count[s] > maxC)
> -				maxV = s, maxC = count[s];
> +			if (count[s] > maxC) {
> +				maxV = s;
> +				maxC = count[s];
> +			}
>  		norm[maxV] += (short)ToDistribute;
>  		return 0;
>  	}
> @@ -578,8 +582,10 @@ static size_t FSE_normalizeM2(short *norm, U32 tableLog, const unsigned *count,
>  	if (total == 0) {
>  		/* all of the symbols were low enough for the lowOne or lowThreshold */
>  		for (s = 0; ToDistribute > 0; s = (s + 1) % (maxSymbolValue + 1))
> -			if (norm[s] > 0)
> -				ToDistribute--, norm[s]++;
> +			if (norm[s] > 0) {
> +				ToDistribute--;
> +				norm[s]++;
> +			}
>  		return 0;
>  	}
>  
> 
> @@ -644,8 +650,10 @@ size_t FSE_normalizeCount(short *normalizedCounter, unsigned tableLog, const uns
>  					U64 restToBeat = vStep * rtbTable[proba];
>  					proba += (count[s] * step) - ((U64)proba << scale) > restToBeat;
>  				}
> -				if (proba > largestP)
> -					largestP = proba, largest = s;
> +				if (proba > largestP) {
> +					largestP = proba;
> +					largest = s;
> +				}
>  				normalizedCounter[s] = proba;
>  				stillToDistribute -= proba;
>  			}
> diff --git a/lib/zstd/huf_compress.c b/lib/zstd/huf_compress.c
> index 08b4ae80aed4..ca12ab400086 100644
> --- a/lib/zstd/huf_compress.c
> +++ b/lib/zstd/huf_compress.c
> @@ -404,8 +404,10 @@ static void HUF_sort(nodeElt *huffNode, const U32 *count, U32 maxSymbolValue)
>  		U32 const c = count[n];
>  		U32 const r = BIT_highbit32(c + 1) + 1;
>  		U32 pos = rank[r].curr++;
> -		while ((pos > rank[r].base) && (c > huffNode[pos - 1].count))
> -			huffNode[pos] = huffNode[pos - 1], pos--;
> +		while ((pos > rank[r].base) && (c > huffNode[pos - 1].count)) {
> +			huffNode[pos] = huffNode[pos - 1];
> +			pos--;
> +		}
>  		huffNode[pos].count = c;
>  		huffNode[pos].byte = (BYTE)n;
>  	}



^ permalink raw reply	[flat|nested] 80+ messages in thread

* Re: [PATCH 09/29] drm/gma500: Avoid comma separated statements
  2021-01-30 18:47   ` Joe Perches
@ 2021-01-30 21:21     ` Patrik Jakobsson
  0 siblings, 0 replies; 80+ messages in thread
From: Patrik Jakobsson @ 2021-01-30 21:21 UTC (permalink / raw)
  To: Joe Perches
  Cc: Jiri Kosina, David Airlie, Daniel Vetter, dri-devel, linux-kernel

On Sat, Jan 30, 2021 at 7:47 PM Joe Perches <joe@perches.com> wrote:
>
> On Mon, 2020-08-24 at 21:56 -0700, Joe Perches wrote:
> > Use semicolons and braces.
>
> Ping?

This entire file is going away so perhaps just drop the patch to avoid
a conflict.

-Patrik

>
> > Signed-off-by: Joe Perches <joe@perches.com>
> > ---
> >  drivers/gpu/drm/gma500/mdfld_intel_display.c | 44 +++++++++++++-------
> >  1 file changed, 28 insertions(+), 16 deletions(-)
> >
> > diff --git a/drivers/gpu/drm/gma500/mdfld_intel_display.c b/drivers/gpu/drm/gma500/mdfld_intel_display.c
> > index aae2d358364c..bfa330df9443 100644
> > --- a/drivers/gpu/drm/gma500/mdfld_intel_display.c
> > +++ b/drivers/gpu/drm/gma500/mdfld_intel_display.c
> > @@ -824,33 +824,45 @@ static int mdfld_crtc_mode_set(struct drm_crtc *crtc,
> >               if ((ksel == KSEL_CRYSTAL_19) || (ksel == KSEL_BYPASS_19)) {
> >                       refclk = 19200;
> >
> >
> > -                     if (is_mipi || is_mipi2)
> > -                             clk_n = 1, clk_p2 = 8;
> > -                     else if (is_hdmi)
> > -                             clk_n = 1, clk_p2 = 10;
> > +                     if (is_mipi || is_mipi2) {
> > +                             clk_n = 1;
> > +                             clk_p2 = 8;
> > +                     } else if (is_hdmi) {
> > +                             clk_n = 1;
> > +                             clk_p2 = 10;
> > +                     }
> >               } else if (ksel == KSEL_BYPASS_25) {
> >                       refclk = 25000;
> >
> >
> > -                     if (is_mipi || is_mipi2)
> > -                             clk_n = 1, clk_p2 = 8;
> > -                     else if (is_hdmi)
> > -                             clk_n = 1, clk_p2 = 10;
> > +                     if (is_mipi || is_mipi2) {
> > +                             clk_n = 1;
> > +                             clk_p2 = 8;
> > +                     } else if (is_hdmi) {
> > +                             clk_n = 1;
> > +                             clk_p2 = 10;
> > +                     }
> >               } else if ((ksel == KSEL_BYPASS_83_100) &&
> >                                       dev_priv->core_freq == 166) {
> >                       refclk = 83000;
> >
> >
> > -                     if (is_mipi || is_mipi2)
> > -                             clk_n = 4, clk_p2 = 8;
> > -                     else if (is_hdmi)
> > -                             clk_n = 4, clk_p2 = 10;
> > +                     if (is_mipi || is_mipi2) {
> > +                             clk_n = 4;
> > +                             clk_p2 = 8;
> > +                     } else if (is_hdmi) {
> > +                             clk_n = 4;
> > +                             clk_p2 = 10;
> > +                     }
> >               } else if ((ksel == KSEL_BYPASS_83_100) &&
> >                                       (dev_priv->core_freq == 100 ||
> >                                       dev_priv->core_freq == 200)) {
> >                       refclk = 100000;
> > -                     if (is_mipi || is_mipi2)
> > -                             clk_n = 4, clk_p2 = 8;
> > -                     else if (is_hdmi)
> > -                             clk_n = 4, clk_p2 = 10;
> > +                     if (is_mipi || is_mipi2) {
> > +                             clk_n = 4;
> > +                             clk_p2 = 8;
> > +                     } else if (is_hdmi) {
> > +                             clk_n = 4;
> > +                             clk_p2 = 10;
> > +                     }
> >               }
> >
> >
> >               if (is_mipi)
>
>

^ permalink raw reply	[flat|nested] 80+ messages in thread

* Re: [PATCH 05/29] ata: Avoid comma separated statements
  2021-01-30 18:56   ` Joe Perches
@ 2021-01-31 15:06     ` Jens Axboe
  0 siblings, 0 replies; 80+ messages in thread
From: Jens Axboe @ 2021-01-31 15:06 UTC (permalink / raw)
  To: Joe Perches, Jiri Kosina, Bartlomiej Zolnierkiewicz
  Cc: linux-ide, linux-kernel

On 1/30/21 11:56 AM, Joe Perches wrote:
> On Mon, 2020-08-24 at 21:56 -0700, Joe Perches wrote:
>> Use semicolons and braces.
> 
> ping?

Queued for 5.12.

-- 
Jens Axboe


^ permalink raw reply	[flat|nested] 80+ messages in thread

* Re: [PATCH 06/29] drbd: Avoid comma separated statements
  2021-01-30 18:57   ` Joe Perches
@ 2021-01-31 15:06     ` Jens Axboe
  0 siblings, 0 replies; 80+ messages in thread
From: Jens Axboe @ 2021-01-31 15:06 UTC (permalink / raw)
  To: Joe Perches, Jiri Kosina, Philipp Reisner, Lars Ellenberg
  Cc: drbd-dev, linux-block, linux-kernel

On 1/30/21 11:57 AM, Joe Perches wrote:
> On Mon, 2020-08-24 at 21:56 -0700, Joe Perches wrote:
>> Use semicolons and braces.
> 
> ping?

Queued for 5.12.

-- 
Jens Axboe


^ permalink raw reply	[flat|nested] 80+ messages in thread

* Re: [PATCH 13/29] bcache: Avoid comma separated statements
  2021-01-30 18:59   ` Joe Perches
@ 2021-01-31 15:58     ` Coly Li
  0 siblings, 0 replies; 80+ messages in thread
From: Coly Li @ 2021-01-31 15:58 UTC (permalink / raw)
  To: Joe Perches; +Cc: linux-bcache, linux-kernel, Jiri Kosina, Kent Overstreet

On 1/31/21 2:59 AM, Joe Perches wrote:
> On Mon, 2020-08-24 at 21:56 -0700, Joe Perches wrote:
>> Use semicolons and braces.
> 
> ping?

It is in my for-next now, thanks for reminding.


Coly Li


> 
>> Signed-off-by: Joe Perches <joe@perches.com>
>> ---
>>  drivers/md/bcache/bset.c  | 12 ++++++++----
>>  drivers/md/bcache/sysfs.c |  6 ++++--
>>  2 files changed, 12 insertions(+), 6 deletions(-)
>>
>> diff --git a/drivers/md/bcache/bset.c b/drivers/md/bcache/bset.c
>> index 67a2c47f4201..94d38e8a59b3 100644
>> --- a/drivers/md/bcache/bset.c
>> +++ b/drivers/md/bcache/bset.c
>> @@ -712,8 +712,10 @@ void bch_bset_build_written_tree(struct btree_keys *b)
>>  	for (j = inorder_next(0, t->size);
>>  	     j;
>>  	     j = inorder_next(j, t->size)) {
>> -		while (bkey_to_cacheline(t, k) < cacheline)
>> -			prev = k, k = bkey_next(k);
>> +		while (bkey_to_cacheline(t, k) < cacheline) {
>> +			prev = k;
>> +			k = bkey_next(k);
>> +		}
>>  
>>
>>  		t->prev[j] = bkey_u64s(prev);
>>  		t->tree[j].m = bkey_to_cacheline_offset(t, cacheline++, k);
>> @@ -901,8 +903,10 @@ unsigned int bch_btree_insert_key(struct btree_keys *b, struct bkey *k,
>>  	status = BTREE_INSERT_STATUS_INSERT;
>>  
>>
>>  	while (m != bset_bkey_last(i) &&
>> -	       bkey_cmp(k, b->ops->is_extents ? &START_KEY(m) : m) > 0)
>> -		prev = m, m = bkey_next(m);
>> +	       bkey_cmp(k, b->ops->is_extents ? &START_KEY(m) : m) > 0) {
>> +		prev = m;
>> +		m = bkey_next(m);
>> +	}
>>  
>>
>>  	/* prev is in the tree, if we merge we're done */
>>  	status = BTREE_INSERT_STATUS_BACK_MERGE;
>> diff --git a/drivers/md/bcache/sysfs.c b/drivers/md/bcache/sysfs.c
>> index ac06c0bc3c0a..1878c5ee53b6 100644
>> --- a/drivers/md/bcache/sysfs.c
>> +++ b/drivers/md/bcache/sysfs.c
>> @@ -1071,8 +1071,10 @@ SHOW(__bch_cache)
>>  			--n;
>>  
>>
>>  		while (cached < p + n &&
>> -		       *cached == BTREE_PRIO)
>> -			cached++, n--;
>> +		       *cached == BTREE_PRIO) {
>> +			cached++;
>> +			n--;
>> +		}
>>  
>>
>>  		for (i = 0; i < n; i++)
>>  			sum += INITIAL_PRIO - cached[i];
> 
> 


^ permalink raw reply	[flat|nested] 80+ messages in thread

* Re: [PATCH 08/29] dma-buf: Avoid comma separated statements
  2021-02-03 13:26     ` Christian König
@ 2021-01-31 17:39       ` Joe Perches
  2021-01-31 17:53         ` Christian König
  2021-02-01 21:54       ` Lyude Paul
  1 sibling, 1 reply; 80+ messages in thread
From: Joe Perches @ 2021-01-31 17:39 UTC (permalink / raw)
  To: Christian König, Jiri Kosina, Sumit Semwal
  Cc: linux-media, dri-devel, linaro-mm-sig, linux-kernel

On Wed, 2021-02-03 at 14:26 +0100, Christian König wrote:
> Am 30.01.21 um 19:47 schrieb Joe Perches:
> > On Mon, 2020-08-24 at 21:56 -0700, Joe Perches wrote:
> > > Use semicolons and braces.
> > Ping?
> > > Signed-off-by: Joe Perches <joe@perches.com>
> Reviewed-by: Christian König <christian.koenig@amd.com>
> 
> Do you have commit rights to drm-misc-next?

No.

> > > ---
> > >   drivers/dma-buf/st-dma-fence.c | 7 +++++--
> > >   1 file changed, 5 insertions(+), 2 deletions(-)
> > > 
> > > diff --git a/drivers/dma-buf/st-dma-fence.c b/drivers/dma-buf/st-dma-fence.c
> > > index e593064341c8..c8a12d7ad71a 100644
> > > --- a/drivers/dma-buf/st-dma-fence.c
> > > +++ b/drivers/dma-buf/st-dma-fence.c
> > > @@ -471,8 +471,11 @@ static int thread_signal_callback(void *arg)
> > >   			dma_fence_signal(f1);
> > > 
> > >   		smp_store_mb(cb.seen, false);
> > > -		if (!f2 || dma_fence_add_callback(f2, &cb.cb, simple_callback))
> > > -			miss++, cb.seen = true;
> > > +		if (!f2 ||
> > > +		    dma_fence_add_callback(f2, &cb.cb, simple_callback)) {
> > > +			miss++;
> > > +			cb.seen = true;
> > > +		}
> > > 
> > >   		if (!t->before)
> > >   			dma_fence_signal(f1);
> > 
> 



^ permalink raw reply	[flat|nested] 80+ messages in thread

* Re: [PATCH 08/29] dma-buf: Avoid comma separated statements
  2021-01-31 17:39       ` Joe Perches
@ 2021-01-31 17:53         ` Christian König
  0 siblings, 0 replies; 80+ messages in thread
From: Christian König @ 2021-01-31 17:53 UTC (permalink / raw)
  To: Joe Perches, Jiri Kosina, Sumit Semwal
  Cc: linux-media, dri-devel, linaro-mm-sig, linux-kernel

Am 31.01.21 um 18:39 schrieb Joe Perches:
> On Wed, 2021-02-03 at 14:26 +0100, Christian König wrote:
>> Am 30.01.21 um 19:47 schrieb Joe Perches:
>>> On Mon, 2020-08-24 at 21:56 -0700, Joe Perches wrote:
>>>> Use semicolons and braces.
>>> Ping?
>>>> Signed-off-by: Joe Perches <joe@perches.com>
>> Reviewed-by: Christian König <christian.koenig@amd.com>
>>
>> Do you have commit rights to drm-misc-next?
> No.

Pushed.

Thanks for the help,
Christian.

>
>>>> ---
>>>>    drivers/dma-buf/st-dma-fence.c | 7 +++++--
>>>>    1 file changed, 5 insertions(+), 2 deletions(-)
>>>>
>>>> diff --git a/drivers/dma-buf/st-dma-fence.c b/drivers/dma-buf/st-dma-fence.c
>>>> index e593064341c8..c8a12d7ad71a 100644
>>>> --- a/drivers/dma-buf/st-dma-fence.c
>>>> +++ b/drivers/dma-buf/st-dma-fence.c
>>>> @@ -471,8 +471,11 @@ static int thread_signal_callback(void *arg)
>>>>    			dma_fence_signal(f1);
>>>>
>>>>    		smp_store_mb(cb.seen, false);
>>>> -		if (!f2 || dma_fence_add_callback(f2, &cb.cb, simple_callback))
>>>> -			miss++, cb.seen = true;
>>>> +		if (!f2 ||
>>>> +		    dma_fence_add_callback(f2, &cb.cb, simple_callback)) {
>>>> +			miss++;
>>>> +			cb.seen = true;
>>>> +		}
>>>>
>>>>    		if (!t->before)
>>>>    			dma_fence_signal(f1);
>


^ permalink raw reply	[flat|nested] 80+ messages in thread

* Re: [PATCH 23/29] fuse: Avoid comma separated statements
  2020-08-25  4:56 ` [PATCH 23/29] fuse: " Joe Perches
  2021-01-30 19:04   ` Joe Perches
@ 2021-02-01  8:12   ` Miklos Szeredi
  1 sibling, 0 replies; 80+ messages in thread
From: Miklos Szeredi @ 2021-02-01  8:12 UTC (permalink / raw)
  To: Joe Perches; +Cc: Jiri Kosina, linux-fsdevel, linux-kernel

On Tue, Aug 25, 2020 at 6:57 AM Joe Perches <joe@perches.com> wrote:
>
> Use semicolons and braces.

Reference to coding style doc?  Or other important reason?  Or just
personal preference?

Thanks,
Miklos

^ permalink raw reply	[flat|nested] 80+ messages in thread

* Re: [PATCH 10/29] drm/i915: Avoid comma separated statements
  2021-01-30 18:47   ` Joe Perches
@ 2021-02-01  8:41     ` Jani Nikula
  0 siblings, 0 replies; 80+ messages in thread
From: Jani Nikula @ 2021-02-01  8:41 UTC (permalink / raw)
  To: Joe Perches, Jiri Kosina, Joonas Lahtinen, Rodrigo Vivi
  Cc: David Airlie, Daniel Vetter, intel-gfx, dri-devel, linux-kernel

On Sat, 30 Jan 2021, Joe Perches <joe@perches.com> wrote:
> On Mon, 2020-08-24 at 21:56 -0700, Joe Perches wrote:
>> Use semicolons and braces.
>
> Ping?

Seems to have fallen between the cracks.

The first two hunks have been fixed, the last two are still there. Care
to respin and rebase against drm-tip (or linux-next) please?

BR,
Jani.

>
>> Signed-off-by: Joe Perches <joe@perches.com>
>> ---
>>  drivers/gpu/drm/i915/gt/gen8_ppgtt.c           | 8 +++++---
>>  drivers/gpu/drm/i915/gt/intel_gt_requests.c    | 6 ++++--
>>  drivers/gpu/drm/i915/gt/selftest_workarounds.c | 6 ++++--
>>  drivers/gpu/drm/i915/intel_runtime_pm.c        | 6 ++++--
>>  4 files changed, 17 insertions(+), 9 deletions(-)
>> 
>> diff --git a/drivers/gpu/drm/i915/gt/gen8_ppgtt.c b/drivers/gpu/drm/i915/gt/gen8_ppgtt.c
>> index 699125928272..114c13285ff1 100644
>> --- a/drivers/gpu/drm/i915/gt/gen8_ppgtt.c
>> +++ b/drivers/gpu/drm/i915/gt/gen8_ppgtt.c
>> @@ -323,10 +323,12 @@ static int __gen8_ppgtt_alloc(struct i915_address_space * const vm,
>>  			}
>>  
>> 
>>  			spin_lock(&pd->lock);
>> -			if (likely(!pd->entry[idx]))
>> +			if (likely(!pd->entry[idx])) {
>>  				set_pd_entry(pd, idx, pt);
>> -			else
>> -				alloc = pt, pt = pd->entry[idx];
>> +			} else {
>> +				alloc = pt;
>> +				pt = pd->entry[idx];
>> +			}
>>  		}
>>  
>> 
>>  		if (lvl) {
>> diff --git a/drivers/gpu/drm/i915/gt/intel_gt_requests.c b/drivers/gpu/drm/i915/gt/intel_gt_requests.c
>> index 66fcbf9d0fdd..54408d0b5e6e 100644
>> --- a/drivers/gpu/drm/i915/gt/intel_gt_requests.c
>> +++ b/drivers/gpu/drm/i915/gt/intel_gt_requests.c
>> @@ -139,8 +139,10 @@ long intel_gt_retire_requests_timeout(struct intel_gt *gt, long timeout)
>>  	LIST_HEAD(free);
>>  
>> 
>>  	interruptible = true;
>> -	if (unlikely(timeout < 0))
>> -		timeout = -timeout, interruptible = false;
>> +	if (unlikely(timeout < 0)) {
>> +		timeout = -timeout;
>> +		interruptible = false;
>> +	}
>>  
>> 
>>  	flush_submission(gt, timeout); /* kick the ksoftirqd tasklets */
>>  	spin_lock(&timelines->lock);
>> diff --git a/drivers/gpu/drm/i915/gt/selftest_workarounds.c b/drivers/gpu/drm/i915/gt/selftest_workarounds.c
>> index febc9e6692ba..3e4cbeed20bd 100644
>> --- a/drivers/gpu/drm/i915/gt/selftest_workarounds.c
>> +++ b/drivers/gpu/drm/i915/gt/selftest_workarounds.c
>> @@ -521,8 +521,10 @@ static int check_dirty_whitelist(struct intel_context *ce)
>>  
>> 
>>  		srm = MI_STORE_REGISTER_MEM;
>>  		lrm = MI_LOAD_REGISTER_MEM;
>> -		if (INTEL_GEN(engine->i915) >= 8)
>> -			lrm++, srm++;
>> +		if (INTEL_GEN(engine->i915) >= 8) {
>> +			lrm++;
>> +			srm++;
>> +		}
>>  
>> 
>>  		pr_debug("%s: Writing garbage to %x\n",
>>  			 engine->name, reg);
>> diff --git a/drivers/gpu/drm/i915/intel_runtime_pm.c b/drivers/gpu/drm/i915/intel_runtime_pm.c
>> index 153ca9e65382..f498f1c80755 100644
>> --- a/drivers/gpu/drm/i915/intel_runtime_pm.c
>> +++ b/drivers/gpu/drm/i915/intel_runtime_pm.c
>> @@ -201,8 +201,10 @@ __print_intel_runtime_pm_wakeref(struct drm_printer *p,
>>  		unsigned long rep;
>>  
>> 
>>  		rep = 1;
>> -		while (i + 1 < dbg->count && dbg->owners[i + 1] == stack)
>> -			rep++, i++;
>> +		while (i + 1 < dbg->count && dbg->owners[i + 1] == stack) {
>> +			rep++;
>> +			i++;
>> +		}
>>  		__print_depot_stack(stack, buf, PAGE_SIZE, 2);
>>  		drm_printf(p, "Wakeref x%lu taken at:\n%s", rep, buf);
>>  	}
>
>

-- 
Jani Nikula, Intel Open Source Graphics Center

^ permalink raw reply	[flat|nested] 80+ messages in thread

* Re: [PATCH 08/29] dma-buf: Avoid comma separated statements
  2021-02-03 13:26     ` Christian König
  2021-01-31 17:39       ` Joe Perches
@ 2021-02-01 21:54       ` Lyude Paul
  2021-02-02  8:33         ` [Linaro-mm-sig] " Christian König
  1 sibling, 1 reply; 80+ messages in thread
From: Lyude Paul @ 2021-02-01 21:54 UTC (permalink / raw)
  To: Christian König, Joe Perches, Jiri Kosina, Sumit Semwal
  Cc: linaro-mm-sig, linux-kernel, dri-devel, linux-media

This is entirely unrelated to this thread, but I noticed when going through dri-
devel that this email is somehow dated two days in the future from now.

On Wed, 2021-02-03 at 14:26 +0100, Christian König wrote:
> Am 30.01.21 um 19:47 schrieb Joe Perches:
> > On Mon, 2020-08-24 at 21:56 -0700, Joe Perches wrote:
> > > Use semicolons and braces.
> > Ping?
> >   
> > > Signed-off-by: Joe Perches <joe@perches.com>
> 
> Reviewed-by: Christian König <christian.koenig@amd.com>
> 
> Do you have commit rights to drm-misc-next?
> 
> > > ---
> > >   drivers/dma-buf/st-dma-fence.c | 7 +++++--
> > >   1 file changed, 5 insertions(+), 2 deletions(-)
> > > 
> > > diff --git a/drivers/dma-buf/st-dma-fence.c b/drivers/dma-buf/st-dma-
> > > fence.c
> > > index e593064341c8..c8a12d7ad71a 100644
> > > --- a/drivers/dma-buf/st-dma-fence.c
> > > +++ b/drivers/dma-buf/st-dma-fence.c
> > > @@ -471,8 +471,11 @@ static int thread_signal_callback(void *arg)
> > >                         dma_fence_signal(f1);
> > >   
> > > 
> > >                 smp_store_mb(cb.seen, false);
> > > -               if (!f2 || dma_fence_add_callback(f2, &cb.cb,
> > > simple_callback))
> > > -                       miss++, cb.seen = true;
> > > +               if (!f2 ||
> > > +                   dma_fence_add_callback(f2, &cb.cb, simple_callback)) {
> > > +                       miss++;
> > > +                       cb.seen = true;
> > > +               }
> > >   
> > > 
> > >                 if (!t->before)
> > >                         dma_fence_signal(f1);
> > 
> 
> _______________________________________________
> dri-devel mailing list
> dri-devel@lists.freedesktop.org
> https://lists.freedesktop.org/mailman/listinfo/dri-devel

-- 
Sincerely,
   Lyude Paul (she/her)
   Software Engineer at Red Hat
   
Note: I deal with a lot of emails and have a lot of bugs on my plate. If you've
asked me a question, are waiting for a review/merge on a patch, etc. and I
haven't responded in a while, please feel free to send me another email to check
on my status. I don't bite!


^ permalink raw reply	[flat|nested] 80+ messages in thread

* Re: [Linaro-mm-sig] [PATCH 08/29] dma-buf: Avoid comma separated statements
  2021-02-01 21:54       ` Lyude Paul
@ 2021-02-02  8:33         ` Christian König
  2021-02-02 18:24           ` Lyude Paul
  0 siblings, 1 reply; 80+ messages in thread
From: Christian König @ 2021-02-02  8:33 UTC (permalink / raw)
  To: lyude, Christian König, Joe Perches, Jiri Kosina, Sumit Semwal
  Cc: linaro-mm-sig, linux-kernel, dri-devel, linux-media

Yeah, known issue.

An NTP server which I don't have access to has gone bananas and 
sometimes spits out invalid time stamps.

Only thing I can do is wait for an admin to take care of this.

Christian.

Am 01.02.21 um 22:54 schrieb Lyude Paul:
> This is entirely unrelated to this thread, but I noticed when going through dri-
> devel that this email is somehow dated two days in the future from now.
>
> On Wed, 2021-02-03 at 14:26 +0100, Christian König wrote:
>> Am 30.01.21 um 19:47 schrieb Joe Perches:
>>> On Mon, 2020-08-24 at 21:56 -0700, Joe Perches wrote:
>>>> Use semicolons and braces.
>>> Ping?
>>>    
>>>> Signed-off-by: Joe Perches <joe@perches.com>
>> Reviewed-by: Christian König <christian.koenig@amd.com>
>>
>> Do you have commit rights to drm-misc-next?
>>
>>>> ---
>>>>    drivers/dma-buf/st-dma-fence.c | 7 +++++--
>>>>    1 file changed, 5 insertions(+), 2 deletions(-)
>>>>
>>>> diff --git a/drivers/dma-buf/st-dma-fence.c b/drivers/dma-buf/st-dma-
>>>> fence.c
>>>> index e593064341c8..c8a12d7ad71a 100644
>>>> --- a/drivers/dma-buf/st-dma-fence.c
>>>> +++ b/drivers/dma-buf/st-dma-fence.c
>>>> @@ -471,8 +471,11 @@ static int thread_signal_callback(void *arg)
>>>>                          dma_fence_signal(f1);
>>>>    
>>>>
>>>>                  smp_store_mb(cb.seen, false);
>>>> -               if (!f2 || dma_fence_add_callback(f2, &cb.cb,
>>>> simple_callback))
>>>> -                       miss++, cb.seen = true;
>>>> +               if (!f2 ||
>>>> +                   dma_fence_add_callback(f2, &cb.cb, simple_callback)) {
>>>> +                       miss++;
>>>> +                       cb.seen = true;
>>>> +               }
>>>>    
>>>>
>>>>                  if (!t->before)
>>>>                          dma_fence_signal(f1);
>> _______________________________________________
>> dri-devel mailing list
>> dri-devel@lists.freedesktop.org
>> https://lists.freedesktop.org/mailman/listinfo/dri-devel


^ permalink raw reply	[flat|nested] 80+ messages in thread

* Re: [Linaro-mm-sig] [PATCH 08/29] dma-buf: Avoid comma separated statements
  2021-02-02  8:33         ` [Linaro-mm-sig] " Christian König
@ 2021-02-02 18:24           ` Lyude Paul
  0 siblings, 0 replies; 80+ messages in thread
From: Lyude Paul @ 2021-02-02 18:24 UTC (permalink / raw)
  To: christian.koenig, Joe Perches, Jiri Kosina, Sumit Semwal
  Cc: linaro-mm-sig, linux-kernel, dri-devel, linux-media

On Tue, 2021-02-02 at 09:33 +0100, Christian König wrote:
> Yeah, known issue.
> 
> An NTP server which I don't have access to has gone bananas and 
> sometimes spits out invalid time stamps.
> 
> Only thing I can do is wait for an admin to take care of this.

haha it's ok! I just thought it was mildly entertaining to see, as my email
client formatted the message timestamp "Next Wednesday" :)

> 
> Christian.
> 
> Am 01.02.21 um 22:54 schrieb Lyude Paul:
> > This is entirely unrelated to this thread, but I noticed when going through
> > dri-
> > devel that this email is somehow dated two days in the future from now.
> > 
> > On Wed, 2021-02-03 at 14:26 +0100, Christian König wrote:
> > > Am 30.01.21 um 19:47 schrieb Joe Perches:
> > > > On Mon, 2020-08-24 at 21:56 -0700, Joe Perches wrote:
> > > > > Use semicolons and braces.
> > > > Ping?
> > > >    
> > > > > Signed-off-by: Joe Perches <joe@perches.com>
> > > Reviewed-by: Christian König <christian.koenig@amd.com>
> > > 
> > > Do you have commit rights to drm-misc-next?
> > > 
> > > > > ---
> > > > >    drivers/dma-buf/st-dma-fence.c | 7 +++++--
> > > > >    1 file changed, 5 insertions(+), 2 deletions(-)
> > > > > 
> > > > > diff --git a/drivers/dma-buf/st-dma-fence.c b/drivers/dma-buf/st-dma-
> > > > > fence.c
> > > > > index e593064341c8..c8a12d7ad71a 100644
> > > > > --- a/drivers/dma-buf/st-dma-fence.c
> > > > > +++ b/drivers/dma-buf/st-dma-fence.c
> > > > > @@ -471,8 +471,11 @@ static int thread_signal_callback(void *arg)
> > > > >                          dma_fence_signal(f1);
> > > > >    
> > > > > 
> > > > >                  smp_store_mb(cb.seen, false);
> > > > > -               if (!f2 || dma_fence_add_callback(f2, &cb.cb,
> > > > > simple_callback))
> > > > > -                       miss++, cb.seen = true;
> > > > > +               if (!f2 ||
> > > > > +                   dma_fence_add_callback(f2, &cb.cb,
> > > > > simple_callback)) {
> > > > > +                       miss++;
> > > > > +                       cb.seen = true;
> > > > > +               }
> > > > >    
> > > > > 
> > > > >                  if (!t->before)
> > > > >                          dma_fence_signal(f1);
> > > _______________________________________________
> > > dri-devel mailing list
> > > dri-devel@lists.freedesktop.org
> > > https://lists.freedesktop.org/mailman/listinfo/dri-devel
> 

-- 
Sincerely,
   Lyude Paul (she/her)
   Software Engineer at Red Hat
   
Note: I deal with a lot of emails and have a lot of bugs on my plate. If you've
asked me a question, are waiting for a review/merge on a patch, etc. and I
haven't responded in a while, please feel free to send me another email to check
on my status. I don't bite!


^ permalink raw reply	[flat|nested] 80+ messages in thread

* Re: [PATCH 08/29] dma-buf: Avoid comma separated statements
  2021-01-30 18:47   ` Joe Perches
@ 2021-02-03 13:26     ` Christian König
  2021-01-31 17:39       ` Joe Perches
  2021-02-01 21:54       ` Lyude Paul
  0 siblings, 2 replies; 80+ messages in thread
From: Christian König @ 2021-02-03 13:26 UTC (permalink / raw)
  To: Joe Perches, Jiri Kosina, Sumit Semwal
  Cc: linux-media, dri-devel, linaro-mm-sig, linux-kernel

Am 30.01.21 um 19:47 schrieb Joe Perches:
> On Mon, 2020-08-24 at 21:56 -0700, Joe Perches wrote:
>> Use semicolons and braces.
> Ping?
>   
>> Signed-off-by: Joe Perches <joe@perches.com>

Reviewed-by: Christian König <christian.koenig@amd.com>

Do you have commit rights to drm-misc-next?

>> ---
>>   drivers/dma-buf/st-dma-fence.c | 7 +++++--
>>   1 file changed, 5 insertions(+), 2 deletions(-)
>>
>> diff --git a/drivers/dma-buf/st-dma-fence.c b/drivers/dma-buf/st-dma-fence.c
>> index e593064341c8..c8a12d7ad71a 100644
>> --- a/drivers/dma-buf/st-dma-fence.c
>> +++ b/drivers/dma-buf/st-dma-fence.c
>> @@ -471,8 +471,11 @@ static int thread_signal_callback(void *arg)
>>   			dma_fence_signal(f1);
>>   
>>
>>   		smp_store_mb(cb.seen, false);
>> -		if (!f2 || dma_fence_add_callback(f2, &cb.cb, simple_callback))
>> -			miss++, cb.seen = true;
>> +		if (!f2 ||
>> +		    dma_fence_add_callback(f2, &cb.cb, simple_callback)) {
>> +			miss++;
>> +			cb.seen = true;
>> +		}
>>   
>>
>>   		if (!t->before)
>>   			dma_fence_signal(f1);
>


^ permalink raw reply	[flat|nested] 80+ messages in thread

* Re: [PATCH 01/29] coding-style.rst: Avoid comma statements
  2021-01-30 18:53   ` Joe Perches
@ 2021-02-04 21:41     ` Jonathan Corbet
  0 siblings, 0 replies; 80+ messages in thread
From: Jonathan Corbet @ 2021-02-04 21:41 UTC (permalink / raw)
  To: Joe Perches, Jiri Kosina, linux-kernel; +Cc: linux-doc

Joe Perches <joe@perches.com> writes:

> On Mon, 2020-08-24 at 21:55 -0700, Joe Perches wrote:
>> Commas are not how statements are terminated.
>> Always use semicolons and braces if necessary.
>
> ping?

Hey, it's only been five months and some...you gotta stop rushing
maintainers this way :)

I guess at the time I assumed that somebody would take care of the
29-part set as a whole.  I've now applied this piece, thanks.

jon

^ permalink raw reply	[flat|nested] 80+ messages in thread

* Re: [PATCH 02/29] alpha: Avoid comma separated statements
  2021-01-30 18:54   ` Joe Perches
@ 2021-02-16 14:39     ` Robert Richter
  2021-02-16 15:10       ` Joe Perches
  0 siblings, 1 reply; 80+ messages in thread
From: Robert Richter @ 2021-02-16 14:39 UTC (permalink / raw)
  To: Joe Perches
  Cc: Jiri Kosina, Richard Henderson, Ivan Kokshaysky, Matt Turner,
	linux-alpha, linux-kernel, oprofile-list

On 30.01.21 10:54:42, Joe Perches wrote:
> On Mon, 2020-08-24 at 21:55 -0700, Joe Perches wrote:
> > Use semicolons and braces.
> 
> ping?
> 
> > 
> > Signed-off-by: Joe Perches <joe@perches.com>
> > ---
> >  arch/alpha/kernel/pci_iommu.c      |  8 +++++---
> >  arch/alpha/oprofile/op_model_ev4.c | 22 ++++++++++++++--------
> >  arch/alpha/oprofile/op_model_ev5.c |  8 +++++---

This patch should be rebased as oprofile is going to be removed in
5.12. A branch is in linux-next.

-Robert

> >  3 files changed, 24 insertions(+), 14 deletions(-)

^ permalink raw reply	[flat|nested] 80+ messages in thread

* Re: [PATCH 02/29] alpha: Avoid comma separated statements
  2021-02-16 14:39     ` Robert Richter
@ 2021-02-16 15:10       ` Joe Perches
  0 siblings, 0 replies; 80+ messages in thread
From: Joe Perches @ 2021-02-16 15:10 UTC (permalink / raw)
  To: Robert Richter
  Cc: Jiri Kosina, Richard Henderson, Ivan Kokshaysky, Matt Turner,
	linux-alpha, linux-kernel, oprofile-list

On Tue, 2021-02-16 at 15:39 +0100, Robert Richter wrote:
> On 30.01.21 10:54:42, Joe Perches wrote:
> > On Mon, 2020-08-24 at 21:55 -0700, Joe Perches wrote:
> > > Use semicolons and braces.
> > 
> > ping?
> > 
> > > 
> > > Signed-off-by: Joe Perches <joe@perches.com>
> > > ---
> > >  arch/alpha/kernel/pci_iommu.c      |  8 +++++---
> > >  arch/alpha/oprofile/op_model_ev4.c | 22 ++++++++++++++--------
> > >  arch/alpha/oprofile/op_model_ev5.c |  8 +++++---
> 
> This patch should be rebased as oprofile is going to be removed in
> 5.12. A branch is in linux-next.

git am --include=arch/alpha/kernel/pci_iommu.c


^ permalink raw reply	[flat|nested] 80+ messages in thread

end of thread, other threads:[~2021-02-16 15:11 UTC | newest]

Thread overview: 80+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-08-25  4:55 [PATCH 00/29] treewide: Convert comma separated statements Joe Perches
2020-08-25  4:55 ` [PATCH 01/29] coding-style.rst: Avoid comma statements Joe Perches
2021-01-30 18:53   ` Joe Perches
2021-02-04 21:41     ` Jonathan Corbet
2020-08-25  4:55 ` [PATCH 02/29] alpha: Avoid comma separated statements Joe Perches
2020-08-25  6:37   ` Robert Richter
2021-01-30 18:54   ` Joe Perches
2021-02-16 14:39     ` Robert Richter
2021-02-16 15:10       ` Joe Perches
2020-08-25  4:56 ` [PATCH 03/29] ia64: " Joe Perches
2021-01-30 18:55   ` Joe Perches
2020-08-25  4:56 ` [PATCH 04/29] sparc: " Joe Perches
2021-01-30 18:56   ` Joe Perches
2020-08-25  4:56 ` [PATCH 05/29] ata: " Joe Perches
2021-01-30 18:56   ` Joe Perches
2021-01-31 15:06     ` Jens Axboe
2020-08-25  4:56 ` [PATCH 06/29] drbd: " Joe Perches
2021-01-30 18:57   ` Joe Perches
2021-01-31 15:06     ` Jens Axboe
2020-08-25  4:56 ` [PATCH 07/29] lp: " Joe Perches
2020-08-25  4:56 ` [PATCH 08/29] dma-buf: " Joe Perches
2020-08-26 15:08   ` Christian König
2020-09-03 12:21     ` Sumit Semwal
2020-09-04 11:42   ` Kieran Bingham
2020-09-04 21:33     ` Joe Perches
2021-01-30 18:47   ` Joe Perches
2021-02-03 13:26     ` Christian König
2021-01-31 17:39       ` Joe Perches
2021-01-31 17:53         ` Christian König
2021-02-01 21:54       ` Lyude Paul
2021-02-02  8:33         ` [Linaro-mm-sig] " Christian König
2021-02-02 18:24           ` Lyude Paul
2020-08-25  4:56 ` [PATCH 09/29] drm/gma500: " Joe Perches
2021-01-30 18:47   ` Joe Perches
2021-01-30 21:21     ` Patrik Jakobsson
2020-08-25  4:56 ` [PATCH 10/29] drm/i915: " Joe Perches
2021-01-30 18:47   ` Joe Perches
2021-02-01  8:41     ` Jani Nikula
2020-08-25  4:56 ` [PATCH 11/29] hwmon: (scmi-hwmon): " Joe Perches
2020-08-25 23:33   ` Guenter Roeck
2020-08-25  4:56 ` [PATCH 12/29] Input: MT - " Joe Perches
2020-08-25 17:07   ` Dmitry Torokhov
2020-08-25  4:56 ` [PATCH 13/29] bcache: " Joe Perches
2021-01-30 18:59   ` Joe Perches
2021-01-31 15:58     ` Coly Li
2020-08-25  4:56 ` [PATCH 14/29] media: " Joe Perches
2020-09-04 11:45   ` Kieran Bingham
2020-08-25  4:56 ` [PATCH 15/29] mtd: " Joe Perches
2020-09-07  7:34   ` Miquel Raynal
2020-08-25  4:56 ` [PATCH 16/29] 8390: " Joe Perches
2020-08-25 14:54   ` David Miller
2020-08-25  4:56 ` [PATCH 17/29] fs_enet: " Joe Perches
2020-08-25 14:55   ` David Miller
2020-08-25  4:56 ` [PATCH 18/29] wan: sbni: " Joe Perches
2020-08-25 14:55   ` David Miller
2020-08-25  4:56 ` [PATCH 19/29] s390/tty3270: " Joe Perches
2021-01-30 19:01   ` Joe Perches
2020-08-25  4:56 ` [PATCH 20/29] scai/arm: " Joe Perches
2020-08-25  4:56 ` [PATCH 21/29] media: atomisp: " Joe Perches
2020-09-04 11:46   ` Kieran Bingham
2020-08-25  4:56 ` [PATCH 22/29] video: fbdev: " Joe Perches
2020-09-08 11:37   ` Bartlomiej Zolnierkiewicz
2020-08-25  4:56 ` [PATCH 23/29] fuse: " Joe Perches
2021-01-30 19:04   ` Joe Perches
2021-02-01  8:12   ` Miklos Szeredi
2020-08-25  4:56 ` [PATCH 24/29] reiserfs: " Joe Perches
2021-01-30 19:04   ` Joe Perches
2020-08-25  4:56 ` [PATCH 25/29] lib/zlib: " Joe Perches
2021-01-30 19:05   ` Joe Perches
2020-08-25  4:56 ` [PATCH 26/29] lib: zstd: " Joe Perches
2021-01-30 19:06   ` Joe Perches
2020-08-25  4:56 ` [PATCH 27/29] ipv6: fib6: " Joe Perches
2020-08-25 14:55   ` David Miller
2020-08-25  4:56 ` [PATCH 28/29] sunrpc: " Joe Perches
2020-08-25 14:55   ` David Miller
2020-08-25  4:56 ` [PATCH 29/29] tools: " Joe Perches
2020-08-26  9:30   ` Thomas Renninger
2020-08-26 14:45     ` Joe Perches
2020-08-26 16:13       ` Thomas Renninger
2020-09-09  2:09 ` [PATCH 00/29] treewide: Convert " Martin K. Petersen

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).