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


Groups > linux.kernel > #1308842

[PATCH v6 08/15] tty: serial: 8250: Add parentheses to macro

From Anton Wuerfel <anton.wuerfel@fau.de>
Newsgroups linux.kernel
Subject [PATCH v6 08/15] tty: serial: 8250: Add parentheses to macro
Date 2016-01-13 22:40 +0100
Message-ID <qQBj6-5yt-51@gated-at.bofh.it> (permalink)
References <qQBj4-5yt-5@gated-at.bofh.it>
Organization linux.* mail to news gateway

Show all headers | View raw


This patch fixes a checkpatch warning caused by missing parentheses
in the definition of a macro.
Furthermore redundant parentheses are removed in an assignment.

Signed-off-by: Anton Würfel <anton.wuerfel@fau.de>
Signed-off-by: Phillip Raffeck <phillip.raffeck@fau.de>
Cc: linux-kernel@i4.cs.fau.de
---
 drivers/tty/serial/8250/8250_core.c | 2 +-
 drivers/tty/serial/8250/8250_pci.c  | 2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/drivers/tty/serial/8250/8250_core.c b/drivers/tty/serial/8250/8250_core.c
index 15082ae..d042ad5 100644
--- a/drivers/tty/serial/8250/8250_core.c
+++ b/drivers/tty/serial/8250/8250_core.c
@@ -686,7 +686,7 @@ static int __init univ8250_console_init(void)
 }
 console_initcall(univ8250_console_init);
 
-#define SERIAL8250_CONSOLE	&univ8250_console
+#define SERIAL8250_CONSOLE	(&univ8250_console)
 #else
 #define SERIAL8250_CONSOLE	NULL
 #endif
diff --git a/drivers/tty/serial/8250/8250_pci.c b/drivers/tty/serial/8250/8250_pci.c
index 8543719..fbd4222 100644
--- a/drivers/tty/serial/8250/8250_pci.c
+++ b/drivers/tty/serial/8250/8250_pci.c
@@ -803,7 +803,7 @@ static int pci_netmos_9900_numports(struct pci_dev *dev)
 	unsigned int pi;
 	unsigned short sub_serports;
 
-	pi = (c & 0xff);
+	pi = c & 0xff;
 
 	if (pi == 2)
 		return 1;
-- 
1.9.1

Back to linux.kernel | Previous | NextPrevious in thread | Next in thread | Find similar | Unroll thread


Thread

[PATCH v6 00/15] tty: serial: 8250: Fix checkpatch warnings Anton Wuerfel <anton.wuerfel@fau.de> - 2016-01-13 22:40 +0100
  [PATCH v6 14/15] tty: serial: 8250: Fix indentation warnings Anton Wuerfel <anton.wuerfel@fau.de> - 2016-01-13 22:40 +0100
  [PATCH v6 02/15] tty: serial: 8250: Replace spaces with tabs Anton Wuerfel <anton.wuerfel@fau.de> - 2016-01-13 22:40 +0100
  [PATCH v6 13/15] tty: serial: 8250: Merge duplicate conditions Anton Wuerfel <anton.wuerfel@fau.de> - 2016-01-13 22:40 +0100
  [PATCH v6 08/15] tty: serial: 8250: Add parentheses to macro Anton Wuerfel <anton.wuerfel@fau.de> - 2016-01-13 22:40 +0100
  Re: [PATCH v6 00/15] tty: serial: 8250: Fix checkpatch warnings Andy Shevchenko <andriy.shevchenko@linux.intel.com> - 2016-01-14 10:20 +0100

csiph-web