Thread (8 messages) 8 messages, 2 authors, 2021-05-21

[PATCH net-next 5/6] net: wan: add braces {} to all arms of the statement

flat view
STALE1973d

From: Guangbin Huang <hidden>
Date: 2021-05-21 01:11:31
Also in: lkml
Subsystem: generic hdlc (wan) drivers, networking drivers, the rest · Maintainers: Krzysztof Halasa, Andrew Lunn, "David S. Miller", Eric Dumazet, Jakub Kicinski, Paolo Abeni, Linus Torvalds

Revision v1 of 5 in this series.

Revisions (5)
  1. v1
  2. v1 current
  3. v1
  4. v1
  5. v1
From: Peng Li <redacted>

Braces {} should be used on all arms of this statement.

Signed-off-by: Peng Li <redacted>
Signed-off-by: Guangbin Huang <redacted>
---
 drivers/net/wan/hd64572.c | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/drivers/net/wan/hd64572.c b/drivers/net/wan/hd64572.c
index 34acea93efdf..7fccf23c8bef 100644
--- a/drivers/net/wan/hd64572.c
+++ b/drivers/net/wan/hd64572.c
@@ -374,8 +374,9 @@ static void sca_set_port(port_t *port)
 			tmc = 1;
 			br = 0;	/* For baud=CLOCK_BASE we use tmc=1 br=0 */
 			brv = 1;
-		} else if (tmc > 255)
+		} else if (tmc > 255) {
 			tmc = 256; /* tmc=0 means 256 - low baud rates */
+		}
 
 		port->settings.clock_rate = CLOCK_BASE / brv / tmc;
 	} else {
-- 
2.8.1
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help