All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH 00/11] tty: serial: 8250: Fix checkpatch warnings
@ 2015-12-16 15:36 ` Anton Wuerfel
  0 siblings, 0 replies; 60+ messages in thread
From: Anton Wuerfel @ 2015-12-16 15:36 UTC (permalink / raw)
  To: linux-serial
  Cc: Greg Kroah-Hartman, Jiri Slaby, James E.J. Bottomley,
	Helge Deller, Peter Hurley, Heikki Krogerus, Andy Shevchenko,
	Qipeng Zha, Desmond Liu, Wang Long, Matt Redfearn, Paul Burton,
	Ralf Baechle, Krzysztof Kozlowski, Peter Hung, Soeren Grunewald,
	Adam Lee, Maciej S. Szmigiero, Mans Rullgard, linux-kernel,
	linux-parisc, linux-kernel, Anton Wuerfel

This patch set fixes several checkpatch warnings in tty/serial/8250.

Patch 1/11:  Adds missing spaces (mainly to function/macro headers)
Patch 2/11:  Fixes code indentation
Patch 3/11:  Slight patch which moves an opening curly brace
Patch 4/11:  Fixes multiline comment style
Patch 5/11:  Removes else blocks after return statements
Patch 6/11:  Slight patch which moves EXPORT_SYMBOL macro to correct position
Patch 7/11:  Slight patch which removes an unneccessary line continuation
Patch 8/11:  Slight patch which adds parentheses to a macro definition
Patch 9/11:  Merges user-visible multiline strings to a single line
Patch 10/11: Replaces printk by corresponding variant of pr_*
Patch 11/11: Removes code which has been commented out

Remaining checkpatch warnings after applying this patch series:

-line over 80 characters
	This error mostly occurs in serial_cs.c, which contains long-lined
	macro calls. However, splitting these calls into multiple lines would
	not increase readability.

-externs should be avoided in .c files
	This occurs in 8250_hp300.c. There is no corresponding header file
	the extern statement could be moved to. It could be moved to 8250.h
	but this would affect other .c files.

-Use #include <linux/*.h> instead of <asm/*.h>
	This warning has been left open for more experienced kernel hackers.
	This patch series is about style issues. We do not intend to alter
	the code behavior.

-struct uart_ops should normally be const
	This warning only occurs in 8250_core.c. The corresponding struct
	cannot be declared as const because it is altered in
	serial8250_isa_init_ports(). Maybe a checkpatch exception should
	be added for this particular warning.

-quoted string split across lines
	These strings were ignored because they otherwise would exceed
	80 characters in a single line. These particular strings use
	format specifiers, which break the ability to grep for them anyway.

Anton Wuerfel (11):
Phillip Raffeck (11):
  tty: serial: 8250: Fix whitespace errors
  tty: serial: 8250: Fix indentation warnings
  tty: serial: 8250: Fix braces after struct
  tty: serial: 8250: Fix multiline comment style
  tty: serial: 8250: Remove else after return
  tty: serial: 8250: Move EXPORT_SYMBOL to function
  tty: serial: 8250: Fix line continuation warning
  tty: serial: 8250: Add parentheses to macro
  tty: serial: 8250: Fix multi-line strings
  tty: serial: 8250: Replace printk by pr_*
  tty: serial: 8250: Delete commented code

 drivers/tty/serial/8250/8250_accent.c        |   2 +-
 drivers/tty/serial/8250/8250_acorn.c         |   2 +-
 drivers/tty/serial/8250/8250_boca.c          |   2 +-
 drivers/tty/serial/8250/8250_core.c          |  16 ++-
 drivers/tty/serial/8250/8250_dw.c            |   6 ++
 drivers/tty/serial/8250/8250_exar_st16c554.c |   2 +-
 drivers/tty/serial/8250/8250_fourport.c      |   2 +-
 drivers/tty/serial/8250/8250_gsc.c           |   6 +-
 drivers/tty/serial/8250/8250_hp300.c         |  22 ++--
 drivers/tty/serial/8250/8250_hub6.c          |   2 +-
 drivers/tty/serial/8250/8250_ingenic.c       |   6 +-
 drivers/tty/serial/8250/8250_pci.c           |  60 +++++------
 drivers/tty/serial/8250/8250_pnp.c           |  16 +--
 drivers/tty/serial/8250/8250_port.c          |  49 +++++----
 drivers/tty/serial/8250/serial_cs.c          | 153 ++++++++++++++-------------
 15 files changed, 181 insertions(+), 165 deletions(-)

-- 
1.9.1

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

* [PATCH 00/11] tty: serial: 8250: Fix checkpatch warnings
@ 2015-12-16 15:36 ` Anton Wuerfel
  0 siblings, 0 replies; 60+ messages in thread
From: Anton Wuerfel @ 2015-12-16 15:36 UTC (permalink / raw)
  To: linux-serial
  Cc: Greg Kroah-Hartman, Jiri Slaby, James E.J. Bottomley,
	Helge Deller, Peter Hurley, Heikki Krogerus, Andy Shevchenko,
	Qipeng Zha, Desmond Liu, Wang Long, Matt Redfearn, Paul Burton,
	Ralf Baechle, Krzysztof Kozlowski, Peter Hung, Soeren Grunewald,
	Adam Lee, Maciej S. Szmigiero, Mans Rullgard, linux-kernel,
	linux-parisc, linux-kernel, Anton Wuerfel, phillip.raffeck

This patch set fixes several checkpatch warnings in tty/serial/8250.

Patch 1/11:  Adds missing spaces (mainly to function/macro headers)
Patch 2/11:  Fixes code indentation
Patch 3/11:  Slight patch which moves an opening curly brace
Patch 4/11:  Fixes multiline comment style
Patch 5/11:  Removes else blocks after return statements
Patch 6/11:  Slight patch which moves EXPORT_SYMBOL macro to correct position
Patch 7/11:  Slight patch which removes an unneccessary line continuation
Patch 8/11:  Slight patch which adds parentheses to a macro definition
Patch 9/11:  Merges user-visible multiline strings to a single line
Patch 10/11: Replaces printk by corresponding variant of pr_*
Patch 11/11: Removes code which has been commented out

Remaining checkpatch warnings after applying this patch series:

-line over 80 characters
	This error mostly occurs in serial_cs.c, which contains long-lined
	macro calls. However, splitting these calls into multiple lines would
	not increase readability.

-externs should be avoided in .c files
	This occurs in 8250_hp300.c. There is no corresponding header file
	the extern statement could be moved to. It could be moved to 8250.h
	but this would affect other .c files.

-Use #include <linux/*.h> instead of <asm/*.h>
	This warning has been left open for more experienced kernel hackers.
	This patch series is about style issues. We do not intend to alter
	the code behavior.

-struct uart_ops should normally be const
	This warning only occurs in 8250_core.c. The corresponding struct
	cannot be declared as const because it is altered in
	serial8250_isa_init_ports(). Maybe a checkpatch exception should
	be added for this particular warning.

-quoted string split across lines
	These strings were ignored because they otherwise would exceed
	80 characters in a single line. These particular strings use
	format specifiers, which break the ability to grep for them anyway.

Anton Wuerfel (11):
Phillip Raffeck (11):
  tty: serial: 8250: Fix whitespace errors
  tty: serial: 8250: Fix indentation warnings
  tty: serial: 8250: Fix braces after struct
  tty: serial: 8250: Fix multiline comment style
  tty: serial: 8250: Remove else after return
  tty: serial: 8250: Move EXPORT_SYMBOL to function
  tty: serial: 8250: Fix line continuation warning
  tty: serial: 8250: Add parentheses to macro
  tty: serial: 8250: Fix multi-line strings
  tty: serial: 8250: Replace printk by pr_*
  tty: serial: 8250: Delete commented code

 drivers/tty/serial/8250/8250_accent.c        |   2 +-
 drivers/tty/serial/8250/8250_acorn.c         |   2 +-
 drivers/tty/serial/8250/8250_boca.c          |   2 +-
 drivers/tty/serial/8250/8250_core.c          |  16 ++-
 drivers/tty/serial/8250/8250_dw.c            |   6 ++
 drivers/tty/serial/8250/8250_exar_st16c554.c |   2 +-
 drivers/tty/serial/8250/8250_fourport.c      |   2 +-
 drivers/tty/serial/8250/8250_gsc.c           |   6 +-
 drivers/tty/serial/8250/8250_hp300.c         |  22 ++--
 drivers/tty/serial/8250/8250_hub6.c          |   2 +-
 drivers/tty/serial/8250/8250_ingenic.c       |   6 +-
 drivers/tty/serial/8250/8250_pci.c           |  60 +++++------
 drivers/tty/serial/8250/8250_pnp.c           |  16 +--
 drivers/tty/serial/8250/8250_port.c          |  49 +++++----
 drivers/tty/serial/8250/serial_cs.c          | 153 ++++++++++++++-------------
 15 files changed, 181 insertions(+), 165 deletions(-)

-- 
1.9.1

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

* [PATCH 00/11] tty: serial: 8250: Fix checkpatch warnings
@ 2015-12-16 15:36 ` Anton Wuerfel
  0 siblings, 0 replies; 60+ messages in thread
From: Anton Wuerfel @ 2015-12-16 15:36 UTC (permalink / raw)
  To: linux-serial
  Cc: Greg Kroah-Hartman, Jiri Slaby, James E.J. Bottomley,
	Helge Deller, Peter Hurley, Heikki Krogerus, Andy Shevchenko,
	Qipeng Zha, Desmond Liu, Wang Long, Matt Redfearn, Paul Burton,
	Ralf Baechle, Krzysztof Kozlowski, Peter Hung, Soeren Grunewald,
	Adam Lee, Maciej S. Szmigiero, Mans Rullgard, linux-kernel,
	linux-parisc, linux-kernel, Anton Wuerfel

This patch set fixes several checkpatch warnings in tty/serial/8250.

Patch 1/11:  Adds missing spaces (mainly to function/macro headers)
Patch 2/11:  Fixes code indentation
Patch 3/11:  Slight patch which moves an opening curly brace
Patch 4/11:  Fixes multiline comment style
Patch 5/11:  Removes else blocks after return statements
Patch 6/11:  Slight patch which moves EXPORT_SYMBOL macro to correct position
Patch 7/11:  Slight patch which removes an unneccessary line continuation
Patch 8/11:  Slight patch which adds parentheses to a macro definition
Patch 9/11:  Merges user-visible multiline strings to a single line
Patch 10/11: Replaces printk by corresponding variant of pr_*
Patch 11/11: Removes code which has been commented out

Remaining checkpatch warnings after applying this patch series:

-line over 80 characters
	This error mostly occurs in serial_cs.c, which contains long-lined
	macro calls. However, splitting these calls into multiple lines would
	not increase readability.

-externs should be avoided in .c files
	This occurs in 8250_hp300.c. There is no corresponding header file
	the extern statement could be moved to. It could be moved to 8250.h
	but this would affect other .c files.

-Use #include <linux/*.h> instead of <asm/*.h>
	This warning has been left open for more experienced kernel hackers.
	This patch series is about style issues. We do not intend to alter
	the code behavior.

-struct uart_ops should normally be const
	This warning only occurs in 8250_core.c. The corresponding struct
	cannot be declared as const because it is altered in
	serial8250_isa_init_ports(). Maybe a checkpatch exception should
	be added for this particular warning.

-quoted string split across lines
	These strings were ignored because they otherwise would exceed
	80 characters in a single line. These particular strings use
	format specifiers, which break the ability to grep for them anyway.

Anton Wuerfel (11):
Phillip Raffeck (11):
  tty: serial: 8250: Fix whitespace errors
  tty: serial: 8250: Fix indentation warnings
  tty: serial: 8250: Fix braces after struct
  tty: serial: 8250: Fix multiline comment style
  tty: serial: 8250: Remove else after return
  tty: serial: 8250: Move EXPORT_SYMBOL to function
  tty: serial: 8250: Fix line continuation warning
  tty: serial: 8250: Add parentheses to macro
  tty: serial: 8250: Fix multi-line strings
  tty: serial: 8250: Replace printk by pr_*
  tty: serial: 8250: Delete commented code

 drivers/tty/serial/8250/8250_accent.c        |   2 +-
 drivers/tty/serial/8250/8250_acorn.c         |   2 +-
 drivers/tty/serial/8250/8250_boca.c          |   2 +-
 drivers/tty/serial/8250/8250_core.c          |  16 ++-
 drivers/tty/serial/8250/8250_dw.c            |   6 ++
 drivers/tty/serial/8250/8250_exar_st16c554.c |   2 +-
 drivers/tty/serial/8250/8250_fourport.c      |   2 +-
 drivers/tty/serial/8250/8250_gsc.c           |   6 +-
 drivers/tty/serial/8250/8250_hp300.c         |  22 ++--
 drivers/tty/serial/8250/8250_hub6.c          |   2 +-
 drivers/tty/serial/8250/8250_ingenic.c       |   6 +-
 drivers/tty/serial/8250/8250_pci.c           |  60 +++++------
 drivers/tty/serial/8250/8250_pnp.c           |  16 +--
 drivers/tty/serial/8250/8250_port.c          |  49 +++++----
 drivers/tty/serial/8250/serial_cs.c          | 153 ++++++++++++++-------------
 15 files changed, 181 insertions(+), 165 deletions(-)

-- 
1.9.1

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

* [PATCH 01/11] tty: serial: 8250: Fix whitespace errors
  2015-12-16 15:36 ` Anton Wuerfel
  (?)
@ 2015-12-16 15:36   ` Anton Wuerfel
  -1 siblings, 0 replies; 60+ messages in thread
From: Anton Wuerfel @ 2015-12-16 15:36 UTC (permalink / raw)
  To: linux-serial
  Cc: Greg Kroah-Hartman, Jiri Slaby, James E.J. Bottomley,
	Helge Deller, Peter Hurley, Heikki Krogerus, Andy Shevchenko,
	Qipeng Zha, Desmond Liu, Wang Long, Matt Redfearn, Paul Burton,
	Ralf Baechle, Krzysztof Kozlowski, Peter Hung, Soeren Grunewald,
	Adam Lee, Maciej S. Szmigiero, Mans Rullgard, linux-kernel,
	linux-parisc, linux-kernel, Anton Wuerfel

This patch fixes whitespace errors reported by checkpatch to increase
readability. Main focus is on missing spaces after commas in
function headers and macros (like foo,bar edited to foo, bar).

Signed-off-by: Anton W=C3=BCrfel <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_accent.c        |  2 +-
 drivers/tty/serial/8250/8250_acorn.c         |  2 +-
 drivers/tty/serial/8250/8250_boca.c          |  2 +-
 drivers/tty/serial/8250/8250_core.c          |  1 +
 drivers/tty/serial/8250/8250_dw.c            |  6 +++
 drivers/tty/serial/8250/8250_exar_st16c554.c |  2 +-
 drivers/tty/serial/8250/8250_fourport.c      |  2 +-
 drivers/tty/serial/8250/8250_hp300.c         |  1 +
 drivers/tty/serial/8250/8250_hub6.c          |  2 +-
 drivers/tty/serial/8250/8250_pci.c           |  7 +++-
 drivers/tty/serial/8250/8250_port.c          |  3 ++
 drivers/tty/serial/8250/serial_cs.c          | 58 ++++++++++++++------=
--------
 12 files changed, 52 insertions(+), 36 deletions(-)

diff --git a/drivers/tty/serial/8250/8250_accent.c b/drivers/tty/serial=
/8250/8250_accent.c
index 34b51c6..c480729 100644
--- a/drivers/tty/serial/8250/8250_accent.c
+++ b/drivers/tty/serial/8250/8250_accent.c
@@ -10,7 +10,7 @@
 #include <linux/init.h>
 #include <linux/serial_8250.h>
=20
-#define PORT(_base,_irq)				\
+#define PORT(_base, _irq)				\
 	{						\
 		.iobase		=3D _base,		\
 		.irq		=3D _irq,			\
diff --git a/drivers/tty/serial/8250/8250_acorn.c b/drivers/tty/serial/=
8250/8250_acorn.c
index 549aa07..402dfdd 100644
--- a/drivers/tty/serial/8250/8250_acorn.c
+++ b/drivers/tty/serial/8250/8250_acorn.c
@@ -70,7 +70,7 @@ serial_card_probe(struct expansion_card *ec, const st=
ruct ecard_id *id)
 	uart.port.regshift	=3D 2;
 	uart.port.dev	=3D &ec->dev;
=20
-	for (i =3D 0; i < info->num_ports; i ++) {
+	for (i =3D 0; i < info->num_ports; i++) {
 		uart.port.membase =3D info->vaddr + type->offset[i];
 		uart.port.mapbase =3D bus_addr + type->offset[i];
=20
diff --git a/drivers/tty/serial/8250/8250_boca.c b/drivers/tty/serial/8=
250/8250_boca.c
index d125dc1..e42a5b5 100644
--- a/drivers/tty/serial/8250/8250_boca.c
+++ b/drivers/tty/serial/8250/8250_boca.c
@@ -10,7 +10,7 @@
 #include <linux/init.h>
 #include <linux/serial_8250.h>
=20
-#define PORT(_base,_irq)				\
+#define PORT(_base, _irq)				\
 	{						\
 		.iobase		=3D _base,		\
 		.irq		=3D _irq,			\
diff --git a/drivers/tty/serial/8250/8250_core.c b/drivers/tty/serial/8=
250/8250_core.c
index 3912646..89a20c9 100644
--- a/drivers/tty/serial/8250/8250_core.c
+++ b/drivers/tty/serial/8250/8250_core.c
@@ -756,6 +756,7 @@ void serial8250_suspend_port(int line)
 	if (!console_suspend_enabled && uart_console(port) &&
 	    port->type !=3D PORT_8250) {
 		unsigned char canary =3D 0xa5;
+
 		serial_out(up, UART_SCR, canary);
 		if (serial_in(up, UART_SCR) =3D=3D canary)
 			up->canary =3D canary;
diff --git a/drivers/tty/serial/8250/8250_dw.c b/drivers/tty/serial/825=
0/8250_dw.c
index a5d319e..0f67355 100644
--- a/drivers/tty/serial/8250/8250_dw.c
+++ b/drivers/tty/serial/8250/8250_dw.c
@@ -102,8 +102,10 @@ static void dw8250_serial_out(struct uart_port *p,=
 int offset, int value)
 	/* Make sure LCR write wasn't ignored */
 	if (offset =3D=3D UART_LCR) {
 		int tries =3D 1000;
+
 		while (tries--) {
 			unsigned int lcr =3D p->serial_in(p, UART_LCR);
+
 			if ((value & ~UART_LCR_SPAR) =3D=3D (lcr & ~UART_LCR_SPAR))
 				return;
 			dw8250_force_idle(p);
@@ -143,8 +145,10 @@ static void dw8250_serial_outq(struct uart_port *p=
, int offset, int value)
 	/* Make sure LCR write wasn't ignored */
 	if (offset =3D=3D UART_LCR) {
 		int tries =3D 1000;
+
 		while (tries--) {
 			unsigned int lcr =3D p->serial_in(p, UART_LCR);
+
 			if ((value & ~UART_LCR_SPAR) =3D=3D (lcr & ~UART_LCR_SPAR))
 				return;
 			dw8250_force_idle(p);
@@ -166,8 +170,10 @@ static void dw8250_serial_out32(struct uart_port *=
p, int offset, int value)
 	/* Make sure LCR write wasn't ignored */
 	if (offset =3D=3D UART_LCR) {
 		int tries =3D 1000;
+
 		while (tries--) {
 			unsigned int lcr =3D p->serial_in(p, UART_LCR);
+
 			if ((value & ~UART_LCR_SPAR) =3D=3D (lcr & ~UART_LCR_SPAR))
 				return;
 			dw8250_force_idle(p);
diff --git a/drivers/tty/serial/8250/8250_exar_st16c554.c b/drivers/tty=
/serial/8250/8250_exar_st16c554.c
index bf53aab..999f2d3 100644
--- a/drivers/tty/serial/8250/8250_exar_st16c554.c
+++ b/drivers/tty/serial/8250/8250_exar_st16c554.c
@@ -13,7 +13,7 @@
 #include <linux/init.h>
 #include <linux/serial_8250.h>
=20
-#define PORT(_base,_irq)				\
+#define PORT(_base, _irq)				\
 	{						\
 		.iobase		=3D _base,		\
 		.irq		=3D _irq,			\
diff --git a/drivers/tty/serial/8250/8250_fourport.c b/drivers/tty/seri=
al/8250/8250_fourport.c
index be15826..9a04a8a 100644
--- a/drivers/tty/serial/8250/8250_fourport.c
+++ b/drivers/tty/serial/8250/8250_fourport.c
@@ -10,7 +10,7 @@
 #include <linux/init.h>
 #include <linux/serial_8250.h>
=20
-#define PORT(_base,_irq)						\
+#define PORT(_base, _irq)						\
 	{								\
 		.iobase		=3D _base,				\
 		.irq		=3D _irq,					\
diff --git a/drivers/tty/serial/8250/8250_hp300.c b/drivers/tty/serial/=
8250/8250_hp300.c
index 2891958..38d8cb2 100644
--- a/drivers/tty/serial/8250/8250_hp300.c
+++ b/drivers/tty/serial/8250/8250_hp300.c
@@ -125,6 +125,7 @@ int __init hp300_setup_serial_console(void)
 	} else {
 #ifdef CONFIG_HPDCA
 		unsigned long pa =3D dio_scodetophysaddr(scode);
+
 		if (!pa)
 			return 0;
=20
diff --git a/drivers/tty/serial/8250/8250_hub6.c b/drivers/tty/serial/8=
250/8250_hub6.c
index a5c778e..27124e2 100644
--- a/drivers/tty/serial/8250/8250_hub6.c
+++ b/drivers/tty/serial/8250/8250_hub6.c
@@ -10,7 +10,7 @@
 #include <linux/init.h>
 #include <linux/serial_8250.h>
=20
-#define HUB6(card,port)							\
+#define HUB6(card, port)						\
 	{								\
 		.iobase		=3D 0x302,				\
 		.irq		=3D 3,					\
diff --git a/drivers/tty/serial/8250/8250_pci.c b/drivers/tty/serial/82=
50/8250_pci.c
index 4097f3f..ed99fdf 100644
--- a/drivers/tty/serial/8250/8250_pci.c
+++ b/drivers/tty/serial/8250/8250_pci.c
@@ -113,6 +113,7 @@ static int addidata_apci7800_setup(struct serial_pr=
ivate *priv,
 				struct uart_8250_port *port, int idx)
 {
 	unsigned int bar =3D 0, offset =3D board->first_offset;
+
 	bar =3D FL_GET_BASE(board->flags);
=20
 	if (idx < 2) {
@@ -1115,6 +1116,7 @@ static struct quatech_feature quatech_cards[] =3D=
 {
 static int pci_quatech_amcc(u16 devid)
 {
 	struct quatech_feature *qf =3D &quatech_cards[0];
+
 	while (qf->devid) {
 		if (qf->devid =3D=3D devid)
 			return qf->amcc;
@@ -1200,6 +1202,7 @@ static int pci_quatech_test(struct uart_8250_port=
 *port)
 {
 	u8 reg;
 	u8 qopr =3D pci_quatech_rqopr(port);
+
 	pci_quatech_wqopr(port, qopr & QPCR_TEST_FOR1);
 	reg =3D pci_quatech_rqopr(port) & 0xC0;
 	if (reg !=3D QPCR_TEST_GET1)
@@ -1284,8 +1287,10 @@ static int pci_quatech_init(struct pci_dev *dev)
 {
 	if (pci_quatech_amcc(dev->device)) {
 		unsigned long base =3D pci_resource_start(dev, 0);
+
 		if (base) {
 			u32 tmp;
+
 			outl(inl(base + 0x38) | 0x00002000, base + 0x38);
 			tmp =3D inl(base + 0x3c);
 			outl(tmp | 0x01000000, base + 0x3c);
@@ -4502,7 +4507,7 @@ static struct pci_device_id serial_pci_tbl[] =3D =
{
 		PCI_ANY_ID, PCI_ANY_ID, 0, 0,
 		pbn_b0_bt_2_921600 },
 	{	PCI_VENDOR_ID_OXSEMI, PCI_DEVICE_ID_OXSEMI_16PCI958,
-		PCI_ANY_ID , PCI_ANY_ID, 0, 0,
+		PCI_ANY_ID, PCI_ANY_ID, 0, 0,
 		pbn_b2_8_1152000 },
=20
 	/*
diff --git a/drivers/tty/serial/8250/8250_port.c b/drivers/tty/serial/8=
250/8250_port.c
index 52d82d2..ae8f993 100644
--- a/drivers/tty/serial/8250/8250_port.c
+++ b/drivers/tty/serial/8250/8250_port.c
@@ -1327,6 +1327,7 @@ static void serial8250_start_tx(struct uart_port =
*port)
=20
 		if (up->bugs & UART_BUG_TXEN) {
 			unsigned char lsr;
+
 			lsr =3D serial_in(up, UART_LSR);
 			up->lsr_saved_flags |=3D lsr & LSR_SAVE_FLAGS;
 			if (lsr & UART_LSR_THRE)
@@ -1734,8 +1735,10 @@ static void wait_for_xmitr(struct uart_8250_port=
 *up, int bits)
 	/* Wait up to 1s for flow control if necessary */
 	if (up->port.flags & UPF_CONS_FLOW) {
 		unsigned int tmout;
+
 		for (tmout =3D 1000000; tmout; tmout--) {
 			unsigned int msr =3D serial_in(up, UART_MSR);
+
 			up->msr_saved_flags |=3D msr & MSR_SAVE_FLAGS;
 			if (msr & UART_MSR_CTS)
 				break;
diff --git a/drivers/tty/serial/8250/serial_cs.c b/drivers/tty/serial/8=
250/serial_cs.c
index 4d180c9..f5270ba 100644
--- a/drivers/tty/serial/8250/serial_cs.c
+++ b/drivers/tty/serial/8250/serial_cs.c
@@ -257,7 +257,7 @@ static const struct serial_quirk quirks[] =3D {
 };
=20
=20
-static int serial_config(struct pcmcia_device * link);
+static int serial_config(struct pcmcia_device *link);
=20
=20
 static void serial_remove(struct pcmcia_device *link)
@@ -309,7 +309,7 @@ static int serial_probe(struct pcmcia_device *link)
 	dev_dbg(&link->dev, "serial_attach()\n");
=20
 	/* Create new serial device */
-	info =3D kzalloc(sizeof (*info), GFP_KERNEL);
+	info =3D kzalloc(sizeof(*info), GFP_KERNEL);
 	if (!info)
 		return -ENOMEM;
 	info->p_dev =3D link;
@@ -339,7 +339,7 @@ static void serial_detach(struct pcmcia_device *lin=
k)
=20
 /*=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D*/
=20
-static int setup_serial(struct pcmcia_device *handle, struct serial_in=
fo * info,
+static int setup_serial(struct pcmcia_device *handle, struct serial_in=
fo *info,
 			unsigned int iobase, int irq)
 {
 	struct uart_8250_port uart;
@@ -600,7 +600,7 @@ static int serial_check_for_multi(struct pcmcia_dev=
ice *p_dev,  void *priv_data)
 }
=20
=20
-static int serial_config(struct pcmcia_device * link)
+static int serial_config(struct pcmcia_device *link)
 {
 	struct serial_info *info =3D link->priv;
 	int i;
@@ -701,7 +701,7 @@ static const struct pcmcia_device_id serial_ids[] =3D=
 {
 	PCMCIA_PFC_DEVICE_PROD_ID12(1, "LINKSYS", "PCMLM336", 0xf7cb0b07, 0x7=
a821b58),
 	PCMCIA_PFC_DEVICE_PROD_ID12(1, "MEGAHERTZ", "XJEM1144/CCEM1144", 0xf5=
10db04, 0x52d21e1e),
 	PCMCIA_PFC_DEVICE_PROD_ID12(1, "MICRO RESEARCH", "COMBO-L/M-336", 0xb=
2ced065, 0x3ced0555),
-	PCMCIA_PFC_DEVICE_PROD_ID12(1, "NEC", "PK-UG-J001" ,0x18df0ba0 ,0x831=
b1064),
+	PCMCIA_PFC_DEVICE_PROD_ID12(1, "NEC", "PK-UG-J001", 0x18df0ba0, 0x831=
b1064),
 	PCMCIA_PFC_DEVICE_PROD_ID12(1, "Ositech", "Trumpcard:Jack of Diamonds=
 Modem+Ethernet", 0xc2f80cd, 0x656947b9),
 	PCMCIA_PFC_DEVICE_PROD_ID12(1, "Ositech", "Trumpcard:Jack of Hearts M=
odem+Ethernet", 0xc2f80cd, 0xdc9ba5ed),
 	PCMCIA_PFC_DEVICE_PROD_ID12(1, "PCMCIAs", "ComboCard", 0xdcfe12d3, 0x=
cd8906cc),
@@ -797,30 +797,30 @@ static const struct pcmcia_device_id serial_ids[]=
 =3D {
 	PCMCIA_DEVICE_CIS_PROD_ID123("ADVANTECH", "COMpad-32/85", "1.0", 0x96=
913a85, 0x8fbe92ae, 0x0877b627, "cis/COMpad2.cis"),
 	PCMCIA_DEVICE_CIS_PROD_ID2("RS-COM 2P", 0xad20b156, "cis/RS-COM-2P.ci=
s"),
 	PCMCIA_DEVICE_CIS_MANF_CARD(0x0013, 0x0000, "cis/GLOBETROTTER.cis"),
-	PCMCIA_DEVICE_PROD_ID12("ELAN DIGITAL SYSTEMS LTD, c1997.","SERIAL CA=
RD: SL100  1.00.",0x19ca78af,0xf964f42b),
-	PCMCIA_DEVICE_PROD_ID12("ELAN DIGITAL SYSTEMS LTD, c1997.","SERIAL CA=
RD: SL100",0x19ca78af,0x71d98e83),
-	PCMCIA_DEVICE_PROD_ID12("ELAN DIGITAL SYSTEMS LTD, c1997.","SERIAL CA=
RD: SL232  1.00.",0x19ca78af,0x69fb7490),
-	PCMCIA_DEVICE_PROD_ID12("ELAN DIGITAL SYSTEMS LTD, c1997.","SERIAL CA=
RD: SL232",0x19ca78af,0xb6bc0235),
-	PCMCIA_DEVICE_PROD_ID12("ELAN DIGITAL SYSTEMS LTD, c2000.","SERIAL CA=
RD: CF232",0x63f2e0bd,0xb9e175d3),
-	PCMCIA_DEVICE_PROD_ID12("ELAN DIGITAL SYSTEMS LTD, c2000.","SERIAL CA=
RD: CF232-5",0x63f2e0bd,0xfce33442),
-	PCMCIA_DEVICE_PROD_ID12("Elan","Serial Port: CF232",0x3beb8cf2,0x171e=
7190),
-	PCMCIA_DEVICE_PROD_ID12("Elan","Serial Port: CF232-5",0x3beb8cf2,0x20=
da4262),
-	PCMCIA_DEVICE_PROD_ID12("Elan","Serial Port: CF428",0x3beb8cf2,0xea5d=
d57d),
-	PCMCIA_DEVICE_PROD_ID12("Elan","Serial Port: CF500",0x3beb8cf2,0xd772=
55fa),
-	PCMCIA_DEVICE_PROD_ID12("Elan","Serial Port: IC232",0x3beb8cf2,0x6a70=
9903),
-	PCMCIA_DEVICE_PROD_ID12("Elan","Serial Port: SL232",0x3beb8cf2,0x1843=
0676),
-	PCMCIA_DEVICE_PROD_ID12("Elan","Serial Port: XL232",0x3beb8cf2,0x6f93=
3767),
-	PCMCIA_MFC_DEVICE_PROD_ID12(0,"Elan","Serial Port: CF332",0x3beb8cf2,=
0x16dc1ba7),
-	PCMCIA_MFC_DEVICE_PROD_ID12(0,"Elan","Serial Port: SL332",0x3beb8cf2,=
0x19816c41),
-	PCMCIA_MFC_DEVICE_PROD_ID12(0,"Elan","Serial Port: SL385",0x3beb8cf2,=
0x64112029),
-	PCMCIA_MFC_DEVICE_PROD_ID12(0,"Elan","Serial Port: SL432",0x3beb8cf2,=
0x1cce7ac4),
-	PCMCIA_MFC_DEVICE_PROD_ID12(0,"Elan","Serial+Parallel Port: SP230",0x=
3beb8cf2,0xdb9e58bc),
-	PCMCIA_MFC_DEVICE_PROD_ID12(1,"Elan","Serial Port: CF332",0x3beb8cf2,=
0x16dc1ba7),
-	PCMCIA_MFC_DEVICE_PROD_ID12(1,"Elan","Serial Port: SL332",0x3beb8cf2,=
0x19816c41),
-	PCMCIA_MFC_DEVICE_PROD_ID12(1,"Elan","Serial Port: SL385",0x3beb8cf2,=
0x64112029),
-	PCMCIA_MFC_DEVICE_PROD_ID12(1,"Elan","Serial Port: SL432",0x3beb8cf2,=
0x1cce7ac4),
-	PCMCIA_MFC_DEVICE_PROD_ID12(2,"Elan","Serial Port: SL432",0x3beb8cf2,=
0x1cce7ac4),
-	PCMCIA_MFC_DEVICE_PROD_ID12(3,"Elan","Serial Port: SL432",0x3beb8cf2,=
0x1cce7ac4),
+	PCMCIA_DEVICE_PROD_ID12("ELAN DIGITAL SYSTEMS LTD, c1997.", "SERIAL C=
ARD: SL100  1.00.", 0x19ca78af, 0xf964f42b),
+	PCMCIA_DEVICE_PROD_ID12("ELAN DIGITAL SYSTEMS LTD, c1997.", "SERIAL C=
ARD: SL100", 0x19ca78af, 0x71d98e83),
+	PCMCIA_DEVICE_PROD_ID12("ELAN DIGITAL SYSTEMS LTD, c1997.", "SERIAL C=
ARD: SL232  1.00.", 0x19ca78af, 0x69fb7490),
+	PCMCIA_DEVICE_PROD_ID12("ELAN DIGITAL SYSTEMS LTD, c1997.", "SERIAL C=
ARD: SL232", 0x19ca78af, 0xb6bc0235),
+	PCMCIA_DEVICE_PROD_ID12("ELAN DIGITAL SYSTEMS LTD, c2000.", "SERIAL C=
ARD: CF232", 0x63f2e0bd, 0xb9e175d3),
+	PCMCIA_DEVICE_PROD_ID12("ELAN DIGITAL SYSTEMS LTD, c2000.", "SERIAL C=
ARD: CF232-5", 0x63f2e0bd, 0xfce33442),
+	PCMCIA_DEVICE_PROD_ID12("Elan", "Serial Port: CF232", 0x3beb8cf2, 0x1=
71e7190),
+	PCMCIA_DEVICE_PROD_ID12("Elan", "Serial Port: CF232-5", 0x3beb8cf2, 0=
x20da4262),
+	PCMCIA_DEVICE_PROD_ID12("Elan", "Serial Port: CF428", 0x3beb8cf2, 0xe=
a5dd57d),
+	PCMCIA_DEVICE_PROD_ID12("Elan", "Serial Port: CF500", 0x3beb8cf2, 0xd=
77255fa),
+	PCMCIA_DEVICE_PROD_ID12("Elan", "Serial Port: IC232", 0x3beb8cf2, 0x6=
a709903),
+	PCMCIA_DEVICE_PROD_ID12("Elan", "Serial Port: SL232", 0x3beb8cf2, 0x1=
8430676),
+	PCMCIA_DEVICE_PROD_ID12("Elan", "Serial Port: XL232", 0x3beb8cf2, 0x6=
f933767),
+	PCMCIA_MFC_DEVICE_PROD_ID12(0, "Elan", "Serial Port: CF332", 0x3beb8c=
f2, 0x16dc1ba7),
+	PCMCIA_MFC_DEVICE_PROD_ID12(0, "Elan", "Serial Port: SL332", 0x3beb8c=
f2, 0x19816c41),
+	PCMCIA_MFC_DEVICE_PROD_ID12(0, "Elan", "Serial Port: SL385", 0x3beb8c=
f2, 0x64112029),
+	PCMCIA_MFC_DEVICE_PROD_ID12(0, "Elan", "Serial Port: SL432", 0x3beb8c=
f2, 0x1cce7ac4),
+	PCMCIA_MFC_DEVICE_PROD_ID12(0, "Elan", "Serial+Parallel Port: SP230",=
 0x3beb8cf2, 0xdb9e58bc),
+	PCMCIA_MFC_DEVICE_PROD_ID12(1, "Elan", "Serial Port: CF332", 0x3beb8c=
f2, 0x16dc1ba7),
+	PCMCIA_MFC_DEVICE_PROD_ID12(1, "Elan", "Serial Port: SL332", 0x3beb8c=
f2, 0x19816c41),
+	PCMCIA_MFC_DEVICE_PROD_ID12(1, "Elan", "Serial Port: SL385", 0x3beb8c=
f2, 0x64112029),
+	PCMCIA_MFC_DEVICE_PROD_ID12(1, "Elan", "Serial Port: SL432", 0x3beb8c=
f2, 0x1cce7ac4),
+	PCMCIA_MFC_DEVICE_PROD_ID12(2, "Elan", "Serial Port: SL432", 0x3beb8c=
f2, 0x1cce7ac4),
+	PCMCIA_MFC_DEVICE_PROD_ID12(3, "Elan", "Serial Port: SL432", 0x3beb8c=
f2, 0x1cce7ac4),
 	PCMCIA_DEVICE_MANF_CARD(0x0279, 0x950b),
 	/* too generic */
 	/* PCMCIA_MFC_DEVICE_MANF_CARD(0, 0x0160, 0x0002), */
--=20
1.9.1

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

* [PATCH 01/11] tty: serial: 8250: Fix whitespace errors
@ 2015-12-16 15:36   ` Anton Wuerfel
  0 siblings, 0 replies; 60+ messages in thread
From: Anton Wuerfel @ 2015-12-16 15:36 UTC (permalink / raw)
  To: linux-serial
  Cc: Greg Kroah-Hartman, Jiri Slaby, James E.J. Bottomley,
	Helge Deller, Peter Hurley, Heikki Krogerus, Andy Shevchenko,
	Qipeng Zha, Desmond Liu, Wang Long, Matt Redfearn, Paul Burton,
	Ralf Baechle, Krzysztof Kozlowski, Peter Hung, Soeren Grunewald,
	Adam Lee, Maciej S. Szmigiero, Mans Rullgard, linux-kernel,
	linux-parisc, linux-kernel, Anton Wuerfel, Phillip Raffeck

This patch fixes whitespace errors reported by checkpatch to increase
readability. Main focus is on missing spaces after commas in
function headers and macros (like foo,bar edited to foo, bar).

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_accent.c        |  2 +-
 drivers/tty/serial/8250/8250_acorn.c         |  2 +-
 drivers/tty/serial/8250/8250_boca.c          |  2 +-
 drivers/tty/serial/8250/8250_core.c          |  1 +
 drivers/tty/serial/8250/8250_dw.c            |  6 +++
 drivers/tty/serial/8250/8250_exar_st16c554.c |  2 +-
 drivers/tty/serial/8250/8250_fourport.c      |  2 +-
 drivers/tty/serial/8250/8250_hp300.c         |  1 +
 drivers/tty/serial/8250/8250_hub6.c          |  2 +-
 drivers/tty/serial/8250/8250_pci.c           |  7 +++-
 drivers/tty/serial/8250/8250_port.c          |  3 ++
 drivers/tty/serial/8250/serial_cs.c          | 58 ++++++++++++++--------------
 12 files changed, 52 insertions(+), 36 deletions(-)

diff --git a/drivers/tty/serial/8250/8250_accent.c b/drivers/tty/serial/8250/8250_accent.c
index 34b51c6..c480729 100644
--- a/drivers/tty/serial/8250/8250_accent.c
+++ b/drivers/tty/serial/8250/8250_accent.c
@@ -10,7 +10,7 @@
 #include <linux/init.h>
 #include <linux/serial_8250.h>
 
-#define PORT(_base,_irq)				\
+#define PORT(_base, _irq)				\
 	{						\
 		.iobase		= _base,		\
 		.irq		= _irq,			\
diff --git a/drivers/tty/serial/8250/8250_acorn.c b/drivers/tty/serial/8250/8250_acorn.c
index 549aa07..402dfdd 100644
--- a/drivers/tty/serial/8250/8250_acorn.c
+++ b/drivers/tty/serial/8250/8250_acorn.c
@@ -70,7 +70,7 @@ serial_card_probe(struct expansion_card *ec, const struct ecard_id *id)
 	uart.port.regshift	= 2;
 	uart.port.dev	= &ec->dev;
 
-	for (i = 0; i < info->num_ports; i ++) {
+	for (i = 0; i < info->num_ports; i++) {
 		uart.port.membase = info->vaddr + type->offset[i];
 		uart.port.mapbase = bus_addr + type->offset[i];
 
diff --git a/drivers/tty/serial/8250/8250_boca.c b/drivers/tty/serial/8250/8250_boca.c
index d125dc1..e42a5b5 100644
--- a/drivers/tty/serial/8250/8250_boca.c
+++ b/drivers/tty/serial/8250/8250_boca.c
@@ -10,7 +10,7 @@
 #include <linux/init.h>
 #include <linux/serial_8250.h>
 
-#define PORT(_base,_irq)				\
+#define PORT(_base, _irq)				\
 	{						\
 		.iobase		= _base,		\
 		.irq		= _irq,			\
diff --git a/drivers/tty/serial/8250/8250_core.c b/drivers/tty/serial/8250/8250_core.c
index 3912646..89a20c9 100644
--- a/drivers/tty/serial/8250/8250_core.c
+++ b/drivers/tty/serial/8250/8250_core.c
@@ -756,6 +756,7 @@ void serial8250_suspend_port(int line)
 	if (!console_suspend_enabled && uart_console(port) &&
 	    port->type != PORT_8250) {
 		unsigned char canary = 0xa5;
+
 		serial_out(up, UART_SCR, canary);
 		if (serial_in(up, UART_SCR) == canary)
 			up->canary = canary;
diff --git a/drivers/tty/serial/8250/8250_dw.c b/drivers/tty/serial/8250/8250_dw.c
index a5d319e..0f67355 100644
--- a/drivers/tty/serial/8250/8250_dw.c
+++ b/drivers/tty/serial/8250/8250_dw.c
@@ -102,8 +102,10 @@ static void dw8250_serial_out(struct uart_port *p, int offset, int value)
 	/* Make sure LCR write wasn't ignored */
 	if (offset == UART_LCR) {
 		int tries = 1000;
+
 		while (tries--) {
 			unsigned int lcr = p->serial_in(p, UART_LCR);
+
 			if ((value & ~UART_LCR_SPAR) == (lcr & ~UART_LCR_SPAR))
 				return;
 			dw8250_force_idle(p);
@@ -143,8 +145,10 @@ static void dw8250_serial_outq(struct uart_port *p, int offset, int value)
 	/* Make sure LCR write wasn't ignored */
 	if (offset == UART_LCR) {
 		int tries = 1000;
+
 		while (tries--) {
 			unsigned int lcr = p->serial_in(p, UART_LCR);
+
 			if ((value & ~UART_LCR_SPAR) == (lcr & ~UART_LCR_SPAR))
 				return;
 			dw8250_force_idle(p);
@@ -166,8 +170,10 @@ static void dw8250_serial_out32(struct uart_port *p, int offset, int value)
 	/* Make sure LCR write wasn't ignored */
 	if (offset == UART_LCR) {
 		int tries = 1000;
+
 		while (tries--) {
 			unsigned int lcr = p->serial_in(p, UART_LCR);
+
 			if ((value & ~UART_LCR_SPAR) == (lcr & ~UART_LCR_SPAR))
 				return;
 			dw8250_force_idle(p);
diff --git a/drivers/tty/serial/8250/8250_exar_st16c554.c b/drivers/tty/serial/8250/8250_exar_st16c554.c
index bf53aab..999f2d3 100644
--- a/drivers/tty/serial/8250/8250_exar_st16c554.c
+++ b/drivers/tty/serial/8250/8250_exar_st16c554.c
@@ -13,7 +13,7 @@
 #include <linux/init.h>
 #include <linux/serial_8250.h>
 
-#define PORT(_base,_irq)				\
+#define PORT(_base, _irq)				\
 	{						\
 		.iobase		= _base,		\
 		.irq		= _irq,			\
diff --git a/drivers/tty/serial/8250/8250_fourport.c b/drivers/tty/serial/8250/8250_fourport.c
index be15826..9a04a8a 100644
--- a/drivers/tty/serial/8250/8250_fourport.c
+++ b/drivers/tty/serial/8250/8250_fourport.c
@@ -10,7 +10,7 @@
 #include <linux/init.h>
 #include <linux/serial_8250.h>
 
-#define PORT(_base,_irq)						\
+#define PORT(_base, _irq)						\
 	{								\
 		.iobase		= _base,				\
 		.irq		= _irq,					\
diff --git a/drivers/tty/serial/8250/8250_hp300.c b/drivers/tty/serial/8250/8250_hp300.c
index 2891958..38d8cb2 100644
--- a/drivers/tty/serial/8250/8250_hp300.c
+++ b/drivers/tty/serial/8250/8250_hp300.c
@@ -125,6 +125,7 @@ int __init hp300_setup_serial_console(void)
 	} else {
 #ifdef CONFIG_HPDCA
 		unsigned long pa = dio_scodetophysaddr(scode);
+
 		if (!pa)
 			return 0;
 
diff --git a/drivers/tty/serial/8250/8250_hub6.c b/drivers/tty/serial/8250/8250_hub6.c
index a5c778e..27124e2 100644
--- a/drivers/tty/serial/8250/8250_hub6.c
+++ b/drivers/tty/serial/8250/8250_hub6.c
@@ -10,7 +10,7 @@
 #include <linux/init.h>
 #include <linux/serial_8250.h>
 
-#define HUB6(card,port)							\
+#define HUB6(card, port)						\
 	{								\
 		.iobase		= 0x302,				\
 		.irq		= 3,					\
diff --git a/drivers/tty/serial/8250/8250_pci.c b/drivers/tty/serial/8250/8250_pci.c
index 4097f3f..ed99fdf 100644
--- a/drivers/tty/serial/8250/8250_pci.c
+++ b/drivers/tty/serial/8250/8250_pci.c
@@ -113,6 +113,7 @@ static int addidata_apci7800_setup(struct serial_private *priv,
 				struct uart_8250_port *port, int idx)
 {
 	unsigned int bar = 0, offset = board->first_offset;
+
 	bar = FL_GET_BASE(board->flags);
 
 	if (idx < 2) {
@@ -1115,6 +1116,7 @@ static struct quatech_feature quatech_cards[] = {
 static int pci_quatech_amcc(u16 devid)
 {
 	struct quatech_feature *qf = &quatech_cards[0];
+
 	while (qf->devid) {
 		if (qf->devid == devid)
 			return qf->amcc;
@@ -1200,6 +1202,7 @@ static int pci_quatech_test(struct uart_8250_port *port)
 {
 	u8 reg;
 	u8 qopr = pci_quatech_rqopr(port);
+
 	pci_quatech_wqopr(port, qopr & QPCR_TEST_FOR1);
 	reg = pci_quatech_rqopr(port) & 0xC0;
 	if (reg != QPCR_TEST_GET1)
@@ -1284,8 +1287,10 @@ static int pci_quatech_init(struct pci_dev *dev)
 {
 	if (pci_quatech_amcc(dev->device)) {
 		unsigned long base = pci_resource_start(dev, 0);
+
 		if (base) {
 			u32 tmp;
+
 			outl(inl(base + 0x38) | 0x00002000, base + 0x38);
 			tmp = inl(base + 0x3c);
 			outl(tmp | 0x01000000, base + 0x3c);
@@ -4502,7 +4507,7 @@ static struct pci_device_id serial_pci_tbl[] = {
 		PCI_ANY_ID, PCI_ANY_ID, 0, 0,
 		pbn_b0_bt_2_921600 },
 	{	PCI_VENDOR_ID_OXSEMI, PCI_DEVICE_ID_OXSEMI_16PCI958,
-		PCI_ANY_ID , PCI_ANY_ID, 0, 0,
+		PCI_ANY_ID, PCI_ANY_ID, 0, 0,
 		pbn_b2_8_1152000 },
 
 	/*
diff --git a/drivers/tty/serial/8250/8250_port.c b/drivers/tty/serial/8250/8250_port.c
index 52d82d2..ae8f993 100644
--- a/drivers/tty/serial/8250/8250_port.c
+++ b/drivers/tty/serial/8250/8250_port.c
@@ -1327,6 +1327,7 @@ static void serial8250_start_tx(struct uart_port *port)
 
 		if (up->bugs & UART_BUG_TXEN) {
 			unsigned char lsr;
+
 			lsr = serial_in(up, UART_LSR);
 			up->lsr_saved_flags |= lsr & LSR_SAVE_FLAGS;
 			if (lsr & UART_LSR_THRE)
@@ -1734,8 +1735,10 @@ static void wait_for_xmitr(struct uart_8250_port *up, int bits)
 	/* Wait up to 1s for flow control if necessary */
 	if (up->port.flags & UPF_CONS_FLOW) {
 		unsigned int tmout;
+
 		for (tmout = 1000000; tmout; tmout--) {
 			unsigned int msr = serial_in(up, UART_MSR);
+
 			up->msr_saved_flags |= msr & MSR_SAVE_FLAGS;
 			if (msr & UART_MSR_CTS)
 				break;
diff --git a/drivers/tty/serial/8250/serial_cs.c b/drivers/tty/serial/8250/serial_cs.c
index 4d180c9..f5270ba 100644
--- a/drivers/tty/serial/8250/serial_cs.c
+++ b/drivers/tty/serial/8250/serial_cs.c
@@ -257,7 +257,7 @@ static const struct serial_quirk quirks[] = {
 };
 
 
-static int serial_config(struct pcmcia_device * link);
+static int serial_config(struct pcmcia_device *link);
 
 
 static void serial_remove(struct pcmcia_device *link)
@@ -309,7 +309,7 @@ static int serial_probe(struct pcmcia_device *link)
 	dev_dbg(&link->dev, "serial_attach()\n");
 
 	/* Create new serial device */
-	info = kzalloc(sizeof (*info), GFP_KERNEL);
+	info = kzalloc(sizeof(*info), GFP_KERNEL);
 	if (!info)
 		return -ENOMEM;
 	info->p_dev = link;
@@ -339,7 +339,7 @@ static void serial_detach(struct pcmcia_device *link)
 
 /*====================================================================*/
 
-static int setup_serial(struct pcmcia_device *handle, struct serial_info * info,
+static int setup_serial(struct pcmcia_device *handle, struct serial_info *info,
 			unsigned int iobase, int irq)
 {
 	struct uart_8250_port uart;
@@ -600,7 +600,7 @@ static int serial_check_for_multi(struct pcmcia_device *p_dev,  void *priv_data)
 }
 
 
-static int serial_config(struct pcmcia_device * link)
+static int serial_config(struct pcmcia_device *link)
 {
 	struct serial_info *info = link->priv;
 	int i;
@@ -701,7 +701,7 @@ static const struct pcmcia_device_id serial_ids[] = {
 	PCMCIA_PFC_DEVICE_PROD_ID12(1, "LINKSYS", "PCMLM336", 0xf7cb0b07, 0x7a821b58),
 	PCMCIA_PFC_DEVICE_PROD_ID12(1, "MEGAHERTZ", "XJEM1144/CCEM1144", 0xf510db04, 0x52d21e1e),
 	PCMCIA_PFC_DEVICE_PROD_ID12(1, "MICRO RESEARCH", "COMBO-L/M-336", 0xb2ced065, 0x3ced0555),
-	PCMCIA_PFC_DEVICE_PROD_ID12(1, "NEC", "PK-UG-J001" ,0x18df0ba0 ,0x831b1064),
+	PCMCIA_PFC_DEVICE_PROD_ID12(1, "NEC", "PK-UG-J001", 0x18df0ba0, 0x831b1064),
 	PCMCIA_PFC_DEVICE_PROD_ID12(1, "Ositech", "Trumpcard:Jack of Diamonds Modem+Ethernet", 0xc2f80cd, 0x656947b9),
 	PCMCIA_PFC_DEVICE_PROD_ID12(1, "Ositech", "Trumpcard:Jack of Hearts Modem+Ethernet", 0xc2f80cd, 0xdc9ba5ed),
 	PCMCIA_PFC_DEVICE_PROD_ID12(1, "PCMCIAs", "ComboCard", 0xdcfe12d3, 0xcd8906cc),
@@ -797,30 +797,30 @@ static const struct pcmcia_device_id serial_ids[] = {
 	PCMCIA_DEVICE_CIS_PROD_ID123("ADVANTECH", "COMpad-32/85", "1.0", 0x96913a85, 0x8fbe92ae, 0x0877b627, "cis/COMpad2.cis"),
 	PCMCIA_DEVICE_CIS_PROD_ID2("RS-COM 2P", 0xad20b156, "cis/RS-COM-2P.cis"),
 	PCMCIA_DEVICE_CIS_MANF_CARD(0x0013, 0x0000, "cis/GLOBETROTTER.cis"),
-	PCMCIA_DEVICE_PROD_ID12("ELAN DIGITAL SYSTEMS LTD, c1997.","SERIAL CARD: SL100  1.00.",0x19ca78af,0xf964f42b),
-	PCMCIA_DEVICE_PROD_ID12("ELAN DIGITAL SYSTEMS LTD, c1997.","SERIAL CARD: SL100",0x19ca78af,0x71d98e83),
-	PCMCIA_DEVICE_PROD_ID12("ELAN DIGITAL SYSTEMS LTD, c1997.","SERIAL CARD: SL232  1.00.",0x19ca78af,0x69fb7490),
-	PCMCIA_DEVICE_PROD_ID12("ELAN DIGITAL SYSTEMS LTD, c1997.","SERIAL CARD: SL232",0x19ca78af,0xb6bc0235),
-	PCMCIA_DEVICE_PROD_ID12("ELAN DIGITAL SYSTEMS LTD, c2000.","SERIAL CARD: CF232",0x63f2e0bd,0xb9e175d3),
-	PCMCIA_DEVICE_PROD_ID12("ELAN DIGITAL SYSTEMS LTD, c2000.","SERIAL CARD: CF232-5",0x63f2e0bd,0xfce33442),
-	PCMCIA_DEVICE_PROD_ID12("Elan","Serial Port: CF232",0x3beb8cf2,0x171e7190),
-	PCMCIA_DEVICE_PROD_ID12("Elan","Serial Port: CF232-5",0x3beb8cf2,0x20da4262),
-	PCMCIA_DEVICE_PROD_ID12("Elan","Serial Port: CF428",0x3beb8cf2,0xea5dd57d),
-	PCMCIA_DEVICE_PROD_ID12("Elan","Serial Port: CF500",0x3beb8cf2,0xd77255fa),
-	PCMCIA_DEVICE_PROD_ID12("Elan","Serial Port: IC232",0x3beb8cf2,0x6a709903),
-	PCMCIA_DEVICE_PROD_ID12("Elan","Serial Port: SL232",0x3beb8cf2,0x18430676),
-	PCMCIA_DEVICE_PROD_ID12("Elan","Serial Port: XL232",0x3beb8cf2,0x6f933767),
-	PCMCIA_MFC_DEVICE_PROD_ID12(0,"Elan","Serial Port: CF332",0x3beb8cf2,0x16dc1ba7),
-	PCMCIA_MFC_DEVICE_PROD_ID12(0,"Elan","Serial Port: SL332",0x3beb8cf2,0x19816c41),
-	PCMCIA_MFC_DEVICE_PROD_ID12(0,"Elan","Serial Port: SL385",0x3beb8cf2,0x64112029),
-	PCMCIA_MFC_DEVICE_PROD_ID12(0,"Elan","Serial Port: SL432",0x3beb8cf2,0x1cce7ac4),
-	PCMCIA_MFC_DEVICE_PROD_ID12(0,"Elan","Serial+Parallel Port: SP230",0x3beb8cf2,0xdb9e58bc),
-	PCMCIA_MFC_DEVICE_PROD_ID12(1,"Elan","Serial Port: CF332",0x3beb8cf2,0x16dc1ba7),
-	PCMCIA_MFC_DEVICE_PROD_ID12(1,"Elan","Serial Port: SL332",0x3beb8cf2,0x19816c41),
-	PCMCIA_MFC_DEVICE_PROD_ID12(1,"Elan","Serial Port: SL385",0x3beb8cf2,0x64112029),
-	PCMCIA_MFC_DEVICE_PROD_ID12(1,"Elan","Serial Port: SL432",0x3beb8cf2,0x1cce7ac4),
-	PCMCIA_MFC_DEVICE_PROD_ID12(2,"Elan","Serial Port: SL432",0x3beb8cf2,0x1cce7ac4),
-	PCMCIA_MFC_DEVICE_PROD_ID12(3,"Elan","Serial Port: SL432",0x3beb8cf2,0x1cce7ac4),
+	PCMCIA_DEVICE_PROD_ID12("ELAN DIGITAL SYSTEMS LTD, c1997.", "SERIAL CARD: SL100  1.00.", 0x19ca78af, 0xf964f42b),
+	PCMCIA_DEVICE_PROD_ID12("ELAN DIGITAL SYSTEMS LTD, c1997.", "SERIAL CARD: SL100", 0x19ca78af, 0x71d98e83),
+	PCMCIA_DEVICE_PROD_ID12("ELAN DIGITAL SYSTEMS LTD, c1997.", "SERIAL CARD: SL232  1.00.", 0x19ca78af, 0x69fb7490),
+	PCMCIA_DEVICE_PROD_ID12("ELAN DIGITAL SYSTEMS LTD, c1997.", "SERIAL CARD: SL232", 0x19ca78af, 0xb6bc0235),
+	PCMCIA_DEVICE_PROD_ID12("ELAN DIGITAL SYSTEMS LTD, c2000.", "SERIAL CARD: CF232", 0x63f2e0bd, 0xb9e175d3),
+	PCMCIA_DEVICE_PROD_ID12("ELAN DIGITAL SYSTEMS LTD, c2000.", "SERIAL CARD: CF232-5", 0x63f2e0bd, 0xfce33442),
+	PCMCIA_DEVICE_PROD_ID12("Elan", "Serial Port: CF232", 0x3beb8cf2, 0x171e7190),
+	PCMCIA_DEVICE_PROD_ID12("Elan", "Serial Port: CF232-5", 0x3beb8cf2, 0x20da4262),
+	PCMCIA_DEVICE_PROD_ID12("Elan", "Serial Port: CF428", 0x3beb8cf2, 0xea5dd57d),
+	PCMCIA_DEVICE_PROD_ID12("Elan", "Serial Port: CF500", 0x3beb8cf2, 0xd77255fa),
+	PCMCIA_DEVICE_PROD_ID12("Elan", "Serial Port: IC232", 0x3beb8cf2, 0x6a709903),
+	PCMCIA_DEVICE_PROD_ID12("Elan", "Serial Port: SL232", 0x3beb8cf2, 0x18430676),
+	PCMCIA_DEVICE_PROD_ID12("Elan", "Serial Port: XL232", 0x3beb8cf2, 0x6f933767),
+	PCMCIA_MFC_DEVICE_PROD_ID12(0, "Elan", "Serial Port: CF332", 0x3beb8cf2, 0x16dc1ba7),
+	PCMCIA_MFC_DEVICE_PROD_ID12(0, "Elan", "Serial Port: SL332", 0x3beb8cf2, 0x19816c41),
+	PCMCIA_MFC_DEVICE_PROD_ID12(0, "Elan", "Serial Port: SL385", 0x3beb8cf2, 0x64112029),
+	PCMCIA_MFC_DEVICE_PROD_ID12(0, "Elan", "Serial Port: SL432", 0x3beb8cf2, 0x1cce7ac4),
+	PCMCIA_MFC_DEVICE_PROD_ID12(0, "Elan", "Serial+Parallel Port: SP230", 0x3beb8cf2, 0xdb9e58bc),
+	PCMCIA_MFC_DEVICE_PROD_ID12(1, "Elan", "Serial Port: CF332", 0x3beb8cf2, 0x16dc1ba7),
+	PCMCIA_MFC_DEVICE_PROD_ID12(1, "Elan", "Serial Port: SL332", 0x3beb8cf2, 0x19816c41),
+	PCMCIA_MFC_DEVICE_PROD_ID12(1, "Elan", "Serial Port: SL385", 0x3beb8cf2, 0x64112029),
+	PCMCIA_MFC_DEVICE_PROD_ID12(1, "Elan", "Serial Port: SL432", 0x3beb8cf2, 0x1cce7ac4),
+	PCMCIA_MFC_DEVICE_PROD_ID12(2, "Elan", "Serial Port: SL432", 0x3beb8cf2, 0x1cce7ac4),
+	PCMCIA_MFC_DEVICE_PROD_ID12(3, "Elan", "Serial Port: SL432", 0x3beb8cf2, 0x1cce7ac4),
 	PCMCIA_DEVICE_MANF_CARD(0x0279, 0x950b),
 	/* too generic */
 	/* PCMCIA_MFC_DEVICE_MANF_CARD(0, 0x0160, 0x0002), */
-- 
1.9.1


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

* [PATCH 01/11] tty: serial: 8250: Fix whitespace errors
@ 2015-12-16 15:36   ` Anton Wuerfel
  0 siblings, 0 replies; 60+ messages in thread
From: Anton Wuerfel @ 2015-12-16 15:36 UTC (permalink / raw)
  To: linux-serial
  Cc: Greg Kroah-Hartman, Jiri Slaby, James E.J. Bottomley,
	Helge Deller, Peter Hurley, Heikki Krogerus, Andy Shevchenko,
	Qipeng Zha, Desmond Liu, Wang Long, Matt Redfearn, Paul Burton,
	Ralf Baechle, Krzysztof Kozlowski, Peter Hung, Soeren Grunewald,
	Adam Lee, Maciej S. Szmigiero, Mans Rullgard, linux-kernel,
	linux-parisc, linux-kernel, Anton Wuerfel

This patch fixes whitespace errors reported by checkpatch to increase
readability. Main focus is on missing spaces after commas in
function headers and macros (like foo,bar edited to foo, bar).

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_accent.c        |  2 +-
 drivers/tty/serial/8250/8250_acorn.c         |  2 +-
 drivers/tty/serial/8250/8250_boca.c          |  2 +-
 drivers/tty/serial/8250/8250_core.c          |  1 +
 drivers/tty/serial/8250/8250_dw.c            |  6 +++
 drivers/tty/serial/8250/8250_exar_st16c554.c |  2 +-
 drivers/tty/serial/8250/8250_fourport.c      |  2 +-
 drivers/tty/serial/8250/8250_hp300.c         |  1 +
 drivers/tty/serial/8250/8250_hub6.c          |  2 +-
 drivers/tty/serial/8250/8250_pci.c           |  7 +++-
 drivers/tty/serial/8250/8250_port.c          |  3 ++
 drivers/tty/serial/8250/serial_cs.c          | 58 ++++++++++++++--------------
 12 files changed, 52 insertions(+), 36 deletions(-)

diff --git a/drivers/tty/serial/8250/8250_accent.c b/drivers/tty/serial/8250/8250_accent.c
index 34b51c6..c480729 100644
--- a/drivers/tty/serial/8250/8250_accent.c
+++ b/drivers/tty/serial/8250/8250_accent.c
@@ -10,7 +10,7 @@
 #include <linux/init.h>
 #include <linux/serial_8250.h>
 
-#define PORT(_base,_irq)				\
+#define PORT(_base, _irq)				\
 	{						\
 		.iobase		= _base,		\
 		.irq		= _irq,			\
diff --git a/drivers/tty/serial/8250/8250_acorn.c b/drivers/tty/serial/8250/8250_acorn.c
index 549aa07..402dfdd 100644
--- a/drivers/tty/serial/8250/8250_acorn.c
+++ b/drivers/tty/serial/8250/8250_acorn.c
@@ -70,7 +70,7 @@ serial_card_probe(struct expansion_card *ec, const struct ecard_id *id)
 	uart.port.regshift	= 2;
 	uart.port.dev	= &ec->dev;
 
-	for (i = 0; i < info->num_ports; i ++) {
+	for (i = 0; i < info->num_ports; i++) {
 		uart.port.membase = info->vaddr + type->offset[i];
 		uart.port.mapbase = bus_addr + type->offset[i];
 
diff --git a/drivers/tty/serial/8250/8250_boca.c b/drivers/tty/serial/8250/8250_boca.c
index d125dc1..e42a5b5 100644
--- a/drivers/tty/serial/8250/8250_boca.c
+++ b/drivers/tty/serial/8250/8250_boca.c
@@ -10,7 +10,7 @@
 #include <linux/init.h>
 #include <linux/serial_8250.h>
 
-#define PORT(_base,_irq)				\
+#define PORT(_base, _irq)				\
 	{						\
 		.iobase		= _base,		\
 		.irq		= _irq,			\
diff --git a/drivers/tty/serial/8250/8250_core.c b/drivers/tty/serial/8250/8250_core.c
index 3912646..89a20c9 100644
--- a/drivers/tty/serial/8250/8250_core.c
+++ b/drivers/tty/serial/8250/8250_core.c
@@ -756,6 +756,7 @@ void serial8250_suspend_port(int line)
 	if (!console_suspend_enabled && uart_console(port) &&
 	    port->type != PORT_8250) {
 		unsigned char canary = 0xa5;
+
 		serial_out(up, UART_SCR, canary);
 		if (serial_in(up, UART_SCR) == canary)
 			up->canary = canary;
diff --git a/drivers/tty/serial/8250/8250_dw.c b/drivers/tty/serial/8250/8250_dw.c
index a5d319e..0f67355 100644
--- a/drivers/tty/serial/8250/8250_dw.c
+++ b/drivers/tty/serial/8250/8250_dw.c
@@ -102,8 +102,10 @@ static void dw8250_serial_out(struct uart_port *p, int offset, int value)
 	/* Make sure LCR write wasn't ignored */
 	if (offset == UART_LCR) {
 		int tries = 1000;
+
 		while (tries--) {
 			unsigned int lcr = p->serial_in(p, UART_LCR);
+
 			if ((value & ~UART_LCR_SPAR) == (lcr & ~UART_LCR_SPAR))
 				return;
 			dw8250_force_idle(p);
@@ -143,8 +145,10 @@ static void dw8250_serial_outq(struct uart_port *p, int offset, int value)
 	/* Make sure LCR write wasn't ignored */
 	if (offset == UART_LCR) {
 		int tries = 1000;
+
 		while (tries--) {
 			unsigned int lcr = p->serial_in(p, UART_LCR);
+
 			if ((value & ~UART_LCR_SPAR) == (lcr & ~UART_LCR_SPAR))
 				return;
 			dw8250_force_idle(p);
@@ -166,8 +170,10 @@ static void dw8250_serial_out32(struct uart_port *p, int offset, int value)
 	/* Make sure LCR write wasn't ignored */
 	if (offset == UART_LCR) {
 		int tries = 1000;
+
 		while (tries--) {
 			unsigned int lcr = p->serial_in(p, UART_LCR);
+
 			if ((value & ~UART_LCR_SPAR) == (lcr & ~UART_LCR_SPAR))
 				return;
 			dw8250_force_idle(p);
diff --git a/drivers/tty/serial/8250/8250_exar_st16c554.c b/drivers/tty/serial/8250/8250_exar_st16c554.c
index bf53aab..999f2d3 100644
--- a/drivers/tty/serial/8250/8250_exar_st16c554.c
+++ b/drivers/tty/serial/8250/8250_exar_st16c554.c
@@ -13,7 +13,7 @@
 #include <linux/init.h>
 #include <linux/serial_8250.h>
 
-#define PORT(_base,_irq)				\
+#define PORT(_base, _irq)				\
 	{						\
 		.iobase		= _base,		\
 		.irq		= _irq,			\
diff --git a/drivers/tty/serial/8250/8250_fourport.c b/drivers/tty/serial/8250/8250_fourport.c
index be15826..9a04a8a 100644
--- a/drivers/tty/serial/8250/8250_fourport.c
+++ b/drivers/tty/serial/8250/8250_fourport.c
@@ -10,7 +10,7 @@
 #include <linux/init.h>
 #include <linux/serial_8250.h>
 
-#define PORT(_base,_irq)						\
+#define PORT(_base, _irq)						\
 	{								\
 		.iobase		= _base,				\
 		.irq		= _irq,					\
diff --git a/drivers/tty/serial/8250/8250_hp300.c b/drivers/tty/serial/8250/8250_hp300.c
index 2891958..38d8cb2 100644
--- a/drivers/tty/serial/8250/8250_hp300.c
+++ b/drivers/tty/serial/8250/8250_hp300.c
@@ -125,6 +125,7 @@ int __init hp300_setup_serial_console(void)
 	} else {
 #ifdef CONFIG_HPDCA
 		unsigned long pa = dio_scodetophysaddr(scode);
+
 		if (!pa)
 			return 0;
 
diff --git a/drivers/tty/serial/8250/8250_hub6.c b/drivers/tty/serial/8250/8250_hub6.c
index a5c778e..27124e2 100644
--- a/drivers/tty/serial/8250/8250_hub6.c
+++ b/drivers/tty/serial/8250/8250_hub6.c
@@ -10,7 +10,7 @@
 #include <linux/init.h>
 #include <linux/serial_8250.h>
 
-#define HUB6(card,port)							\
+#define HUB6(card, port)						\
 	{								\
 		.iobase		= 0x302,				\
 		.irq		= 3,					\
diff --git a/drivers/tty/serial/8250/8250_pci.c b/drivers/tty/serial/8250/8250_pci.c
index 4097f3f..ed99fdf 100644
--- a/drivers/tty/serial/8250/8250_pci.c
+++ b/drivers/tty/serial/8250/8250_pci.c
@@ -113,6 +113,7 @@ static int addidata_apci7800_setup(struct serial_private *priv,
 				struct uart_8250_port *port, int idx)
 {
 	unsigned int bar = 0, offset = board->first_offset;
+
 	bar = FL_GET_BASE(board->flags);
 
 	if (idx < 2) {
@@ -1115,6 +1116,7 @@ static struct quatech_feature quatech_cards[] = {
 static int pci_quatech_amcc(u16 devid)
 {
 	struct quatech_feature *qf = &quatech_cards[0];
+
 	while (qf->devid) {
 		if (qf->devid == devid)
 			return qf->amcc;
@@ -1200,6 +1202,7 @@ static int pci_quatech_test(struct uart_8250_port *port)
 {
 	u8 reg;
 	u8 qopr = pci_quatech_rqopr(port);
+
 	pci_quatech_wqopr(port, qopr & QPCR_TEST_FOR1);
 	reg = pci_quatech_rqopr(port) & 0xC0;
 	if (reg != QPCR_TEST_GET1)
@@ -1284,8 +1287,10 @@ static int pci_quatech_init(struct pci_dev *dev)
 {
 	if (pci_quatech_amcc(dev->device)) {
 		unsigned long base = pci_resource_start(dev, 0);
+
 		if (base) {
 			u32 tmp;
+
 			outl(inl(base + 0x38) | 0x00002000, base + 0x38);
 			tmp = inl(base + 0x3c);
 			outl(tmp | 0x01000000, base + 0x3c);
@@ -4502,7 +4507,7 @@ static struct pci_device_id serial_pci_tbl[] = {
 		PCI_ANY_ID, PCI_ANY_ID, 0, 0,
 		pbn_b0_bt_2_921600 },
 	{	PCI_VENDOR_ID_OXSEMI, PCI_DEVICE_ID_OXSEMI_16PCI958,
-		PCI_ANY_ID , PCI_ANY_ID, 0, 0,
+		PCI_ANY_ID, PCI_ANY_ID, 0, 0,
 		pbn_b2_8_1152000 },
 
 	/*
diff --git a/drivers/tty/serial/8250/8250_port.c b/drivers/tty/serial/8250/8250_port.c
index 52d82d2..ae8f993 100644
--- a/drivers/tty/serial/8250/8250_port.c
+++ b/drivers/tty/serial/8250/8250_port.c
@@ -1327,6 +1327,7 @@ static void serial8250_start_tx(struct uart_port *port)
 
 		if (up->bugs & UART_BUG_TXEN) {
 			unsigned char lsr;
+
 			lsr = serial_in(up, UART_LSR);
 			up->lsr_saved_flags |= lsr & LSR_SAVE_FLAGS;
 			if (lsr & UART_LSR_THRE)
@@ -1734,8 +1735,10 @@ static void wait_for_xmitr(struct uart_8250_port *up, int bits)
 	/* Wait up to 1s for flow control if necessary */
 	if (up->port.flags & UPF_CONS_FLOW) {
 		unsigned int tmout;
+
 		for (tmout = 1000000; tmout; tmout--) {
 			unsigned int msr = serial_in(up, UART_MSR);
+
 			up->msr_saved_flags |= msr & MSR_SAVE_FLAGS;
 			if (msr & UART_MSR_CTS)
 				break;
diff --git a/drivers/tty/serial/8250/serial_cs.c b/drivers/tty/serial/8250/serial_cs.c
index 4d180c9..f5270ba 100644
--- a/drivers/tty/serial/8250/serial_cs.c
+++ b/drivers/tty/serial/8250/serial_cs.c
@@ -257,7 +257,7 @@ static const struct serial_quirk quirks[] = {
 };
 
 
-static int serial_config(struct pcmcia_device * link);
+static int serial_config(struct pcmcia_device *link);
 
 
 static void serial_remove(struct pcmcia_device *link)
@@ -309,7 +309,7 @@ static int serial_probe(struct pcmcia_device *link)
 	dev_dbg(&link->dev, "serial_attach()\n");
 
 	/* Create new serial device */
-	info = kzalloc(sizeof (*info), GFP_KERNEL);
+	info = kzalloc(sizeof(*info), GFP_KERNEL);
 	if (!info)
 		return -ENOMEM;
 	info->p_dev = link;
@@ -339,7 +339,7 @@ static void serial_detach(struct pcmcia_device *link)
 
 /*====================================================================*/
 
-static int setup_serial(struct pcmcia_device *handle, struct serial_info * info,
+static int setup_serial(struct pcmcia_device *handle, struct serial_info *info,
 			unsigned int iobase, int irq)
 {
 	struct uart_8250_port uart;
@@ -600,7 +600,7 @@ static int serial_check_for_multi(struct pcmcia_device *p_dev,  void *priv_data)
 }
 
 
-static int serial_config(struct pcmcia_device * link)
+static int serial_config(struct pcmcia_device *link)
 {
 	struct serial_info *info = link->priv;
 	int i;
@@ -701,7 +701,7 @@ static const struct pcmcia_device_id serial_ids[] = {
 	PCMCIA_PFC_DEVICE_PROD_ID12(1, "LINKSYS", "PCMLM336", 0xf7cb0b07, 0x7a821b58),
 	PCMCIA_PFC_DEVICE_PROD_ID12(1, "MEGAHERTZ", "XJEM1144/CCEM1144", 0xf510db04, 0x52d21e1e),
 	PCMCIA_PFC_DEVICE_PROD_ID12(1, "MICRO RESEARCH", "COMBO-L/M-336", 0xb2ced065, 0x3ced0555),
-	PCMCIA_PFC_DEVICE_PROD_ID12(1, "NEC", "PK-UG-J001" ,0x18df0ba0 ,0x831b1064),
+	PCMCIA_PFC_DEVICE_PROD_ID12(1, "NEC", "PK-UG-J001", 0x18df0ba0, 0x831b1064),
 	PCMCIA_PFC_DEVICE_PROD_ID12(1, "Ositech", "Trumpcard:Jack of Diamonds Modem+Ethernet", 0xc2f80cd, 0x656947b9),
 	PCMCIA_PFC_DEVICE_PROD_ID12(1, "Ositech", "Trumpcard:Jack of Hearts Modem+Ethernet", 0xc2f80cd, 0xdc9ba5ed),
 	PCMCIA_PFC_DEVICE_PROD_ID12(1, "PCMCIAs", "ComboCard", 0xdcfe12d3, 0xcd8906cc),
@@ -797,30 +797,30 @@ static const struct pcmcia_device_id serial_ids[] = {
 	PCMCIA_DEVICE_CIS_PROD_ID123("ADVANTECH", "COMpad-32/85", "1.0", 0x96913a85, 0x8fbe92ae, 0x0877b627, "cis/COMpad2.cis"),
 	PCMCIA_DEVICE_CIS_PROD_ID2("RS-COM 2P", 0xad20b156, "cis/RS-COM-2P.cis"),
 	PCMCIA_DEVICE_CIS_MANF_CARD(0x0013, 0x0000, "cis/GLOBETROTTER.cis"),
-	PCMCIA_DEVICE_PROD_ID12("ELAN DIGITAL SYSTEMS LTD, c1997.","SERIAL CARD: SL100  1.00.",0x19ca78af,0xf964f42b),
-	PCMCIA_DEVICE_PROD_ID12("ELAN DIGITAL SYSTEMS LTD, c1997.","SERIAL CARD: SL100",0x19ca78af,0x71d98e83),
-	PCMCIA_DEVICE_PROD_ID12("ELAN DIGITAL SYSTEMS LTD, c1997.","SERIAL CARD: SL232  1.00.",0x19ca78af,0x69fb7490),
-	PCMCIA_DEVICE_PROD_ID12("ELAN DIGITAL SYSTEMS LTD, c1997.","SERIAL CARD: SL232",0x19ca78af,0xb6bc0235),
-	PCMCIA_DEVICE_PROD_ID12("ELAN DIGITAL SYSTEMS LTD, c2000.","SERIAL CARD: CF232",0x63f2e0bd,0xb9e175d3),
-	PCMCIA_DEVICE_PROD_ID12("ELAN DIGITAL SYSTEMS LTD, c2000.","SERIAL CARD: CF232-5",0x63f2e0bd,0xfce33442),
-	PCMCIA_DEVICE_PROD_ID12("Elan","Serial Port: CF232",0x3beb8cf2,0x171e7190),
-	PCMCIA_DEVICE_PROD_ID12("Elan","Serial Port: CF232-5",0x3beb8cf2,0x20da4262),
-	PCMCIA_DEVICE_PROD_ID12("Elan","Serial Port: CF428",0x3beb8cf2,0xea5dd57d),
-	PCMCIA_DEVICE_PROD_ID12("Elan","Serial Port: CF500",0x3beb8cf2,0xd77255fa),
-	PCMCIA_DEVICE_PROD_ID12("Elan","Serial Port: IC232",0x3beb8cf2,0x6a709903),
-	PCMCIA_DEVICE_PROD_ID12("Elan","Serial Port: SL232",0x3beb8cf2,0x18430676),
-	PCMCIA_DEVICE_PROD_ID12("Elan","Serial Port: XL232",0x3beb8cf2,0x6f933767),
-	PCMCIA_MFC_DEVICE_PROD_ID12(0,"Elan","Serial Port: CF332",0x3beb8cf2,0x16dc1ba7),
-	PCMCIA_MFC_DEVICE_PROD_ID12(0,"Elan","Serial Port: SL332",0x3beb8cf2,0x19816c41),
-	PCMCIA_MFC_DEVICE_PROD_ID12(0,"Elan","Serial Port: SL385",0x3beb8cf2,0x64112029),
-	PCMCIA_MFC_DEVICE_PROD_ID12(0,"Elan","Serial Port: SL432",0x3beb8cf2,0x1cce7ac4),
-	PCMCIA_MFC_DEVICE_PROD_ID12(0,"Elan","Serial+Parallel Port: SP230",0x3beb8cf2,0xdb9e58bc),
-	PCMCIA_MFC_DEVICE_PROD_ID12(1,"Elan","Serial Port: CF332",0x3beb8cf2,0x16dc1ba7),
-	PCMCIA_MFC_DEVICE_PROD_ID12(1,"Elan","Serial Port: SL332",0x3beb8cf2,0x19816c41),
-	PCMCIA_MFC_DEVICE_PROD_ID12(1,"Elan","Serial Port: SL385",0x3beb8cf2,0x64112029),
-	PCMCIA_MFC_DEVICE_PROD_ID12(1,"Elan","Serial Port: SL432",0x3beb8cf2,0x1cce7ac4),
-	PCMCIA_MFC_DEVICE_PROD_ID12(2,"Elan","Serial Port: SL432",0x3beb8cf2,0x1cce7ac4),
-	PCMCIA_MFC_DEVICE_PROD_ID12(3,"Elan","Serial Port: SL432",0x3beb8cf2,0x1cce7ac4),
+	PCMCIA_DEVICE_PROD_ID12("ELAN DIGITAL SYSTEMS LTD, c1997.", "SERIAL CARD: SL100  1.00.", 0x19ca78af, 0xf964f42b),
+	PCMCIA_DEVICE_PROD_ID12("ELAN DIGITAL SYSTEMS LTD, c1997.", "SERIAL CARD: SL100", 0x19ca78af, 0x71d98e83),
+	PCMCIA_DEVICE_PROD_ID12("ELAN DIGITAL SYSTEMS LTD, c1997.", "SERIAL CARD: SL232  1.00.", 0x19ca78af, 0x69fb7490),
+	PCMCIA_DEVICE_PROD_ID12("ELAN DIGITAL SYSTEMS LTD, c1997.", "SERIAL CARD: SL232", 0x19ca78af, 0xb6bc0235),
+	PCMCIA_DEVICE_PROD_ID12("ELAN DIGITAL SYSTEMS LTD, c2000.", "SERIAL CARD: CF232", 0x63f2e0bd, 0xb9e175d3),
+	PCMCIA_DEVICE_PROD_ID12("ELAN DIGITAL SYSTEMS LTD, c2000.", "SERIAL CARD: CF232-5", 0x63f2e0bd, 0xfce33442),
+	PCMCIA_DEVICE_PROD_ID12("Elan", "Serial Port: CF232", 0x3beb8cf2, 0x171e7190),
+	PCMCIA_DEVICE_PROD_ID12("Elan", "Serial Port: CF232-5", 0x3beb8cf2, 0x20da4262),
+	PCMCIA_DEVICE_PROD_ID12("Elan", "Serial Port: CF428", 0x3beb8cf2, 0xea5dd57d),
+	PCMCIA_DEVICE_PROD_ID12("Elan", "Serial Port: CF500", 0x3beb8cf2, 0xd77255fa),
+	PCMCIA_DEVICE_PROD_ID12("Elan", "Serial Port: IC232", 0x3beb8cf2, 0x6a709903),
+	PCMCIA_DEVICE_PROD_ID12("Elan", "Serial Port: SL232", 0x3beb8cf2, 0x18430676),
+	PCMCIA_DEVICE_PROD_ID12("Elan", "Serial Port: XL232", 0x3beb8cf2, 0x6f933767),
+	PCMCIA_MFC_DEVICE_PROD_ID12(0, "Elan", "Serial Port: CF332", 0x3beb8cf2, 0x16dc1ba7),
+	PCMCIA_MFC_DEVICE_PROD_ID12(0, "Elan", "Serial Port: SL332", 0x3beb8cf2, 0x19816c41),
+	PCMCIA_MFC_DEVICE_PROD_ID12(0, "Elan", "Serial Port: SL385", 0x3beb8cf2, 0x64112029),
+	PCMCIA_MFC_DEVICE_PROD_ID12(0, "Elan", "Serial Port: SL432", 0x3beb8cf2, 0x1cce7ac4),
+	PCMCIA_MFC_DEVICE_PROD_ID12(0, "Elan", "Serial+Parallel Port: SP230", 0x3beb8cf2, 0xdb9e58bc),
+	PCMCIA_MFC_DEVICE_PROD_ID12(1, "Elan", "Serial Port: CF332", 0x3beb8cf2, 0x16dc1ba7),
+	PCMCIA_MFC_DEVICE_PROD_ID12(1, "Elan", "Serial Port: SL332", 0x3beb8cf2, 0x19816c41),
+	PCMCIA_MFC_DEVICE_PROD_ID12(1, "Elan", "Serial Port: SL385", 0x3beb8cf2, 0x64112029),
+	PCMCIA_MFC_DEVICE_PROD_ID12(1, "Elan", "Serial Port: SL432", 0x3beb8cf2, 0x1cce7ac4),
+	PCMCIA_MFC_DEVICE_PROD_ID12(2, "Elan", "Serial Port: SL432", 0x3beb8cf2, 0x1cce7ac4),
+	PCMCIA_MFC_DEVICE_PROD_ID12(3, "Elan", "Serial Port: SL432", 0x3beb8cf2, 0x1cce7ac4),
 	PCMCIA_DEVICE_MANF_CARD(0x0279, 0x950b),
 	/* too generic */
 	/* PCMCIA_MFC_DEVICE_MANF_CARD(0, 0x0160, 0x0002), */
-- 
1.9.1

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

* [PATCH 02/11] tty: serial: 8250: Fix indentation warnings
  2015-12-16 15:36 ` Anton Wuerfel
  (?)
@ 2015-12-16 15:36   ` Anton Wuerfel
  -1 siblings, 0 replies; 60+ messages in thread
From: Anton Wuerfel @ 2015-12-16 15:36 UTC (permalink / raw)
  To: linux-serial
  Cc: Greg Kroah-Hartman, Jiri Slaby, James E.J. Bottomley,
	Helge Deller, Peter Hurley, Heikki Krogerus, Andy Shevchenko,
	Qipeng Zha, Desmond Liu, Wang Long, Matt Redfearn, Paul Burton,
	Ralf Baechle, Krzysztof Kozlowski, Peter Hung, Soeren Grunewald,
	Adam Lee, Maciej S. Szmigiero, Mans Rullgard, linux-kernel,
	linux-parisc, linux-kernel, Anton Wuerfel

Checkpatch complains about incorrect indentation of switch/case stateme=
nts.
This patch fixes the corresponding warnings. Additionally some indentat=
ion
is changed to match the correct format specified in the Linux Kernel
Coding Style.

Signed-off-by: Anton W=C3=BCrfel <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_pci.c  | 31 +++++++++++++++--------------=
--
 drivers/tty/serial/8250/8250_pnp.c  |  4 ++--
 drivers/tty/serial/8250/8250_port.c | 14 +++++++-------
 3 files changed, 24 insertions(+), 25 deletions(-)

diff --git a/drivers/tty/serial/8250/8250_pci.c b/drivers/tty/serial/82=
50/8250_pci.c
index ed99fdf..41508a5 100644
--- a/drivers/tty/serial/8250/8250_pci.c
+++ b/drivers/tty/serial/8250/8250_pci.c
@@ -722,7 +722,7 @@ static int pci_ni8430_init(struct pci_dev *dev)
 	 */
 	pcibios_resource_to_bus(dev->bus, &region, &dev->resource[bar]);
 	device_window =3D ((region.start + MITE_IOWBSR1_WIN_OFFSET) & 0xfffff=
f00)
-	                | MITE_IOWBSR1_WENAB | MITE_IOWBSR1_WSIZE;
+			| MITE_IOWBSR1_WENAB | MITE_IOWBSR1_WSIZE;
 	writel(device_window, p + MITE_IOWBSR1);
=20
 	/* Set window access to go to RAMSEL IO address space */
@@ -843,17 +843,16 @@ static int pci_netmos_init(struct pci_dev *dev)
 		return 0;
=20
 	switch (dev->device) { /* FALLTHROUGH on all */
-		case PCI_DEVICE_ID_NETMOS_9904:
-		case PCI_DEVICE_ID_NETMOS_9912:
-		case PCI_DEVICE_ID_NETMOS_9922:
-		case PCI_DEVICE_ID_NETMOS_9900:
-			num_serial =3D pci_netmos_9900_numports(dev);
-			break;
+	case PCI_DEVICE_ID_NETMOS_9904:
+	case PCI_DEVICE_ID_NETMOS_9912:
+	case PCI_DEVICE_ID_NETMOS_9922:
+	case PCI_DEVICE_ID_NETMOS_9900:
+		num_serial =3D pci_netmos_9900_numports(dev);
+		break;
=20
-		default:
-			if (num_serial =3D=3D 0 ) {
-				moan_device("unknown NetMos/Mostech device", dev);
-			}
+	default:
+		if (num_serial =3D=3D 0)
+			moan_device("unknown NetMos/Mostech device", dev);
 	}
=20
 	if (num_serial =3D=3D 0)
@@ -1766,7 +1765,7 @@ xr17v35x_has_slave(struct serial_private *priv)
 	const int dev_id =3D priv->dev->device;
=20
 	return ((dev_id =3D=3D PCI_DEVICE_ID_EXAR_XR17V4358) ||
-	        (dev_id =3D=3D PCI_DEVICE_ID_EXAR_XR17V8358));
+		(dev_id =3D=3D PCI_DEVICE_ID_EXAR_XR17V8358));
 }
=20
 static int
@@ -1866,8 +1865,8 @@ pci_fastcom335_setup(struct serial_private *priv,
=20
 static int
 pci_wch_ch353_setup(struct serial_private *priv,
-                    const struct pciserial_board *board,
-                    struct uart_8250_port *port, int idx)
+		    const struct pciserial_board *board,
+		    struct uart_8250_port *port, int idx)
 {
 	port->port.flags |=3D UPF_FIXED_TYPE;
 	port->port.type =3D PORT_16550A;
@@ -1876,8 +1875,8 @@ pci_wch_ch353_setup(struct serial_private *priv,
=20
 static int
 pci_wch_ch38x_setup(struct serial_private *priv,
-                    const struct pciserial_board *board,
-                    struct uart_8250_port *port, int idx)
+		    const struct pciserial_board *board,
+		    struct uart_8250_port *port, int idx)
 {
 	port->port.flags |=3D UPF_FIXED_TYPE;
 	port->port.type =3D PORT_16850;
diff --git a/drivers/tty/serial/8250/8250_pnp.c b/drivers/tty/serial/82=
50/8250_pnp.c
index 658b392..1f18065 100644
--- a/drivers/tty/serial/8250/8250_pnp.c
+++ b/drivers/tty/serial/8250/8250_pnp.c
@@ -425,8 +425,8 @@ static int check_resources(struct pnp_dev *dev)
 static int serial_pnp_guess_board(struct pnp_dev *dev)
 {
 	if (!(check_name(pnp_dev_name(dev)) ||
-		(dev->card && check_name(dev->card->name))))
-			return -ENODEV;
+	    (dev->card && check_name(dev->card->name))))
+		return -ENODEV;
=20
 	if (check_resources(dev))
 		return 0;
diff --git a/drivers/tty/serial/8250/8250_port.c b/drivers/tty/serial/8=
250/8250_port.c
index ae8f993..57ad0f2 100644
--- a/drivers/tty/serial/8250/8250_port.c
+++ b/drivers/tty/serial/8250/8250_port.c
@@ -52,7 +52,7 @@
 #define DEBUG_AUTOCONF(fmt...)	do { } while (0)
 #endif
=20
-#define BOTH_EMPTY 	(UART_LSR_TEMT | UART_LSR_THRE)
+#define BOTH_EMPTY	(UART_LSR_TEMT | UART_LSR_THRE)
=20
 /*
  * Here we define the default xmit fifo size used for each type of UAR=
T.
@@ -2236,9 +2236,9 @@ static void serial8250_set_divisor(struct uart_po=
rt *port, unsigned int baud,
 		serial_port_out(port, 0x2, quot_frac);
 }
=20
-static unsigned int
-serial8250_get_baud_rate(struct uart_port *port, struct ktermios *term=
ios,
-			 struct ktermios *old)
+static unsigned int serial8250_get_baud_rate(struct uart_port *port,
+					     struct ktermios *termios,
+					     struct ktermios *old)
 {
 	unsigned int tolerance =3D port->uartclk / 100;
=20
@@ -2253,9 +2253,9 @@ serial8250_get_baud_rate(struct uart_port *port, =
struct ktermios *termios,
 				  (port->uartclk + tolerance) / 16);
 }
=20
-void
-serial8250_do_set_termios(struct uart_port *port, struct ktermios *ter=
mios,
-		          struct ktermios *old)
+void serial8250_do_set_termios(struct uart_port *port,
+			       struct ktermios *termios,
+			       struct ktermios *old)
 {
 	struct uart_8250_port *up =3D up_to_u8250p(port);
 	unsigned char cval;
--=20
1.9.1

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

* [PATCH 02/11] tty: serial: 8250: Fix indentation warnings
@ 2015-12-16 15:36   ` Anton Wuerfel
  0 siblings, 0 replies; 60+ messages in thread
From: Anton Wuerfel @ 2015-12-16 15:36 UTC (permalink / raw)
  To: linux-serial
  Cc: Greg Kroah-Hartman, Jiri Slaby, James E.J. Bottomley,
	Helge Deller, Peter Hurley, Heikki Krogerus, Andy Shevchenko,
	Qipeng Zha, Desmond Liu, Wang Long, Matt Redfearn, Paul Burton,
	Ralf Baechle, Krzysztof Kozlowski, Peter Hung, Soeren Grunewald,
	Adam Lee, Maciej S. Szmigiero, Mans Rullgard, linux-kernel,
	linux-parisc, linux-kernel, Anton Wuerfel, Phillip Raffeck

Checkpatch complains about incorrect indentation of switch/case statements.
This patch fixes the corresponding warnings. Additionally some indentation
is changed to match the correct format specified in the Linux Kernel
Coding Style.

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_pci.c  | 31 +++++++++++++++----------------
 drivers/tty/serial/8250/8250_pnp.c  |  4 ++--
 drivers/tty/serial/8250/8250_port.c | 14 +++++++-------
 3 files changed, 24 insertions(+), 25 deletions(-)

diff --git a/drivers/tty/serial/8250/8250_pci.c b/drivers/tty/serial/8250/8250_pci.c
index ed99fdf..41508a5 100644
--- a/drivers/tty/serial/8250/8250_pci.c
+++ b/drivers/tty/serial/8250/8250_pci.c
@@ -722,7 +722,7 @@ static int pci_ni8430_init(struct pci_dev *dev)
 	 */
 	pcibios_resource_to_bus(dev->bus, &region, &dev->resource[bar]);
 	device_window = ((region.start + MITE_IOWBSR1_WIN_OFFSET) & 0xffffff00)
-	                | MITE_IOWBSR1_WENAB | MITE_IOWBSR1_WSIZE;
+			| MITE_IOWBSR1_WENAB | MITE_IOWBSR1_WSIZE;
 	writel(device_window, p + MITE_IOWBSR1);
 
 	/* Set window access to go to RAMSEL IO address space */
@@ -843,17 +843,16 @@ static int pci_netmos_init(struct pci_dev *dev)
 		return 0;
 
 	switch (dev->device) { /* FALLTHROUGH on all */
-		case PCI_DEVICE_ID_NETMOS_9904:
-		case PCI_DEVICE_ID_NETMOS_9912:
-		case PCI_DEVICE_ID_NETMOS_9922:
-		case PCI_DEVICE_ID_NETMOS_9900:
-			num_serial = pci_netmos_9900_numports(dev);
-			break;
+	case PCI_DEVICE_ID_NETMOS_9904:
+	case PCI_DEVICE_ID_NETMOS_9912:
+	case PCI_DEVICE_ID_NETMOS_9922:
+	case PCI_DEVICE_ID_NETMOS_9900:
+		num_serial = pci_netmos_9900_numports(dev);
+		break;
 
-		default:
-			if (num_serial == 0 ) {
-				moan_device("unknown NetMos/Mostech device", dev);
-			}
+	default:
+		if (num_serial == 0)
+			moan_device("unknown NetMos/Mostech device", dev);
 	}
 
 	if (num_serial == 0)
@@ -1766,7 +1765,7 @@ xr17v35x_has_slave(struct serial_private *priv)
 	const int dev_id = priv->dev->device;
 
 	return ((dev_id == PCI_DEVICE_ID_EXAR_XR17V4358) ||
-	        (dev_id == PCI_DEVICE_ID_EXAR_XR17V8358));
+		(dev_id == PCI_DEVICE_ID_EXAR_XR17V8358));
 }
 
 static int
@@ -1866,8 +1865,8 @@ pci_fastcom335_setup(struct serial_private *priv,
 
 static int
 pci_wch_ch353_setup(struct serial_private *priv,
-                    const struct pciserial_board *board,
-                    struct uart_8250_port *port, int idx)
+		    const struct pciserial_board *board,
+		    struct uart_8250_port *port, int idx)
 {
 	port->port.flags |= UPF_FIXED_TYPE;
 	port->port.type = PORT_16550A;
@@ -1876,8 +1875,8 @@ pci_wch_ch353_setup(struct serial_private *priv,
 
 static int
 pci_wch_ch38x_setup(struct serial_private *priv,
-                    const struct pciserial_board *board,
-                    struct uart_8250_port *port, int idx)
+		    const struct pciserial_board *board,
+		    struct uart_8250_port *port, int idx)
 {
 	port->port.flags |= UPF_FIXED_TYPE;
 	port->port.type = PORT_16850;
diff --git a/drivers/tty/serial/8250/8250_pnp.c b/drivers/tty/serial/8250/8250_pnp.c
index 658b392..1f18065 100644
--- a/drivers/tty/serial/8250/8250_pnp.c
+++ b/drivers/tty/serial/8250/8250_pnp.c
@@ -425,8 +425,8 @@ static int check_resources(struct pnp_dev *dev)
 static int serial_pnp_guess_board(struct pnp_dev *dev)
 {
 	if (!(check_name(pnp_dev_name(dev)) ||
-		(dev->card && check_name(dev->card->name))))
-			return -ENODEV;
+	    (dev->card && check_name(dev->card->name))))
+		return -ENODEV;
 
 	if (check_resources(dev))
 		return 0;
diff --git a/drivers/tty/serial/8250/8250_port.c b/drivers/tty/serial/8250/8250_port.c
index ae8f993..57ad0f2 100644
--- a/drivers/tty/serial/8250/8250_port.c
+++ b/drivers/tty/serial/8250/8250_port.c
@@ -52,7 +52,7 @@
 #define DEBUG_AUTOCONF(fmt...)	do { } while (0)
 #endif
 
-#define BOTH_EMPTY 	(UART_LSR_TEMT | UART_LSR_THRE)
+#define BOTH_EMPTY	(UART_LSR_TEMT | UART_LSR_THRE)
 
 /*
  * Here we define the default xmit fifo size used for each type of UART.
@@ -2236,9 +2236,9 @@ static void serial8250_set_divisor(struct uart_port *port, unsigned int baud,
 		serial_port_out(port, 0x2, quot_frac);
 }
 
-static unsigned int
-serial8250_get_baud_rate(struct uart_port *port, struct ktermios *termios,
-			 struct ktermios *old)
+static unsigned int serial8250_get_baud_rate(struct uart_port *port,
+					     struct ktermios *termios,
+					     struct ktermios *old)
 {
 	unsigned int tolerance = port->uartclk / 100;
 
@@ -2253,9 +2253,9 @@ serial8250_get_baud_rate(struct uart_port *port, struct ktermios *termios,
 				  (port->uartclk + tolerance) / 16);
 }
 
-void
-serial8250_do_set_termios(struct uart_port *port, struct ktermios *termios,
-		          struct ktermios *old)
+void serial8250_do_set_termios(struct uart_port *port,
+			       struct ktermios *termios,
+			       struct ktermios *old)
 {
 	struct uart_8250_port *up = up_to_u8250p(port);
 	unsigned char cval;
-- 
1.9.1


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

* [PATCH 02/11] tty: serial: 8250: Fix indentation warnings
@ 2015-12-16 15:36   ` Anton Wuerfel
  0 siblings, 0 replies; 60+ messages in thread
From: Anton Wuerfel @ 2015-12-16 15:36 UTC (permalink / raw)
  To: linux-serial
  Cc: Greg Kroah-Hartman, Jiri Slaby, James E.J. Bottomley,
	Helge Deller, Peter Hurley, Heikki Krogerus, Andy Shevchenko,
	Qipeng Zha, Desmond Liu, Wang Long, Matt Redfearn, Paul Burton,
	Ralf Baechle, Krzysztof Kozlowski, Peter Hung, Soeren Grunewald,
	Adam Lee, Maciej S. Szmigiero, Mans Rullgard, linux-kernel,
	linux-parisc, linux-kernel, Anton Wuerfel

Checkpatch complains about incorrect indentation of switch/case statements.
This patch fixes the corresponding warnings. Additionally some indentation
is changed to match the correct format specified in the Linux Kernel
Coding Style.

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_pci.c  | 31 +++++++++++++++----------------
 drivers/tty/serial/8250/8250_pnp.c  |  4 ++--
 drivers/tty/serial/8250/8250_port.c | 14 +++++++-------
 3 files changed, 24 insertions(+), 25 deletions(-)

diff --git a/drivers/tty/serial/8250/8250_pci.c b/drivers/tty/serial/8250/8250_pci.c
index ed99fdf..41508a5 100644
--- a/drivers/tty/serial/8250/8250_pci.c
+++ b/drivers/tty/serial/8250/8250_pci.c
@@ -722,7 +722,7 @@ static int pci_ni8430_init(struct pci_dev *dev)
 	 */
 	pcibios_resource_to_bus(dev->bus, &region, &dev->resource[bar]);
 	device_window = ((region.start + MITE_IOWBSR1_WIN_OFFSET) & 0xffffff00)
-	                | MITE_IOWBSR1_WENAB | MITE_IOWBSR1_WSIZE;
+			| MITE_IOWBSR1_WENAB | MITE_IOWBSR1_WSIZE;
 	writel(device_window, p + MITE_IOWBSR1);
 
 	/* Set window access to go to RAMSEL IO address space */
@@ -843,17 +843,16 @@ static int pci_netmos_init(struct pci_dev *dev)
 		return 0;
 
 	switch (dev->device) { /* FALLTHROUGH on all */
-		case PCI_DEVICE_ID_NETMOS_9904:
-		case PCI_DEVICE_ID_NETMOS_9912:
-		case PCI_DEVICE_ID_NETMOS_9922:
-		case PCI_DEVICE_ID_NETMOS_9900:
-			num_serial = pci_netmos_9900_numports(dev);
-			break;
+	case PCI_DEVICE_ID_NETMOS_9904:
+	case PCI_DEVICE_ID_NETMOS_9912:
+	case PCI_DEVICE_ID_NETMOS_9922:
+	case PCI_DEVICE_ID_NETMOS_9900:
+		num_serial = pci_netmos_9900_numports(dev);
+		break;
 
-		default:
-			if (num_serial == 0 ) {
-				moan_device("unknown NetMos/Mostech device", dev);
-			}
+	default:
+		if (num_serial == 0)
+			moan_device("unknown NetMos/Mostech device", dev);
 	}
 
 	if (num_serial == 0)
@@ -1766,7 +1765,7 @@ xr17v35x_has_slave(struct serial_private *priv)
 	const int dev_id = priv->dev->device;
 
 	return ((dev_id == PCI_DEVICE_ID_EXAR_XR17V4358) ||
-	        (dev_id == PCI_DEVICE_ID_EXAR_XR17V8358));
+		(dev_id == PCI_DEVICE_ID_EXAR_XR17V8358));
 }
 
 static int
@@ -1866,8 +1865,8 @@ pci_fastcom335_setup(struct serial_private *priv,
 
 static int
 pci_wch_ch353_setup(struct serial_private *priv,
-                    const struct pciserial_board *board,
-                    struct uart_8250_port *port, int idx)
+		    const struct pciserial_board *board,
+		    struct uart_8250_port *port, int idx)
 {
 	port->port.flags |= UPF_FIXED_TYPE;
 	port->port.type = PORT_16550A;
@@ -1876,8 +1875,8 @@ pci_wch_ch353_setup(struct serial_private *priv,
 
 static int
 pci_wch_ch38x_setup(struct serial_private *priv,
-                    const struct pciserial_board *board,
-                    struct uart_8250_port *port, int idx)
+		    const struct pciserial_board *board,
+		    struct uart_8250_port *port, int idx)
 {
 	port->port.flags |= UPF_FIXED_TYPE;
 	port->port.type = PORT_16850;
diff --git a/drivers/tty/serial/8250/8250_pnp.c b/drivers/tty/serial/8250/8250_pnp.c
index 658b392..1f18065 100644
--- a/drivers/tty/serial/8250/8250_pnp.c
+++ b/drivers/tty/serial/8250/8250_pnp.c
@@ -425,8 +425,8 @@ static int check_resources(struct pnp_dev *dev)
 static int serial_pnp_guess_board(struct pnp_dev *dev)
 {
 	if (!(check_name(pnp_dev_name(dev)) ||
-		(dev->card && check_name(dev->card->name))))
-			return -ENODEV;
+	    (dev->card && check_name(dev->card->name))))
+		return -ENODEV;
 
 	if (check_resources(dev))
 		return 0;
diff --git a/drivers/tty/serial/8250/8250_port.c b/drivers/tty/serial/8250/8250_port.c
index ae8f993..57ad0f2 100644
--- a/drivers/tty/serial/8250/8250_port.c
+++ b/drivers/tty/serial/8250/8250_port.c
@@ -52,7 +52,7 @@
 #define DEBUG_AUTOCONF(fmt...)	do { } while (0)
 #endif
 
-#define BOTH_EMPTY 	(UART_LSR_TEMT | UART_LSR_THRE)
+#define BOTH_EMPTY	(UART_LSR_TEMT | UART_LSR_THRE)
 
 /*
  * Here we define the default xmit fifo size used for each type of UART.
@@ -2236,9 +2236,9 @@ static void serial8250_set_divisor(struct uart_port *port, unsigned int baud,
 		serial_port_out(port, 0x2, quot_frac);
 }
 
-static unsigned int
-serial8250_get_baud_rate(struct uart_port *port, struct ktermios *termios,
-			 struct ktermios *old)
+static unsigned int serial8250_get_baud_rate(struct uart_port *port,
+					     struct ktermios *termios,
+					     struct ktermios *old)
 {
 	unsigned int tolerance = port->uartclk / 100;
 
@@ -2253,9 +2253,9 @@ serial8250_get_baud_rate(struct uart_port *port, struct ktermios *termios,
 				  (port->uartclk + tolerance) / 16);
 }
 
-void
-serial8250_do_set_termios(struct uart_port *port, struct ktermios *termios,
-		          struct ktermios *old)
+void serial8250_do_set_termios(struct uart_port *port,
+			       struct ktermios *termios,
+			       struct ktermios *old)
 {
 	struct uart_8250_port *up = up_to_u8250p(port);
 	unsigned char cval;
-- 
1.9.1

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

* [PATCH 03/11] tty: serial: 8250: Fix braces after struct
  2015-12-16 15:36 ` Anton Wuerfel
  (?)
@ 2015-12-16 15:36   ` Anton Wuerfel
  -1 siblings, 0 replies; 60+ messages in thread
From: Anton Wuerfel @ 2015-12-16 15:36 UTC (permalink / raw)
  To: linux-serial
  Cc: Greg Kroah-Hartman, Jiri Slaby, James E.J. Bottomley,
	Helge Deller, Peter Hurley, Heikki Krogerus, Andy Shevchenko,
	Qipeng Zha, Desmond Liu, Wang Long, Matt Redfearn, Paul Burton,
	Ralf Baechle, Krzysztof Kozlowski, Peter Hung, Soeren Grunewald,
	Adam Lee, Maciej S. Szmigiero, Mans Rullgard, linux-kernel,
	linux-parisc, linux-kernel, Anton Wuerfel

This patch fixes a checkpatch warning by moving an opening  curly brace
to its correct position

Signed-off-by: Anton W=C3=BCrfel <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_hp300.c | 3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)

diff --git a/drivers/tty/serial/8250/8250_hp300.c b/drivers/tty/serial/=
8250/8250_hp300.c
index 38d8cb2..694b509 100644
--- a/drivers/tty/serial/8250/8250_hp300.c
+++ b/drivers/tty/serial/8250/8250_hp300.c
@@ -24,8 +24,7 @@
 #endif
=20
 #ifdef CONFIG_HPAPCI
-struct hp300_port
-{
+struct hp300_port {
 	struct hp300_port *next;	/* next port */
 	int line;			/* line (tty) number */
 };
--=20
1.9.1

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

* [PATCH 03/11] tty: serial: 8250: Fix braces after struct
@ 2015-12-16 15:36   ` Anton Wuerfel
  0 siblings, 0 replies; 60+ messages in thread
From: Anton Wuerfel @ 2015-12-16 15:36 UTC (permalink / raw)
  To: linux-serial
  Cc: Greg Kroah-Hartman, Jiri Slaby, James E.J. Bottomley,
	Helge Deller, Peter Hurley, Heikki Krogerus, Andy Shevchenko,
	Qipeng Zha, Desmond Liu, Wang Long, Matt Redfearn, Paul Burton,
	Ralf Baechle, Krzysztof Kozlowski, Peter Hung, Soeren Grunewald,
	Adam Lee, Maciej S. Szmigiero, Mans Rullgard, linux-kernel,
	linux-parisc, linux-kernel, Anton Wuerfel, Phillip Raffeck

This patch fixes a checkpatch warning by moving an opening  curly brace
to its correct position

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_hp300.c | 3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)

diff --git a/drivers/tty/serial/8250/8250_hp300.c b/drivers/tty/serial/8250/8250_hp300.c
index 38d8cb2..694b509 100644
--- a/drivers/tty/serial/8250/8250_hp300.c
+++ b/drivers/tty/serial/8250/8250_hp300.c
@@ -24,8 +24,7 @@
 #endif
 
 #ifdef CONFIG_HPAPCI
-struct hp300_port
-{
+struct hp300_port {
 	struct hp300_port *next;	/* next port */
 	int line;			/* line (tty) number */
 };
-- 
1.9.1


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

* [PATCH 03/11] tty: serial: 8250: Fix braces after struct
@ 2015-12-16 15:36   ` Anton Wuerfel
  0 siblings, 0 replies; 60+ messages in thread
From: Anton Wuerfel @ 2015-12-16 15:36 UTC (permalink / raw)
  To: linux-serial
  Cc: Greg Kroah-Hartman, Jiri Slaby, James E.J. Bottomley,
	Helge Deller, Peter Hurley, Heikki Krogerus, Andy Shevchenko,
	Qipeng Zha, Desmond Liu, Wang Long, Matt Redfearn, Paul Burton,
	Ralf Baechle, Krzysztof Kozlowski, Peter Hung, Soeren Grunewald,
	Adam Lee, Maciej S. Szmigiero, Mans Rullgard, linux-kernel,
	linux-parisc, linux-kernel, Anton Wuerfel

This patch fixes a checkpatch warning by moving an opening  curly brace
to its correct position

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_hp300.c | 3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)

diff --git a/drivers/tty/serial/8250/8250_hp300.c b/drivers/tty/serial/8250/8250_hp300.c
index 38d8cb2..694b509 100644
--- a/drivers/tty/serial/8250/8250_hp300.c
+++ b/drivers/tty/serial/8250/8250_hp300.c
@@ -24,8 +24,7 @@
 #endif
 
 #ifdef CONFIG_HPAPCI
-struct hp300_port
-{
+struct hp300_port {
 	struct hp300_port *next;	/* next port */
 	int line;			/* line (tty) number */
 };
-- 
1.9.1

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

* [PATCH 04/11] tty: serial: 8250: Fix multiline comment style
  2015-12-16 15:36 ` Anton Wuerfel
  (?)
@ 2015-12-16 15:36   ` Anton Wuerfel
  -1 siblings, 0 replies; 60+ messages in thread
From: Anton Wuerfel @ 2015-12-16 15:36 UTC (permalink / raw)
  To: linux-serial
  Cc: Greg Kroah-Hartman, Jiri Slaby, James E.J. Bottomley,
	Helge Deller, Peter Hurley, Heikki Krogerus, Andy Shevchenko,
	Qipeng Zha, Desmond Liu, Wang Long, Matt Redfearn, Paul Burton,
	Ralf Baechle, Krzysztof Kozlowski, Peter Hung, Soeren Grunewald,
	Adam Lee, Maciej S. Szmigiero, Mans Rullgard, linux-kernel,
	linux-parisc, linux-kernel, Anton Wuerfel

Checkpatch outputs some warnings about incorrect comment style,
which is fixed by this patch.

Signed-off-by: Anton W=C3=BCrfel <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_ingenic.c |  6 ++-
 drivers/tty/serial/8250/8250_pnp.c     |  6 ++-
 drivers/tty/serial/8250/8250_port.c    | 29 ++++++-----
 drivers/tty/serial/8250/serial_cs.c    | 92 +++++++++++++++++++-------=
--------
 4 files changed, 75 insertions(+), 58 deletions(-)

diff --git a/drivers/tty/serial/8250/8250_ingenic.c b/drivers/tty/seria=
l/8250/8250_ingenic.c
index 49394b4..c53d2501 100644
--- a/drivers/tty/serial/8250/8250_ingenic.c
+++ b/drivers/tty/serial/8250/8250_ingenic.c
@@ -153,13 +153,15 @@ static void ingenic_uart_serial_out(struct uart_p=
ort *p, int offset, int value)
=20
 	case UART_IER:
 		/* Enable receive timeout interrupt with the
-		 * receive line status interrupt */
+		 * receive line status interrupt
+		 */
 		value |=3D (value & 0x4) << 2;
 		break;
=20
 	case UART_MCR:
 		/* If we have enabled modem status IRQs we should enable modem
-		 * mode. */
+		 * mode.
+		 */
 		ier =3D p->serial_in(p, UART_IER);
=20
 		if (ier & UART_IER_MSI)
diff --git a/drivers/tty/serial/8250/8250_pnp.c b/drivers/tty/serial/82=
50/8250_pnp.c
index 1f18065..2731031 100644
--- a/drivers/tty/serial/8250/8250_pnp.c
+++ b/drivers/tty/serial/8250/8250_pnp.c
@@ -367,8 +367,10 @@ static const struct pnp_device_id pnp_dev_table[] =
=3D {
 	{	"PNPCXXX",		UNKNOWN_DEV	},
 	/* More unknown PnP modems */
 	{	"PNPDXXX",		UNKNOWN_DEV	},
-	/* Winbond CIR port, should not be probed. We should keep track
-	   of it to prevent the legacy serial driver from probing it */
+	/*
+	 * Winbond CIR port, should not be probed. We should keep track
+	 * of it to prevent the legacy serial driver from probing it
+	 */
 	{	"WEC1022",		CIR_PORT	},
 	/*
 	 * SMSC IrCC SIR/FIR port, should not be probed by serial driver
diff --git a/drivers/tty/serial/8250/8250_port.c b/drivers/tty/serial/8=
250/8250_port.c
index 57ad0f2..0ec823e 100644
--- a/drivers/tty/serial/8250/8250_port.c
+++ b/drivers/tty/serial/8250/8250_port.c
@@ -250,9 +250,11 @@ static const struct serial8250_config uart_config[=
] =3D {
 		.fcr		=3D UART_FCR_ENABLE_FIFO | UART_FCR_R_TRIG_10,
 		.flags		=3D UART_CAP_FIFO | UART_CAP_AFE,
 	},
-/* tx_loadsz is set to 63-bytes instead of 64-bytes to implement
-workaround of errata A-008006 which states that tx_loadsz should  be
-configured less than Maximum supported fifo bytes */
+	/*
+	 * tx_loadsz is set to 63-bytes instead of 64-bytes to implement
+	 * workaround of errata A-008006 which states that tx_loadsz should b=
e
+	 * configured less than Maximum supported fifo bytes
+	 */
 	[PORT_16550A_FSL64] =3D {
 		.name		=3D "16550A_FSL64",
 		.fifo_size	=3D 64,
@@ -1970,16 +1972,17 @@ int serial8250_do_startup(struct uart_port *por=
t)
=20
 	serial8250_set_mctrl(port, port->mctrl);
=20
-	/* Serial over Lan (SoL) hack:
-	   Intel 8257x Gigabit ethernet chips have a
-	   16550 emulation, to be used for Serial Over Lan.
-	   Those chips take a longer time than a normal
-	   serial device to signalize that a transmission
-	   data was queued. Due to that, the above test generally
-	   fails. One solution would be to delay the reading of
-	   iir. However, this is not reliable, since the timeout
-	   is variable. So, let's just don't test if we receive
-	   TX irq. This way, we'll never enable UART_BUG_TXEN.
+	/*
+	 * Serial over Lan (SoL) hack:
+	 * Intel 8257x Gigabit ethernet chips have a
+	 * 16550 emulation, to be used for Serial Over Lan.
+	 * Those chips take a longer time than a normal
+	 * serial device to signalize that a transmission
+	 * data was queued. Due to that, the above test generally
+	 * fails. One solution would be to delay the reading of
+	 * iir. However, this is not reliable, since the timeout
+	 * is variable. So, let's just don't test if we receive
+	 * TX irq. This way, we'll never enable UART_BUG_TXEN.
 	 */
 	if (up->port.flags & UPF_NO_TXEN_TEST)
 		goto dont_test_tx_en;
diff --git a/drivers/tty/serial/8250/serial_cs.c b/drivers/tty/serial/8=
250/serial_cs.c
index f5270ba..a4bdcf6 100644
--- a/drivers/tty/serial/8250/serial_cs.c
+++ b/drivers/tty/serial/8250/serial_cs.c
@@ -1,35 +1,37 @@
-/*=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D
-
-    A driver for PCMCIA serial devices
-
-    serial_cs.c 1.134 2002/05/04 05:48:53
-
-    The contents of this file are subject to the Mozilla Public
-    License Version 1.1 (the "License"); you may not use this file
-    except in compliance with the License. You may obtain a copy of
-    the License at http://www.mozilla.org/MPL/
-
-    Software distributed under the License is distributed on an "AS
-    IS" basis, WITHOUT WARRANTY OF ANY KIND, either express or
-    implied. See the License for the specific language governing
-    rights and limitations under the License.
-
-    The initial developer of the original code is David A. Hinds
-    <dahinds@users.sourceforge.net>.  Portions created by David A. Hin=
ds
-    are Copyright (C) 1999 David A. Hinds.  All Rights Reserved.
-
-    Alternatively, the contents of this file may be used under the
-    terms of the GNU General Public License version 2 (the "GPL"), in =
which
-    case the provisions of the GPL are applicable instead of the
-    above.  If you wish to allow the use of your version of this file
-    only under the terms of the GPL and not to allow others to use
-    your version of this file under the MPL, indicate your decision
-    by deleting the provisions above and replace them with the notice
-    and other provisions required by the GPL.  If you do not delete
-    the provisions above, a recipient may use your version of this
-    file under either the MPL or the GPL.
-   =20
-=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D*/
+/*
+ * =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D
+ *
+ * A driver for PCMCIA serial devices
+ *
+ * serial_cs.c 1.134 2002/05/04 05:48:53
+ *
+ * The contents of this file are subject to the Mozilla Public
+ * License Version 1.1 (the "License"); you may not use this file
+ * except in compliance with the License. You may obtain a copy of
+ * the License at http://www.mozilla.org/MPL/
+ *
+ * Software distributed under the License is distributed on an "AS
+ * IS" basis, WITHOUT WARRANTY OF ANY KIND, either express or
+ * implied. See the License for the specific language governing
+ * rights and limitations under the License.
+ *
+ * The initial developer of the original code is David A. Hinds
+ * <dahinds@users.sourceforge.net>.  Portions created by David A. Hind=
s
+ * are Copyright (C) 1999 David A. Hinds.  All Rights Reserved.
+ *
+ * Alternatively, the contents of this file may be used under the
+ * terms of the GNU General Public License version 2 (the "GPL"), in w=
hich
+ * case the provisions of the GPL are applicable instead of the
+ * above.  If you wish to allow the use of your version of this file
+ * only under the terms of the GPL and not to allow others to use
+ * your version of this file under the MPL, indicate your decision
+ * by deleting the provisions above and replace them with the notice
+ * and other provisions required by the GPL.  If you do not delete
+ * the provisions above, a recipient may use your version of this
+ * file under either the MPL or the GPL.
+ *
+ * =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D
+ */
=20
 #include <linux/module.h>
 #include <linux/moduleparam.h>
@@ -441,16 +443,20 @@ static int simple_config(struct pcmcia_device *li=
nk)
 	struct serial_info *info =3D link->priv;
 	int i =3D -ENODEV, try;
=20
-	/* First pass: look for a config entry that looks normal.
-	 * Two tries: without IO aliases, then with aliases */
+	/*
+	 * First pass: look for a config entry that looks normal.
+	 * Two tries: without IO aliases, then with aliases
+	 */
 	link->config_flags |=3D CONF_AUTO_SET_VPP;
 	for (try =3D 0; try < 4; try++)
 		if (!pcmcia_loop_config(link, simple_config_check, &try))
 			goto found_port;
=20
-	/* Second pass: try to find an entry that isn't picky about
-	   its base address, then try to grab any standard serial port
-	   address, and finally try to get any free port. */
+	/*
+	 * Second pass: try to find an entry that isn't picky about
+	 * its base address, then try to grab any standard serial port
+	 * address, and finally try to get any free port.
+	 */
 	if (!pcmcia_loop_config(link, simple_config_check_notpicky, NULL))
 		goto found_port;
=20
@@ -480,8 +486,10 @@ static int multi_config_check(struct pcmcia_device=
 *p_dev, void *priv_data)
 	if (p_dev->resource[1]->end)
 		return -EINVAL;
=20
-	/* The quad port cards have bad CIS's, so just look for a
-	   window larger than 8 ports and assume it will be right */
+	/*
+	 * The quad port cards have bad CIS's, so just look for a
+	 * window larger than 8 ports and assume it will be right
+	 */
 	if (p_dev->resource[0]->end <=3D 8)
 		return -EINVAL;
=20
@@ -623,8 +631,10 @@ static int serial_config(struct pcmcia_device *lin=
k)
 			break;
 		}
=20
-	/* Another check for dual-serial cards: look for either serial or
-	   multifunction cards that ask for appropriate IO port ranges */
+	/*
+	 * Another check for dual-serial cards: look for either serial or
+	 * multifunction cards that ask for appropriate IO port ranges
+	 */
 	if ((info->multi =3D=3D 0) &&
 	    (link->has_func_id) &&
 	    (link->socket->pcmcia_pfc =3D=3D 0) &&
--=20
1.9.1

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

* [PATCH 04/11] tty: serial: 8250: Fix multiline comment style
@ 2015-12-16 15:36   ` Anton Wuerfel
  0 siblings, 0 replies; 60+ messages in thread
From: Anton Wuerfel @ 2015-12-16 15:36 UTC (permalink / raw)
  To: linux-serial
  Cc: Greg Kroah-Hartman, Jiri Slaby, James E.J. Bottomley,
	Helge Deller, Peter Hurley, Heikki Krogerus, Andy Shevchenko,
	Qipeng Zha, Desmond Liu, Wang Long, Matt Redfearn, Paul Burton,
	Ralf Baechle, Krzysztof Kozlowski, Peter Hung, Soeren Grunewald,
	Adam Lee, Maciej S. Szmigiero, Mans Rullgard, linux-kernel,
	linux-parisc, linux-kernel, Anton Wuerfel, Phillip Raffeck

Checkpatch outputs some warnings about incorrect comment style,
which is fixed by this patch.

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_ingenic.c |  6 ++-
 drivers/tty/serial/8250/8250_pnp.c     |  6 ++-
 drivers/tty/serial/8250/8250_port.c    | 29 ++++++-----
 drivers/tty/serial/8250/serial_cs.c    | 92 +++++++++++++++++++---------------
 4 files changed, 75 insertions(+), 58 deletions(-)

diff --git a/drivers/tty/serial/8250/8250_ingenic.c b/drivers/tty/serial/8250/8250_ingenic.c
index 49394b4..c53d2501 100644
--- a/drivers/tty/serial/8250/8250_ingenic.c
+++ b/drivers/tty/serial/8250/8250_ingenic.c
@@ -153,13 +153,15 @@ static void ingenic_uart_serial_out(struct uart_port *p, int offset, int value)
 
 	case UART_IER:
 		/* Enable receive timeout interrupt with the
-		 * receive line status interrupt */
+		 * receive line status interrupt
+		 */
 		value |= (value & 0x4) << 2;
 		break;
 
 	case UART_MCR:
 		/* If we have enabled modem status IRQs we should enable modem
-		 * mode. */
+		 * mode.
+		 */
 		ier = p->serial_in(p, UART_IER);
 
 		if (ier & UART_IER_MSI)
diff --git a/drivers/tty/serial/8250/8250_pnp.c b/drivers/tty/serial/8250/8250_pnp.c
index 1f18065..2731031 100644
--- a/drivers/tty/serial/8250/8250_pnp.c
+++ b/drivers/tty/serial/8250/8250_pnp.c
@@ -367,8 +367,10 @@ static const struct pnp_device_id pnp_dev_table[] = {
 	{	"PNPCXXX",		UNKNOWN_DEV	},
 	/* More unknown PnP modems */
 	{	"PNPDXXX",		UNKNOWN_DEV	},
-	/* Winbond CIR port, should not be probed. We should keep track
-	   of it to prevent the legacy serial driver from probing it */
+	/*
+	 * Winbond CIR port, should not be probed. We should keep track
+	 * of it to prevent the legacy serial driver from probing it
+	 */
 	{	"WEC1022",		CIR_PORT	},
 	/*
 	 * SMSC IrCC SIR/FIR port, should not be probed by serial driver
diff --git a/drivers/tty/serial/8250/8250_port.c b/drivers/tty/serial/8250/8250_port.c
index 57ad0f2..0ec823e 100644
--- a/drivers/tty/serial/8250/8250_port.c
+++ b/drivers/tty/serial/8250/8250_port.c
@@ -250,9 +250,11 @@ static const struct serial8250_config uart_config[] = {
 		.fcr		= UART_FCR_ENABLE_FIFO | UART_FCR_R_TRIG_10,
 		.flags		= UART_CAP_FIFO | UART_CAP_AFE,
 	},
-/* tx_loadsz is set to 63-bytes instead of 64-bytes to implement
-workaround of errata A-008006 which states that tx_loadsz should  be
-configured less than Maximum supported fifo bytes */
+	/*
+	 * tx_loadsz is set to 63-bytes instead of 64-bytes to implement
+	 * workaround of errata A-008006 which states that tx_loadsz should be
+	 * configured less than Maximum supported fifo bytes
+	 */
 	[PORT_16550A_FSL64] = {
 		.name		= "16550A_FSL64",
 		.fifo_size	= 64,
@@ -1970,16 +1972,17 @@ int serial8250_do_startup(struct uart_port *port)
 
 	serial8250_set_mctrl(port, port->mctrl);
 
-	/* Serial over Lan (SoL) hack:
-	   Intel 8257x Gigabit ethernet chips have a
-	   16550 emulation, to be used for Serial Over Lan.
-	   Those chips take a longer time than a normal
-	   serial device to signalize that a transmission
-	   data was queued. Due to that, the above test generally
-	   fails. One solution would be to delay the reading of
-	   iir. However, this is not reliable, since the timeout
-	   is variable. So, let's just don't test if we receive
-	   TX irq. This way, we'll never enable UART_BUG_TXEN.
+	/*
+	 * Serial over Lan (SoL) hack:
+	 * Intel 8257x Gigabit ethernet chips have a
+	 * 16550 emulation, to be used for Serial Over Lan.
+	 * Those chips take a longer time than a normal
+	 * serial device to signalize that a transmission
+	 * data was queued. Due to that, the above test generally
+	 * fails. One solution would be to delay the reading of
+	 * iir. However, this is not reliable, since the timeout
+	 * is variable. So, let's just don't test if we receive
+	 * TX irq. This way, we'll never enable UART_BUG_TXEN.
 	 */
 	if (up->port.flags & UPF_NO_TXEN_TEST)
 		goto dont_test_tx_en;
diff --git a/drivers/tty/serial/8250/serial_cs.c b/drivers/tty/serial/8250/serial_cs.c
index f5270ba..a4bdcf6 100644
--- a/drivers/tty/serial/8250/serial_cs.c
+++ b/drivers/tty/serial/8250/serial_cs.c
@@ -1,35 +1,37 @@
-/*======================================================================
-
-    A driver for PCMCIA serial devices
-
-    serial_cs.c 1.134 2002/05/04 05:48:53
-
-    The contents of this file are subject to the Mozilla Public
-    License Version 1.1 (the "License"); you may not use this file
-    except in compliance with the License. You may obtain a copy of
-    the License at http://www.mozilla.org/MPL/
-
-    Software distributed under the License is distributed on an "AS
-    IS" basis, WITHOUT WARRANTY OF ANY KIND, either express or
-    implied. See the License for the specific language governing
-    rights and limitations under the License.
-
-    The initial developer of the original code is David A. Hinds
-    <dahinds@users.sourceforge.net>.  Portions created by David A. Hinds
-    are Copyright (C) 1999 David A. Hinds.  All Rights Reserved.
-
-    Alternatively, the contents of this file may be used under the
-    terms of the GNU General Public License version 2 (the "GPL"), in which
-    case the provisions of the GPL are applicable instead of the
-    above.  If you wish to allow the use of your version of this file
-    only under the terms of the GPL and not to allow others to use
-    your version of this file under the MPL, indicate your decision
-    by deleting the provisions above and replace them with the notice
-    and other provisions required by the GPL.  If you do not delete
-    the provisions above, a recipient may use your version of this
-    file under either the MPL or the GPL.
-    
-======================================================================*/
+/*
+ * ======================================================================
+ *
+ * A driver for PCMCIA serial devices
+ *
+ * serial_cs.c 1.134 2002/05/04 05:48:53
+ *
+ * The contents of this file are subject to the Mozilla Public
+ * License Version 1.1 (the "License"); you may not use this file
+ * except in compliance with the License. You may obtain a copy of
+ * the License at http://www.mozilla.org/MPL/
+ *
+ * Software distributed under the License is distributed on an "AS
+ * IS" basis, WITHOUT WARRANTY OF ANY KIND, either express or
+ * implied. See the License for the specific language governing
+ * rights and limitations under the License.
+ *
+ * The initial developer of the original code is David A. Hinds
+ * <dahinds@users.sourceforge.net>.  Portions created by David A. Hinds
+ * are Copyright (C) 1999 David A. Hinds.  All Rights Reserved.
+ *
+ * Alternatively, the contents of this file may be used under the
+ * terms of the GNU General Public License version 2 (the "GPL"), in which
+ * case the provisions of the GPL are applicable instead of the
+ * above.  If you wish to allow the use of your version of this file
+ * only under the terms of the GPL and not to allow others to use
+ * your version of this file under the MPL, indicate your decision
+ * by deleting the provisions above and replace them with the notice
+ * and other provisions required by the GPL.  If you do not delete
+ * the provisions above, a recipient may use your version of this
+ * file under either the MPL or the GPL.
+ *
+ * ======================================================================
+ */
 
 #include <linux/module.h>
 #include <linux/moduleparam.h>
@@ -441,16 +443,20 @@ static int simple_config(struct pcmcia_device *link)
 	struct serial_info *info = link->priv;
 	int i = -ENODEV, try;
 
-	/* First pass: look for a config entry that looks normal.
-	 * Two tries: without IO aliases, then with aliases */
+	/*
+	 * First pass: look for a config entry that looks normal.
+	 * Two tries: without IO aliases, then with aliases
+	 */
 	link->config_flags |= CONF_AUTO_SET_VPP;
 	for (try = 0; try < 4; try++)
 		if (!pcmcia_loop_config(link, simple_config_check, &try))
 			goto found_port;
 
-	/* Second pass: try to find an entry that isn't picky about
-	   its base address, then try to grab any standard serial port
-	   address, and finally try to get any free port. */
+	/*
+	 * Second pass: try to find an entry that isn't picky about
+	 * its base address, then try to grab any standard serial port
+	 * address, and finally try to get any free port.
+	 */
 	if (!pcmcia_loop_config(link, simple_config_check_notpicky, NULL))
 		goto found_port;
 
@@ -480,8 +486,10 @@ static int multi_config_check(struct pcmcia_device *p_dev, void *priv_data)
 	if (p_dev->resource[1]->end)
 		return -EINVAL;
 
-	/* The quad port cards have bad CIS's, so just look for a
-	   window larger than 8 ports and assume it will be right */
+	/*
+	 * The quad port cards have bad CIS's, so just look for a
+	 * window larger than 8 ports and assume it will be right
+	 */
 	if (p_dev->resource[0]->end <= 8)
 		return -EINVAL;
 
@@ -623,8 +631,10 @@ static int serial_config(struct pcmcia_device *link)
 			break;
 		}
 
-	/* Another check for dual-serial cards: look for either serial or
-	   multifunction cards that ask for appropriate IO port ranges */
+	/*
+	 * Another check for dual-serial cards: look for either serial or
+	 * multifunction cards that ask for appropriate IO port ranges
+	 */
 	if ((info->multi == 0) &&
 	    (link->has_func_id) &&
 	    (link->socket->pcmcia_pfc == 0) &&
-- 
1.9.1


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

* [PATCH 04/11] tty: serial: 8250: Fix multiline comment style
@ 2015-12-16 15:36   ` Anton Wuerfel
  0 siblings, 0 replies; 60+ messages in thread
From: Anton Wuerfel @ 2015-12-16 15:36 UTC (permalink / raw)
  To: linux-serial
  Cc: Greg Kroah-Hartman, Jiri Slaby, James E.J. Bottomley,
	Helge Deller, Peter Hurley, Heikki Krogerus, Andy Shevchenko,
	Qipeng Zha, Desmond Liu, Wang Long, Matt Redfearn, Paul Burton,
	Ralf Baechle, Krzysztof Kozlowski, Peter Hung, Soeren Grunewald,
	Adam Lee, Maciej S. Szmigiero, Mans Rullgard, linux-kernel,
	linux-parisc, linux-kernel, Anton Wuerfel

Checkpatch outputs some warnings about incorrect comment style,
which is fixed by this patch.

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_ingenic.c |  6 ++-
 drivers/tty/serial/8250/8250_pnp.c     |  6 ++-
 drivers/tty/serial/8250/8250_port.c    | 29 ++++++-----
 drivers/tty/serial/8250/serial_cs.c    | 92 +++++++++++++++++++---------------
 4 files changed, 75 insertions(+), 58 deletions(-)

diff --git a/drivers/tty/serial/8250/8250_ingenic.c b/drivers/tty/serial/8250/8250_ingenic.c
index 49394b4..c53d2501 100644
--- a/drivers/tty/serial/8250/8250_ingenic.c
+++ b/drivers/tty/serial/8250/8250_ingenic.c
@@ -153,13 +153,15 @@ static void ingenic_uart_serial_out(struct uart_port *p, int offset, int value)
 
 	case UART_IER:
 		/* Enable receive timeout interrupt with the
-		 * receive line status interrupt */
+		 * receive line status interrupt
+		 */
 		value |= (value & 0x4) << 2;
 		break;
 
 	case UART_MCR:
 		/* If we have enabled modem status IRQs we should enable modem
-		 * mode. */
+		 * mode.
+		 */
 		ier = p->serial_in(p, UART_IER);
 
 		if (ier & UART_IER_MSI)
diff --git a/drivers/tty/serial/8250/8250_pnp.c b/drivers/tty/serial/8250/8250_pnp.c
index 1f18065..2731031 100644
--- a/drivers/tty/serial/8250/8250_pnp.c
+++ b/drivers/tty/serial/8250/8250_pnp.c
@@ -367,8 +367,10 @@ static const struct pnp_device_id pnp_dev_table[] = {
 	{	"PNPCXXX",		UNKNOWN_DEV	},
 	/* More unknown PnP modems */
 	{	"PNPDXXX",		UNKNOWN_DEV	},
-	/* Winbond CIR port, should not be probed. We should keep track
-	   of it to prevent the legacy serial driver from probing it */
+	/*
+	 * Winbond CIR port, should not be probed. We should keep track
+	 * of it to prevent the legacy serial driver from probing it
+	 */
 	{	"WEC1022",		CIR_PORT	},
 	/*
 	 * SMSC IrCC SIR/FIR port, should not be probed by serial driver
diff --git a/drivers/tty/serial/8250/8250_port.c b/drivers/tty/serial/8250/8250_port.c
index 57ad0f2..0ec823e 100644
--- a/drivers/tty/serial/8250/8250_port.c
+++ b/drivers/tty/serial/8250/8250_port.c
@@ -250,9 +250,11 @@ static const struct serial8250_config uart_config[] = {
 		.fcr		= UART_FCR_ENABLE_FIFO | UART_FCR_R_TRIG_10,
 		.flags		= UART_CAP_FIFO | UART_CAP_AFE,
 	},
-/* tx_loadsz is set to 63-bytes instead of 64-bytes to implement
-workaround of errata A-008006 which states that tx_loadsz should  be
-configured less than Maximum supported fifo bytes */
+	/*
+	 * tx_loadsz is set to 63-bytes instead of 64-bytes to implement
+	 * workaround of errata A-008006 which states that tx_loadsz should be
+	 * configured less than Maximum supported fifo bytes
+	 */
 	[PORT_16550A_FSL64] = {
 		.name		= "16550A_FSL64",
 		.fifo_size	= 64,
@@ -1970,16 +1972,17 @@ int serial8250_do_startup(struct uart_port *port)
 
 	serial8250_set_mctrl(port, port->mctrl);
 
-	/* Serial over Lan (SoL) hack:
-	   Intel 8257x Gigabit ethernet chips have a
-	   16550 emulation, to be used for Serial Over Lan.
-	   Those chips take a longer time than a normal
-	   serial device to signalize that a transmission
-	   data was queued. Due to that, the above test generally
-	   fails. One solution would be to delay the reading of
-	   iir. However, this is not reliable, since the timeout
-	   is variable. So, let's just don't test if we receive
-	   TX irq. This way, we'll never enable UART_BUG_TXEN.
+	/*
+	 * Serial over Lan (SoL) hack:
+	 * Intel 8257x Gigabit ethernet chips have a
+	 * 16550 emulation, to be used for Serial Over Lan.
+	 * Those chips take a longer time than a normal
+	 * serial device to signalize that a transmission
+	 * data was queued. Due to that, the above test generally
+	 * fails. One solution would be to delay the reading of
+	 * iir. However, this is not reliable, since the timeout
+	 * is variable. So, let's just don't test if we receive
+	 * TX irq. This way, we'll never enable UART_BUG_TXEN.
 	 */
 	if (up->port.flags & UPF_NO_TXEN_TEST)
 		goto dont_test_tx_en;
diff --git a/drivers/tty/serial/8250/serial_cs.c b/drivers/tty/serial/8250/serial_cs.c
index f5270ba..a4bdcf6 100644
--- a/drivers/tty/serial/8250/serial_cs.c
+++ b/drivers/tty/serial/8250/serial_cs.c
@@ -1,35 +1,37 @@
-/*======================================================================
-
-    A driver for PCMCIA serial devices
-
-    serial_cs.c 1.134 2002/05/04 05:48:53
-
-    The contents of this file are subject to the Mozilla Public
-    License Version 1.1 (the "License"); you may not use this file
-    except in compliance with the License. You may obtain a copy of
-    the License at http://www.mozilla.org/MPL/
-
-    Software distributed under the License is distributed on an "AS
-    IS" basis, WITHOUT WARRANTY OF ANY KIND, either express or
-    implied. See the License for the specific language governing
-    rights and limitations under the License.
-
-    The initial developer of the original code is David A. Hinds
-    <dahinds@users.sourceforge.net>.  Portions created by David A. Hinds
-    are Copyright (C) 1999 David A. Hinds.  All Rights Reserved.
-
-    Alternatively, the contents of this file may be used under the
-    terms of the GNU General Public License version 2 (the "GPL"), in which
-    case the provisions of the GPL are applicable instead of the
-    above.  If you wish to allow the use of your version of this file
-    only under the terms of the GPL and not to allow others to use
-    your version of this file under the MPL, indicate your decision
-    by deleting the provisions above and replace them with the notice
-    and other provisions required by the GPL.  If you do not delete
-    the provisions above, a recipient may use your version of this
-    file under either the MPL or the GPL.
-    
-======================================================================*/
+/*
+ * ======================================================================
+ *
+ * A driver for PCMCIA serial devices
+ *
+ * serial_cs.c 1.134 2002/05/04 05:48:53
+ *
+ * The contents of this file are subject to the Mozilla Public
+ * License Version 1.1 (the "License"); you may not use this file
+ * except in compliance with the License. You may obtain a copy of
+ * the License at http://www.mozilla.org/MPL/
+ *
+ * Software distributed under the License is distributed on an "AS
+ * IS" basis, WITHOUT WARRANTY OF ANY KIND, either express or
+ * implied. See the License for the specific language governing
+ * rights and limitations under the License.
+ *
+ * The initial developer of the original code is David A. Hinds
+ * <dahinds@users.sourceforge.net>.  Portions created by David A. Hinds
+ * are Copyright (C) 1999 David A. Hinds.  All Rights Reserved.
+ *
+ * Alternatively, the contents of this file may be used under the
+ * terms of the GNU General Public License version 2 (the "GPL"), in which
+ * case the provisions of the GPL are applicable instead of the
+ * above.  If you wish to allow the use of your version of this file
+ * only under the terms of the GPL and not to allow others to use
+ * your version of this file under the MPL, indicate your decision
+ * by deleting the provisions above and replace them with the notice
+ * and other provisions required by the GPL.  If you do not delete
+ * the provisions above, a recipient may use your version of this
+ * file under either the MPL or the GPL.
+ *
+ * ======================================================================
+ */
 
 #include <linux/module.h>
 #include <linux/moduleparam.h>
@@ -441,16 +443,20 @@ static int simple_config(struct pcmcia_device *link)
 	struct serial_info *info = link->priv;
 	int i = -ENODEV, try;
 
-	/* First pass: look for a config entry that looks normal.
-	 * Two tries: without IO aliases, then with aliases */
+	/*
+	 * First pass: look for a config entry that looks normal.
+	 * Two tries: without IO aliases, then with aliases
+	 */
 	link->config_flags |= CONF_AUTO_SET_VPP;
 	for (try = 0; try < 4; try++)
 		if (!pcmcia_loop_config(link, simple_config_check, &try))
 			goto found_port;
 
-	/* Second pass: try to find an entry that isn't picky about
-	   its base address, then try to grab any standard serial port
-	   address, and finally try to get any free port. */
+	/*
+	 * Second pass: try to find an entry that isn't picky about
+	 * its base address, then try to grab any standard serial port
+	 * address, and finally try to get any free port.
+	 */
 	if (!pcmcia_loop_config(link, simple_config_check_notpicky, NULL))
 		goto found_port;
 
@@ -480,8 +486,10 @@ static int multi_config_check(struct pcmcia_device *p_dev, void *priv_data)
 	if (p_dev->resource[1]->end)
 		return -EINVAL;
 
-	/* The quad port cards have bad CIS's, so just look for a
-	   window larger than 8 ports and assume it will be right */
+	/*
+	 * The quad port cards have bad CIS's, so just look for a
+	 * window larger than 8 ports and assume it will be right
+	 */
 	if (p_dev->resource[0]->end <= 8)
 		return -EINVAL;
 
@@ -623,8 +631,10 @@ static int serial_config(struct pcmcia_device *link)
 			break;
 		}
 
-	/* Another check for dual-serial cards: look for either serial or
-	   multifunction cards that ask for appropriate IO port ranges */
+	/*
+	 * Another check for dual-serial cards: look for either serial or
+	 * multifunction cards that ask for appropriate IO port ranges
+	 */
 	if ((info->multi == 0) &&
 	    (link->has_func_id) &&
 	    (link->socket->pcmcia_pfc == 0) &&
-- 
1.9.1

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

* [PATCH 05/11] tty: serial: 8250: Remove else after return
  2015-12-16 15:36 ` Anton Wuerfel
  (?)
@ 2015-12-16 15:36   ` Anton Wuerfel
  -1 siblings, 0 replies; 60+ messages in thread
From: Anton Wuerfel @ 2015-12-16 15:36 UTC (permalink / raw)
  To: linux-serial
  Cc: Greg Kroah-Hartman, Jiri Slaby, James E.J. Bottomley,
	Helge Deller, Peter Hurley, Heikki Krogerus, Andy Shevchenko,
	Qipeng Zha, Desmond Liu, Wang Long, Matt Redfearn, Paul Burton,
	Ralf Baechle, Krzysztof Kozlowski, Peter Hung, Soeren Grunewald,
	Adam Lee, Maciej S. Szmigiero, Mans Rullgard, linux-kernel,
	linux-parisc, linux-kernel, Anton Wuerfel

This patch fixes checkpatch warnings about unnecessary else blocks afte=
r
return statements.

Signed-off-by: Anton W=C3=BCrfel <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_pci.c | 15 +++++++--------
 1 file changed, 7 insertions(+), 8 deletions(-)

diff --git a/drivers/tty/serial/8250/8250_pci.c b/drivers/tty/serial/82=
50/8250_pci.c
index 41508a5..3bc0303 100644
--- a/drivers/tty/serial/8250/8250_pci.c
+++ b/drivers/tty/serial/8250/8250_pci.c
@@ -806,10 +806,10 @@ static int pci_netmos_9900_numports(struct pci_de=
v *dev)
=20
 	pi =3D (c & 0xff);
=20
-	if (pi =3D=3D 2) {
+	if (pi =3D=3D 2)
 		return 1;
-	} else if ((pi =3D=3D 0) &&
-			   (dev->device =3D=3D PCI_DEVICE_ID_NETMOS_9900)) {
+
+	if ((pi =3D=3D 0) && (dev->device =3D=3D PCI_DEVICE_ID_NETMOS_9900)) =
{
 		/* two possibilities: 0x30ps encodes number of parallel and
 		 * serial ports, or 0x1000 indicates *something*. This is not
 		 * immediately obvious, since the 2s1p+4s configuration seems
@@ -817,12 +817,11 @@ static int pci_netmos_9900_numports(struct pci_de=
v *dev)
 		 * advertising the same function 3 as the 4s+2s1p config.
 		 */
 		sub_serports =3D dev->subsystem_device & 0xf;
-		if (sub_serports > 0) {
+		if (sub_serports > 0)
 			return sub_serports;
-		} else {
-			dev_err(&dev->dev, "NetMos/Mostech serial driver ignoring port on a=
mbiguous config.\n");
-			return 0;
-		}
+
+		dev_err(&dev->dev, "NetMos/Mostech serial driver ignoring port on am=
biguous config.\n");
+		return 0;
 	}
=20
 	moan_device("unknown NetMos/Mostech program interface", dev);
--=20
1.9.1

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

* [PATCH 05/11] tty: serial: 8250: Remove else after return
@ 2015-12-16 15:36   ` Anton Wuerfel
  0 siblings, 0 replies; 60+ messages in thread
From: Anton Wuerfel @ 2015-12-16 15:36 UTC (permalink / raw)
  To: linux-serial
  Cc: Greg Kroah-Hartman, Jiri Slaby, James E.J. Bottomley,
	Helge Deller, Peter Hurley, Heikki Krogerus, Andy Shevchenko,
	Qipeng Zha, Desmond Liu, Wang Long, Matt Redfearn, Paul Burton,
	Ralf Baechle, Krzysztof Kozlowski, Peter Hung, Soeren Grunewald,
	Adam Lee, Maciej S. Szmigiero, Mans Rullgard, linux-kernel,
	linux-parisc, linux-kernel, Anton Wuerfel, Phillip Raffeck

This patch fixes checkpatch warnings about unnecessary else blocks after
return statements.

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_pci.c | 15 +++++++--------
 1 file changed, 7 insertions(+), 8 deletions(-)

diff --git a/drivers/tty/serial/8250/8250_pci.c b/drivers/tty/serial/8250/8250_pci.c
index 41508a5..3bc0303 100644
--- a/drivers/tty/serial/8250/8250_pci.c
+++ b/drivers/tty/serial/8250/8250_pci.c
@@ -806,10 +806,10 @@ static int pci_netmos_9900_numports(struct pci_dev *dev)
 
 	pi = (c & 0xff);
 
-	if (pi == 2) {
+	if (pi == 2)
 		return 1;
-	} else if ((pi == 0) &&
-			   (dev->device == PCI_DEVICE_ID_NETMOS_9900)) {
+
+	if ((pi == 0) && (dev->device == PCI_DEVICE_ID_NETMOS_9900)) {
 		/* two possibilities: 0x30ps encodes number of parallel and
 		 * serial ports, or 0x1000 indicates *something*. This is not
 		 * immediately obvious, since the 2s1p+4s configuration seems
@@ -817,12 +817,11 @@ static int pci_netmos_9900_numports(struct pci_dev *dev)
 		 * advertising the same function 3 as the 4s+2s1p config.
 		 */
 		sub_serports = dev->subsystem_device & 0xf;
-		if (sub_serports > 0) {
+		if (sub_serports > 0)
 			return sub_serports;
-		} else {
-			dev_err(&dev->dev, "NetMos/Mostech serial driver ignoring port on ambiguous config.\n");
-			return 0;
-		}
+
+		dev_err(&dev->dev, "NetMos/Mostech serial driver ignoring port on ambiguous config.\n");
+		return 0;
 	}
 
 	moan_device("unknown NetMos/Mostech program interface", dev);
-- 
1.9.1


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

* [PATCH 05/11] tty: serial: 8250: Remove else after return
@ 2015-12-16 15:36   ` Anton Wuerfel
  0 siblings, 0 replies; 60+ messages in thread
From: Anton Wuerfel @ 2015-12-16 15:36 UTC (permalink / raw)
  To: linux-serial
  Cc: Greg Kroah-Hartman, Jiri Slaby, James E.J. Bottomley,
	Helge Deller, Peter Hurley, Heikki Krogerus, Andy Shevchenko,
	Qipeng Zha, Desmond Liu, Wang Long, Matt Redfearn, Paul Burton,
	Ralf Baechle, Krzysztof Kozlowski, Peter Hung, Soeren Grunewald,
	Adam Lee, Maciej S. Szmigiero, Mans Rullgard, linux-kernel,
	linux-parisc, linux-kernel, Anton Wuerfel

This patch fixes checkpatch warnings about unnecessary else blocks after
return statements.

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_pci.c | 15 +++++++--------
 1 file changed, 7 insertions(+), 8 deletions(-)

diff --git a/drivers/tty/serial/8250/8250_pci.c b/drivers/tty/serial/8250/8250_pci.c
index 41508a5..3bc0303 100644
--- a/drivers/tty/serial/8250/8250_pci.c
+++ b/drivers/tty/serial/8250/8250_pci.c
@@ -806,10 +806,10 @@ static int pci_netmos_9900_numports(struct pci_dev *dev)
 
 	pi = (c & 0xff);
 
-	if (pi == 2) {
+	if (pi == 2)
 		return 1;
-	} else if ((pi == 0) &&
-			   (dev->device == PCI_DEVICE_ID_NETMOS_9900)) {
+
+	if ((pi == 0) && (dev->device == PCI_DEVICE_ID_NETMOS_9900)) {
 		/* two possibilities: 0x30ps encodes number of parallel and
 		 * serial ports, or 0x1000 indicates *something*. This is not
 		 * immediately obvious, since the 2s1p+4s configuration seems
@@ -817,12 +817,11 @@ static int pci_netmos_9900_numports(struct pci_dev *dev)
 		 * advertising the same function 3 as the 4s+2s1p config.
 		 */
 		sub_serports = dev->subsystem_device & 0xf;
-		if (sub_serports > 0) {
+		if (sub_serports > 0)
 			return sub_serports;
-		} else {
-			dev_err(&dev->dev, "NetMos/Mostech serial driver ignoring port on ambiguous config.\n");
-			return 0;
-		}
+
+		dev_err(&dev->dev, "NetMos/Mostech serial driver ignoring port on ambiguous config.\n");
+		return 0;
 	}
 
 	moan_device("unknown NetMos/Mostech program interface", dev);
-- 
1.9.1

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

* [PATCH 06/11] tty: serial: 8250: Move EXPORT_SYMBOL to function
  2015-12-16 15:36 ` Anton Wuerfel
  (?)
@ 2015-12-16 15:36   ` Anton Wuerfel
  -1 siblings, 0 replies; 60+ messages in thread
From: Anton Wuerfel @ 2015-12-16 15:36 UTC (permalink / raw)
  To: linux-serial
  Cc: Greg Kroah-Hartman, Jiri Slaby, James E.J. Bottomley,
	Helge Deller, Peter Hurley, Heikki Krogerus, Andy Shevchenko,
	Qipeng Zha, Desmond Liu, Wang Long, Matt Redfearn, Paul Burton,
	Ralf Baechle, Krzysztof Kozlowski, Peter Hung, Soeren Grunewald,
	Adam Lee, Maciej S. Szmigiero, Mans Rullgard, linux-kernel,
	linux-parisc, linux-kernel, Anton Wuerfel

This patch moves EXPORT_SYMBOL macros directly after the definition of
the corresponding symbol to remove checkpatch warnings.

Signed-off-by: Anton W=C3=BCrfel <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 | 5 ++---
 1 file changed, 2 insertions(+), 3 deletions(-)

diff --git a/drivers/tty/serial/8250/8250_core.c b/drivers/tty/serial/8=
250/8250_core.c
index 89a20c9..67147b2 100644
--- a/drivers/tty/serial/8250/8250_core.c
+++ b/drivers/tty/serial/8250/8250_core.c
@@ -764,6 +764,7 @@ void serial8250_suspend_port(int line)
=20
 	uart_suspend_port(&serial8250_reg, port);
 }
+EXPORT_SYMBOL(serial8250_suspend_port);
=20
 /**
  *	serial8250_resume_port - resume one serial port
@@ -789,6 +790,7 @@ void serial8250_resume_port(int line)
 	}
 	uart_resume_port(&serial8250_reg, port);
 }
+EXPORT_SYMBOL(serial8250_resume_port);
=20
 /*
  * Register a set of serial devices attached to a platform device.  Th=
e
@@ -1168,9 +1170,6 @@ static void __exit serial8250_exit(void)
 module_init(serial8250_init);
 module_exit(serial8250_exit);
=20
-EXPORT_SYMBOL(serial8250_suspend_port);
-EXPORT_SYMBOL(serial8250_resume_port);
-
 MODULE_LICENSE("GPL");
 MODULE_DESCRIPTION("Generic 8250/16x50 serial driver");
=20
--=20
1.9.1

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

* [PATCH 06/11] tty: serial: 8250: Move EXPORT_SYMBOL to function
@ 2015-12-16 15:36   ` Anton Wuerfel
  0 siblings, 0 replies; 60+ messages in thread
From: Anton Wuerfel @ 2015-12-16 15:36 UTC (permalink / raw)
  To: linux-serial
  Cc: Greg Kroah-Hartman, Jiri Slaby, James E.J. Bottomley,
	Helge Deller, Peter Hurley, Heikki Krogerus, Andy Shevchenko,
	Qipeng Zha, Desmond Liu, Wang Long, Matt Redfearn, Paul Burton,
	Ralf Baechle, Krzysztof Kozlowski, Peter Hung, Soeren Grunewald,
	Adam Lee, Maciej S. Szmigiero, Mans Rullgard, linux-kernel,
	linux-parisc, linux-kernel, Anton Wuerfel, Phillip Raffeck

This patch moves EXPORT_SYMBOL macros directly after the definition of
the corresponding symbol to remove checkpatch warnings.

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 | 5 ++---
 1 file changed, 2 insertions(+), 3 deletions(-)

diff --git a/drivers/tty/serial/8250/8250_core.c b/drivers/tty/serial/8250/8250_core.c
index 89a20c9..67147b2 100644
--- a/drivers/tty/serial/8250/8250_core.c
+++ b/drivers/tty/serial/8250/8250_core.c
@@ -764,6 +764,7 @@ void serial8250_suspend_port(int line)
 
 	uart_suspend_port(&serial8250_reg, port);
 }
+EXPORT_SYMBOL(serial8250_suspend_port);
 
 /**
  *	serial8250_resume_port - resume one serial port
@@ -789,6 +790,7 @@ void serial8250_resume_port(int line)
 	}
 	uart_resume_port(&serial8250_reg, port);
 }
+EXPORT_SYMBOL(serial8250_resume_port);
 
 /*
  * Register a set of serial devices attached to a platform device.  The
@@ -1168,9 +1170,6 @@ static void __exit serial8250_exit(void)
 module_init(serial8250_init);
 module_exit(serial8250_exit);
 
-EXPORT_SYMBOL(serial8250_suspend_port);
-EXPORT_SYMBOL(serial8250_resume_port);
-
 MODULE_LICENSE("GPL");
 MODULE_DESCRIPTION("Generic 8250/16x50 serial driver");
 
-- 
1.9.1


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

* [PATCH 06/11] tty: serial: 8250: Move EXPORT_SYMBOL to function
@ 2015-12-16 15:36   ` Anton Wuerfel
  0 siblings, 0 replies; 60+ messages in thread
From: Anton Wuerfel @ 2015-12-16 15:36 UTC (permalink / raw)
  To: linux-serial
  Cc: Greg Kroah-Hartman, Jiri Slaby, James E.J. Bottomley,
	Helge Deller, Peter Hurley, Heikki Krogerus, Andy Shevchenko,
	Qipeng Zha, Desmond Liu, Wang Long, Matt Redfearn, Paul Burton,
	Ralf Baechle, Krzysztof Kozlowski, Peter Hung, Soeren Grunewald,
	Adam Lee, Maciej S. Szmigiero, Mans Rullgard, linux-kernel,
	linux-parisc, linux-kernel, Anton Wuerfel

This patch moves EXPORT_SYMBOL macros directly after the definition of
the corresponding symbol to remove checkpatch warnings.

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 | 5 ++---
 1 file changed, 2 insertions(+), 3 deletions(-)

diff --git a/drivers/tty/serial/8250/8250_core.c b/drivers/tty/serial/8250/8250_core.c
index 89a20c9..67147b2 100644
--- a/drivers/tty/serial/8250/8250_core.c
+++ b/drivers/tty/serial/8250/8250_core.c
@@ -764,6 +764,7 @@ void serial8250_suspend_port(int line)
 
 	uart_suspend_port(&serial8250_reg, port);
 }
+EXPORT_SYMBOL(serial8250_suspend_port);
 
 /**
  *	serial8250_resume_port - resume one serial port
@@ -789,6 +790,7 @@ void serial8250_resume_port(int line)
 	}
 	uart_resume_port(&serial8250_reg, port);
 }
+EXPORT_SYMBOL(serial8250_resume_port);
 
 /*
  * Register a set of serial devices attached to a platform device.  The
@@ -1168,9 +1170,6 @@ static void __exit serial8250_exit(void)
 module_init(serial8250_init);
 module_exit(serial8250_exit);
 
-EXPORT_SYMBOL(serial8250_suspend_port);
-EXPORT_SYMBOL(serial8250_resume_port);
-
 MODULE_LICENSE("GPL");
 MODULE_DESCRIPTION("Generic 8250/16x50 serial driver");
 
-- 
1.9.1

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

* [PATCH 07/11] tty: serial: 8250: Fix line continuation warning
  2015-12-16 15:36 ` Anton Wuerfel
  (?)
@ 2015-12-16 15:36   ` Anton Wuerfel
  -1 siblings, 0 replies; 60+ messages in thread
From: Anton Wuerfel @ 2015-12-16 15:36 UTC (permalink / raw)
  To: linux-serial
  Cc: Greg Kroah-Hartman, Jiri Slaby, James E.J. Bottomley,
	Helge Deller, Peter Hurley, Heikki Krogerus, Andy Shevchenko,
	Qipeng Zha, Desmond Liu, Wang Long, Matt Redfearn, Paul Burton,
	Ralf Baechle, Krzysztof Kozlowski, Peter Hung, Soeren Grunewald,
	Adam Lee, Maciej S. Szmigiero, Mans Rullgard, linux-kernel,
	linux-parisc, linux-kernel, Anton Wuerfel

=46ixed checkpatch warning about an unnecessary line continuation in a
multi-line variable assignment.

Signed-off-by: Anton W=C3=BCrfel <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_hp300.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/drivers/tty/serial/8250/8250_hp300.c b/drivers/tty/serial/=
8250/8250_hp300.c
index 694b509..52c43da 100644
--- a/drivers/tty/serial/8250/8250_hp300.c
+++ b/drivers/tty/serial/8250/8250_hp300.c
@@ -249,8 +249,8 @@ static int __init hp300_8250_init(void)
=20
 		/* Memory mapped I/O */
 		uart.port.iotype =3D UPIO_MEM;
-		uart.port.flags =3D UPF_SKIP_TEST | UPF_SHARE_IRQ \
-			      | UPF_BOOT_AUTOCONF;
+		uart.port.flags =3D UPF_SKIP_TEST | UPF_SHARE_IRQ
+				| UPF_BOOT_AUTOCONF;
 		/* XXX - no interrupt support yet */
 		uart.port.irq =3D 0;
 		uart.port.uartclk =3D HPAPCI_BAUD_BASE * 16;
--=20
1.9.1

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

* [PATCH 07/11] tty: serial: 8250: Fix line continuation warning
@ 2015-12-16 15:36   ` Anton Wuerfel
  0 siblings, 0 replies; 60+ messages in thread
From: Anton Wuerfel @ 2015-12-16 15:36 UTC (permalink / raw)
  To: linux-serial
  Cc: Greg Kroah-Hartman, Jiri Slaby, James E.J. Bottomley,
	Helge Deller, Peter Hurley, Heikki Krogerus, Andy Shevchenko,
	Qipeng Zha, Desmond Liu, Wang Long, Matt Redfearn, Paul Burton,
	Ralf Baechle, Krzysztof Kozlowski, Peter Hung, Soeren Grunewald,
	Adam Lee, Maciej S. Szmigiero, Mans Rullgard, linux-kernel,
	linux-parisc, linux-kernel, Anton Wuerfel, Phillip Raffeck

Fixed checkpatch warning about an unnecessary line continuation in a
multi-line variable 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_hp300.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/drivers/tty/serial/8250/8250_hp300.c b/drivers/tty/serial/8250/8250_hp300.c
index 694b509..52c43da 100644
--- a/drivers/tty/serial/8250/8250_hp300.c
+++ b/drivers/tty/serial/8250/8250_hp300.c
@@ -249,8 +249,8 @@ static int __init hp300_8250_init(void)
 
 		/* Memory mapped I/O */
 		uart.port.iotype = UPIO_MEM;
-		uart.port.flags = UPF_SKIP_TEST | UPF_SHARE_IRQ \
-			      | UPF_BOOT_AUTOCONF;
+		uart.port.flags = UPF_SKIP_TEST | UPF_SHARE_IRQ
+				| UPF_BOOT_AUTOCONF;
 		/* XXX - no interrupt support yet */
 		uart.port.irq = 0;
 		uart.port.uartclk = HPAPCI_BAUD_BASE * 16;
-- 
1.9.1


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

* [PATCH 07/11] tty: serial: 8250: Fix line continuation warning
@ 2015-12-16 15:36   ` Anton Wuerfel
  0 siblings, 0 replies; 60+ messages in thread
From: Anton Wuerfel @ 2015-12-16 15:36 UTC (permalink / raw)
  To: linux-serial
  Cc: Greg Kroah-Hartman, Jiri Slaby, James E.J. Bottomley,
	Helge Deller, Peter Hurley, Heikki Krogerus, Andy Shevchenko,
	Qipeng Zha, Desmond Liu, Wang Long, Matt Redfearn, Paul Burton,
	Ralf Baechle, Krzysztof Kozlowski, Peter Hung, Soeren Grunewald,
	Adam Lee, Maciej S. Szmigiero, Mans Rullgard, linux-kernel,
	linux-parisc, linux-kernel, Anton Wuerfel

Fixed checkpatch warning about an unnecessary line continuation in a
multi-line variable 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_hp300.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/drivers/tty/serial/8250/8250_hp300.c b/drivers/tty/serial/8250/8250_hp300.c
index 694b509..52c43da 100644
--- a/drivers/tty/serial/8250/8250_hp300.c
+++ b/drivers/tty/serial/8250/8250_hp300.c
@@ -249,8 +249,8 @@ static int __init hp300_8250_init(void)
 
 		/* Memory mapped I/O */
 		uart.port.iotype = UPIO_MEM;
-		uart.port.flags = UPF_SKIP_TEST | UPF_SHARE_IRQ \
-			      | UPF_BOOT_AUTOCONF;
+		uart.port.flags = UPF_SKIP_TEST | UPF_SHARE_IRQ
+				| UPF_BOOT_AUTOCONF;
 		/* XXX - no interrupt support yet */
 		uart.port.irq = 0;
 		uart.port.uartclk = HPAPCI_BAUD_BASE * 16;
-- 
1.9.1

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

* [PATCH 08/11] tty: serial: 8250: Add parentheses to macro
  2015-12-16 15:36 ` Anton Wuerfel
  (?)
@ 2015-12-16 15:36   ` Anton Wuerfel
  -1 siblings, 0 replies; 60+ messages in thread
From: Anton Wuerfel @ 2015-12-16 15:36 UTC (permalink / raw)
  To: linux-serial
  Cc: Greg Kroah-Hartman, Jiri Slaby, James E.J. Bottomley,
	Helge Deller, Peter Hurley, Heikki Krogerus, Andy Shevchenko,
	Qipeng Zha, Desmond Liu, Wang Long, Matt Redfearn, Paul Burton,
	Ralf Baechle, Krzysztof Kozlowski, Peter Hung, Soeren Grunewald,
	Adam Lee, Maciej S. Szmigiero, Mans Rullgard, linux-kernel,
	linux-parisc, linux-kernel, Anton Wuerfel

This patch fixes a checkpatch warning caused by missing parentheses
in the definition of a macro.

Signed-off-by: Anton W=C3=BCrfel <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 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/tty/serial/8250/8250_core.c b/drivers/tty/serial/8=
250/8250_core.c
index 67147b2..3c29530 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);
=20
-#define SERIAL8250_CONSOLE	&univ8250_console
+#define SERIAL8250_CONSOLE	(&univ8250_console)
 #else
 #define SERIAL8250_CONSOLE	NULL
 #endif
--=20
1.9.1

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

* [PATCH 08/11] tty: serial: 8250: Add parentheses to macro
@ 2015-12-16 15:36   ` Anton Wuerfel
  0 siblings, 0 replies; 60+ messages in thread
From: Anton Wuerfel @ 2015-12-16 15:36 UTC (permalink / raw)
  To: linux-serial
  Cc: Greg Kroah-Hartman, Jiri Slaby, James E.J. Bottomley,
	Helge Deller, Peter Hurley, Heikki Krogerus, Andy Shevchenko,
	Qipeng Zha, Desmond Liu, Wang Long, Matt Redfearn, Paul Burton,
	Ralf Baechle, Krzysztof Kozlowski, Peter Hung, Soeren Grunewald,
	Adam Lee, Maciej S. Szmigiero, Mans Rullgard, linux-kernel,
	linux-parisc, linux-kernel, Anton Wuerfel, Phillip Raffeck

This patch fixes a checkpatch warning caused by missing parentheses
in the definition of a macro.

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 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/tty/serial/8250/8250_core.c b/drivers/tty/serial/8250/8250_core.c
index 67147b2..3c29530 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
-- 
1.9.1


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

* [PATCH 08/11] tty: serial: 8250: Add parentheses to macro
@ 2015-12-16 15:36   ` Anton Wuerfel
  0 siblings, 0 replies; 60+ messages in thread
From: Anton Wuerfel @ 2015-12-16 15:36 UTC (permalink / raw)
  To: linux-serial
  Cc: Greg Kroah-Hartman, Jiri Slaby, James E.J. Bottomley,
	Helge Deller, Peter Hurley, Heikki Krogerus, Andy Shevchenko,
	Qipeng Zha, Desmond Liu, Wang Long, Matt Redfearn, Paul Burton,
	Ralf Baechle, Krzysztof Kozlowski, Peter Hung, Soeren Grunewald,
	Adam Lee, Maciej S. Szmigiero, Mans Rullgard, linux-kernel,
	linux-parisc, linux-kernel, Anton Wuerfel

This patch fixes a checkpatch warning caused by missing parentheses
in the definition of a macro.

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 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/tty/serial/8250/8250_core.c b/drivers/tty/serial/8250/8250_core.c
index 67147b2..3c29530 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
-- 
1.9.1

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

* [PATCH 09/11] tty: serial: 8250: Fix multi-line strings
  2015-12-16 15:36 ` Anton Wuerfel
  (?)
@ 2015-12-16 15:36   ` Anton Wuerfel
  -1 siblings, 0 replies; 60+ messages in thread
From: Anton Wuerfel @ 2015-12-16 15:36 UTC (permalink / raw)
  To: linux-serial
  Cc: Greg Kroah-Hartman, Jiri Slaby, James E.J. Bottomley,
	Helge Deller, Peter Hurley, Heikki Krogerus, Andy Shevchenko,
	Qipeng Zha, Desmond Liu, Wang Long, Matt Redfearn, Paul Burton,
	Ralf Baechle, Krzysztof Kozlowski, Peter Hung, Soeren Grunewald,
	Adam Lee, Maciej S. Szmigiero, Mans Rullgard, linux-kernel,
	linux-parisc, linux-kernel, Anton Wuerfel

Merged user-visible multi-line strings into a single line according to =
the
Linux Kernel Coding Style, which allows user-visible strings to exceed =
the
maximum line length of 80 characters. The main reason for this is to
facilitate grepping for these strings.
However, some strings were ignored in this patch, because the use of
format specifiers breaks the ability to grep anyway.

Signed-off-by: Anton W=C3=BCrfel <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 | 3 +--
 drivers/tty/serial/8250/serial_cs.c | 3 +--
 2 files changed, 2 insertions(+), 4 deletions(-)

diff --git a/drivers/tty/serial/8250/8250_core.c b/drivers/tty/serial/8=
250/8250_core.c
index 3c29530..2b3731f 100644
--- a/drivers/tty/serial/8250/8250_core.c
+++ b/drivers/tty/serial/8250/8250_core.c
@@ -1174,8 +1174,7 @@ MODULE_LICENSE("GPL");
 MODULE_DESCRIPTION("Generic 8250/16x50 serial driver");
=20
 module_param(share_irqs, uint, 0644);
-MODULE_PARM_DESC(share_irqs, "Share IRQs with other non-8250/16x50 dev=
ices"
-	" (unsafe)");
+MODULE_PARM_DESC(share_irqs, "Share IRQs with other non-8250/16x50 dev=
ices (unsafe)");
=20
 module_param(nr_uarts, uint, 0644);
 MODULE_PARM_DESC(nr_uarts, "Maximum number of UARTs supported. (1-" __=
MODULE_STRING(CONFIG_SERIAL_8250_NR_UARTS) ")");
diff --git a/drivers/tty/serial/8250/serial_cs.c b/drivers/tty/serial/8=
250/serial_cs.c
index a4bdcf6..65d341d 100644
--- a/drivers/tty/serial/8250/serial_cs.c
+++ b/drivers/tty/serial/8250/serial_cs.c
@@ -535,8 +535,7 @@ static int multi_config(struct pcmcia_device *link)
 		info->multi =3D 2;
 		if (pcmcia_loop_config(link, multi_config_check_notpicky,
 				       &base2)) {
-			dev_warn(&link->dev, "no usable port range "
-			       "found, giving up\n");
+			dev_warn(&link->dev, "no usable port range found, giving up\n");
 			return -ENODEV;
 		}
 	}
--=20
1.9.1

--
To unsubscribe from this list: send the line "unsubscribe linux-parisc"=
 in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

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

* [PATCH 09/11] tty: serial: 8250: Fix multi-line strings
@ 2015-12-16 15:36   ` Anton Wuerfel
  0 siblings, 0 replies; 60+ messages in thread
From: Anton Wuerfel @ 2015-12-16 15:36 UTC (permalink / raw)
  To: linux-serial
  Cc: Greg Kroah-Hartman, Jiri Slaby, James E.J. Bottomley,
	Helge Deller, Peter Hurley, Heikki Krogerus, Andy Shevchenko,
	Qipeng Zha, Desmond Liu, Wang Long, Matt Redfearn, Paul Burton,
	Ralf Baechle, Krzysztof Kozlowski, Peter Hung, Soeren Grunewald,
	Adam Lee, Maciej S. Szmigiero, Mans Rullgard, linux-kernel,
	linux-parisc, linux-kernel, Anton Wuerfel, Phillip Raffeck

Merged user-visible multi-line strings into a single line according to the
Linux Kernel Coding Style, which allows user-visible strings to exceed the
maximum line length of 80 characters. The main reason for this is to
facilitate grepping for these strings.
However, some strings were ignored in this patch, because the use of
format specifiers breaks the ability to grep anyway.

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 | 3 +--
 drivers/tty/serial/8250/serial_cs.c | 3 +--
 2 files changed, 2 insertions(+), 4 deletions(-)

diff --git a/drivers/tty/serial/8250/8250_core.c b/drivers/tty/serial/8250/8250_core.c
index 3c29530..2b3731f 100644
--- a/drivers/tty/serial/8250/8250_core.c
+++ b/drivers/tty/serial/8250/8250_core.c
@@ -1174,8 +1174,7 @@ MODULE_LICENSE("GPL");
 MODULE_DESCRIPTION("Generic 8250/16x50 serial driver");
 
 module_param(share_irqs, uint, 0644);
-MODULE_PARM_DESC(share_irqs, "Share IRQs with other non-8250/16x50 devices"
-	" (unsafe)");
+MODULE_PARM_DESC(share_irqs, "Share IRQs with other non-8250/16x50 devices (unsafe)");
 
 module_param(nr_uarts, uint, 0644);
 MODULE_PARM_DESC(nr_uarts, "Maximum number of UARTs supported. (1-" __MODULE_STRING(CONFIG_SERIAL_8250_NR_UARTS) ")");
diff --git a/drivers/tty/serial/8250/serial_cs.c b/drivers/tty/serial/8250/serial_cs.c
index a4bdcf6..65d341d 100644
--- a/drivers/tty/serial/8250/serial_cs.c
+++ b/drivers/tty/serial/8250/serial_cs.c
@@ -535,8 +535,7 @@ static int multi_config(struct pcmcia_device *link)
 		info->multi = 2;
 		if (pcmcia_loop_config(link, multi_config_check_notpicky,
 				       &base2)) {
-			dev_warn(&link->dev, "no usable port range "
-			       "found, giving up\n");
+			dev_warn(&link->dev, "no usable port range found, giving up\n");
 			return -ENODEV;
 		}
 	}
-- 
1.9.1


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

* [PATCH 09/11] tty: serial: 8250: Fix multi-line strings
@ 2015-12-16 15:36   ` Anton Wuerfel
  0 siblings, 0 replies; 60+ messages in thread
From: Anton Wuerfel @ 2015-12-16 15:36 UTC (permalink / raw)
  To: linux-serial
  Cc: Greg Kroah-Hartman, Jiri Slaby, James E.J. Bottomley,
	Helge Deller, Peter Hurley, Heikki Krogerus, Andy Shevchenko,
	Qipeng Zha, Desmond Liu, Wang Long, Matt Redfearn, Paul Burton,
	Ralf Baechle, Krzysztof Kozlowski, Peter Hung, Soeren Grunewald,
	Adam Lee, Maciej S. Szmigiero, Mans Rullgard, linux-kernel,
	linux-parisc, linux-kernel, Anton Wuerfel

Merged user-visible multi-line strings into a single line according to the
Linux Kernel Coding Style, which allows user-visible strings to exceed the
maximum line length of 80 characters. The main reason for this is to
facilitate grepping for these strings.
However, some strings were ignored in this patch, because the use of
format specifiers breaks the ability to grep anyway.

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 | 3 +--
 drivers/tty/serial/8250/serial_cs.c | 3 +--
 2 files changed, 2 insertions(+), 4 deletions(-)

diff --git a/drivers/tty/serial/8250/8250_core.c b/drivers/tty/serial/8250/8250_core.c
index 3c29530..2b3731f 100644
--- a/drivers/tty/serial/8250/8250_core.c
+++ b/drivers/tty/serial/8250/8250_core.c
@@ -1174,8 +1174,7 @@ MODULE_LICENSE("GPL");
 MODULE_DESCRIPTION("Generic 8250/16x50 serial driver");
 
 module_param(share_irqs, uint, 0644);
-MODULE_PARM_DESC(share_irqs, "Share IRQs with other non-8250/16x50 devices"
-	" (unsafe)");
+MODULE_PARM_DESC(share_irqs, "Share IRQs with other non-8250/16x50 devices (unsafe)");
 
 module_param(nr_uarts, uint, 0644);
 MODULE_PARM_DESC(nr_uarts, "Maximum number of UARTs supported. (1-" __MODULE_STRING(CONFIG_SERIAL_8250_NR_UARTS) ")");
diff --git a/drivers/tty/serial/8250/serial_cs.c b/drivers/tty/serial/8250/serial_cs.c
index a4bdcf6..65d341d 100644
--- a/drivers/tty/serial/8250/serial_cs.c
+++ b/drivers/tty/serial/8250/serial_cs.c
@@ -535,8 +535,7 @@ static int multi_config(struct pcmcia_device *link)
 		info->multi = 2;
 		if (pcmcia_loop_config(link, multi_config_check_notpicky,
 				       &base2)) {
-			dev_warn(&link->dev, "no usable port range "
-			       "found, giving up\n");
+			dev_warn(&link->dev, "no usable port range found, giving up\n");
 			return -ENODEV;
 		}
 	}
-- 
1.9.1

--
To unsubscribe from this list: send the line "unsubscribe linux-parisc" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

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

* [PATCH 10/11] tty: serial: 8250: Replace printk by pr_*
  2015-12-16 15:36 ` Anton Wuerfel
  (?)
@ 2015-12-16 15:36   ` Anton Wuerfel
  -1 siblings, 0 replies; 60+ messages in thread
From: Anton Wuerfel @ 2015-12-16 15:36 UTC (permalink / raw)
  To: linux-serial
  Cc: Greg Kroah-Hartman, Jiri Slaby, James E.J. Bottomley,
	Helge Deller, Peter Hurley, Heikki Krogerus, Andy Shevchenko,
	Qipeng Zha, Desmond Liu, Wang Long, Matt Redfearn, Paul Burton,
	Ralf Baechle, Krzysztof Kozlowski, Peter Hung, Soeren Grunewald,
	Adam Lee, Maciej S. Szmigiero, Mans Rullgard, linux-kernel,
	linux-parisc, linux-kernel, Anton Wuerfel

This patch replaces printk by the corresponding variant of pr_* in orde=
r to
fix checkpatch warnings.

Signed-off-by: Anton W=C3=BCrfel <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  |  5 ++---
 drivers/tty/serial/8250/8250_gsc.c   |  6 ++----
 drivers/tty/serial/8250/8250_hp300.c | 14 +++++++-------
 drivers/tty/serial/8250/8250_pnp.c   |  6 +++---
 drivers/tty/serial/8250/8250_port.c  |  3 +--
 5 files changed, 15 insertions(+), 19 deletions(-)

diff --git a/drivers/tty/serial/8250/8250_core.c b/drivers/tty/serial/8=
250/8250_core.c
index 2b3731f..b5e0c48 100644
--- a/drivers/tty/serial/8250/8250_core.c
+++ b/drivers/tty/serial/8250/8250_core.c
@@ -1095,9 +1095,8 @@ static int __init serial8250_init(void)
=20
 	serial8250_isa_init_ports();
=20
-	printk(KERN_INFO "Serial: 8250/16550 driver, "
-		"%d ports, IRQ sharing %sabled\n", nr_uarts,
-		share_irqs ? "en" : "dis");
+	pr_info("Serial: 8250/16550 driver, %d ports, IRQ sharing %sabled\n",
+		nr_uarts, share_irqs ? "en" : "dis");
=20
 #ifdef CONFIG_SPARC
 	ret =3D sunserial_register_minors(&serial8250_reg, UART_NR);
diff --git a/drivers/tty/serial/8250/8250_gsc.c b/drivers/tty/serial/82=
50/8250_gsc.c
index 2e3ea1a..a9b63d0 100644
--- a/drivers/tty/serial/8250/8250_gsc.c
+++ b/drivers/tty/serial/8250/8250_gsc.c
@@ -42,8 +42,7 @@ static int __init serial_init_chip(struct parisc_devi=
ce *dev)
 		 * the user what they're missing.
 		 */
 		if (parisc_parent(dev)->id.hw_type !=3D HPHW_IOA)
-			printk(KERN_INFO
-				"Serial: device 0x%llx not configured.\n"
+			pr_info("Serial: device 0x%llx not configured.\n"
 				"Enable support for Wax, Lasi, Asp or Dino.\n",
 				(unsigned long long)dev->hpa.start);
 		return -ENODEV;
@@ -66,8 +65,7 @@ static int __init serial_init_chip(struct parisc_devi=
ce *dev)
=20
 	err =3D serial8250_register_8250_port(&uart);
 	if (err < 0) {
-		printk(KERN_WARNING
-			"serial8250_register_8250_port returned error %d\n", err);
+		pr_warn("serial8250_register_8250_port returned error %d\n", err);
 		iounmap(uart.port.membase);
 		return err;
 	}
diff --git a/drivers/tty/serial/8250/8250_hp300.c b/drivers/tty/serial/=
8250/8250_hp300.c
index 52c43da..85b574896 100644
--- a/drivers/tty/serial/8250/8250_hp300.c
+++ b/drivers/tty/serial/8250/8250_hp300.c
@@ -110,7 +110,7 @@ int __init hp300_setup_serial_console(void)
 	/* Check for APCI console */
 	if (scode =3D=3D 256) {
 #ifdef CONFIG_HPAPCI
-		printk(KERN_INFO "Serial console is HP APCI 1\n");
+		pr_info("Serial console is HP APCI 1\n");
=20
 		port.uartclk =3D HPAPCI_BAUD_BASE * 16;
 		port.mapbase =3D (FRODO_BASE + FRODO_APCI_OFFSET(1));
@@ -118,7 +118,7 @@ int __init hp300_setup_serial_console(void)
 		port.regshift =3D 2;
 		add_preferred_console("ttyS", port.line, "9600n8");
 #else
-		printk(KERN_WARNING "Serial console is APCI but support is disabled =
(CONFIG_HPAPCI)!\n");
+		pr_warn("Serial console is APCI but support is disabled (CONFIG_HPAP=
CI)!\n");
 		return 0;
 #endif
 	} else {
@@ -128,7 +128,7 @@ int __init hp300_setup_serial_console(void)
 		if (!pa)
 			return 0;
=20
-		printk(KERN_INFO "Serial console is HP DCA at select code %d\n", sco=
de);
+		pr_info("Serial console is HP DCA at select code %d\n", scode);
=20
 		port.uartclk =3D HPDCA_BAUD_BASE * 16;
 		port.mapbase =3D (pa + UART_OFFSET);
@@ -142,13 +142,13 @@ int __init hp300_setup_serial_console(void)
 		if (DIO_ID(pa + DIO_VIRADDRBASE) & 0x80)
 			add_preferred_console("ttyS", port.line, "9600n8");
 #else
-		printk(KERN_WARNING "Serial console is DCA but support is disabled (=
CONFIG_HPDCA)!\n");
+		pr_warn("Serial console is DCA but support is disabled (CONFIG_HPDCA=
)!\n");
 		return 0;
 #endif
 	}
=20
 	if (early_serial_setup(&port) < 0)
-		printk(KERN_WARNING "hp300_setup_serial_console(): early_serial_setu=
p() failed.\n");
+		pr_warn("hp300_setup_serial_console(): early_serial_setup() failed.\=
n");
 	return 0;
 }
 #endif /* CONFIG_SERIAL_8250_CONSOLE */
@@ -180,7 +180,7 @@ static int hpdca_init_one(struct dio_dev *d,
 	line =3D serial8250_register_8250_port(&uart);
=20
 	if (line < 0) {
-		printk(KERN_NOTICE "8250_hp300: register_serial() DCA scode %d"
+		pr_notice("8250_hp300: register_serial() DCA scode %d"
 		       " irq %d failed\n", d->scode, uart.port.irq);
 		return -ENOMEM;
 	}
@@ -261,7 +261,7 @@ static int __init hp300_8250_init(void)
 		line =3D serial8250_register_8250_port(&uart);
=20
 		if (line < 0) {
-			printk(KERN_NOTICE "8250_hp300: register_serial() APCI"
+			pr_notice("8250_hp300: register_serial() APCI"
 			       " %d irq %d failed\n", i, uart.port.irq);
 			kfree(port);
 			continue;
diff --git a/drivers/tty/serial/8250/8250_pnp.c b/drivers/tty/serial/82=
50/8250_pnp.c
index 2731031..3811c67 100644
--- a/drivers/tty/serial/8250/8250_pnp.c
+++ b/drivers/tty/serial/8250/8250_pnp.c
@@ -465,9 +465,9 @@ serial_pnp_probe(struct pnp_dev *dev, const struct =
pnp_device_id *dev_id)
 		return -ENODEV;
=20
 #ifdef SERIAL_DEBUG_PNP
-	printk(KERN_DEBUG
-		"Setup PNP port: port %x, mem 0x%lx, irq %d, type %d\n",
-		       uart.port.iobase, uart.port.mapbase, uart.port.irq, uart.port=
=2Eiotype);
+	pr_debug("Setup PNP port: port %x, mem 0x%lx, irq %d, type %d\n",
+		 uart.port.iobase, uart.port.mapbase,
+		 uart.port.irq, uart.port.iotype);
 #endif
 	if (flags & CIR_PORT) {
 		uart.port.flags |=3D UPF_FIXED_PORT | UPF_FIXED_TYPE;
diff --git a/drivers/tty/serial/8250/8250_port.c b/drivers/tty/serial/8=
250/8250_port.c
index 0ec823e..1b2aaf9 100644
--- a/drivers/tty/serial/8250/8250_port.c
+++ b/drivers/tty/serial/8250/8250_port.c
@@ -1222,8 +1222,7 @@ static void autoconfig(struct uart_8250_port *up)
 out_lock:
 	spin_unlock_irqrestore(&port->lock, flags);
 	if (up->capabilities !=3D old_capabilities) {
-		printk(KERN_WARNING
-		       "ttyS%d: detected caps %08x should be %08x\n",
+		pr_warn("ttyS%d: detected caps %08x should be %08x\n",
 		       serial_index(port), old_capabilities,
 		       up->capabilities);
 	}
--=20
1.9.1

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

* [PATCH 10/11] tty: serial: 8250: Replace printk by pr_*
@ 2015-12-16 15:36   ` Anton Wuerfel
  0 siblings, 0 replies; 60+ messages in thread
From: Anton Wuerfel @ 2015-12-16 15:36 UTC (permalink / raw)
  To: linux-serial
  Cc: Greg Kroah-Hartman, Jiri Slaby, James E.J. Bottomley,
	Helge Deller, Peter Hurley, Heikki Krogerus, Andy Shevchenko,
	Qipeng Zha, Desmond Liu, Wang Long, Matt Redfearn, Paul Burton,
	Ralf Baechle, Krzysztof Kozlowski, Peter Hung, Soeren Grunewald,
	Adam Lee, Maciej S. Szmigiero, Mans Rullgard, linux-kernel,
	linux-parisc, linux-kernel, Anton Wuerfel, Phillip Raffeck

This patch replaces printk by the corresponding variant of pr_* in order to
fix checkpatch warnings.

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  |  5 ++---
 drivers/tty/serial/8250/8250_gsc.c   |  6 ++----
 drivers/tty/serial/8250/8250_hp300.c | 14 +++++++-------
 drivers/tty/serial/8250/8250_pnp.c   |  6 +++---
 drivers/tty/serial/8250/8250_port.c  |  3 +--
 5 files changed, 15 insertions(+), 19 deletions(-)

diff --git a/drivers/tty/serial/8250/8250_core.c b/drivers/tty/serial/8250/8250_core.c
index 2b3731f..b5e0c48 100644
--- a/drivers/tty/serial/8250/8250_core.c
+++ b/drivers/tty/serial/8250/8250_core.c
@@ -1095,9 +1095,8 @@ static int __init serial8250_init(void)
 
 	serial8250_isa_init_ports();
 
-	printk(KERN_INFO "Serial: 8250/16550 driver, "
-		"%d ports, IRQ sharing %sabled\n", nr_uarts,
-		share_irqs ? "en" : "dis");
+	pr_info("Serial: 8250/16550 driver, %d ports, IRQ sharing %sabled\n",
+		nr_uarts, share_irqs ? "en" : "dis");
 
 #ifdef CONFIG_SPARC
 	ret = sunserial_register_minors(&serial8250_reg, UART_NR);
diff --git a/drivers/tty/serial/8250/8250_gsc.c b/drivers/tty/serial/8250/8250_gsc.c
index 2e3ea1a..a9b63d0 100644
--- a/drivers/tty/serial/8250/8250_gsc.c
+++ b/drivers/tty/serial/8250/8250_gsc.c
@@ -42,8 +42,7 @@ static int __init serial_init_chip(struct parisc_device *dev)
 		 * the user what they're missing.
 		 */
 		if (parisc_parent(dev)->id.hw_type != HPHW_IOA)
-			printk(KERN_INFO
-				"Serial: device 0x%llx not configured.\n"
+			pr_info("Serial: device 0x%llx not configured.\n"
 				"Enable support for Wax, Lasi, Asp or Dino.\n",
 				(unsigned long long)dev->hpa.start);
 		return -ENODEV;
@@ -66,8 +65,7 @@ static int __init serial_init_chip(struct parisc_device *dev)
 
 	err = serial8250_register_8250_port(&uart);
 	if (err < 0) {
-		printk(KERN_WARNING
-			"serial8250_register_8250_port returned error %d\n", err);
+		pr_warn("serial8250_register_8250_port returned error %d\n", err);
 		iounmap(uart.port.membase);
 		return err;
 	}
diff --git a/drivers/tty/serial/8250/8250_hp300.c b/drivers/tty/serial/8250/8250_hp300.c
index 52c43da..85b574896 100644
--- a/drivers/tty/serial/8250/8250_hp300.c
+++ b/drivers/tty/serial/8250/8250_hp300.c
@@ -110,7 +110,7 @@ int __init hp300_setup_serial_console(void)
 	/* Check for APCI console */
 	if (scode == 256) {
 #ifdef CONFIG_HPAPCI
-		printk(KERN_INFO "Serial console is HP APCI 1\n");
+		pr_info("Serial console is HP APCI 1\n");
 
 		port.uartclk = HPAPCI_BAUD_BASE * 16;
 		port.mapbase = (FRODO_BASE + FRODO_APCI_OFFSET(1));
@@ -118,7 +118,7 @@ int __init hp300_setup_serial_console(void)
 		port.regshift = 2;
 		add_preferred_console("ttyS", port.line, "9600n8");
 #else
-		printk(KERN_WARNING "Serial console is APCI but support is disabled (CONFIG_HPAPCI)!\n");
+		pr_warn("Serial console is APCI but support is disabled (CONFIG_HPAPCI)!\n");
 		return 0;
 #endif
 	} else {
@@ -128,7 +128,7 @@ int __init hp300_setup_serial_console(void)
 		if (!pa)
 			return 0;
 
-		printk(KERN_INFO "Serial console is HP DCA at select code %d\n", scode);
+		pr_info("Serial console is HP DCA at select code %d\n", scode);
 
 		port.uartclk = HPDCA_BAUD_BASE * 16;
 		port.mapbase = (pa + UART_OFFSET);
@@ -142,13 +142,13 @@ int __init hp300_setup_serial_console(void)
 		if (DIO_ID(pa + DIO_VIRADDRBASE) & 0x80)
 			add_preferred_console("ttyS", port.line, "9600n8");
 #else
-		printk(KERN_WARNING "Serial console is DCA but support is disabled (CONFIG_HPDCA)!\n");
+		pr_warn("Serial console is DCA but support is disabled (CONFIG_HPDCA)!\n");
 		return 0;
 #endif
 	}
 
 	if (early_serial_setup(&port) < 0)
-		printk(KERN_WARNING "hp300_setup_serial_console(): early_serial_setup() failed.\n");
+		pr_warn("hp300_setup_serial_console(): early_serial_setup() failed.\n");
 	return 0;
 }
 #endif /* CONFIG_SERIAL_8250_CONSOLE */
@@ -180,7 +180,7 @@ static int hpdca_init_one(struct dio_dev *d,
 	line = serial8250_register_8250_port(&uart);
 
 	if (line < 0) {
-		printk(KERN_NOTICE "8250_hp300: register_serial() DCA scode %d"
+		pr_notice("8250_hp300: register_serial() DCA scode %d"
 		       " irq %d failed\n", d->scode, uart.port.irq);
 		return -ENOMEM;
 	}
@@ -261,7 +261,7 @@ static int __init hp300_8250_init(void)
 		line = serial8250_register_8250_port(&uart);
 
 		if (line < 0) {
-			printk(KERN_NOTICE "8250_hp300: register_serial() APCI"
+			pr_notice("8250_hp300: register_serial() APCI"
 			       " %d irq %d failed\n", i, uart.port.irq);
 			kfree(port);
 			continue;
diff --git a/drivers/tty/serial/8250/8250_pnp.c b/drivers/tty/serial/8250/8250_pnp.c
index 2731031..3811c67 100644
--- a/drivers/tty/serial/8250/8250_pnp.c
+++ b/drivers/tty/serial/8250/8250_pnp.c
@@ -465,9 +465,9 @@ serial_pnp_probe(struct pnp_dev *dev, const struct pnp_device_id *dev_id)
 		return -ENODEV;
 
 #ifdef SERIAL_DEBUG_PNP
-	printk(KERN_DEBUG
-		"Setup PNP port: port %x, mem 0x%lx, irq %d, type %d\n",
-		       uart.port.iobase, uart.port.mapbase, uart.port.irq, uart.port.iotype);
+	pr_debug("Setup PNP port: port %x, mem 0x%lx, irq %d, type %d\n",
+		 uart.port.iobase, uart.port.mapbase,
+		 uart.port.irq, uart.port.iotype);
 #endif
 	if (flags & CIR_PORT) {
 		uart.port.flags |= UPF_FIXED_PORT | UPF_FIXED_TYPE;
diff --git a/drivers/tty/serial/8250/8250_port.c b/drivers/tty/serial/8250/8250_port.c
index 0ec823e..1b2aaf9 100644
--- a/drivers/tty/serial/8250/8250_port.c
+++ b/drivers/tty/serial/8250/8250_port.c
@@ -1222,8 +1222,7 @@ static void autoconfig(struct uart_8250_port *up)
 out_lock:
 	spin_unlock_irqrestore(&port->lock, flags);
 	if (up->capabilities != old_capabilities) {
-		printk(KERN_WARNING
-		       "ttyS%d: detected caps %08x should be %08x\n",
+		pr_warn("ttyS%d: detected caps %08x should be %08x\n",
 		       serial_index(port), old_capabilities,
 		       up->capabilities);
 	}
-- 
1.9.1


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

* [PATCH 10/11] tty: serial: 8250: Replace printk by pr_*
@ 2015-12-16 15:36   ` Anton Wuerfel
  0 siblings, 0 replies; 60+ messages in thread
From: Anton Wuerfel @ 2015-12-16 15:36 UTC (permalink / raw)
  To: linux-serial
  Cc: Greg Kroah-Hartman, Jiri Slaby, James E.J. Bottomley,
	Helge Deller, Peter Hurley, Heikki Krogerus, Andy Shevchenko,
	Qipeng Zha, Desmond Liu, Wang Long, Matt Redfearn, Paul Burton,
	Ralf Baechle, Krzysztof Kozlowski, Peter Hung, Soeren Grunewald,
	Adam Lee, Maciej S. Szmigiero, Mans Rullgard, linux-kernel,
	linux-parisc, linux-kernel, Anton Wuerfel

This patch replaces printk by the corresponding variant of pr_* in order to
fix checkpatch warnings.

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  |  5 ++---
 drivers/tty/serial/8250/8250_gsc.c   |  6 ++----
 drivers/tty/serial/8250/8250_hp300.c | 14 +++++++-------
 drivers/tty/serial/8250/8250_pnp.c   |  6 +++---
 drivers/tty/serial/8250/8250_port.c  |  3 +--
 5 files changed, 15 insertions(+), 19 deletions(-)

diff --git a/drivers/tty/serial/8250/8250_core.c b/drivers/tty/serial/8250/8250_core.c
index 2b3731f..b5e0c48 100644
--- a/drivers/tty/serial/8250/8250_core.c
+++ b/drivers/tty/serial/8250/8250_core.c
@@ -1095,9 +1095,8 @@ static int __init serial8250_init(void)
 
 	serial8250_isa_init_ports();
 
-	printk(KERN_INFO "Serial: 8250/16550 driver, "
-		"%d ports, IRQ sharing %sabled\n", nr_uarts,
-		share_irqs ? "en" : "dis");
+	pr_info("Serial: 8250/16550 driver, %d ports, IRQ sharing %sabled\n",
+		nr_uarts, share_irqs ? "en" : "dis");
 
 #ifdef CONFIG_SPARC
 	ret = sunserial_register_minors(&serial8250_reg, UART_NR);
diff --git a/drivers/tty/serial/8250/8250_gsc.c b/drivers/tty/serial/8250/8250_gsc.c
index 2e3ea1a..a9b63d0 100644
--- a/drivers/tty/serial/8250/8250_gsc.c
+++ b/drivers/tty/serial/8250/8250_gsc.c
@@ -42,8 +42,7 @@ static int __init serial_init_chip(struct parisc_device *dev)
 		 * the user what they're missing.
 		 */
 		if (parisc_parent(dev)->id.hw_type != HPHW_IOA)
-			printk(KERN_INFO
-				"Serial: device 0x%llx not configured.\n"
+			pr_info("Serial: device 0x%llx not configured.\n"
 				"Enable support for Wax, Lasi, Asp or Dino.\n",
 				(unsigned long long)dev->hpa.start);
 		return -ENODEV;
@@ -66,8 +65,7 @@ static int __init serial_init_chip(struct parisc_device *dev)
 
 	err = serial8250_register_8250_port(&uart);
 	if (err < 0) {
-		printk(KERN_WARNING
-			"serial8250_register_8250_port returned error %d\n", err);
+		pr_warn("serial8250_register_8250_port returned error %d\n", err);
 		iounmap(uart.port.membase);
 		return err;
 	}
diff --git a/drivers/tty/serial/8250/8250_hp300.c b/drivers/tty/serial/8250/8250_hp300.c
index 52c43da..85b574896 100644
--- a/drivers/tty/serial/8250/8250_hp300.c
+++ b/drivers/tty/serial/8250/8250_hp300.c
@@ -110,7 +110,7 @@ int __init hp300_setup_serial_console(void)
 	/* Check for APCI console */
 	if (scode == 256) {
 #ifdef CONFIG_HPAPCI
-		printk(KERN_INFO "Serial console is HP APCI 1\n");
+		pr_info("Serial console is HP APCI 1\n");
 
 		port.uartclk = HPAPCI_BAUD_BASE * 16;
 		port.mapbase = (FRODO_BASE + FRODO_APCI_OFFSET(1));
@@ -118,7 +118,7 @@ int __init hp300_setup_serial_console(void)
 		port.regshift = 2;
 		add_preferred_console("ttyS", port.line, "9600n8");
 #else
-		printk(KERN_WARNING "Serial console is APCI but support is disabled (CONFIG_HPAPCI)!\n");
+		pr_warn("Serial console is APCI but support is disabled (CONFIG_HPAPCI)!\n");
 		return 0;
 #endif
 	} else {
@@ -128,7 +128,7 @@ int __init hp300_setup_serial_console(void)
 		if (!pa)
 			return 0;
 
-		printk(KERN_INFO "Serial console is HP DCA at select code %d\n", scode);
+		pr_info("Serial console is HP DCA at select code %d\n", scode);
 
 		port.uartclk = HPDCA_BAUD_BASE * 16;
 		port.mapbase = (pa + UART_OFFSET);
@@ -142,13 +142,13 @@ int __init hp300_setup_serial_console(void)
 		if (DIO_ID(pa + DIO_VIRADDRBASE) & 0x80)
 			add_preferred_console("ttyS", port.line, "9600n8");
 #else
-		printk(KERN_WARNING "Serial console is DCA but support is disabled (CONFIG_HPDCA)!\n");
+		pr_warn("Serial console is DCA but support is disabled (CONFIG_HPDCA)!\n");
 		return 0;
 #endif
 	}
 
 	if (early_serial_setup(&port) < 0)
-		printk(KERN_WARNING "hp300_setup_serial_console(): early_serial_setup() failed.\n");
+		pr_warn("hp300_setup_serial_console(): early_serial_setup() failed.\n");
 	return 0;
 }
 #endif /* CONFIG_SERIAL_8250_CONSOLE */
@@ -180,7 +180,7 @@ static int hpdca_init_one(struct dio_dev *d,
 	line = serial8250_register_8250_port(&uart);
 
 	if (line < 0) {
-		printk(KERN_NOTICE "8250_hp300: register_serial() DCA scode %d"
+		pr_notice("8250_hp300: register_serial() DCA scode %d"
 		       " irq %d failed\n", d->scode, uart.port.irq);
 		return -ENOMEM;
 	}
@@ -261,7 +261,7 @@ static int __init hp300_8250_init(void)
 		line = serial8250_register_8250_port(&uart);
 
 		if (line < 0) {
-			printk(KERN_NOTICE "8250_hp300: register_serial() APCI"
+			pr_notice("8250_hp300: register_serial() APCI"
 			       " %d irq %d failed\n", i, uart.port.irq);
 			kfree(port);
 			continue;
diff --git a/drivers/tty/serial/8250/8250_pnp.c b/drivers/tty/serial/8250/8250_pnp.c
index 2731031..3811c67 100644
--- a/drivers/tty/serial/8250/8250_pnp.c
+++ b/drivers/tty/serial/8250/8250_pnp.c
@@ -465,9 +465,9 @@ serial_pnp_probe(struct pnp_dev *dev, const struct pnp_device_id *dev_id)
 		return -ENODEV;
 
 #ifdef SERIAL_DEBUG_PNP
-	printk(KERN_DEBUG
-		"Setup PNP port: port %x, mem 0x%lx, irq %d, type %d\n",
-		       uart.port.iobase, uart.port.mapbase, uart.port.irq, uart.port.iotype);
+	pr_debug("Setup PNP port: port %x, mem 0x%lx, irq %d, type %d\n",
+		 uart.port.iobase, uart.port.mapbase,
+		 uart.port.irq, uart.port.iotype);
 #endif
 	if (flags & CIR_PORT) {
 		uart.port.flags |= UPF_FIXED_PORT | UPF_FIXED_TYPE;
diff --git a/drivers/tty/serial/8250/8250_port.c b/drivers/tty/serial/8250/8250_port.c
index 0ec823e..1b2aaf9 100644
--- a/drivers/tty/serial/8250/8250_port.c
+++ b/drivers/tty/serial/8250/8250_port.c
@@ -1222,8 +1222,7 @@ static void autoconfig(struct uart_8250_port *up)
 out_lock:
 	spin_unlock_irqrestore(&port->lock, flags);
 	if (up->capabilities != old_capabilities) {
-		printk(KERN_WARNING
-		       "ttyS%d: detected caps %08x should be %08x\n",
+		pr_warn("ttyS%d: detected caps %08x should be %08x\n",
 		       serial_index(port), old_capabilities,
 		       up->capabilities);
 	}
-- 
1.9.1

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

* [PATCH 11/11] tty: serial: 8250: Delete commented code
  2015-12-16 15:36 ` Anton Wuerfel
  (?)
@ 2015-12-16 15:36   ` Anton Wuerfel
  -1 siblings, 0 replies; 60+ messages in thread
From: Anton Wuerfel @ 2015-12-16 15:36 UTC (permalink / raw)
  To: linux-serial
  Cc: Greg Kroah-Hartman, Jiri Slaby, James E.J. Bottomley,
	Helge Deller, Peter Hurley, Heikki Krogerus, Andy Shevchenko,
	Qipeng Zha, Desmond Liu, Wang Long, Matt Redfearn, Paul Burton,
	Ralf Baechle, Krzysztof Kozlowski, Peter Hung, Soeren Grunewald,
	Adam Lee, Maciej S. Szmigiero, Mans Rullgard, linux-kernel,
	linux-parisc, linux-kernel, Anton Wuerfel

This patch removes code which has been commented out. It serves no
documentary purposes and decreases the readability of the remaining cod=
e.
=46urthermore the comment style causes checkpatch warnings. If this cod=
e
should ever be needed again, git keeps track of it.

Signed-off-by: Anton W=C3=BCrfel <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_pci.c | 7 -------
 1 file changed, 7 deletions(-)

diff --git a/drivers/tty/serial/8250/8250_pci.c b/drivers/tty/serial/82=
50/8250_pci.c
index 3bc0303..9136f0f 100644
--- a/drivers/tty/serial/8250/8250_pci.c
+++ b/drivers/tty/serial/8250/8250_pci.c
@@ -4928,16 +4928,9 @@ static struct pci_device_id serial_pci_tbl[] =3D=
 {
 	{	PCI_VENDOR_ID_KORENIX, PCI_DEVICE_ID_KORENIX_JETCARDF0,
 		0x1208, 0x0004, 0, 0,
 		pbn_b0_4_921600 },
-/*	{	PCI_VENDOR_ID_KORENIX, PCI_DEVICE_ID_KORENIX_JETCARDF0,
-		0x1402, 0x0002, 0, 0,
-		pbn_b0_2_921600 }, */
-/*	{	PCI_VENDOR_ID_KORENIX, PCI_DEVICE_ID_KORENIX_JETCARDF0,
-		0x1404, 0x0004, 0, 0,
-		pbn_b0_4_921600 }, */
 	{	PCI_VENDOR_ID_KORENIX, PCI_DEVICE_ID_KORENIX_JETCARDF1,
 		0x1208, 0x0004, 0, 0,
 		pbn_b0_4_921600 },
-
 	{	PCI_VENDOR_ID_KORENIX, PCI_DEVICE_ID_KORENIX_JETCARDF2,
 		0x1204, 0x0004, 0, 0,
 		pbn_b0_4_921600 },
--=20
1.9.1

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

* [PATCH 11/11] tty: serial: 8250: Delete commented code
@ 2015-12-16 15:36   ` Anton Wuerfel
  0 siblings, 0 replies; 60+ messages in thread
From: Anton Wuerfel @ 2015-12-16 15:36 UTC (permalink / raw)
  To: linux-serial
  Cc: Greg Kroah-Hartman, Jiri Slaby, James E.J. Bottomley,
	Helge Deller, Peter Hurley, Heikki Krogerus, Andy Shevchenko,
	Qipeng Zha, Desmond Liu, Wang Long, Matt Redfearn, Paul Burton,
	Ralf Baechle, Krzysztof Kozlowski, Peter Hung, Soeren Grunewald,
	Adam Lee, Maciej S. Szmigiero, Mans Rullgard, linux-kernel,
	linux-parisc, linux-kernel, Anton Wuerfel, Phillip Raffeck

This patch removes code which has been commented out. It serves no
documentary purposes and decreases the readability of the remaining code.
Furthermore the comment style causes checkpatch warnings. If this code
should ever be needed again, git keeps track of it.

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_pci.c | 7 -------
 1 file changed, 7 deletions(-)

diff --git a/drivers/tty/serial/8250/8250_pci.c b/drivers/tty/serial/8250/8250_pci.c
index 3bc0303..9136f0f 100644
--- a/drivers/tty/serial/8250/8250_pci.c
+++ b/drivers/tty/serial/8250/8250_pci.c
@@ -4928,16 +4928,9 @@ static struct pci_device_id serial_pci_tbl[] = {
 	{	PCI_VENDOR_ID_KORENIX, PCI_DEVICE_ID_KORENIX_JETCARDF0,
 		0x1208, 0x0004, 0, 0,
 		pbn_b0_4_921600 },
-/*	{	PCI_VENDOR_ID_KORENIX, PCI_DEVICE_ID_KORENIX_JETCARDF0,
-		0x1402, 0x0002, 0, 0,
-		pbn_b0_2_921600 }, */
-/*	{	PCI_VENDOR_ID_KORENIX, PCI_DEVICE_ID_KORENIX_JETCARDF0,
-		0x1404, 0x0004, 0, 0,
-		pbn_b0_4_921600 }, */
 	{	PCI_VENDOR_ID_KORENIX, PCI_DEVICE_ID_KORENIX_JETCARDF1,
 		0x1208, 0x0004, 0, 0,
 		pbn_b0_4_921600 },
-
 	{	PCI_VENDOR_ID_KORENIX, PCI_DEVICE_ID_KORENIX_JETCARDF2,
 		0x1204, 0x0004, 0, 0,
 		pbn_b0_4_921600 },
-- 
1.9.1


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

* [PATCH 11/11] tty: serial: 8250: Delete commented code
@ 2015-12-16 15:36   ` Anton Wuerfel
  0 siblings, 0 replies; 60+ messages in thread
From: Anton Wuerfel @ 2015-12-16 15:36 UTC (permalink / raw)
  To: linux-serial
  Cc: Greg Kroah-Hartman, Jiri Slaby, James E.J. Bottomley,
	Helge Deller, Peter Hurley, Heikki Krogerus, Andy Shevchenko,
	Qipeng Zha, Desmond Liu, Wang Long, Matt Redfearn, Paul Burton,
	Ralf Baechle, Krzysztof Kozlowski, Peter Hung, Soeren Grunewald,
	Adam Lee, Maciej S. Szmigiero, Mans Rullgard, linux-kernel,
	linux-parisc, linux-kernel, Anton Wuerfel

This patch removes code which has been commented out. It serves no
documentary purposes and decreases the readability of the remaining code.
Furthermore the comment style causes checkpatch warnings. If this code
should ever be needed again, git keeps track of it.

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_pci.c | 7 -------
 1 file changed, 7 deletions(-)

diff --git a/drivers/tty/serial/8250/8250_pci.c b/drivers/tty/serial/8250/8250_pci.c
index 3bc0303..9136f0f 100644
--- a/drivers/tty/serial/8250/8250_pci.c
+++ b/drivers/tty/serial/8250/8250_pci.c
@@ -4928,16 +4928,9 @@ static struct pci_device_id serial_pci_tbl[] = {
 	{	PCI_VENDOR_ID_KORENIX, PCI_DEVICE_ID_KORENIX_JETCARDF0,
 		0x1208, 0x0004, 0, 0,
 		pbn_b0_4_921600 },
-/*	{	PCI_VENDOR_ID_KORENIX, PCI_DEVICE_ID_KORENIX_JETCARDF0,
-		0x1402, 0x0002, 0, 0,
-		pbn_b0_2_921600 }, */
-/*	{	PCI_VENDOR_ID_KORENIX, PCI_DEVICE_ID_KORENIX_JETCARDF0,
-		0x1404, 0x0004, 0, 0,
-		pbn_b0_4_921600 }, */
 	{	PCI_VENDOR_ID_KORENIX, PCI_DEVICE_ID_KORENIX_JETCARDF1,
 		0x1208, 0x0004, 0, 0,
 		pbn_b0_4_921600 },
-
 	{	PCI_VENDOR_ID_KORENIX, PCI_DEVICE_ID_KORENIX_JETCARDF2,
 		0x1204, 0x0004, 0, 0,
 		pbn_b0_4_921600 },
-- 
1.9.1

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

* Re: [PATCH 01/11] tty: serial: 8250: Fix whitespace errors
  2015-12-16 15:36   ` Anton Wuerfel
  (?)
@ 2015-12-16 16:43     ` Peter Hurley
  -1 siblings, 0 replies; 60+ messages in thread
From: Peter Hurley @ 2015-12-16 16:43 UTC (permalink / raw)
  To: Anton Wuerfel
  Cc: linux-serial, Greg Kroah-Hartman, Jiri Slaby,
	James E.J. Bottomley, Helge Deller, Heikki Krogerus,
	Andy Shevchenko, Qipeng Zha, Desmond Liu, Wang Long,
	Matt Redfearn, Paul Burton, Ralf Baechle, Krzysztof Kozlowski,
	Peter Hung, Soeren Grunewald, Adam Lee, Maciej S. Szmigiero,
	Mans Rullgard, linux-kernel, linux-parisc, linux-kernel,
	Phillip Raffeck

Hi Anton,

On 12/16/2015 07:36 AM, Anton Wuerfel wrote:
> This patch fixes whitespace errors reported by checkpatch to increase
> readability. Main focus is on missing spaces after commas in
> function headers and macros (like foo,bar edited to foo, bar).

Comments below.

> Signed-off-by: Anton W=C3=BCrfel <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_accent.c        |  2 +-
>  drivers/tty/serial/8250/8250_acorn.c         |  2 +-
>  drivers/tty/serial/8250/8250_boca.c          |  2 +-
>  drivers/tty/serial/8250/8250_core.c          |  1 +
>  drivers/tty/serial/8250/8250_dw.c            |  6 +++
>  drivers/tty/serial/8250/8250_exar_st16c554.c |  2 +-
>  drivers/tty/serial/8250/8250_fourport.c      |  2 +-
>  drivers/tty/serial/8250/8250_hp300.c         |  1 +
>  drivers/tty/serial/8250/8250_hub6.c          |  2 +-
>  drivers/tty/serial/8250/8250_pci.c           |  7 +++-
>  drivers/tty/serial/8250/8250_port.c          |  3 ++
>  drivers/tty/serial/8250/serial_cs.c          | 58 ++++++++++++++----=
----------
>  12 files changed, 52 insertions(+), 36 deletions(-)
>=20
> diff --git a/drivers/tty/serial/8250/8250_accent.c b/drivers/tty/seri=
al/8250/8250_accent.c
> index 34b51c6..c480729 100644
> --- a/drivers/tty/serial/8250/8250_accent.c
> +++ b/drivers/tty/serial/8250/8250_accent.c
> @@ -10,7 +10,7 @@
>  #include <linux/init.h>
>  #include <linux/serial_8250.h>
> =20
> -#define PORT(_base,_irq)				\
> +#define PORT(_base, _irq)				\

ok

>  	{						\
>  		.iobase		=3D _base,		\
>  		.irq		=3D _irq,			\
> diff --git a/drivers/tty/serial/8250/8250_acorn.c b/drivers/tty/seria=
l/8250/8250_acorn.c
> index 549aa07..402dfdd 100644
> --- a/drivers/tty/serial/8250/8250_acorn.c
> +++ b/drivers/tty/serial/8250/8250_acorn.c
> @@ -70,7 +70,7 @@ serial_card_probe(struct expansion_card *ec, const =
struct ecard_id *id)
>  	uart.port.regshift	=3D 2;
>  	uart.port.dev	=3D &ec->dev;
> =20
> -	for (i =3D 0; i < info->num_ports; i ++) {
> +	for (i =3D 0; i < info->num_ports; i++) {

Ok

>  		uart.port.membase =3D info->vaddr + type->offset[i];
>  		uart.port.mapbase =3D bus_addr + type->offset[i];
> =20
> diff --git a/drivers/tty/serial/8250/8250_boca.c b/drivers/tty/serial=
/8250/8250_boca.c
> index d125dc1..e42a5b5 100644
> --- a/drivers/tty/serial/8250/8250_boca.c
> +++ b/drivers/tty/serial/8250/8250_boca.c
> @@ -10,7 +10,7 @@
>  #include <linux/init.h>
>  #include <linux/serial_8250.h>
> =20
> -#define PORT(_base,_irq)				\
> +#define PORT(_base, _irq)				\

Ok

>  	{						\
>  		.iobase		=3D _base,		\
>  		.irq		=3D _irq,			\
> diff --git a/drivers/tty/serial/8250/8250_core.c b/drivers/tty/serial=
/8250/8250_core.c
> index 3912646..89a20c9 100644
> --- a/drivers/tty/serial/8250/8250_core.c
> +++ b/drivers/tty/serial/8250/8250_core.c
> @@ -756,6 +756,7 @@ void serial8250_suspend_port(int line)
>  	if (!console_suspend_enabled && uart_console(port) &&
>  	    port->type !=3D PORT_8250) {
>  		unsigned char canary =3D 0xa5;
> +

Not ok.

>  		serial_out(up, UART_SCR, canary);
>  		if (serial_in(up, UART_SCR) =3D=3D canary)
>  			up->canary =3D canary;
> diff --git a/drivers/tty/serial/8250/8250_dw.c b/drivers/tty/serial/8=
250/8250_dw.c
> index a5d319e..0f67355 100644
> --- a/drivers/tty/serial/8250/8250_dw.c
> +++ b/drivers/tty/serial/8250/8250_dw.c
> @@ -102,8 +102,10 @@ static void dw8250_serial_out(struct uart_port *=
p, int offset, int value)
>  	/* Make sure LCR write wasn't ignored */
>  	if (offset =3D=3D UART_LCR) {
>  		int tries =3D 1000;
> +

Not ok.

>  		while (tries--) {
>  			unsigned int lcr =3D p->serial_in(p, UART_LCR);
> +
>  			if ((value & ~UART_LCR_SPAR) =3D=3D (lcr & ~UART_LCR_SPAR))
>  				return;
>  			dw8250_force_idle(p);
> @@ -143,8 +145,10 @@ static void dw8250_serial_outq(struct uart_port =
*p, int offset, int value)
>  	/* Make sure LCR write wasn't ignored */
>  	if (offset =3D=3D UART_LCR) {
>  		int tries =3D 1000;
> +

Not ok.

>  		while (tries--) {
>  			unsigned int lcr =3D p->serial_in(p, UART_LCR);
> +

Not ok.

In particular, I dislike separation between initialized variables and
following statements, _especially_ when the initialization is non-trivi=
al.


>  			if ((value & ~UART_LCR_SPAR) =3D=3D (lcr & ~UART_LCR_SPAR))
>  				return;
>  			dw8250_force_idle(p);
> @@ -166,8 +170,10 @@ static void dw8250_serial_out32(struct uart_port=
 *p, int offset, int value)
>  	/* Make sure LCR write wasn't ignored */
>  	if (offset =3D=3D UART_LCR) {
>  		int tries =3D 1000;
> +

Not ok.

>  		while (tries--) {
>  			unsigned int lcr =3D p->serial_in(p, UART_LCR);
> +

Not ok.

>  			if ((value & ~UART_LCR_SPAR) =3D=3D (lcr & ~UART_LCR_SPAR))
>  				return;
>  			dw8250_force_idle(p);
> diff --git a/drivers/tty/serial/8250/8250_exar_st16c554.c b/drivers/t=
ty/serial/8250/8250_exar_st16c554.c
> index bf53aab..999f2d3 100644
> --- a/drivers/tty/serial/8250/8250_exar_st16c554.c
> +++ b/drivers/tty/serial/8250/8250_exar_st16c554.c
> @@ -13,7 +13,7 @@
>  #include <linux/init.h>
>  #include <linux/serial_8250.h>
> =20
> -#define PORT(_base,_irq)				\
> +#define PORT(_base, _irq)				\

Ok

>  	{						\
>  		.iobase		=3D _base,		\
>  		.irq		=3D _irq,			\
> diff --git a/drivers/tty/serial/8250/8250_fourport.c b/drivers/tty/se=
rial/8250/8250_fourport.c
> index be15826..9a04a8a 100644
> --- a/drivers/tty/serial/8250/8250_fourport.c
> +++ b/drivers/tty/serial/8250/8250_fourport.c
> @@ -10,7 +10,7 @@
>  #include <linux/init.h>
>  #include <linux/serial_8250.h>
> =20
> -#define PORT(_base,_irq)						\
> +#define PORT(_base, _irq)						\

Ok

>  	{								\
>  		.iobase		=3D _base,				\
>  		.irq		=3D _irq,					\
> diff --git a/drivers/tty/serial/8250/8250_hp300.c b/drivers/tty/seria=
l/8250/8250_hp300.c
> index 2891958..38d8cb2 100644
> --- a/drivers/tty/serial/8250/8250_hp300.c
> +++ b/drivers/tty/serial/8250/8250_hp300.c
> @@ -125,6 +125,7 @@ int __init hp300_setup_serial_console(void)
>  	} else {
>  #ifdef CONFIG_HPDCA
>  		unsigned long pa =3D dio_scodetophysaddr(scode);
> +
>  		if (!pa)
>  			return 0;

Not ok.

This is a particularly good example of how bad that style is.
The relevant code is the call to dio_scode_tophysaddr() _not the if (!p=
a)_

Newline after uninitialized vars - ok.
Newline after initialized vars - not ok. Unless trivial initialization =
and
you wrote it.


> diff --git a/drivers/tty/serial/8250/8250_hub6.c b/drivers/tty/serial=
/8250/8250_hub6.c
> index a5c778e..27124e2 100644
> --- a/drivers/tty/serial/8250/8250_hub6.c
> +++ b/drivers/tty/serial/8250/8250_hub6.c
> @@ -10,7 +10,7 @@
>  #include <linux/init.h>
>  #include <linux/serial_8250.h>
> =20
> -#define HUB6(card,port)							\
> +#define HUB6(card, port)						\

ok

>  	{								\
>  		.iobase		=3D 0x302,				\
>  		.irq		=3D 3,					\
> diff --git a/drivers/tty/serial/8250/8250_pci.c b/drivers/tty/serial/=
8250/8250_pci.c
> index 4097f3f..ed99fdf 100644
> --- a/drivers/tty/serial/8250/8250_pci.c
> +++ b/drivers/tty/serial/8250/8250_pci.c
> @@ -113,6 +113,7 @@ static int addidata_apci7800_setup(struct serial_=
private *priv,
>  				struct uart_8250_port *port, int idx)
>  {
>  	unsigned int bar =3D 0, offset =3D board->first_offset;
> +

not ok

>  	bar =3D FL_GET_BASE(board->flags);
> =20
>  	if (idx < 2) {
> @@ -1115,6 +1116,7 @@ static struct quatech_feature quatech_cards[] =3D=
 {
>  static int pci_quatech_amcc(u16 devid)
>  {
>  	struct quatech_feature *qf =3D &quatech_cards[0];
> +

not ok

>  	while (qf->devid) {
>  		if (qf->devid =3D=3D devid)
>  			return qf->amcc;
> @@ -1200,6 +1202,7 @@ static int pci_quatech_test(struct uart_8250_po=
rt *port)
>  {
>  	u8 reg;
>  	u8 qopr =3D pci_quatech_rqopr(port);
> +

Swap the declaration order and its ok. IOW,

+ 	u8 qopr =3D pci_quatech_rqopr(port);
+ 	u8 reg;
+

or even better

+ 	u8 reg, qopr;
+
+ 	qopr =3D pci_quatech_rqopr(port);

>  	pci_quatech_wqopr(port, qopr & QPCR_TEST_FOR1);
>  	reg =3D pci_quatech_rqopr(port) & 0xC0;
>  	if (reg !=3D QPCR_TEST_GET1)
> @@ -1284,8 +1287,10 @@ static int pci_quatech_init(struct pci_dev *de=
v)
>  {
>  	if (pci_quatech_amcc(dev->device)) {
>  		unsigned long base =3D pci_resource_start(dev, 0);
> +

not ok


>  		if (base) {
>  			u32 tmp;
> +

ok

>  			outl(inl(base + 0x38) | 0x00002000, base + 0x38);
>  			tmp =3D inl(base + 0x3c);
>  			outl(tmp | 0x01000000, base + 0x3c);
> @@ -4502,7 +4507,7 @@ static struct pci_device_id serial_pci_tbl[] =3D=
 {
>  		PCI_ANY_ID, PCI_ANY_ID, 0, 0,
>  		pbn_b0_bt_2_921600 },
>  	{	PCI_VENDOR_ID_OXSEMI, PCI_DEVICE_ID_OXSEMI_16PCI958,
> -		PCI_ANY_ID , PCI_ANY_ID, 0, 0,
> +		PCI_ANY_ID, PCI_ANY_ID, 0, 0,

ok

>  		pbn_b2_8_1152000 },
> =20
>  	/*
> diff --git a/drivers/tty/serial/8250/8250_port.c b/drivers/tty/serial=
/8250/8250_port.c
> index 52d82d2..ae8f993 100644
> --- a/drivers/tty/serial/8250/8250_port.c
> +++ b/drivers/tty/serial/8250/8250_port.c
> @@ -1327,6 +1327,7 @@ static void serial8250_start_tx(struct uart_por=
t *port)
> =20
>  		if (up->bugs & UART_BUG_TXEN) {
>  			unsigned char lsr;
> +

ok

>  			lsr =3D serial_in(up, UART_LSR);
>  			up->lsr_saved_flags |=3D lsr & LSR_SAVE_FLAGS;
>  			if (lsr & UART_LSR_THRE)
> @@ -1734,8 +1735,10 @@ static void wait_for_xmitr(struct uart_8250_po=
rt *up, int bits)
>  	/* Wait up to 1s for flow control if necessary */
>  	if (up->port.flags & UPF_CONS_FLOW) {
>  		unsigned int tmout;
> +

ok

>  		for (tmout =3D 1000000; tmout; tmout--) {
>  			unsigned int msr =3D serial_in(up, UART_MSR);
> +

not ok

>  			up->msr_saved_flags |=3D msr & MSR_SAVE_FLAGS;
>  			if (msr & UART_MSR_CTS)
>  				break;
> diff --git a/drivers/tty/serial/8250/serial_cs.c b/drivers/tty/serial=
/8250/serial_cs.c
> index 4d180c9..f5270ba 100644
> --- a/drivers/tty/serial/8250/serial_cs.c
> +++ b/drivers/tty/serial/8250/serial_cs.c
> @@ -257,7 +257,7 @@ static const struct serial_quirk quirks[] =3D {
>  };
> =20
> =20
> -static int serial_config(struct pcmcia_device * link);
> +static int serial_config(struct pcmcia_device *link);

ok

> =20
> =20
>  static void serial_remove(struct pcmcia_device *link)
> @@ -309,7 +309,7 @@ static int serial_probe(struct pcmcia_device *lin=
k)
>  	dev_dbg(&link->dev, "serial_attach()\n");
> =20
>  	/* Create new serial device */
> -	info =3D kzalloc(sizeof (*info), GFP_KERNEL);
> +	info =3D kzalloc(sizeof(*info), GFP_KERNEL);

ok

>  	if (!info)
>  		return -ENOMEM;
>  	info->p_dev =3D link;
> @@ -339,7 +339,7 @@ static void serial_detach(struct pcmcia_device *l=
ink)
> =20
>  /*=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D*/
> =20
> -static int setup_serial(struct pcmcia_device *handle, struct serial_=
info * info,
> +static int setup_serial(struct pcmcia_device *handle, struct serial_=
info *info,

ok

>  			unsigned int iobase, int irq)
>  {
>  	struct uart_8250_port uart;
> @@ -600,7 +600,7 @@ static int serial_check_for_multi(struct pcmcia_d=
evice *p_dev,  void *priv_data)
>  }
> =20
> =20
> -static int serial_config(struct pcmcia_device * link)
> +static int serial_config(struct pcmcia_device *link)

ok

>  {
>  	struct serial_info *info =3D link->priv;
>  	int i;
> @@ -701,7 +701,7 @@ static const struct pcmcia_device_id serial_ids[]=
 =3D {
>  	PCMCIA_PFC_DEVICE_PROD_ID12(1, "LINKSYS", "PCMLM336", 0xf7cb0b07, 0=
x7a821b58),
>  	PCMCIA_PFC_DEVICE_PROD_ID12(1, "MEGAHERTZ", "XJEM1144/CCEM1144", 0x=
f510db04, 0x52d21e1e),
>  	PCMCIA_PFC_DEVICE_PROD_ID12(1, "MICRO RESEARCH", "COMBO-L/M-336", 0=
xb2ced065, 0x3ced0555),
> -	PCMCIA_PFC_DEVICE_PROD_ID12(1, "NEC", "PK-UG-J001" ,0x18df0ba0 ,0x8=
31b1064),
> +	PCMCIA_PFC_DEVICE_PROD_ID12(1, "NEC", "PK-UG-J001", 0x18df0ba0, 0x8=
31b1064),

ok


>  	PCMCIA_PFC_DEVICE_PROD_ID12(1, "Ositech", "Trumpcard:Jack of Diamon=
ds Modem+Ethernet", 0xc2f80cd, 0x656947b9),
>  	PCMCIA_PFC_DEVICE_PROD_ID12(1, "Ositech", "Trumpcard:Jack of Hearts=
 Modem+Ethernet", 0xc2f80cd, 0xdc9ba5ed),
>  	PCMCIA_PFC_DEVICE_PROD_ID12(1, "PCMCIAs", "ComboCard", 0xdcfe12d3, =
0xcd8906cc),
> @@ -797,30 +797,30 @@ static const struct pcmcia_device_id serial_ids=
[] =3D {
>  	PCMCIA_DEVICE_CIS_PROD_ID123("ADVANTECH", "COMpad-32/85", "1.0", 0x=
96913a85, 0x8fbe92ae, 0x0877b627, "cis/COMpad2.cis"),
>  	PCMCIA_DEVICE_CIS_PROD_ID2("RS-COM 2P", 0xad20b156, "cis/RS-COM-2P.=
cis"),
>  	PCMCIA_DEVICE_CIS_MANF_CARD(0x0013, 0x0000, "cis/GLOBETROTTER.cis")=
,
> -	PCMCIA_DEVICE_PROD_ID12("ELAN DIGITAL SYSTEMS LTD, c1997.","SERIAL =
CARD: SL100  1.00.",0x19ca78af,0xf964f42b),
> -	PCMCIA_DEVICE_PROD_ID12("ELAN DIGITAL SYSTEMS LTD, c1997.","SERIAL =
CARD: SL100",0x19ca78af,0x71d98e83),
> -	PCMCIA_DEVICE_PROD_ID12("ELAN DIGITAL SYSTEMS LTD, c1997.","SERIAL =
CARD: SL232  1.00.",0x19ca78af,0x69fb7490),
> -	PCMCIA_DEVICE_PROD_ID12("ELAN DIGITAL SYSTEMS LTD, c1997.","SERIAL =
CARD: SL232",0x19ca78af,0xb6bc0235),
> -	PCMCIA_DEVICE_PROD_ID12("ELAN DIGITAL SYSTEMS LTD, c2000.","SERIAL =
CARD: CF232",0x63f2e0bd,0xb9e175d3),
> -	PCMCIA_DEVICE_PROD_ID12("ELAN DIGITAL SYSTEMS LTD, c2000.","SERIAL =
CARD: CF232-5",0x63f2e0bd,0xfce33442),
> -	PCMCIA_DEVICE_PROD_ID12("Elan","Serial Port: CF232",0x3beb8cf2,0x17=
1e7190),
> -	PCMCIA_DEVICE_PROD_ID12("Elan","Serial Port: CF232-5",0x3beb8cf2,0x=
20da4262),
> -	PCMCIA_DEVICE_PROD_ID12("Elan","Serial Port: CF428",0x3beb8cf2,0xea=
5dd57d),
> -	PCMCIA_DEVICE_PROD_ID12("Elan","Serial Port: CF500",0x3beb8cf2,0xd7=
7255fa),
> -	PCMCIA_DEVICE_PROD_ID12("Elan","Serial Port: IC232",0x3beb8cf2,0x6a=
709903),
> -	PCMCIA_DEVICE_PROD_ID12("Elan","Serial Port: SL232",0x3beb8cf2,0x18=
430676),
> -	PCMCIA_DEVICE_PROD_ID12("Elan","Serial Port: XL232",0x3beb8cf2,0x6f=
933767),
> -	PCMCIA_MFC_DEVICE_PROD_ID12(0,"Elan","Serial Port: CF332",0x3beb8cf=
2,0x16dc1ba7),
> -	PCMCIA_MFC_DEVICE_PROD_ID12(0,"Elan","Serial Port: SL332",0x3beb8cf=
2,0x19816c41),
> -	PCMCIA_MFC_DEVICE_PROD_ID12(0,"Elan","Serial Port: SL385",0x3beb8cf=
2,0x64112029),
> -	PCMCIA_MFC_DEVICE_PROD_ID12(0,"Elan","Serial Port: SL432",0x3beb8cf=
2,0x1cce7ac4),
> -	PCMCIA_MFC_DEVICE_PROD_ID12(0,"Elan","Serial+Parallel Port: SP230",=
0x3beb8cf2,0xdb9e58bc),
> -	PCMCIA_MFC_DEVICE_PROD_ID12(1,"Elan","Serial Port: CF332",0x3beb8cf=
2,0x16dc1ba7),
> -	PCMCIA_MFC_DEVICE_PROD_ID12(1,"Elan","Serial Port: SL332",0x3beb8cf=
2,0x19816c41),
> -	PCMCIA_MFC_DEVICE_PROD_ID12(1,"Elan","Serial Port: SL385",0x3beb8cf=
2,0x64112029),
> -	PCMCIA_MFC_DEVICE_PROD_ID12(1,"Elan","Serial Port: SL432",0x3beb8cf=
2,0x1cce7ac4),
> -	PCMCIA_MFC_DEVICE_PROD_ID12(2,"Elan","Serial Port: SL432",0x3beb8cf=
2,0x1cce7ac4),
> -	PCMCIA_MFC_DEVICE_PROD_ID12(3,"Elan","Serial Port: SL432",0x3beb8cf=
2,0x1cce7ac4),
> +	PCMCIA_DEVICE_PROD_ID12("ELAN DIGITAL SYSTEMS LTD, c1997.", "SERIAL=
 CARD: SL100  1.00.", 0x19ca78af, 0xf964f42b),
> +	PCMCIA_DEVICE_PROD_ID12("ELAN DIGITAL SYSTEMS LTD, c1997.", "SERIAL=
 CARD: SL100", 0x19ca78af, 0x71d98e83),
> +	PCMCIA_DEVICE_PROD_ID12("ELAN DIGITAL SYSTEMS LTD, c1997.", "SERIAL=
 CARD: SL232  1.00.", 0x19ca78af, 0x69fb7490),
> +	PCMCIA_DEVICE_PROD_ID12("ELAN DIGITAL SYSTEMS LTD, c1997.", "SERIAL=
 CARD: SL232", 0x19ca78af, 0xb6bc0235),
> +	PCMCIA_DEVICE_PROD_ID12("ELAN DIGITAL SYSTEMS LTD, c2000.", "SERIAL=
 CARD: CF232", 0x63f2e0bd, 0xb9e175d3),
> +	PCMCIA_DEVICE_PROD_ID12("ELAN DIGITAL SYSTEMS LTD, c2000.", "SERIAL=
 CARD: CF232-5", 0x63f2e0bd, 0xfce33442),
> +	PCMCIA_DEVICE_PROD_ID12("Elan", "Serial Port: CF232", 0x3beb8cf2, 0=
x171e7190),
> +	PCMCIA_DEVICE_PROD_ID12("Elan", "Serial Port: CF232-5", 0x3beb8cf2,=
 0x20da4262),
> +	PCMCIA_DEVICE_PROD_ID12("Elan", "Serial Port: CF428", 0x3beb8cf2, 0=
xea5dd57d),
> +	PCMCIA_DEVICE_PROD_ID12("Elan", "Serial Port: CF500", 0x3beb8cf2, 0=
xd77255fa),
> +	PCMCIA_DEVICE_PROD_ID12("Elan", "Serial Port: IC232", 0x3beb8cf2, 0=
x6a709903),
> +	PCMCIA_DEVICE_PROD_ID12("Elan", "Serial Port: SL232", 0x3beb8cf2, 0=
x18430676),
> +	PCMCIA_DEVICE_PROD_ID12("Elan", "Serial Port: XL232", 0x3beb8cf2, 0=
x6f933767),
> +	PCMCIA_MFC_DEVICE_PROD_ID12(0, "Elan", "Serial Port: CF332", 0x3beb=
8cf2, 0x16dc1ba7),
> +	PCMCIA_MFC_DEVICE_PROD_ID12(0, "Elan", "Serial Port: SL332", 0x3beb=
8cf2, 0x19816c41),
> +	PCMCIA_MFC_DEVICE_PROD_ID12(0, "Elan", "Serial Port: SL385", 0x3beb=
8cf2, 0x64112029),
> +	PCMCIA_MFC_DEVICE_PROD_ID12(0, "Elan", "Serial Port: SL432", 0x3beb=
8cf2, 0x1cce7ac4),
> +	PCMCIA_MFC_DEVICE_PROD_ID12(0, "Elan", "Serial+Parallel Port: SP230=
", 0x3beb8cf2, 0xdb9e58bc),
> +	PCMCIA_MFC_DEVICE_PROD_ID12(1, "Elan", "Serial Port: CF332", 0x3beb=
8cf2, 0x16dc1ba7),
> +	PCMCIA_MFC_DEVICE_PROD_ID12(1, "Elan", "Serial Port: SL332", 0x3beb=
8cf2, 0x19816c41),
> +	PCMCIA_MFC_DEVICE_PROD_ID12(1, "Elan", "Serial Port: SL385", 0x3beb=
8cf2, 0x64112029),
> +	PCMCIA_MFC_DEVICE_PROD_ID12(1, "Elan", "Serial Port: SL432", 0x3beb=
8cf2, 0x1cce7ac4),
> +	PCMCIA_MFC_DEVICE_PROD_ID12(2, "Elan", "Serial Port: SL432", 0x3beb=
8cf2, 0x1cce7ac4),
> +	PCMCIA_MFC_DEVICE_PROD_ID12(3, "Elan", "Serial Port: SL432", 0x3beb=
8cf2, 0x1cce7ac4),
>  	PCMCIA_DEVICE_MANF_CARD(0x0279, 0x950b),
>  	/* too generic */
>  	/* PCMCIA_MFC_DEVICE_MANF_CARD(0, 0x0160, 0x0002), */

ok


--
To unsubscribe from this list: send the line "unsubscribe linux-parisc"=
 in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

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

* Re: [PATCH 01/11] tty: serial: 8250: Fix whitespace errors
@ 2015-12-16 16:43     ` Peter Hurley
  0 siblings, 0 replies; 60+ messages in thread
From: Peter Hurley @ 2015-12-16 16:43 UTC (permalink / raw)
  To: Anton Wuerfel
  Cc: linux-serial, Greg Kroah-Hartman, Jiri Slaby,
	James E.J. Bottomley, Helge Deller, Heikki Krogerus,
	Andy Shevchenko, Qipeng Zha, Desmond Liu, Wang Long,
	Matt Redfearn, Paul Burton, Ralf Baechle, Krzysztof Kozlowski,
	Peter Hung, Soeren Grunewald, Adam Lee, Maciej S. Szmigiero,
	Mans Rullgard, linux-kernel, linux-parisc, linux-kernel,
	Phillip Raffeck

Hi Anton,

On 12/16/2015 07:36 AM, Anton Wuerfel wrote:
> This patch fixes whitespace errors reported by checkpatch to increase
> readability. Main focus is on missing spaces after commas in
> function headers and macros (like foo,bar edited to foo, bar).

Comments below.

> 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_accent.c        |  2 +-
>  drivers/tty/serial/8250/8250_acorn.c         |  2 +-
>  drivers/tty/serial/8250/8250_boca.c          |  2 +-
>  drivers/tty/serial/8250/8250_core.c          |  1 +
>  drivers/tty/serial/8250/8250_dw.c            |  6 +++
>  drivers/tty/serial/8250/8250_exar_st16c554.c |  2 +-
>  drivers/tty/serial/8250/8250_fourport.c      |  2 +-
>  drivers/tty/serial/8250/8250_hp300.c         |  1 +
>  drivers/tty/serial/8250/8250_hub6.c          |  2 +-
>  drivers/tty/serial/8250/8250_pci.c           |  7 +++-
>  drivers/tty/serial/8250/8250_port.c          |  3 ++
>  drivers/tty/serial/8250/serial_cs.c          | 58 ++++++++++++++--------------
>  12 files changed, 52 insertions(+), 36 deletions(-)
> 
> diff --git a/drivers/tty/serial/8250/8250_accent.c b/drivers/tty/serial/8250/8250_accent.c
> index 34b51c6..c480729 100644
> --- a/drivers/tty/serial/8250/8250_accent.c
> +++ b/drivers/tty/serial/8250/8250_accent.c
> @@ -10,7 +10,7 @@
>  #include <linux/init.h>
>  #include <linux/serial_8250.h>
>  
> -#define PORT(_base,_irq)				\
> +#define PORT(_base, _irq)				\

ok

>  	{						\
>  		.iobase		= _base,		\
>  		.irq		= _irq,			\
> diff --git a/drivers/tty/serial/8250/8250_acorn.c b/drivers/tty/serial/8250/8250_acorn.c
> index 549aa07..402dfdd 100644
> --- a/drivers/tty/serial/8250/8250_acorn.c
> +++ b/drivers/tty/serial/8250/8250_acorn.c
> @@ -70,7 +70,7 @@ serial_card_probe(struct expansion_card *ec, const struct ecard_id *id)
>  	uart.port.regshift	= 2;
>  	uart.port.dev	= &ec->dev;
>  
> -	for (i = 0; i < info->num_ports; i ++) {
> +	for (i = 0; i < info->num_ports; i++) {

Ok

>  		uart.port.membase = info->vaddr + type->offset[i];
>  		uart.port.mapbase = bus_addr + type->offset[i];
>  
> diff --git a/drivers/tty/serial/8250/8250_boca.c b/drivers/tty/serial/8250/8250_boca.c
> index d125dc1..e42a5b5 100644
> --- a/drivers/tty/serial/8250/8250_boca.c
> +++ b/drivers/tty/serial/8250/8250_boca.c
> @@ -10,7 +10,7 @@
>  #include <linux/init.h>
>  #include <linux/serial_8250.h>
>  
> -#define PORT(_base,_irq)				\
> +#define PORT(_base, _irq)				\

Ok

>  	{						\
>  		.iobase		= _base,		\
>  		.irq		= _irq,			\
> diff --git a/drivers/tty/serial/8250/8250_core.c b/drivers/tty/serial/8250/8250_core.c
> index 3912646..89a20c9 100644
> --- a/drivers/tty/serial/8250/8250_core.c
> +++ b/drivers/tty/serial/8250/8250_core.c
> @@ -756,6 +756,7 @@ void serial8250_suspend_port(int line)
>  	if (!console_suspend_enabled && uart_console(port) &&
>  	    port->type != PORT_8250) {
>  		unsigned char canary = 0xa5;
> +

Not ok.

>  		serial_out(up, UART_SCR, canary);
>  		if (serial_in(up, UART_SCR) == canary)
>  			up->canary = canary;
> diff --git a/drivers/tty/serial/8250/8250_dw.c b/drivers/tty/serial/8250/8250_dw.c
> index a5d319e..0f67355 100644
> --- a/drivers/tty/serial/8250/8250_dw.c
> +++ b/drivers/tty/serial/8250/8250_dw.c
> @@ -102,8 +102,10 @@ static void dw8250_serial_out(struct uart_port *p, int offset, int value)
>  	/* Make sure LCR write wasn't ignored */
>  	if (offset == UART_LCR) {
>  		int tries = 1000;
> +

Not ok.

>  		while (tries--) {
>  			unsigned int lcr = p->serial_in(p, UART_LCR);
> +
>  			if ((value & ~UART_LCR_SPAR) == (lcr & ~UART_LCR_SPAR))
>  				return;
>  			dw8250_force_idle(p);
> @@ -143,8 +145,10 @@ static void dw8250_serial_outq(struct uart_port *p, int offset, int value)
>  	/* Make sure LCR write wasn't ignored */
>  	if (offset == UART_LCR) {
>  		int tries = 1000;
> +

Not ok.

>  		while (tries--) {
>  			unsigned int lcr = p->serial_in(p, UART_LCR);
> +

Not ok.

In particular, I dislike separation between initialized variables and
following statements, _especially_ when the initialization is non-trivial.


>  			if ((value & ~UART_LCR_SPAR) == (lcr & ~UART_LCR_SPAR))
>  				return;
>  			dw8250_force_idle(p);
> @@ -166,8 +170,10 @@ static void dw8250_serial_out32(struct uart_port *p, int offset, int value)
>  	/* Make sure LCR write wasn't ignored */
>  	if (offset == UART_LCR) {
>  		int tries = 1000;
> +

Not ok.

>  		while (tries--) {
>  			unsigned int lcr = p->serial_in(p, UART_LCR);
> +

Not ok.

>  			if ((value & ~UART_LCR_SPAR) == (lcr & ~UART_LCR_SPAR))
>  				return;
>  			dw8250_force_idle(p);
> diff --git a/drivers/tty/serial/8250/8250_exar_st16c554.c b/drivers/tty/serial/8250/8250_exar_st16c554.c
> index bf53aab..999f2d3 100644
> --- a/drivers/tty/serial/8250/8250_exar_st16c554.c
> +++ b/drivers/tty/serial/8250/8250_exar_st16c554.c
> @@ -13,7 +13,7 @@
>  #include <linux/init.h>
>  #include <linux/serial_8250.h>
>  
> -#define PORT(_base,_irq)				\
> +#define PORT(_base, _irq)				\

Ok

>  	{						\
>  		.iobase		= _base,		\
>  		.irq		= _irq,			\
> diff --git a/drivers/tty/serial/8250/8250_fourport.c b/drivers/tty/serial/8250/8250_fourport.c
> index be15826..9a04a8a 100644
> --- a/drivers/tty/serial/8250/8250_fourport.c
> +++ b/drivers/tty/serial/8250/8250_fourport.c
> @@ -10,7 +10,7 @@
>  #include <linux/init.h>
>  #include <linux/serial_8250.h>
>  
> -#define PORT(_base,_irq)						\
> +#define PORT(_base, _irq)						\

Ok

>  	{								\
>  		.iobase		= _base,				\
>  		.irq		= _irq,					\
> diff --git a/drivers/tty/serial/8250/8250_hp300.c b/drivers/tty/serial/8250/8250_hp300.c
> index 2891958..38d8cb2 100644
> --- a/drivers/tty/serial/8250/8250_hp300.c
> +++ b/drivers/tty/serial/8250/8250_hp300.c
> @@ -125,6 +125,7 @@ int __init hp300_setup_serial_console(void)
>  	} else {
>  #ifdef CONFIG_HPDCA
>  		unsigned long pa = dio_scodetophysaddr(scode);
> +
>  		if (!pa)
>  			return 0;

Not ok.

This is a particularly good example of how bad that style is.
The relevant code is the call to dio_scode_tophysaddr() _not the if (!pa)_

Newline after uninitialized vars - ok.
Newline after initialized vars - not ok. Unless trivial initialization and
you wrote it.


> diff --git a/drivers/tty/serial/8250/8250_hub6.c b/drivers/tty/serial/8250/8250_hub6.c
> index a5c778e..27124e2 100644
> --- a/drivers/tty/serial/8250/8250_hub6.c
> +++ b/drivers/tty/serial/8250/8250_hub6.c
> @@ -10,7 +10,7 @@
>  #include <linux/init.h>
>  #include <linux/serial_8250.h>
>  
> -#define HUB6(card,port)							\
> +#define HUB6(card, port)						\

ok

>  	{								\
>  		.iobase		= 0x302,				\
>  		.irq		= 3,					\
> diff --git a/drivers/tty/serial/8250/8250_pci.c b/drivers/tty/serial/8250/8250_pci.c
> index 4097f3f..ed99fdf 100644
> --- a/drivers/tty/serial/8250/8250_pci.c
> +++ b/drivers/tty/serial/8250/8250_pci.c
> @@ -113,6 +113,7 @@ static int addidata_apci7800_setup(struct serial_private *priv,
>  				struct uart_8250_port *port, int idx)
>  {
>  	unsigned int bar = 0, offset = board->first_offset;
> +

not ok

>  	bar = FL_GET_BASE(board->flags);
>  
>  	if (idx < 2) {
> @@ -1115,6 +1116,7 @@ static struct quatech_feature quatech_cards[] = {
>  static int pci_quatech_amcc(u16 devid)
>  {
>  	struct quatech_feature *qf = &quatech_cards[0];
> +

not ok

>  	while (qf->devid) {
>  		if (qf->devid == devid)
>  			return qf->amcc;
> @@ -1200,6 +1202,7 @@ static int pci_quatech_test(struct uart_8250_port *port)
>  {
>  	u8 reg;
>  	u8 qopr = pci_quatech_rqopr(port);
> +

Swap the declaration order and its ok. IOW,

+ 	u8 qopr = pci_quatech_rqopr(port);
+ 	u8 reg;
+

or even better

+ 	u8 reg, qopr;
+
+ 	qopr = pci_quatech_rqopr(port);

>  	pci_quatech_wqopr(port, qopr & QPCR_TEST_FOR1);
>  	reg = pci_quatech_rqopr(port) & 0xC0;
>  	if (reg != QPCR_TEST_GET1)
> @@ -1284,8 +1287,10 @@ static int pci_quatech_init(struct pci_dev *dev)
>  {
>  	if (pci_quatech_amcc(dev->device)) {
>  		unsigned long base = pci_resource_start(dev, 0);
> +

not ok


>  		if (base) {
>  			u32 tmp;
> +

ok

>  			outl(inl(base + 0x38) | 0x00002000, base + 0x38);
>  			tmp = inl(base + 0x3c);
>  			outl(tmp | 0x01000000, base + 0x3c);
> @@ -4502,7 +4507,7 @@ static struct pci_device_id serial_pci_tbl[] = {
>  		PCI_ANY_ID, PCI_ANY_ID, 0, 0,
>  		pbn_b0_bt_2_921600 },
>  	{	PCI_VENDOR_ID_OXSEMI, PCI_DEVICE_ID_OXSEMI_16PCI958,
> -		PCI_ANY_ID , PCI_ANY_ID, 0, 0,
> +		PCI_ANY_ID, PCI_ANY_ID, 0, 0,

ok

>  		pbn_b2_8_1152000 },
>  
>  	/*
> diff --git a/drivers/tty/serial/8250/8250_port.c b/drivers/tty/serial/8250/8250_port.c
> index 52d82d2..ae8f993 100644
> --- a/drivers/tty/serial/8250/8250_port.c
> +++ b/drivers/tty/serial/8250/8250_port.c
> @@ -1327,6 +1327,7 @@ static void serial8250_start_tx(struct uart_port *port)
>  
>  		if (up->bugs & UART_BUG_TXEN) {
>  			unsigned char lsr;
> +

ok

>  			lsr = serial_in(up, UART_LSR);
>  			up->lsr_saved_flags |= lsr & LSR_SAVE_FLAGS;
>  			if (lsr & UART_LSR_THRE)
> @@ -1734,8 +1735,10 @@ static void wait_for_xmitr(struct uart_8250_port *up, int bits)
>  	/* Wait up to 1s for flow control if necessary */
>  	if (up->port.flags & UPF_CONS_FLOW) {
>  		unsigned int tmout;
> +

ok

>  		for (tmout = 1000000; tmout; tmout--) {
>  			unsigned int msr = serial_in(up, UART_MSR);
> +

not ok

>  			up->msr_saved_flags |= msr & MSR_SAVE_FLAGS;
>  			if (msr & UART_MSR_CTS)
>  				break;
> diff --git a/drivers/tty/serial/8250/serial_cs.c b/drivers/tty/serial/8250/serial_cs.c
> index 4d180c9..f5270ba 100644
> --- a/drivers/tty/serial/8250/serial_cs.c
> +++ b/drivers/tty/serial/8250/serial_cs.c
> @@ -257,7 +257,7 @@ static const struct serial_quirk quirks[] = {
>  };
>  
>  
> -static int serial_config(struct pcmcia_device * link);
> +static int serial_config(struct pcmcia_device *link);

ok

>  
>  
>  static void serial_remove(struct pcmcia_device *link)
> @@ -309,7 +309,7 @@ static int serial_probe(struct pcmcia_device *link)
>  	dev_dbg(&link->dev, "serial_attach()\n");
>  
>  	/* Create new serial device */
> -	info = kzalloc(sizeof (*info), GFP_KERNEL);
> +	info = kzalloc(sizeof(*info), GFP_KERNEL);

ok

>  	if (!info)
>  		return -ENOMEM;
>  	info->p_dev = link;
> @@ -339,7 +339,7 @@ static void serial_detach(struct pcmcia_device *link)
>  
>  /*====================================================================*/
>  
> -static int setup_serial(struct pcmcia_device *handle, struct serial_info * info,
> +static int setup_serial(struct pcmcia_device *handle, struct serial_info *info,

ok

>  			unsigned int iobase, int irq)
>  {
>  	struct uart_8250_port uart;
> @@ -600,7 +600,7 @@ static int serial_check_for_multi(struct pcmcia_device *p_dev,  void *priv_data)
>  }
>  
>  
> -static int serial_config(struct pcmcia_device * link)
> +static int serial_config(struct pcmcia_device *link)

ok

>  {
>  	struct serial_info *info = link->priv;
>  	int i;
> @@ -701,7 +701,7 @@ static const struct pcmcia_device_id serial_ids[] = {
>  	PCMCIA_PFC_DEVICE_PROD_ID12(1, "LINKSYS", "PCMLM336", 0xf7cb0b07, 0x7a821b58),
>  	PCMCIA_PFC_DEVICE_PROD_ID12(1, "MEGAHERTZ", "XJEM1144/CCEM1144", 0xf510db04, 0x52d21e1e),
>  	PCMCIA_PFC_DEVICE_PROD_ID12(1, "MICRO RESEARCH", "COMBO-L/M-336", 0xb2ced065, 0x3ced0555),
> -	PCMCIA_PFC_DEVICE_PROD_ID12(1, "NEC", "PK-UG-J001" ,0x18df0ba0 ,0x831b1064),
> +	PCMCIA_PFC_DEVICE_PROD_ID12(1, "NEC", "PK-UG-J001", 0x18df0ba0, 0x831b1064),

ok


>  	PCMCIA_PFC_DEVICE_PROD_ID12(1, "Ositech", "Trumpcard:Jack of Diamonds Modem+Ethernet", 0xc2f80cd, 0x656947b9),
>  	PCMCIA_PFC_DEVICE_PROD_ID12(1, "Ositech", "Trumpcard:Jack of Hearts Modem+Ethernet", 0xc2f80cd, 0xdc9ba5ed),
>  	PCMCIA_PFC_DEVICE_PROD_ID12(1, "PCMCIAs", "ComboCard", 0xdcfe12d3, 0xcd8906cc),
> @@ -797,30 +797,30 @@ static const struct pcmcia_device_id serial_ids[] = {
>  	PCMCIA_DEVICE_CIS_PROD_ID123("ADVANTECH", "COMpad-32/85", "1.0", 0x96913a85, 0x8fbe92ae, 0x0877b627, "cis/COMpad2.cis"),
>  	PCMCIA_DEVICE_CIS_PROD_ID2("RS-COM 2P", 0xad20b156, "cis/RS-COM-2P.cis"),
>  	PCMCIA_DEVICE_CIS_MANF_CARD(0x0013, 0x0000, "cis/GLOBETROTTER.cis"),
> -	PCMCIA_DEVICE_PROD_ID12("ELAN DIGITAL SYSTEMS LTD, c1997.","SERIAL CARD: SL100  1.00.",0x19ca78af,0xf964f42b),
> -	PCMCIA_DEVICE_PROD_ID12("ELAN DIGITAL SYSTEMS LTD, c1997.","SERIAL CARD: SL100",0x19ca78af,0x71d98e83),
> -	PCMCIA_DEVICE_PROD_ID12("ELAN DIGITAL SYSTEMS LTD, c1997.","SERIAL CARD: SL232  1.00.",0x19ca78af,0x69fb7490),
> -	PCMCIA_DEVICE_PROD_ID12("ELAN DIGITAL SYSTEMS LTD, c1997.","SERIAL CARD: SL232",0x19ca78af,0xb6bc0235),
> -	PCMCIA_DEVICE_PROD_ID12("ELAN DIGITAL SYSTEMS LTD, c2000.","SERIAL CARD: CF232",0x63f2e0bd,0xb9e175d3),
> -	PCMCIA_DEVICE_PROD_ID12("ELAN DIGITAL SYSTEMS LTD, c2000.","SERIAL CARD: CF232-5",0x63f2e0bd,0xfce33442),
> -	PCMCIA_DEVICE_PROD_ID12("Elan","Serial Port: CF232",0x3beb8cf2,0x171e7190),
> -	PCMCIA_DEVICE_PROD_ID12("Elan","Serial Port: CF232-5",0x3beb8cf2,0x20da4262),
> -	PCMCIA_DEVICE_PROD_ID12("Elan","Serial Port: CF428",0x3beb8cf2,0xea5dd57d),
> -	PCMCIA_DEVICE_PROD_ID12("Elan","Serial Port: CF500",0x3beb8cf2,0xd77255fa),
> -	PCMCIA_DEVICE_PROD_ID12("Elan","Serial Port: IC232",0x3beb8cf2,0x6a709903),
> -	PCMCIA_DEVICE_PROD_ID12("Elan","Serial Port: SL232",0x3beb8cf2,0x18430676),
> -	PCMCIA_DEVICE_PROD_ID12("Elan","Serial Port: XL232",0x3beb8cf2,0x6f933767),
> -	PCMCIA_MFC_DEVICE_PROD_ID12(0,"Elan","Serial Port: CF332",0x3beb8cf2,0x16dc1ba7),
> -	PCMCIA_MFC_DEVICE_PROD_ID12(0,"Elan","Serial Port: SL332",0x3beb8cf2,0x19816c41),
> -	PCMCIA_MFC_DEVICE_PROD_ID12(0,"Elan","Serial Port: SL385",0x3beb8cf2,0x64112029),
> -	PCMCIA_MFC_DEVICE_PROD_ID12(0,"Elan","Serial Port: SL432",0x3beb8cf2,0x1cce7ac4),
> -	PCMCIA_MFC_DEVICE_PROD_ID12(0,"Elan","Serial+Parallel Port: SP230",0x3beb8cf2,0xdb9e58bc),
> -	PCMCIA_MFC_DEVICE_PROD_ID12(1,"Elan","Serial Port: CF332",0x3beb8cf2,0x16dc1ba7),
> -	PCMCIA_MFC_DEVICE_PROD_ID12(1,"Elan","Serial Port: SL332",0x3beb8cf2,0x19816c41),
> -	PCMCIA_MFC_DEVICE_PROD_ID12(1,"Elan","Serial Port: SL385",0x3beb8cf2,0x64112029),
> -	PCMCIA_MFC_DEVICE_PROD_ID12(1,"Elan","Serial Port: SL432",0x3beb8cf2,0x1cce7ac4),
> -	PCMCIA_MFC_DEVICE_PROD_ID12(2,"Elan","Serial Port: SL432",0x3beb8cf2,0x1cce7ac4),
> -	PCMCIA_MFC_DEVICE_PROD_ID12(3,"Elan","Serial Port: SL432",0x3beb8cf2,0x1cce7ac4),
> +	PCMCIA_DEVICE_PROD_ID12("ELAN DIGITAL SYSTEMS LTD, c1997.", "SERIAL CARD: SL100  1.00.", 0x19ca78af, 0xf964f42b),
> +	PCMCIA_DEVICE_PROD_ID12("ELAN DIGITAL SYSTEMS LTD, c1997.", "SERIAL CARD: SL100", 0x19ca78af, 0x71d98e83),
> +	PCMCIA_DEVICE_PROD_ID12("ELAN DIGITAL SYSTEMS LTD, c1997.", "SERIAL CARD: SL232  1.00.", 0x19ca78af, 0x69fb7490),
> +	PCMCIA_DEVICE_PROD_ID12("ELAN DIGITAL SYSTEMS LTD, c1997.", "SERIAL CARD: SL232", 0x19ca78af, 0xb6bc0235),
> +	PCMCIA_DEVICE_PROD_ID12("ELAN DIGITAL SYSTEMS LTD, c2000.", "SERIAL CARD: CF232", 0x63f2e0bd, 0xb9e175d3),
> +	PCMCIA_DEVICE_PROD_ID12("ELAN DIGITAL SYSTEMS LTD, c2000.", "SERIAL CARD: CF232-5", 0x63f2e0bd, 0xfce33442),
> +	PCMCIA_DEVICE_PROD_ID12("Elan", "Serial Port: CF232", 0x3beb8cf2, 0x171e7190),
> +	PCMCIA_DEVICE_PROD_ID12("Elan", "Serial Port: CF232-5", 0x3beb8cf2, 0x20da4262),
> +	PCMCIA_DEVICE_PROD_ID12("Elan", "Serial Port: CF428", 0x3beb8cf2, 0xea5dd57d),
> +	PCMCIA_DEVICE_PROD_ID12("Elan", "Serial Port: CF500", 0x3beb8cf2, 0xd77255fa),
> +	PCMCIA_DEVICE_PROD_ID12("Elan", "Serial Port: IC232", 0x3beb8cf2, 0x6a709903),
> +	PCMCIA_DEVICE_PROD_ID12("Elan", "Serial Port: SL232", 0x3beb8cf2, 0x18430676),
> +	PCMCIA_DEVICE_PROD_ID12("Elan", "Serial Port: XL232", 0x3beb8cf2, 0x6f933767),
> +	PCMCIA_MFC_DEVICE_PROD_ID12(0, "Elan", "Serial Port: CF332", 0x3beb8cf2, 0x16dc1ba7),
> +	PCMCIA_MFC_DEVICE_PROD_ID12(0, "Elan", "Serial Port: SL332", 0x3beb8cf2, 0x19816c41),
> +	PCMCIA_MFC_DEVICE_PROD_ID12(0, "Elan", "Serial Port: SL385", 0x3beb8cf2, 0x64112029),
> +	PCMCIA_MFC_DEVICE_PROD_ID12(0, "Elan", "Serial Port: SL432", 0x3beb8cf2, 0x1cce7ac4),
> +	PCMCIA_MFC_DEVICE_PROD_ID12(0, "Elan", "Serial+Parallel Port: SP230", 0x3beb8cf2, 0xdb9e58bc),
> +	PCMCIA_MFC_DEVICE_PROD_ID12(1, "Elan", "Serial Port: CF332", 0x3beb8cf2, 0x16dc1ba7),
> +	PCMCIA_MFC_DEVICE_PROD_ID12(1, "Elan", "Serial Port: SL332", 0x3beb8cf2, 0x19816c41),
> +	PCMCIA_MFC_DEVICE_PROD_ID12(1, "Elan", "Serial Port: SL385", 0x3beb8cf2, 0x64112029),
> +	PCMCIA_MFC_DEVICE_PROD_ID12(1, "Elan", "Serial Port: SL432", 0x3beb8cf2, 0x1cce7ac4),
> +	PCMCIA_MFC_DEVICE_PROD_ID12(2, "Elan", "Serial Port: SL432", 0x3beb8cf2, 0x1cce7ac4),
> +	PCMCIA_MFC_DEVICE_PROD_ID12(3, "Elan", "Serial Port: SL432", 0x3beb8cf2, 0x1cce7ac4),
>  	PCMCIA_DEVICE_MANF_CARD(0x0279, 0x950b),
>  	/* too generic */
>  	/* PCMCIA_MFC_DEVICE_MANF_CARD(0, 0x0160, 0x0002), */

ok



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

* Re: [PATCH 01/11] tty: serial: 8250: Fix whitespace errors
@ 2015-12-16 16:43     ` Peter Hurley
  0 siblings, 0 replies; 60+ messages in thread
From: Peter Hurley @ 2015-12-16 16:43 UTC (permalink / raw)
  To: Anton Wuerfel
  Cc: linux-serial, Greg Kroah-Hartman, Jiri Slaby,
	James E.J. Bottomley, Helge Deller, Heikki Krogerus,
	Andy Shevchenko, Qipeng Zha, Desmond Liu, Wang Long,
	Matt Redfearn, Paul Burton, Ralf Baechle, Krzysztof Kozlowski,
	Peter Hung, Soeren Grunewald, Adam Lee, Maciej S. Szmigiero,
	Mans Rullgard, linux-kernel, linux-parisc, linux-kernel,
	Phillip Raffeck

Hi Anton,

On 12/16/2015 07:36 AM, Anton Wuerfel wrote:
> This patch fixes whitespace errors reported by checkpatch to increase
> readability. Main focus is on missing spaces after commas in
> function headers and macros (like foo,bar edited to foo, bar).

Comments below.

> 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_accent.c        |  2 +-
>  drivers/tty/serial/8250/8250_acorn.c         |  2 +-
>  drivers/tty/serial/8250/8250_boca.c          |  2 +-
>  drivers/tty/serial/8250/8250_core.c          |  1 +
>  drivers/tty/serial/8250/8250_dw.c            |  6 +++
>  drivers/tty/serial/8250/8250_exar_st16c554.c |  2 +-
>  drivers/tty/serial/8250/8250_fourport.c      |  2 +-
>  drivers/tty/serial/8250/8250_hp300.c         |  1 +
>  drivers/tty/serial/8250/8250_hub6.c          |  2 +-
>  drivers/tty/serial/8250/8250_pci.c           |  7 +++-
>  drivers/tty/serial/8250/8250_port.c          |  3 ++
>  drivers/tty/serial/8250/serial_cs.c          | 58 ++++++++++++++--------------
>  12 files changed, 52 insertions(+), 36 deletions(-)
> 
> diff --git a/drivers/tty/serial/8250/8250_accent.c b/drivers/tty/serial/8250/8250_accent.c
> index 34b51c6..c480729 100644
> --- a/drivers/tty/serial/8250/8250_accent.c
> +++ b/drivers/tty/serial/8250/8250_accent.c
> @@ -10,7 +10,7 @@
>  #include <linux/init.h>
>  #include <linux/serial_8250.h>
>  
> -#define PORT(_base,_irq)				\
> +#define PORT(_base, _irq)				\

ok

>  	{						\
>  		.iobase		= _base,		\
>  		.irq		= _irq,			\
> diff --git a/drivers/tty/serial/8250/8250_acorn.c b/drivers/tty/serial/8250/8250_acorn.c
> index 549aa07..402dfdd 100644
> --- a/drivers/tty/serial/8250/8250_acorn.c
> +++ b/drivers/tty/serial/8250/8250_acorn.c
> @@ -70,7 +70,7 @@ serial_card_probe(struct expansion_card *ec, const struct ecard_id *id)
>  	uart.port.regshift	= 2;
>  	uart.port.dev	= &ec->dev;
>  
> -	for (i = 0; i < info->num_ports; i ++) {
> +	for (i = 0; i < info->num_ports; i++) {

Ok

>  		uart.port.membase = info->vaddr + type->offset[i];
>  		uart.port.mapbase = bus_addr + type->offset[i];
>  
> diff --git a/drivers/tty/serial/8250/8250_boca.c b/drivers/tty/serial/8250/8250_boca.c
> index d125dc1..e42a5b5 100644
> --- a/drivers/tty/serial/8250/8250_boca.c
> +++ b/drivers/tty/serial/8250/8250_boca.c
> @@ -10,7 +10,7 @@
>  #include <linux/init.h>
>  #include <linux/serial_8250.h>
>  
> -#define PORT(_base,_irq)				\
> +#define PORT(_base, _irq)				\

Ok

>  	{						\
>  		.iobase		= _base,		\
>  		.irq		= _irq,			\
> diff --git a/drivers/tty/serial/8250/8250_core.c b/drivers/tty/serial/8250/8250_core.c
> index 3912646..89a20c9 100644
> --- a/drivers/tty/serial/8250/8250_core.c
> +++ b/drivers/tty/serial/8250/8250_core.c
> @@ -756,6 +756,7 @@ void serial8250_suspend_port(int line)
>  	if (!console_suspend_enabled && uart_console(port) &&
>  	    port->type != PORT_8250) {
>  		unsigned char canary = 0xa5;
> +

Not ok.

>  		serial_out(up, UART_SCR, canary);
>  		if (serial_in(up, UART_SCR) == canary)
>  			up->canary = canary;
> diff --git a/drivers/tty/serial/8250/8250_dw.c b/drivers/tty/serial/8250/8250_dw.c
> index a5d319e..0f67355 100644
> --- a/drivers/tty/serial/8250/8250_dw.c
> +++ b/drivers/tty/serial/8250/8250_dw.c
> @@ -102,8 +102,10 @@ static void dw8250_serial_out(struct uart_port *p, int offset, int value)
>  	/* Make sure LCR write wasn't ignored */
>  	if (offset == UART_LCR) {
>  		int tries = 1000;
> +

Not ok.

>  		while (tries--) {
>  			unsigned int lcr = p->serial_in(p, UART_LCR);
> +
>  			if ((value & ~UART_LCR_SPAR) == (lcr & ~UART_LCR_SPAR))
>  				return;
>  			dw8250_force_idle(p);
> @@ -143,8 +145,10 @@ static void dw8250_serial_outq(struct uart_port *p, int offset, int value)
>  	/* Make sure LCR write wasn't ignored */
>  	if (offset == UART_LCR) {
>  		int tries = 1000;
> +

Not ok.

>  		while (tries--) {
>  			unsigned int lcr = p->serial_in(p, UART_LCR);
> +

Not ok.

In particular, I dislike separation between initialized variables and
following statements, _especially_ when the initialization is non-trivial.


>  			if ((value & ~UART_LCR_SPAR) == (lcr & ~UART_LCR_SPAR))
>  				return;
>  			dw8250_force_idle(p);
> @@ -166,8 +170,10 @@ static void dw8250_serial_out32(struct uart_port *p, int offset, int value)
>  	/* Make sure LCR write wasn't ignored */
>  	if (offset == UART_LCR) {
>  		int tries = 1000;
> +

Not ok.

>  		while (tries--) {
>  			unsigned int lcr = p->serial_in(p, UART_LCR);
> +

Not ok.

>  			if ((value & ~UART_LCR_SPAR) == (lcr & ~UART_LCR_SPAR))
>  				return;
>  			dw8250_force_idle(p);
> diff --git a/drivers/tty/serial/8250/8250_exar_st16c554.c b/drivers/tty/serial/8250/8250_exar_st16c554.c
> index bf53aab..999f2d3 100644
> --- a/drivers/tty/serial/8250/8250_exar_st16c554.c
> +++ b/drivers/tty/serial/8250/8250_exar_st16c554.c
> @@ -13,7 +13,7 @@
>  #include <linux/init.h>
>  #include <linux/serial_8250.h>
>  
> -#define PORT(_base,_irq)				\
> +#define PORT(_base, _irq)				\

Ok

>  	{						\
>  		.iobase		= _base,		\
>  		.irq		= _irq,			\
> diff --git a/drivers/tty/serial/8250/8250_fourport.c b/drivers/tty/serial/8250/8250_fourport.c
> index be15826..9a04a8a 100644
> --- a/drivers/tty/serial/8250/8250_fourport.c
> +++ b/drivers/tty/serial/8250/8250_fourport.c
> @@ -10,7 +10,7 @@
>  #include <linux/init.h>
>  #include <linux/serial_8250.h>
>  
> -#define PORT(_base,_irq)						\
> +#define PORT(_base, _irq)						\

Ok

>  	{								\
>  		.iobase		= _base,				\
>  		.irq		= _irq,					\
> diff --git a/drivers/tty/serial/8250/8250_hp300.c b/drivers/tty/serial/8250/8250_hp300.c
> index 2891958..38d8cb2 100644
> --- a/drivers/tty/serial/8250/8250_hp300.c
> +++ b/drivers/tty/serial/8250/8250_hp300.c
> @@ -125,6 +125,7 @@ int __init hp300_setup_serial_console(void)
>  	} else {
>  #ifdef CONFIG_HPDCA
>  		unsigned long pa = dio_scodetophysaddr(scode);
> +
>  		if (!pa)
>  			return 0;

Not ok.

This is a particularly good example of how bad that style is.
The relevant code is the call to dio_scode_tophysaddr() _not the if (!pa)_

Newline after uninitialized vars - ok.
Newline after initialized vars - not ok. Unless trivial initialization and
you wrote it.


> diff --git a/drivers/tty/serial/8250/8250_hub6.c b/drivers/tty/serial/8250/8250_hub6.c
> index a5c778e..27124e2 100644
> --- a/drivers/tty/serial/8250/8250_hub6.c
> +++ b/drivers/tty/serial/8250/8250_hub6.c
> @@ -10,7 +10,7 @@
>  #include <linux/init.h>
>  #include <linux/serial_8250.h>
>  
> -#define HUB6(card,port)							\
> +#define HUB6(card, port)						\

ok

>  	{								\
>  		.iobase		= 0x302,				\
>  		.irq		= 3,					\
> diff --git a/drivers/tty/serial/8250/8250_pci.c b/drivers/tty/serial/8250/8250_pci.c
> index 4097f3f..ed99fdf 100644
> --- a/drivers/tty/serial/8250/8250_pci.c
> +++ b/drivers/tty/serial/8250/8250_pci.c
> @@ -113,6 +113,7 @@ static int addidata_apci7800_setup(struct serial_private *priv,
>  				struct uart_8250_port *port, int idx)
>  {
>  	unsigned int bar = 0, offset = board->first_offset;
> +

not ok

>  	bar = FL_GET_BASE(board->flags);
>  
>  	if (idx < 2) {
> @@ -1115,6 +1116,7 @@ static struct quatech_feature quatech_cards[] = {
>  static int pci_quatech_amcc(u16 devid)
>  {
>  	struct quatech_feature *qf = &quatech_cards[0];
> +

not ok

>  	while (qf->devid) {
>  		if (qf->devid == devid)
>  			return qf->amcc;
> @@ -1200,6 +1202,7 @@ static int pci_quatech_test(struct uart_8250_port *port)
>  {
>  	u8 reg;
>  	u8 qopr = pci_quatech_rqopr(port);
> +

Swap the declaration order and its ok. IOW,

+ 	u8 qopr = pci_quatech_rqopr(port);
+ 	u8 reg;
+

or even better

+ 	u8 reg, qopr;
+
+ 	qopr = pci_quatech_rqopr(port);

>  	pci_quatech_wqopr(port, qopr & QPCR_TEST_FOR1);
>  	reg = pci_quatech_rqopr(port) & 0xC0;
>  	if (reg != QPCR_TEST_GET1)
> @@ -1284,8 +1287,10 @@ static int pci_quatech_init(struct pci_dev *dev)
>  {
>  	if (pci_quatech_amcc(dev->device)) {
>  		unsigned long base = pci_resource_start(dev, 0);
> +

not ok


>  		if (base) {
>  			u32 tmp;
> +

ok

>  			outl(inl(base + 0x38) | 0x00002000, base + 0x38);
>  			tmp = inl(base + 0x3c);
>  			outl(tmp | 0x01000000, base + 0x3c);
> @@ -4502,7 +4507,7 @@ static struct pci_device_id serial_pci_tbl[] = {
>  		PCI_ANY_ID, PCI_ANY_ID, 0, 0,
>  		pbn_b0_bt_2_921600 },
>  	{	PCI_VENDOR_ID_OXSEMI, PCI_DEVICE_ID_OXSEMI_16PCI958,
> -		PCI_ANY_ID , PCI_ANY_ID, 0, 0,
> +		PCI_ANY_ID, PCI_ANY_ID, 0, 0,

ok

>  		pbn_b2_8_1152000 },
>  
>  	/*
> diff --git a/drivers/tty/serial/8250/8250_port.c b/drivers/tty/serial/8250/8250_port.c
> index 52d82d2..ae8f993 100644
> --- a/drivers/tty/serial/8250/8250_port.c
> +++ b/drivers/tty/serial/8250/8250_port.c
> @@ -1327,6 +1327,7 @@ static void serial8250_start_tx(struct uart_port *port)
>  
>  		if (up->bugs & UART_BUG_TXEN) {
>  			unsigned char lsr;
> +

ok

>  			lsr = serial_in(up, UART_LSR);
>  			up->lsr_saved_flags |= lsr & LSR_SAVE_FLAGS;
>  			if (lsr & UART_LSR_THRE)
> @@ -1734,8 +1735,10 @@ static void wait_for_xmitr(struct uart_8250_port *up, int bits)
>  	/* Wait up to 1s for flow control if necessary */
>  	if (up->port.flags & UPF_CONS_FLOW) {
>  		unsigned int tmout;
> +

ok

>  		for (tmout = 1000000; tmout; tmout--) {
>  			unsigned int msr = serial_in(up, UART_MSR);
> +

not ok

>  			up->msr_saved_flags |= msr & MSR_SAVE_FLAGS;
>  			if (msr & UART_MSR_CTS)
>  				break;
> diff --git a/drivers/tty/serial/8250/serial_cs.c b/drivers/tty/serial/8250/serial_cs.c
> index 4d180c9..f5270ba 100644
> --- a/drivers/tty/serial/8250/serial_cs.c
> +++ b/drivers/tty/serial/8250/serial_cs.c
> @@ -257,7 +257,7 @@ static const struct serial_quirk quirks[] = {
>  };
>  
>  
> -static int serial_config(struct pcmcia_device * link);
> +static int serial_config(struct pcmcia_device *link);

ok

>  
>  
>  static void serial_remove(struct pcmcia_device *link)
> @@ -309,7 +309,7 @@ static int serial_probe(struct pcmcia_device *link)
>  	dev_dbg(&link->dev, "serial_attach()\n");
>  
>  	/* Create new serial device */
> -	info = kzalloc(sizeof (*info), GFP_KERNEL);
> +	info = kzalloc(sizeof(*info), GFP_KERNEL);

ok

>  	if (!info)
>  		return -ENOMEM;
>  	info->p_dev = link;
> @@ -339,7 +339,7 @@ static void serial_detach(struct pcmcia_device *link)
>  
>  /*====================================================================*/
>  
> -static int setup_serial(struct pcmcia_device *handle, struct serial_info * info,
> +static int setup_serial(struct pcmcia_device *handle, struct serial_info *info,

ok

>  			unsigned int iobase, int irq)
>  {
>  	struct uart_8250_port uart;
> @@ -600,7 +600,7 @@ static int serial_check_for_multi(struct pcmcia_device *p_dev,  void *priv_data)
>  }
>  
>  
> -static int serial_config(struct pcmcia_device * link)
> +static int serial_config(struct pcmcia_device *link)

ok

>  {
>  	struct serial_info *info = link->priv;
>  	int i;
> @@ -701,7 +701,7 @@ static const struct pcmcia_device_id serial_ids[] = {
>  	PCMCIA_PFC_DEVICE_PROD_ID12(1, "LINKSYS", "PCMLM336", 0xf7cb0b07, 0x7a821b58),
>  	PCMCIA_PFC_DEVICE_PROD_ID12(1, "MEGAHERTZ", "XJEM1144/CCEM1144", 0xf510db04, 0x52d21e1e),
>  	PCMCIA_PFC_DEVICE_PROD_ID12(1, "MICRO RESEARCH", "COMBO-L/M-336", 0xb2ced065, 0x3ced0555),
> -	PCMCIA_PFC_DEVICE_PROD_ID12(1, "NEC", "PK-UG-J001" ,0x18df0ba0 ,0x831b1064),
> +	PCMCIA_PFC_DEVICE_PROD_ID12(1, "NEC", "PK-UG-J001", 0x18df0ba0, 0x831b1064),

ok


>  	PCMCIA_PFC_DEVICE_PROD_ID12(1, "Ositech", "Trumpcard:Jack of Diamonds Modem+Ethernet", 0xc2f80cd, 0x656947b9),
>  	PCMCIA_PFC_DEVICE_PROD_ID12(1, "Ositech", "Trumpcard:Jack of Hearts Modem+Ethernet", 0xc2f80cd, 0xdc9ba5ed),
>  	PCMCIA_PFC_DEVICE_PROD_ID12(1, "PCMCIAs", "ComboCard", 0xdcfe12d3, 0xcd8906cc),
> @@ -797,30 +797,30 @@ static const struct pcmcia_device_id serial_ids[] = {
>  	PCMCIA_DEVICE_CIS_PROD_ID123("ADVANTECH", "COMpad-32/85", "1.0", 0x96913a85, 0x8fbe92ae, 0x0877b627, "cis/COMpad2.cis"),
>  	PCMCIA_DEVICE_CIS_PROD_ID2("RS-COM 2P", 0xad20b156, "cis/RS-COM-2P.cis"),
>  	PCMCIA_DEVICE_CIS_MANF_CARD(0x0013, 0x0000, "cis/GLOBETROTTER.cis"),
> -	PCMCIA_DEVICE_PROD_ID12("ELAN DIGITAL SYSTEMS LTD, c1997.","SERIAL CARD: SL100  1.00.",0x19ca78af,0xf964f42b),
> -	PCMCIA_DEVICE_PROD_ID12("ELAN DIGITAL SYSTEMS LTD, c1997.","SERIAL CARD: SL100",0x19ca78af,0x71d98e83),
> -	PCMCIA_DEVICE_PROD_ID12("ELAN DIGITAL SYSTEMS LTD, c1997.","SERIAL CARD: SL232  1.00.",0x19ca78af,0x69fb7490),
> -	PCMCIA_DEVICE_PROD_ID12("ELAN DIGITAL SYSTEMS LTD, c1997.","SERIAL CARD: SL232",0x19ca78af,0xb6bc0235),
> -	PCMCIA_DEVICE_PROD_ID12("ELAN DIGITAL SYSTEMS LTD, c2000.","SERIAL CARD: CF232",0x63f2e0bd,0xb9e175d3),
> -	PCMCIA_DEVICE_PROD_ID12("ELAN DIGITAL SYSTEMS LTD, c2000.","SERIAL CARD: CF232-5",0x63f2e0bd,0xfce33442),
> -	PCMCIA_DEVICE_PROD_ID12("Elan","Serial Port: CF232",0x3beb8cf2,0x171e7190),
> -	PCMCIA_DEVICE_PROD_ID12("Elan","Serial Port: CF232-5",0x3beb8cf2,0x20da4262),
> -	PCMCIA_DEVICE_PROD_ID12("Elan","Serial Port: CF428",0x3beb8cf2,0xea5dd57d),
> -	PCMCIA_DEVICE_PROD_ID12("Elan","Serial Port: CF500",0x3beb8cf2,0xd77255fa),
> -	PCMCIA_DEVICE_PROD_ID12("Elan","Serial Port: IC232",0x3beb8cf2,0x6a709903),
> -	PCMCIA_DEVICE_PROD_ID12("Elan","Serial Port: SL232",0x3beb8cf2,0x18430676),
> -	PCMCIA_DEVICE_PROD_ID12("Elan","Serial Port: XL232",0x3beb8cf2,0x6f933767),
> -	PCMCIA_MFC_DEVICE_PROD_ID12(0,"Elan","Serial Port: CF332",0x3beb8cf2,0x16dc1ba7),
> -	PCMCIA_MFC_DEVICE_PROD_ID12(0,"Elan","Serial Port: SL332",0x3beb8cf2,0x19816c41),
> -	PCMCIA_MFC_DEVICE_PROD_ID12(0,"Elan","Serial Port: SL385",0x3beb8cf2,0x64112029),
> -	PCMCIA_MFC_DEVICE_PROD_ID12(0,"Elan","Serial Port: SL432",0x3beb8cf2,0x1cce7ac4),
> -	PCMCIA_MFC_DEVICE_PROD_ID12(0,"Elan","Serial+Parallel Port: SP230",0x3beb8cf2,0xdb9e58bc),
> -	PCMCIA_MFC_DEVICE_PROD_ID12(1,"Elan","Serial Port: CF332",0x3beb8cf2,0x16dc1ba7),
> -	PCMCIA_MFC_DEVICE_PROD_ID12(1,"Elan","Serial Port: SL332",0x3beb8cf2,0x19816c41),
> -	PCMCIA_MFC_DEVICE_PROD_ID12(1,"Elan","Serial Port: SL385",0x3beb8cf2,0x64112029),
> -	PCMCIA_MFC_DEVICE_PROD_ID12(1,"Elan","Serial Port: SL432",0x3beb8cf2,0x1cce7ac4),
> -	PCMCIA_MFC_DEVICE_PROD_ID12(2,"Elan","Serial Port: SL432",0x3beb8cf2,0x1cce7ac4),
> -	PCMCIA_MFC_DEVICE_PROD_ID12(3,"Elan","Serial Port: SL432",0x3beb8cf2,0x1cce7ac4),
> +	PCMCIA_DEVICE_PROD_ID12("ELAN DIGITAL SYSTEMS LTD, c1997.", "SERIAL CARD: SL100  1.00.", 0x19ca78af, 0xf964f42b),
> +	PCMCIA_DEVICE_PROD_ID12("ELAN DIGITAL SYSTEMS LTD, c1997.", "SERIAL CARD: SL100", 0x19ca78af, 0x71d98e83),
> +	PCMCIA_DEVICE_PROD_ID12("ELAN DIGITAL SYSTEMS LTD, c1997.", "SERIAL CARD: SL232  1.00.", 0x19ca78af, 0x69fb7490),
> +	PCMCIA_DEVICE_PROD_ID12("ELAN DIGITAL SYSTEMS LTD, c1997.", "SERIAL CARD: SL232", 0x19ca78af, 0xb6bc0235),
> +	PCMCIA_DEVICE_PROD_ID12("ELAN DIGITAL SYSTEMS LTD, c2000.", "SERIAL CARD: CF232", 0x63f2e0bd, 0xb9e175d3),
> +	PCMCIA_DEVICE_PROD_ID12("ELAN DIGITAL SYSTEMS LTD, c2000.", "SERIAL CARD: CF232-5", 0x63f2e0bd, 0xfce33442),
> +	PCMCIA_DEVICE_PROD_ID12("Elan", "Serial Port: CF232", 0x3beb8cf2, 0x171e7190),
> +	PCMCIA_DEVICE_PROD_ID12("Elan", "Serial Port: CF232-5", 0x3beb8cf2, 0x20da4262),
> +	PCMCIA_DEVICE_PROD_ID12("Elan", "Serial Port: CF428", 0x3beb8cf2, 0xea5dd57d),
> +	PCMCIA_DEVICE_PROD_ID12("Elan", "Serial Port: CF500", 0x3beb8cf2, 0xd77255fa),
> +	PCMCIA_DEVICE_PROD_ID12("Elan", "Serial Port: IC232", 0x3beb8cf2, 0x6a709903),
> +	PCMCIA_DEVICE_PROD_ID12("Elan", "Serial Port: SL232", 0x3beb8cf2, 0x18430676),
> +	PCMCIA_DEVICE_PROD_ID12("Elan", "Serial Port: XL232", 0x3beb8cf2, 0x6f933767),
> +	PCMCIA_MFC_DEVICE_PROD_ID12(0, "Elan", "Serial Port: CF332", 0x3beb8cf2, 0x16dc1ba7),
> +	PCMCIA_MFC_DEVICE_PROD_ID12(0, "Elan", "Serial Port: SL332", 0x3beb8cf2, 0x19816c41),
> +	PCMCIA_MFC_DEVICE_PROD_ID12(0, "Elan", "Serial Port: SL385", 0x3beb8cf2, 0x64112029),
> +	PCMCIA_MFC_DEVICE_PROD_ID12(0, "Elan", "Serial Port: SL432", 0x3beb8cf2, 0x1cce7ac4),
> +	PCMCIA_MFC_DEVICE_PROD_ID12(0, "Elan", "Serial+Parallel Port: SP230", 0x3beb8cf2, 0xdb9e58bc),
> +	PCMCIA_MFC_DEVICE_PROD_ID12(1, "Elan", "Serial Port: CF332", 0x3beb8cf2, 0x16dc1ba7),
> +	PCMCIA_MFC_DEVICE_PROD_ID12(1, "Elan", "Serial Port: SL332", 0x3beb8cf2, 0x19816c41),
> +	PCMCIA_MFC_DEVICE_PROD_ID12(1, "Elan", "Serial Port: SL385", 0x3beb8cf2, 0x64112029),
> +	PCMCIA_MFC_DEVICE_PROD_ID12(1, "Elan", "Serial Port: SL432", 0x3beb8cf2, 0x1cce7ac4),
> +	PCMCIA_MFC_DEVICE_PROD_ID12(2, "Elan", "Serial Port: SL432", 0x3beb8cf2, 0x1cce7ac4),
> +	PCMCIA_MFC_DEVICE_PROD_ID12(3, "Elan", "Serial Port: SL432", 0x3beb8cf2, 0x1cce7ac4),
>  	PCMCIA_DEVICE_MANF_CARD(0x0279, 0x950b),
>  	/* too generic */
>  	/* PCMCIA_MFC_DEVICE_MANF_CARD(0, 0x0160, 0x0002), */

ok


--
To unsubscribe from this list: send the line "unsubscribe linux-parisc" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

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

* Re: [PATCH 02/11] tty: serial: 8250: Fix indentation warnings
  2015-12-16 15:36   ` Anton Wuerfel
  (?)
@ 2015-12-16 16:49     ` Peter Hurley
  -1 siblings, 0 replies; 60+ messages in thread
From: Peter Hurley @ 2015-12-16 16:49 UTC (permalink / raw)
  To: Anton Wuerfel
  Cc: linux-serial, Greg Kroah-Hartman, Jiri Slaby,
	James E.J. Bottomley, Helge Deller, Heikki Krogerus,
	Andy Shevchenko, Qipeng Zha, Desmond Liu, Wang Long,
	Matt Redfearn, Paul Burton, Ralf Baechle, Krzysztof Kozlowski,
	Peter Hung, Soeren Grunewald, Adam Lee, Maciej S. Szmigiero,
	Mans Rullgard, linux-kernel, linux-parisc, linux-kernel,
	Phillip Raffeck

Hi Anton,

On 12/16/2015 07:36 AM, Anton Wuerfel wrote:
> Checkpatch complains about incorrect indentation of switch/case state=
ments.
> This patch fixes the corresponding warnings. Additionally some indent=
ation
> is changed to match the correct format specified in the Linux Kernel
> Coding Style.

This patch needs split; separate the "leading spaces instead of tabs" f=
rom
the "GNU-style indent level".

Personally, I don't think it's worth changing existing code to meet the
GNU indent style unless it's being rewritten for some other reason.
But Greg's the maintainer, so it's his choice.

Regards,
Peter Hurley


> Signed-off-by: Anton W=C3=BCrfel <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_pci.c  | 31 +++++++++++++++------------=
----
>  drivers/tty/serial/8250/8250_pnp.c  |  4 ++--
>  drivers/tty/serial/8250/8250_port.c | 14 +++++++-------
>  3 files changed, 24 insertions(+), 25 deletions(-)
>=20
> diff --git a/drivers/tty/serial/8250/8250_pci.c b/drivers/tty/serial/=
8250/8250_pci.c
> index ed99fdf..41508a5 100644
> --- a/drivers/tty/serial/8250/8250_pci.c
> +++ b/drivers/tty/serial/8250/8250_pci.c
> @@ -722,7 +722,7 @@ static int pci_ni8430_init(struct pci_dev *dev)
>  	 */
>  	pcibios_resource_to_bus(dev->bus, &region, &dev->resource[bar]);
>  	device_window =3D ((region.start + MITE_IOWBSR1_WIN_OFFSET) & 0xfff=
fff00)
> -	                | MITE_IOWBSR1_WENAB | MITE_IOWBSR1_WSIZE;
> +			| MITE_IOWBSR1_WENAB | MITE_IOWBSR1_WSIZE;
>  	writel(device_window, p + MITE_IOWBSR1);
> =20
>  	/* Set window access to go to RAMSEL IO address space */
> @@ -843,17 +843,16 @@ static int pci_netmos_init(struct pci_dev *dev)
>  		return 0;
> =20
>  	switch (dev->device) { /* FALLTHROUGH on all */
> -		case PCI_DEVICE_ID_NETMOS_9904:
> -		case PCI_DEVICE_ID_NETMOS_9912:
> -		case PCI_DEVICE_ID_NETMOS_9922:
> -		case PCI_DEVICE_ID_NETMOS_9900:
> -			num_serial =3D pci_netmos_9900_numports(dev);
> -			break;
> +	case PCI_DEVICE_ID_NETMOS_9904:
> +	case PCI_DEVICE_ID_NETMOS_9912:
> +	case PCI_DEVICE_ID_NETMOS_9922:
> +	case PCI_DEVICE_ID_NETMOS_9900:
> +		num_serial =3D pci_netmos_9900_numports(dev);
> +		break;
> =20
> -		default:
> -			if (num_serial =3D=3D 0 ) {
> -				moan_device("unknown NetMos/Mostech device", dev);
> -			}
> +	default:
> +		if (num_serial =3D=3D 0)
> +			moan_device("unknown NetMos/Mostech device", dev);
>  	}
> =20
>  	if (num_serial =3D=3D 0)
> @@ -1766,7 +1765,7 @@ xr17v35x_has_slave(struct serial_private *priv)
>  	const int dev_id =3D priv->dev->device;
> =20
>  	return ((dev_id =3D=3D PCI_DEVICE_ID_EXAR_XR17V4358) ||
> -	        (dev_id =3D=3D PCI_DEVICE_ID_EXAR_XR17V8358));
> +		(dev_id =3D=3D PCI_DEVICE_ID_EXAR_XR17V8358));
>  }
> =20
>  static int
> @@ -1866,8 +1865,8 @@ pci_fastcom335_setup(struct serial_private *pri=
v,
> =20
>  static int
>  pci_wch_ch353_setup(struct serial_private *priv,
> -                    const struct pciserial_board *board,
> -                    struct uart_8250_port *port, int idx)
> +		    const struct pciserial_board *board,
> +		    struct uart_8250_port *port, int idx)
>  {
>  	port->port.flags |=3D UPF_FIXED_TYPE;
>  	port->port.type =3D PORT_16550A;
> @@ -1876,8 +1875,8 @@ pci_wch_ch353_setup(struct serial_private *priv=
,
> =20
>  static int
>  pci_wch_ch38x_setup(struct serial_private *priv,
> -                    const struct pciserial_board *board,
> -                    struct uart_8250_port *port, int idx)
> +		    const struct pciserial_board *board,
> +		    struct uart_8250_port *port, int idx)
>  {
>  	port->port.flags |=3D UPF_FIXED_TYPE;
>  	port->port.type =3D PORT_16850;
> diff --git a/drivers/tty/serial/8250/8250_pnp.c b/drivers/tty/serial/=
8250/8250_pnp.c
> index 658b392..1f18065 100644
> --- a/drivers/tty/serial/8250/8250_pnp.c
> +++ b/drivers/tty/serial/8250/8250_pnp.c
> @@ -425,8 +425,8 @@ static int check_resources(struct pnp_dev *dev)
>  static int serial_pnp_guess_board(struct pnp_dev *dev)
>  {
>  	if (!(check_name(pnp_dev_name(dev)) ||
> -		(dev->card && check_name(dev->card->name))))
> -			return -ENODEV;
> +	    (dev->card && check_name(dev->card->name))))
> +		return -ENODEV;
> =20
>  	if (check_resources(dev))
>  		return 0;
> diff --git a/drivers/tty/serial/8250/8250_port.c b/drivers/tty/serial=
/8250/8250_port.c
> index ae8f993..57ad0f2 100644
> --- a/drivers/tty/serial/8250/8250_port.c
> +++ b/drivers/tty/serial/8250/8250_port.c
> @@ -52,7 +52,7 @@
>  #define DEBUG_AUTOCONF(fmt...)	do { } while (0)
>  #endif
> =20
> -#define BOTH_EMPTY 	(UART_LSR_TEMT | UART_LSR_THRE)
> +#define BOTH_EMPTY	(UART_LSR_TEMT | UART_LSR_THRE)
> =20
>  /*
>   * Here we define the default xmit fifo size used for each type of U=
ART.
> @@ -2236,9 +2236,9 @@ static void serial8250_set_divisor(struct uart_=
port *port, unsigned int baud,
>  		serial_port_out(port, 0x2, quot_frac);
>  }
> =20
> -static unsigned int
> -serial8250_get_baud_rate(struct uart_port *port, struct ktermios *te=
rmios,
> -			 struct ktermios *old)
> +static unsigned int serial8250_get_baud_rate(struct uart_port *port,
> +					     struct ktermios *termios,
> +					     struct ktermios *old)
>  {
>  	unsigned int tolerance =3D port->uartclk / 100;
> =20
> @@ -2253,9 +2253,9 @@ serial8250_get_baud_rate(struct uart_port *port=
, struct ktermios *termios,
>  				  (port->uartclk + tolerance) / 16);
>  }
> =20
> -void
> -serial8250_do_set_termios(struct uart_port *port, struct ktermios *t=
ermios,
> -		          struct ktermios *old)
> +void serial8250_do_set_termios(struct uart_port *port,
> +			       struct ktermios *termios,
> +			       struct ktermios *old)
>  {
>  	struct uart_8250_port *up =3D up_to_u8250p(port);
>  	unsigned char cval;
>=20

--
To unsubscribe from this list: send the line "unsubscribe linux-parisc"=
 in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

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

* Re: [PATCH 02/11] tty: serial: 8250: Fix indentation warnings
@ 2015-12-16 16:49     ` Peter Hurley
  0 siblings, 0 replies; 60+ messages in thread
From: Peter Hurley @ 2015-12-16 16:49 UTC (permalink / raw)
  To: Anton Wuerfel
  Cc: linux-serial, Greg Kroah-Hartman, Jiri Slaby,
	James E.J. Bottomley, Helge Deller, Heikki Krogerus,
	Andy Shevchenko, Qipeng Zha, Desmond Liu, Wang Long,
	Matt Redfearn, Paul Burton, Ralf Baechle, Krzysztof Kozlowski,
	Peter Hung, Soeren Grunewald, Adam Lee, Maciej S. Szmigiero,
	Mans Rullgard, linux-kernel, linux-parisc, linux-kernel,
	Phillip Raffeck

Hi Anton,

On 12/16/2015 07:36 AM, Anton Wuerfel wrote:
> Checkpatch complains about incorrect indentation of switch/case statements.
> This patch fixes the corresponding warnings. Additionally some indentation
> is changed to match the correct format specified in the Linux Kernel
> Coding Style.

This patch needs split; separate the "leading spaces instead of tabs" from
the "GNU-style indent level".

Personally, I don't think it's worth changing existing code to meet the
GNU indent style unless it's being rewritten for some other reason.
But Greg's the maintainer, so it's his choice.

Regards,
Peter Hurley


> 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_pci.c  | 31 +++++++++++++++----------------
>  drivers/tty/serial/8250/8250_pnp.c  |  4 ++--
>  drivers/tty/serial/8250/8250_port.c | 14 +++++++-------
>  3 files changed, 24 insertions(+), 25 deletions(-)
> 
> diff --git a/drivers/tty/serial/8250/8250_pci.c b/drivers/tty/serial/8250/8250_pci.c
> index ed99fdf..41508a5 100644
> --- a/drivers/tty/serial/8250/8250_pci.c
> +++ b/drivers/tty/serial/8250/8250_pci.c
> @@ -722,7 +722,7 @@ static int pci_ni8430_init(struct pci_dev *dev)
>  	 */
>  	pcibios_resource_to_bus(dev->bus, &region, &dev->resource[bar]);
>  	device_window = ((region.start + MITE_IOWBSR1_WIN_OFFSET) & 0xffffff00)
> -	                | MITE_IOWBSR1_WENAB | MITE_IOWBSR1_WSIZE;
> +			| MITE_IOWBSR1_WENAB | MITE_IOWBSR1_WSIZE;
>  	writel(device_window, p + MITE_IOWBSR1);
>  
>  	/* Set window access to go to RAMSEL IO address space */
> @@ -843,17 +843,16 @@ static int pci_netmos_init(struct pci_dev *dev)
>  		return 0;
>  
>  	switch (dev->device) { /* FALLTHROUGH on all */
> -		case PCI_DEVICE_ID_NETMOS_9904:
> -		case PCI_DEVICE_ID_NETMOS_9912:
> -		case PCI_DEVICE_ID_NETMOS_9922:
> -		case PCI_DEVICE_ID_NETMOS_9900:
> -			num_serial = pci_netmos_9900_numports(dev);
> -			break;
> +	case PCI_DEVICE_ID_NETMOS_9904:
> +	case PCI_DEVICE_ID_NETMOS_9912:
> +	case PCI_DEVICE_ID_NETMOS_9922:
> +	case PCI_DEVICE_ID_NETMOS_9900:
> +		num_serial = pci_netmos_9900_numports(dev);
> +		break;
>  
> -		default:
> -			if (num_serial == 0 ) {
> -				moan_device("unknown NetMos/Mostech device", dev);
> -			}
> +	default:
> +		if (num_serial == 0)
> +			moan_device("unknown NetMos/Mostech device", dev);
>  	}
>  
>  	if (num_serial == 0)
> @@ -1766,7 +1765,7 @@ xr17v35x_has_slave(struct serial_private *priv)
>  	const int dev_id = priv->dev->device;
>  
>  	return ((dev_id == PCI_DEVICE_ID_EXAR_XR17V4358) ||
> -	        (dev_id == PCI_DEVICE_ID_EXAR_XR17V8358));
> +		(dev_id == PCI_DEVICE_ID_EXAR_XR17V8358));
>  }
>  
>  static int
> @@ -1866,8 +1865,8 @@ pci_fastcom335_setup(struct serial_private *priv,
>  
>  static int
>  pci_wch_ch353_setup(struct serial_private *priv,
> -                    const struct pciserial_board *board,
> -                    struct uart_8250_port *port, int idx)
> +		    const struct pciserial_board *board,
> +		    struct uart_8250_port *port, int idx)
>  {
>  	port->port.flags |= UPF_FIXED_TYPE;
>  	port->port.type = PORT_16550A;
> @@ -1876,8 +1875,8 @@ pci_wch_ch353_setup(struct serial_private *priv,
>  
>  static int
>  pci_wch_ch38x_setup(struct serial_private *priv,
> -                    const struct pciserial_board *board,
> -                    struct uart_8250_port *port, int idx)
> +		    const struct pciserial_board *board,
> +		    struct uart_8250_port *port, int idx)
>  {
>  	port->port.flags |= UPF_FIXED_TYPE;
>  	port->port.type = PORT_16850;
> diff --git a/drivers/tty/serial/8250/8250_pnp.c b/drivers/tty/serial/8250/8250_pnp.c
> index 658b392..1f18065 100644
> --- a/drivers/tty/serial/8250/8250_pnp.c
> +++ b/drivers/tty/serial/8250/8250_pnp.c
> @@ -425,8 +425,8 @@ static int check_resources(struct pnp_dev *dev)
>  static int serial_pnp_guess_board(struct pnp_dev *dev)
>  {
>  	if (!(check_name(pnp_dev_name(dev)) ||
> -		(dev->card && check_name(dev->card->name))))
> -			return -ENODEV;
> +	    (dev->card && check_name(dev->card->name))))
> +		return -ENODEV;
>  
>  	if (check_resources(dev))
>  		return 0;
> diff --git a/drivers/tty/serial/8250/8250_port.c b/drivers/tty/serial/8250/8250_port.c
> index ae8f993..57ad0f2 100644
> --- a/drivers/tty/serial/8250/8250_port.c
> +++ b/drivers/tty/serial/8250/8250_port.c
> @@ -52,7 +52,7 @@
>  #define DEBUG_AUTOCONF(fmt...)	do { } while (0)
>  #endif
>  
> -#define BOTH_EMPTY 	(UART_LSR_TEMT | UART_LSR_THRE)
> +#define BOTH_EMPTY	(UART_LSR_TEMT | UART_LSR_THRE)
>  
>  /*
>   * Here we define the default xmit fifo size used for each type of UART.
> @@ -2236,9 +2236,9 @@ static void serial8250_set_divisor(struct uart_port *port, unsigned int baud,
>  		serial_port_out(port, 0x2, quot_frac);
>  }
>  
> -static unsigned int
> -serial8250_get_baud_rate(struct uart_port *port, struct ktermios *termios,
> -			 struct ktermios *old)
> +static unsigned int serial8250_get_baud_rate(struct uart_port *port,
> +					     struct ktermios *termios,
> +					     struct ktermios *old)
>  {
>  	unsigned int tolerance = port->uartclk / 100;
>  
> @@ -2253,9 +2253,9 @@ serial8250_get_baud_rate(struct uart_port *port, struct ktermios *termios,
>  				  (port->uartclk + tolerance) / 16);
>  }
>  
> -void
> -serial8250_do_set_termios(struct uart_port *port, struct ktermios *termios,
> -		          struct ktermios *old)
> +void serial8250_do_set_termios(struct uart_port *port,
> +			       struct ktermios *termios,
> +			       struct ktermios *old)
>  {
>  	struct uart_8250_port *up = up_to_u8250p(port);
>  	unsigned char cval;
> 


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

* Re: [PATCH 02/11] tty: serial: 8250: Fix indentation warnings
@ 2015-12-16 16:49     ` Peter Hurley
  0 siblings, 0 replies; 60+ messages in thread
From: Peter Hurley @ 2015-12-16 16:49 UTC (permalink / raw)
  To: Anton Wuerfel
  Cc: linux-serial, Greg Kroah-Hartman, Jiri Slaby,
	James E.J. Bottomley, Helge Deller, Heikki Krogerus,
	Andy Shevchenko, Qipeng Zha, Desmond Liu, Wang Long,
	Matt Redfearn, Paul Burton, Ralf Baechle, Krzysztof Kozlowski,
	Peter Hung, Soeren Grunewald, Adam Lee, Maciej S. Szmigiero,
	Mans Rullgard, linux-kernel, linux-parisc, linux-kernel,
	Phillip Raffeck

Hi Anton,

On 12/16/2015 07:36 AM, Anton Wuerfel wrote:
> Checkpatch complains about incorrect indentation of switch/case statements.
> This patch fixes the corresponding warnings. Additionally some indentation
> is changed to match the correct format specified in the Linux Kernel
> Coding Style.

This patch needs split; separate the "leading spaces instead of tabs" from
the "GNU-style indent level".

Personally, I don't think it's worth changing existing code to meet the
GNU indent style unless it's being rewritten for some other reason.
But Greg's the maintainer, so it's his choice.

Regards,
Peter Hurley


> 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_pci.c  | 31 +++++++++++++++----------------
>  drivers/tty/serial/8250/8250_pnp.c  |  4 ++--
>  drivers/tty/serial/8250/8250_port.c | 14 +++++++-------
>  3 files changed, 24 insertions(+), 25 deletions(-)
> 
> diff --git a/drivers/tty/serial/8250/8250_pci.c b/drivers/tty/serial/8250/8250_pci.c
> index ed99fdf..41508a5 100644
> --- a/drivers/tty/serial/8250/8250_pci.c
> +++ b/drivers/tty/serial/8250/8250_pci.c
> @@ -722,7 +722,7 @@ static int pci_ni8430_init(struct pci_dev *dev)
>  	 */
>  	pcibios_resource_to_bus(dev->bus, &region, &dev->resource[bar]);
>  	device_window = ((region.start + MITE_IOWBSR1_WIN_OFFSET) & 0xffffff00)
> -	                | MITE_IOWBSR1_WENAB | MITE_IOWBSR1_WSIZE;
> +			| MITE_IOWBSR1_WENAB | MITE_IOWBSR1_WSIZE;
>  	writel(device_window, p + MITE_IOWBSR1);
>  
>  	/* Set window access to go to RAMSEL IO address space */
> @@ -843,17 +843,16 @@ static int pci_netmos_init(struct pci_dev *dev)
>  		return 0;
>  
>  	switch (dev->device) { /* FALLTHROUGH on all */
> -		case PCI_DEVICE_ID_NETMOS_9904:
> -		case PCI_DEVICE_ID_NETMOS_9912:
> -		case PCI_DEVICE_ID_NETMOS_9922:
> -		case PCI_DEVICE_ID_NETMOS_9900:
> -			num_serial = pci_netmos_9900_numports(dev);
> -			break;
> +	case PCI_DEVICE_ID_NETMOS_9904:
> +	case PCI_DEVICE_ID_NETMOS_9912:
> +	case PCI_DEVICE_ID_NETMOS_9922:
> +	case PCI_DEVICE_ID_NETMOS_9900:
> +		num_serial = pci_netmos_9900_numports(dev);
> +		break;
>  
> -		default:
> -			if (num_serial == 0 ) {
> -				moan_device("unknown NetMos/Mostech device", dev);
> -			}
> +	default:
> +		if (num_serial == 0)
> +			moan_device("unknown NetMos/Mostech device", dev);
>  	}
>  
>  	if (num_serial == 0)
> @@ -1766,7 +1765,7 @@ xr17v35x_has_slave(struct serial_private *priv)
>  	const int dev_id = priv->dev->device;
>  
>  	return ((dev_id == PCI_DEVICE_ID_EXAR_XR17V4358) ||
> -	        (dev_id == PCI_DEVICE_ID_EXAR_XR17V8358));
> +		(dev_id == PCI_DEVICE_ID_EXAR_XR17V8358));
>  }
>  
>  static int
> @@ -1866,8 +1865,8 @@ pci_fastcom335_setup(struct serial_private *priv,
>  
>  static int
>  pci_wch_ch353_setup(struct serial_private *priv,
> -                    const struct pciserial_board *board,
> -                    struct uart_8250_port *port, int idx)
> +		    const struct pciserial_board *board,
> +		    struct uart_8250_port *port, int idx)
>  {
>  	port->port.flags |= UPF_FIXED_TYPE;
>  	port->port.type = PORT_16550A;
> @@ -1876,8 +1875,8 @@ pci_wch_ch353_setup(struct serial_private *priv,
>  
>  static int
>  pci_wch_ch38x_setup(struct serial_private *priv,
> -                    const struct pciserial_board *board,
> -                    struct uart_8250_port *port, int idx)
> +		    const struct pciserial_board *board,
> +		    struct uart_8250_port *port, int idx)
>  {
>  	port->port.flags |= UPF_FIXED_TYPE;
>  	port->port.type = PORT_16850;
> diff --git a/drivers/tty/serial/8250/8250_pnp.c b/drivers/tty/serial/8250/8250_pnp.c
> index 658b392..1f18065 100644
> --- a/drivers/tty/serial/8250/8250_pnp.c
> +++ b/drivers/tty/serial/8250/8250_pnp.c
> @@ -425,8 +425,8 @@ static int check_resources(struct pnp_dev *dev)
>  static int serial_pnp_guess_board(struct pnp_dev *dev)
>  {
>  	if (!(check_name(pnp_dev_name(dev)) ||
> -		(dev->card && check_name(dev->card->name))))
> -			return -ENODEV;
> +	    (dev->card && check_name(dev->card->name))))
> +		return -ENODEV;
>  
>  	if (check_resources(dev))
>  		return 0;
> diff --git a/drivers/tty/serial/8250/8250_port.c b/drivers/tty/serial/8250/8250_port.c
> index ae8f993..57ad0f2 100644
> --- a/drivers/tty/serial/8250/8250_port.c
> +++ b/drivers/tty/serial/8250/8250_port.c
> @@ -52,7 +52,7 @@
>  #define DEBUG_AUTOCONF(fmt...)	do { } while (0)
>  #endif
>  
> -#define BOTH_EMPTY 	(UART_LSR_TEMT | UART_LSR_THRE)
> +#define BOTH_EMPTY	(UART_LSR_TEMT | UART_LSR_THRE)
>  
>  /*
>   * Here we define the default xmit fifo size used for each type of UART.
> @@ -2236,9 +2236,9 @@ static void serial8250_set_divisor(struct uart_port *port, unsigned int baud,
>  		serial_port_out(port, 0x2, quot_frac);
>  }
>  
> -static unsigned int
> -serial8250_get_baud_rate(struct uart_port *port, struct ktermios *termios,
> -			 struct ktermios *old)
> +static unsigned int serial8250_get_baud_rate(struct uart_port *port,
> +					     struct ktermios *termios,
> +					     struct ktermios *old)
>  {
>  	unsigned int tolerance = port->uartclk / 100;
>  
> @@ -2253,9 +2253,9 @@ serial8250_get_baud_rate(struct uart_port *port, struct ktermios *termios,
>  				  (port->uartclk + tolerance) / 16);
>  }
>  
> -void
> -serial8250_do_set_termios(struct uart_port *port, struct ktermios *termios,
> -		          struct ktermios *old)
> +void serial8250_do_set_termios(struct uart_port *port,
> +			       struct ktermios *termios,
> +			       struct ktermios *old)
>  {
>  	struct uart_8250_port *up = up_to_u8250p(port);
>  	unsigned char cval;
> 

--
To unsubscribe from this list: send the line "unsubscribe linux-parisc" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

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

* Re: [PATCH 04/11] tty: serial: 8250: Fix multiline comment style
  2015-12-16 15:36   ` Anton Wuerfel
  (?)
@ 2015-12-16 16:52     ` Peter Hurley
  -1 siblings, 0 replies; 60+ messages in thread
From: Peter Hurley @ 2015-12-16 16:52 UTC (permalink / raw)
  To: Anton Wuerfel
  Cc: linux-serial, Greg Kroah-Hartman, Jiri Slaby,
	James E.J. Bottomley, Helge Deller, Heikki Krogerus,
	Andy Shevchenko, Qipeng Zha, Desmond Liu, Wang Long,
	Matt Redfearn, Paul Burton, Ralf Baechle, Krzysztof Kozlowski,
	Peter Hung, Soeren Grunewald, Adam Lee, Maciej S. Szmigiero,
	Mans Rullgard, linux-kernel, linux-parisc, linux-kernel,
	Phillip Raffeck

On 12/16/2015 07:36 AM, Anton Wuerfel wrote:
> Checkpatch outputs some warnings about incorrect comment style,
> which is fixed by this patch.
>=20

Please fix the comments in a consistent fashion. For example ...

> Signed-off-by: Anton W=C3=BCrfel <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_ingenic.c |  6 ++-
>  drivers/tty/serial/8250/8250_pnp.c     |  6 ++-
>  drivers/tty/serial/8250/8250_port.c    | 29 ++++++-----
>  drivers/tty/serial/8250/serial_cs.c    | 92 +++++++++++++++++++-----=
----------
>  4 files changed, 75 insertions(+), 58 deletions(-)
>=20
> diff --git a/drivers/tty/serial/8250/8250_ingenic.c b/drivers/tty/ser=
ial/8250/8250_ingenic.c
> index 49394b4..c53d2501 100644
> --- a/drivers/tty/serial/8250/8250_ingenic.c
> +++ b/drivers/tty/serial/8250/8250_ingenic.c
> @@ -153,13 +153,15 @@ static void ingenic_uart_serial_out(struct uart=
_port *p, int offset, int value)
> =20
>  	case UART_IER:
>  		/* Enable receive timeout interrupt with the
> -		 * receive line status interrupt */
> +		 * receive line status interrupt
> +		 */

This isn't the same style as ...

>  		value |=3D (value & 0x4) << 2;
>  		break;
> =20
>  	case UART_MCR:
>  		/* If we have enabled modem status IRQs we should enable modem
> -		 * mode. */
> +		 * mode.
> +		 */
>  		ier =3D p->serial_in(p, UART_IER);
> =20
>  		if (ier & UART_IER_MSI)
> diff --git a/drivers/tty/serial/8250/8250_pnp.c b/drivers/tty/serial/=
8250/8250_pnp.c
> index 1f18065..2731031 100644
> --- a/drivers/tty/serial/8250/8250_pnp.c
> +++ b/drivers/tty/serial/8250/8250_pnp.c
> @@ -367,8 +367,10 @@ static const struct pnp_device_id pnp_dev_table[=
] =3D {
>  	{	"PNPCXXX",		UNKNOWN_DEV	},
>  	/* More unknown PnP modems */
>  	{	"PNPDXXX",		UNKNOWN_DEV	},
> -	/* Winbond CIR port, should not be probed. We should keep track
> -	   of it to prevent the legacy serial driver from probing it */
> +	/*
> +	 * Winbond CIR port, should not be probed. We should keep track
> +	 * of it to prevent the legacy serial driver from probing it
> +	 */

this style.

>  	{	"WEC1022",		CIR_PORT	},
>  	/*
>  	 * SMSC IrCC SIR/FIR port, should not be probed by serial driver
> diff --git a/drivers/tty/serial/8250/8250_port.c b/drivers/tty/serial=
/8250/8250_port.c
> index 57ad0f2..0ec823e 100644
> --- a/drivers/tty/serial/8250/8250_port.c
> +++ b/drivers/tty/serial/8250/8250_port.c
> @@ -250,9 +250,11 @@ static const struct serial8250_config uart_confi=
g[] =3D {
>  		.fcr		=3D UART_FCR_ENABLE_FIFO | UART_FCR_R_TRIG_10,
>  		.flags		=3D UART_CAP_FIFO | UART_CAP_AFE,
>  	},
> -/* tx_loadsz is set to 63-bytes instead of 64-bytes to implement
> -workaround of errata A-008006 which states that tx_loadsz should  be
> -configured less than Maximum supported fifo bytes */
> +	/*
> +	 * tx_loadsz is set to 63-bytes instead of 64-bytes to implement
> +	 * workaround of errata A-008006 which states that tx_loadsz should=
 be
> +	 * configured less than Maximum supported fifo bytes
> +	 */
>  	[PORT_16550A_FSL64] =3D {
>  		.name		=3D "16550A_FSL64",
>  		.fifo_size	=3D 64,
> @@ -1970,16 +1972,17 @@ int serial8250_do_startup(struct uart_port *p=
ort)
> =20
>  	serial8250_set_mctrl(port, port->mctrl);
> =20
> -	/* Serial over Lan (SoL) hack:
> -	   Intel 8257x Gigabit ethernet chips have a
> -	   16550 emulation, to be used for Serial Over Lan.
> -	   Those chips take a longer time than a normal
> -	   serial device to signalize that a transmission
> -	   data was queued. Due to that, the above test generally
> -	   fails. One solution would be to delay the reading of
> -	   iir. However, this is not reliable, since the timeout
> -	   is variable. So, let's just don't test if we receive
> -	   TX irq. This way, we'll never enable UART_BUG_TXEN.
> +	/*
> +	 * Serial over Lan (SoL) hack:
> +	 * Intel 8257x Gigabit ethernet chips have a
> +	 * 16550 emulation, to be used for Serial Over Lan.
> +	 * Those chips take a longer time than a normal
> +	 * serial device to signalize that a transmission
> +	 * data was queued. Due to that, the above test generally
> +	 * fails. One solution would be to delay the reading of
> +	 * iir. However, this is not reliable, since the timeout
> +	 * is variable. So, let's just don't test if we receive
> +	 * TX irq. This way, we'll never enable UART_BUG_TXEN.
>  	 */

Might as well unwrap this to max line length too.


>  	if (up->port.flags & UPF_NO_TXEN_TEST)
>  		goto dont_test_tx_en;
> diff --git a/drivers/tty/serial/8250/serial_cs.c b/drivers/tty/serial=
/8250/serial_cs.c
> index f5270ba..a4bdcf6 100644
> --- a/drivers/tty/serial/8250/serial_cs.c
> +++ b/drivers/tty/serial/8250/serial_cs.c
> @@ -1,35 +1,37 @@
> -/*=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D
> -
> -    A driver for PCMCIA serial devices
> -
> -    serial_cs.c 1.134 2002/05/04 05:48:53
> -
> -    The contents of this file are subject to the Mozilla Public
> -    License Version 1.1 (the "License"); you may not use this file
> -    except in compliance with the License. You may obtain a copy of
> -    the License at http://www.mozilla.org/MPL/
> -
> -    Software distributed under the License is distributed on an "AS
> -    IS" basis, WITHOUT WARRANTY OF ANY KIND, either express or
> -    implied. See the License for the specific language governing
> -    rights and limitations under the License.
> -
> -    The initial developer of the original code is David A. Hinds
> -    <dahinds@users.sourceforge.net>.  Portions created by David A. H=
inds
> -    are Copyright (C) 1999 David A. Hinds.  All Rights Reserved.
> -
> -    Alternatively, the contents of this file may be used under the
> -    terms of the GNU General Public License version 2 (the "GPL"), i=
n which
> -    case the provisions of the GPL are applicable instead of the
> -    above.  If you wish to allow the use of your version of this fil=
e
> -    only under the terms of the GPL and not to allow others to use
> -    your version of this file under the MPL, indicate your decision
> -    by deleting the provisions above and replace them with the notic=
e
> -    and other provisions required by the GPL.  If you do not delete
> -    the provisions above, a recipient may use your version of this
> -    file under either the MPL or the GPL.
> -   =20
> -=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D*/
> +/*
> + * =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D
> + *
> + * A driver for PCMCIA serial devices
> + *
> + * serial_cs.c 1.134 2002/05/04 05:48:53
> + *
> + * The contents of this file are subject to the Mozilla Public
> + * License Version 1.1 (the "License"); you may not use this file
> + * except in compliance with the License. You may obtain a copy of
> + * the License at http://www.mozilla.org/MPL/
> + *
> + * Software distributed under the License is distributed on an "AS
> + * IS" basis, WITHOUT WARRANTY OF ANY KIND, either express or
> + * implied. See the License for the specific language governing
> + * rights and limitations under the License.
> + *
> + * The initial developer of the original code is David A. Hinds
> + * <dahinds@users.sourceforge.net>.  Portions created by David A. Hi=
nds
> + * are Copyright (C) 1999 David A. Hinds.  All Rights Reserved.
> + *
> + * Alternatively, the contents of this file may be used under the
> + * terms of the GNU General Public License version 2 (the "GPL"), in=
 which
> + * case the provisions of the GPL are applicable instead of the
> + * above.  If you wish to allow the use of your version of this file
> + * only under the terms of the GPL and not to allow others to use
> + * your version of this file under the MPL, indicate your decision
> + * by deleting the provisions above and replace them with the notice
> + * and other provisions required by the GPL.  If you do not delete
> + * the provisions above, a recipient may use your version of this
> + * file under either the MPL or the GPL.
> + *
> + * =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D
> + */
> =20
>  #include <linux/module.h>
>  #include <linux/moduleparam.h>
> @@ -441,16 +443,20 @@ static int simple_config(struct pcmcia_device *=
link)
>  	struct serial_info *info =3D link->priv;
>  	int i =3D -ENODEV, try;
> =20
> -	/* First pass: look for a config entry that looks normal.
> -	 * Two tries: without IO aliases, then with aliases */
> +	/*
> +	 * First pass: look for a config entry that looks normal.
> +	 * Two tries: without IO aliases, then with aliases
> +	 */
>  	link->config_flags |=3D CONF_AUTO_SET_VPP;
>  	for (try =3D 0; try < 4; try++)
>  		if (!pcmcia_loop_config(link, simple_config_check, &try))
>  			goto found_port;
> =20
> -	/* Second pass: try to find an entry that isn't picky about
> -	   its base address, then try to grab any standard serial port
> -	   address, and finally try to get any free port. */
> +	/*
> +	 * Second pass: try to find an entry that isn't picky about
> +	 * its base address, then try to grab any standard serial port
> +	 * address, and finally try to get any free port.
> +	 */
>  	if (!pcmcia_loop_config(link, simple_config_check_notpicky, NULL))
>  		goto found_port;
> =20
> @@ -480,8 +486,10 @@ static int multi_config_check(struct pcmcia_devi=
ce *p_dev, void *priv_data)
>  	if (p_dev->resource[1]->end)
>  		return -EINVAL;
> =20
> -	/* The quad port cards have bad CIS's, so just look for a
> -	   window larger than 8 ports and assume it will be right */
> +	/*
> +	 * The quad port cards have bad CIS's, so just look for a
> +	 * window larger than 8 ports and assume it will be right
> +	 */
>  	if (p_dev->resource[0]->end <=3D 8)
>  		return -EINVAL;
> =20
> @@ -623,8 +631,10 @@ static int serial_config(struct pcmcia_device *l=
ink)
>  			break;
>  		}
> =20
> -	/* Another check for dual-serial cards: look for either serial or
> -	   multifunction cards that ask for appropriate IO port ranges */
> +	/*
> +	 * Another check for dual-serial cards: look for either serial or
> +	 * multifunction cards that ask for appropriate IO port ranges
> +	 */
>  	if ((info->multi =3D=3D 0) &&
>  	    (link->has_func_id) &&
>  	    (link->socket->pcmcia_pfc =3D=3D 0) &&
>=20

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

* Re: [PATCH 04/11] tty: serial: 8250: Fix multiline comment style
@ 2015-12-16 16:52     ` Peter Hurley
  0 siblings, 0 replies; 60+ messages in thread
From: Peter Hurley @ 2015-12-16 16:52 UTC (permalink / raw)
  To: Anton Wuerfel
  Cc: linux-serial, Greg Kroah-Hartman, Jiri Slaby,
	James E.J. Bottomley, Helge Deller, Heikki Krogerus,
	Andy Shevchenko, Qipeng Zha, Desmond Liu, Wang Long,
	Matt Redfearn, Paul Burton, Ralf Baechle, Krzysztof Kozlowski,
	Peter Hung, Soeren Grunewald, Adam Lee, Maciej S. Szmigiero,
	Mans Rullgard, linux-kernel, linux-parisc, linux-kernel,
	Phillip Raffeck

On 12/16/2015 07:36 AM, Anton Wuerfel wrote:
> Checkpatch outputs some warnings about incorrect comment style,
> which is fixed by this patch.
> 

Please fix the comments in a consistent fashion. For example ...

> 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_ingenic.c |  6 ++-
>  drivers/tty/serial/8250/8250_pnp.c     |  6 ++-
>  drivers/tty/serial/8250/8250_port.c    | 29 ++++++-----
>  drivers/tty/serial/8250/serial_cs.c    | 92 +++++++++++++++++++---------------
>  4 files changed, 75 insertions(+), 58 deletions(-)
> 
> diff --git a/drivers/tty/serial/8250/8250_ingenic.c b/drivers/tty/serial/8250/8250_ingenic.c
> index 49394b4..c53d2501 100644
> --- a/drivers/tty/serial/8250/8250_ingenic.c
> +++ b/drivers/tty/serial/8250/8250_ingenic.c
> @@ -153,13 +153,15 @@ static void ingenic_uart_serial_out(struct uart_port *p, int offset, int value)
>  
>  	case UART_IER:
>  		/* Enable receive timeout interrupt with the
> -		 * receive line status interrupt */
> +		 * receive line status interrupt
> +		 */

This isn't the same style as ...

>  		value |= (value & 0x4) << 2;
>  		break;
>  
>  	case UART_MCR:
>  		/* If we have enabled modem status IRQs we should enable modem
> -		 * mode. */
> +		 * mode.
> +		 */
>  		ier = p->serial_in(p, UART_IER);
>  
>  		if (ier & UART_IER_MSI)
> diff --git a/drivers/tty/serial/8250/8250_pnp.c b/drivers/tty/serial/8250/8250_pnp.c
> index 1f18065..2731031 100644
> --- a/drivers/tty/serial/8250/8250_pnp.c
> +++ b/drivers/tty/serial/8250/8250_pnp.c
> @@ -367,8 +367,10 @@ static const struct pnp_device_id pnp_dev_table[] = {
>  	{	"PNPCXXX",		UNKNOWN_DEV	},
>  	/* More unknown PnP modems */
>  	{	"PNPDXXX",		UNKNOWN_DEV	},
> -	/* Winbond CIR port, should not be probed. We should keep track
> -	   of it to prevent the legacy serial driver from probing it */
> +	/*
> +	 * Winbond CIR port, should not be probed. We should keep track
> +	 * of it to prevent the legacy serial driver from probing it
> +	 */

this style.

>  	{	"WEC1022",		CIR_PORT	},
>  	/*
>  	 * SMSC IrCC SIR/FIR port, should not be probed by serial driver
> diff --git a/drivers/tty/serial/8250/8250_port.c b/drivers/tty/serial/8250/8250_port.c
> index 57ad0f2..0ec823e 100644
> --- a/drivers/tty/serial/8250/8250_port.c
> +++ b/drivers/tty/serial/8250/8250_port.c
> @@ -250,9 +250,11 @@ static const struct serial8250_config uart_config[] = {
>  		.fcr		= UART_FCR_ENABLE_FIFO | UART_FCR_R_TRIG_10,
>  		.flags		= UART_CAP_FIFO | UART_CAP_AFE,
>  	},
> -/* tx_loadsz is set to 63-bytes instead of 64-bytes to implement
> -workaround of errata A-008006 which states that tx_loadsz should  be
> -configured less than Maximum supported fifo bytes */
> +	/*
> +	 * tx_loadsz is set to 63-bytes instead of 64-bytes to implement
> +	 * workaround of errata A-008006 which states that tx_loadsz should be
> +	 * configured less than Maximum supported fifo bytes
> +	 */
>  	[PORT_16550A_FSL64] = {
>  		.name		= "16550A_FSL64",
>  		.fifo_size	= 64,
> @@ -1970,16 +1972,17 @@ int serial8250_do_startup(struct uart_port *port)
>  
>  	serial8250_set_mctrl(port, port->mctrl);
>  
> -	/* Serial over Lan (SoL) hack:
> -	   Intel 8257x Gigabit ethernet chips have a
> -	   16550 emulation, to be used for Serial Over Lan.
> -	   Those chips take a longer time than a normal
> -	   serial device to signalize that a transmission
> -	   data was queued. Due to that, the above test generally
> -	   fails. One solution would be to delay the reading of
> -	   iir. However, this is not reliable, since the timeout
> -	   is variable. So, let's just don't test if we receive
> -	   TX irq. This way, we'll never enable UART_BUG_TXEN.
> +	/*
> +	 * Serial over Lan (SoL) hack:
> +	 * Intel 8257x Gigabit ethernet chips have a
> +	 * 16550 emulation, to be used for Serial Over Lan.
> +	 * Those chips take a longer time than a normal
> +	 * serial device to signalize that a transmission
> +	 * data was queued. Due to that, the above test generally
> +	 * fails. One solution would be to delay the reading of
> +	 * iir. However, this is not reliable, since the timeout
> +	 * is variable. So, let's just don't test if we receive
> +	 * TX irq. This way, we'll never enable UART_BUG_TXEN.
>  	 */

Might as well unwrap this to max line length too.


>  	if (up->port.flags & UPF_NO_TXEN_TEST)
>  		goto dont_test_tx_en;
> diff --git a/drivers/tty/serial/8250/serial_cs.c b/drivers/tty/serial/8250/serial_cs.c
> index f5270ba..a4bdcf6 100644
> --- a/drivers/tty/serial/8250/serial_cs.c
> +++ b/drivers/tty/serial/8250/serial_cs.c
> @@ -1,35 +1,37 @@
> -/*======================================================================
> -
> -    A driver for PCMCIA serial devices
> -
> -    serial_cs.c 1.134 2002/05/04 05:48:53
> -
> -    The contents of this file are subject to the Mozilla Public
> -    License Version 1.1 (the "License"); you may not use this file
> -    except in compliance with the License. You may obtain a copy of
> -    the License at http://www.mozilla.org/MPL/
> -
> -    Software distributed under the License is distributed on an "AS
> -    IS" basis, WITHOUT WARRANTY OF ANY KIND, either express or
> -    implied. See the License for the specific language governing
> -    rights and limitations under the License.
> -
> -    The initial developer of the original code is David A. Hinds
> -    <dahinds@users.sourceforge.net>.  Portions created by David A. Hinds
> -    are Copyright (C) 1999 David A. Hinds.  All Rights Reserved.
> -
> -    Alternatively, the contents of this file may be used under the
> -    terms of the GNU General Public License version 2 (the "GPL"), in which
> -    case the provisions of the GPL are applicable instead of the
> -    above.  If you wish to allow the use of your version of this file
> -    only under the terms of the GPL and not to allow others to use
> -    your version of this file under the MPL, indicate your decision
> -    by deleting the provisions above and replace them with the notice
> -    and other provisions required by the GPL.  If you do not delete
> -    the provisions above, a recipient may use your version of this
> -    file under either the MPL or the GPL.
> -    
> -======================================================================*/
> +/*
> + * ======================================================================
> + *
> + * A driver for PCMCIA serial devices
> + *
> + * serial_cs.c 1.134 2002/05/04 05:48:53
> + *
> + * The contents of this file are subject to the Mozilla Public
> + * License Version 1.1 (the "License"); you may not use this file
> + * except in compliance with the License. You may obtain a copy of
> + * the License at http://www.mozilla.org/MPL/
> + *
> + * Software distributed under the License is distributed on an "AS
> + * IS" basis, WITHOUT WARRANTY OF ANY KIND, either express or
> + * implied. See the License for the specific language governing
> + * rights and limitations under the License.
> + *
> + * The initial developer of the original code is David A. Hinds
> + * <dahinds@users.sourceforge.net>.  Portions created by David A. Hinds
> + * are Copyright (C) 1999 David A. Hinds.  All Rights Reserved.
> + *
> + * Alternatively, the contents of this file may be used under the
> + * terms of the GNU General Public License version 2 (the "GPL"), in which
> + * case the provisions of the GPL are applicable instead of the
> + * above.  If you wish to allow the use of your version of this file
> + * only under the terms of the GPL and not to allow others to use
> + * your version of this file under the MPL, indicate your decision
> + * by deleting the provisions above and replace them with the notice
> + * and other provisions required by the GPL.  If you do not delete
> + * the provisions above, a recipient may use your version of this
> + * file under either the MPL or the GPL.
> + *
> + * ======================================================================
> + */
>  
>  #include <linux/module.h>
>  #include <linux/moduleparam.h>
> @@ -441,16 +443,20 @@ static int simple_config(struct pcmcia_device *link)
>  	struct serial_info *info = link->priv;
>  	int i = -ENODEV, try;
>  
> -	/* First pass: look for a config entry that looks normal.
> -	 * Two tries: without IO aliases, then with aliases */
> +	/*
> +	 * First pass: look for a config entry that looks normal.
> +	 * Two tries: without IO aliases, then with aliases
> +	 */
>  	link->config_flags |= CONF_AUTO_SET_VPP;
>  	for (try = 0; try < 4; try++)
>  		if (!pcmcia_loop_config(link, simple_config_check, &try))
>  			goto found_port;
>  
> -	/* Second pass: try to find an entry that isn't picky about
> -	   its base address, then try to grab any standard serial port
> -	   address, and finally try to get any free port. */
> +	/*
> +	 * Second pass: try to find an entry that isn't picky about
> +	 * its base address, then try to grab any standard serial port
> +	 * address, and finally try to get any free port.
> +	 */
>  	if (!pcmcia_loop_config(link, simple_config_check_notpicky, NULL))
>  		goto found_port;
>  
> @@ -480,8 +486,10 @@ static int multi_config_check(struct pcmcia_device *p_dev, void *priv_data)
>  	if (p_dev->resource[1]->end)
>  		return -EINVAL;
>  
> -	/* The quad port cards have bad CIS's, so just look for a
> -	   window larger than 8 ports and assume it will be right */
> +	/*
> +	 * The quad port cards have bad CIS's, so just look for a
> +	 * window larger than 8 ports and assume it will be right
> +	 */
>  	if (p_dev->resource[0]->end <= 8)
>  		return -EINVAL;
>  
> @@ -623,8 +631,10 @@ static int serial_config(struct pcmcia_device *link)
>  			break;
>  		}
>  
> -	/* Another check for dual-serial cards: look for either serial or
> -	   multifunction cards that ask for appropriate IO port ranges */
> +	/*
> +	 * Another check for dual-serial cards: look for either serial or
> +	 * multifunction cards that ask for appropriate IO port ranges
> +	 */
>  	if ((info->multi == 0) &&
>  	    (link->has_func_id) &&
>  	    (link->socket->pcmcia_pfc == 0) &&
> 


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

* Re: [PATCH 04/11] tty: serial: 8250: Fix multiline comment style
@ 2015-12-16 16:52     ` Peter Hurley
  0 siblings, 0 replies; 60+ messages in thread
From: Peter Hurley @ 2015-12-16 16:52 UTC (permalink / raw)
  To: Anton Wuerfel
  Cc: linux-serial, Greg Kroah-Hartman, Jiri Slaby,
	James E.J. Bottomley, Helge Deller, Heikki Krogerus,
	Andy Shevchenko, Qipeng Zha, Desmond Liu, Wang Long,
	Matt Redfearn, Paul Burton, Ralf Baechle, Krzysztof Kozlowski,
	Peter Hung, Soeren Grunewald, Adam Lee, Maciej S. Szmigiero,
	Mans Rullgard, linux-kernel, linux-parisc, linux-kernel,
	Phillip Raffeck

On 12/16/2015 07:36 AM, Anton Wuerfel wrote:
> Checkpatch outputs some warnings about incorrect comment style,
> which is fixed by this patch.
> 

Please fix the comments in a consistent fashion. For example ...

> 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_ingenic.c |  6 ++-
>  drivers/tty/serial/8250/8250_pnp.c     |  6 ++-
>  drivers/tty/serial/8250/8250_port.c    | 29 ++++++-----
>  drivers/tty/serial/8250/serial_cs.c    | 92 +++++++++++++++++++---------------
>  4 files changed, 75 insertions(+), 58 deletions(-)
> 
> diff --git a/drivers/tty/serial/8250/8250_ingenic.c b/drivers/tty/serial/8250/8250_ingenic.c
> index 49394b4..c53d2501 100644
> --- a/drivers/tty/serial/8250/8250_ingenic.c
> +++ b/drivers/tty/serial/8250/8250_ingenic.c
> @@ -153,13 +153,15 @@ static void ingenic_uart_serial_out(struct uart_port *p, int offset, int value)
>  
>  	case UART_IER:
>  		/* Enable receive timeout interrupt with the
> -		 * receive line status interrupt */
> +		 * receive line status interrupt
> +		 */

This isn't the same style as ...

>  		value |= (value & 0x4) << 2;
>  		break;
>  
>  	case UART_MCR:
>  		/* If we have enabled modem status IRQs we should enable modem
> -		 * mode. */
> +		 * mode.
> +		 */
>  		ier = p->serial_in(p, UART_IER);
>  
>  		if (ier & UART_IER_MSI)
> diff --git a/drivers/tty/serial/8250/8250_pnp.c b/drivers/tty/serial/8250/8250_pnp.c
> index 1f18065..2731031 100644
> --- a/drivers/tty/serial/8250/8250_pnp.c
> +++ b/drivers/tty/serial/8250/8250_pnp.c
> @@ -367,8 +367,10 @@ static const struct pnp_device_id pnp_dev_table[] = {
>  	{	"PNPCXXX",		UNKNOWN_DEV	},
>  	/* More unknown PnP modems */
>  	{	"PNPDXXX",		UNKNOWN_DEV	},
> -	/* Winbond CIR port, should not be probed. We should keep track
> -	   of it to prevent the legacy serial driver from probing it */
> +	/*
> +	 * Winbond CIR port, should not be probed. We should keep track
> +	 * of it to prevent the legacy serial driver from probing it
> +	 */

this style.

>  	{	"WEC1022",		CIR_PORT	},
>  	/*
>  	 * SMSC IrCC SIR/FIR port, should not be probed by serial driver
> diff --git a/drivers/tty/serial/8250/8250_port.c b/drivers/tty/serial/8250/8250_port.c
> index 57ad0f2..0ec823e 100644
> --- a/drivers/tty/serial/8250/8250_port.c
> +++ b/drivers/tty/serial/8250/8250_port.c
> @@ -250,9 +250,11 @@ static const struct serial8250_config uart_config[] = {
>  		.fcr		= UART_FCR_ENABLE_FIFO | UART_FCR_R_TRIG_10,
>  		.flags		= UART_CAP_FIFO | UART_CAP_AFE,
>  	},
> -/* tx_loadsz is set to 63-bytes instead of 64-bytes to implement
> -workaround of errata A-008006 which states that tx_loadsz should  be
> -configured less than Maximum supported fifo bytes */
> +	/*
> +	 * tx_loadsz is set to 63-bytes instead of 64-bytes to implement
> +	 * workaround of errata A-008006 which states that tx_loadsz should be
> +	 * configured less than Maximum supported fifo bytes
> +	 */
>  	[PORT_16550A_FSL64] = {
>  		.name		= "16550A_FSL64",
>  		.fifo_size	= 64,
> @@ -1970,16 +1972,17 @@ int serial8250_do_startup(struct uart_port *port)
>  
>  	serial8250_set_mctrl(port, port->mctrl);
>  
> -	/* Serial over Lan (SoL) hack:
> -	   Intel 8257x Gigabit ethernet chips have a
> -	   16550 emulation, to be used for Serial Over Lan.
> -	   Those chips take a longer time than a normal
> -	   serial device to signalize that a transmission
> -	   data was queued. Due to that, the above test generally
> -	   fails. One solution would be to delay the reading of
> -	   iir. However, this is not reliable, since the timeout
> -	   is variable. So, let's just don't test if we receive
> -	   TX irq. This way, we'll never enable UART_BUG_TXEN.
> +	/*
> +	 * Serial over Lan (SoL) hack:
> +	 * Intel 8257x Gigabit ethernet chips have a
> +	 * 16550 emulation, to be used for Serial Over Lan.
> +	 * Those chips take a longer time than a normal
> +	 * serial device to signalize that a transmission
> +	 * data was queued. Due to that, the above test generally
> +	 * fails. One solution would be to delay the reading of
> +	 * iir. However, this is not reliable, since the timeout
> +	 * is variable. So, let's just don't test if we receive
> +	 * TX irq. This way, we'll never enable UART_BUG_TXEN.
>  	 */

Might as well unwrap this to max line length too.


>  	if (up->port.flags & UPF_NO_TXEN_TEST)
>  		goto dont_test_tx_en;
> diff --git a/drivers/tty/serial/8250/serial_cs.c b/drivers/tty/serial/8250/serial_cs.c
> index f5270ba..a4bdcf6 100644
> --- a/drivers/tty/serial/8250/serial_cs.c
> +++ b/drivers/tty/serial/8250/serial_cs.c
> @@ -1,35 +1,37 @@
> -/*======================================================================
> -
> -    A driver for PCMCIA serial devices
> -
> -    serial_cs.c 1.134 2002/05/04 05:48:53
> -
> -    The contents of this file are subject to the Mozilla Public
> -    License Version 1.1 (the "License"); you may not use this file
> -    except in compliance with the License. You may obtain a copy of
> -    the License at http://www.mozilla.org/MPL/
> -
> -    Software distributed under the License is distributed on an "AS
> -    IS" basis, WITHOUT WARRANTY OF ANY KIND, either express or
> -    implied. See the License for the specific language governing
> -    rights and limitations under the License.
> -
> -    The initial developer of the original code is David A. Hinds
> -    <dahinds@users.sourceforge.net>.  Portions created by David A. Hinds
> -    are Copyright (C) 1999 David A. Hinds.  All Rights Reserved.
> -
> -    Alternatively, the contents of this file may be used under the
> -    terms of the GNU General Public License version 2 (the "GPL"), in which
> -    case the provisions of the GPL are applicable instead of the
> -    above.  If you wish to allow the use of your version of this file
> -    only under the terms of the GPL and not to allow others to use
> -    your version of this file under the MPL, indicate your decision
> -    by deleting the provisions above and replace them with the notice
> -    and other provisions required by the GPL.  If you do not delete
> -    the provisions above, a recipient may use your version of this
> -    file under either the MPL or the GPL.
> -    
> -======================================================================*/
> +/*
> + * ======================================================================
> + *
> + * A driver for PCMCIA serial devices
> + *
> + * serial_cs.c 1.134 2002/05/04 05:48:53
> + *
> + * The contents of this file are subject to the Mozilla Public
> + * License Version 1.1 (the "License"); you may not use this file
> + * except in compliance with the License. You may obtain a copy of
> + * the License at http://www.mozilla.org/MPL/
> + *
> + * Software distributed under the License is distributed on an "AS
> + * IS" basis, WITHOUT WARRANTY OF ANY KIND, either express or
> + * implied. See the License for the specific language governing
> + * rights and limitations under the License.
> + *
> + * The initial developer of the original code is David A. Hinds
> + * <dahinds@users.sourceforge.net>.  Portions created by David A. Hinds
> + * are Copyright (C) 1999 David A. Hinds.  All Rights Reserved.
> + *
> + * Alternatively, the contents of this file may be used under the
> + * terms of the GNU General Public License version 2 (the "GPL"), in which
> + * case the provisions of the GPL are applicable instead of the
> + * above.  If you wish to allow the use of your version of this file
> + * only under the terms of the GPL and not to allow others to use
> + * your version of this file under the MPL, indicate your decision
> + * by deleting the provisions above and replace them with the notice
> + * and other provisions required by the GPL.  If you do not delete
> + * the provisions above, a recipient may use your version of this
> + * file under either the MPL or the GPL.
> + *
> + * ======================================================================
> + */
>  
>  #include <linux/module.h>
>  #include <linux/moduleparam.h>
> @@ -441,16 +443,20 @@ static int simple_config(struct pcmcia_device *link)
>  	struct serial_info *info = link->priv;
>  	int i = -ENODEV, try;
>  
> -	/* First pass: look for a config entry that looks normal.
> -	 * Two tries: without IO aliases, then with aliases */
> +	/*
> +	 * First pass: look for a config entry that looks normal.
> +	 * Two tries: without IO aliases, then with aliases
> +	 */
>  	link->config_flags |= CONF_AUTO_SET_VPP;
>  	for (try = 0; try < 4; try++)
>  		if (!pcmcia_loop_config(link, simple_config_check, &try))
>  			goto found_port;
>  
> -	/* Second pass: try to find an entry that isn't picky about
> -	   its base address, then try to grab any standard serial port
> -	   address, and finally try to get any free port. */
> +	/*
> +	 * Second pass: try to find an entry that isn't picky about
> +	 * its base address, then try to grab any standard serial port
> +	 * address, and finally try to get any free port.
> +	 */
>  	if (!pcmcia_loop_config(link, simple_config_check_notpicky, NULL))
>  		goto found_port;
>  
> @@ -480,8 +486,10 @@ static int multi_config_check(struct pcmcia_device *p_dev, void *priv_data)
>  	if (p_dev->resource[1]->end)
>  		return -EINVAL;
>  
> -	/* The quad port cards have bad CIS's, so just look for a
> -	   window larger than 8 ports and assume it will be right */
> +	/*
> +	 * The quad port cards have bad CIS's, so just look for a
> +	 * window larger than 8 ports and assume it will be right
> +	 */
>  	if (p_dev->resource[0]->end <= 8)
>  		return -EINVAL;
>  
> @@ -623,8 +631,10 @@ static int serial_config(struct pcmcia_device *link)
>  			break;
>  		}
>  
> -	/* Another check for dual-serial cards: look for either serial or
> -	   multifunction cards that ask for appropriate IO port ranges */
> +	/*
> +	 * Another check for dual-serial cards: look for either serial or
> +	 * multifunction cards that ask for appropriate IO port ranges
> +	 */
>  	if ((info->multi == 0) &&
>  	    (link->has_func_id) &&
>  	    (link->socket->pcmcia_pfc == 0) &&
> 

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

* Re: [PATCH 10/11] tty: serial: 8250: Replace printk by pr_*
  2015-12-16 15:36   ` Anton Wuerfel
  (?)
@ 2015-12-16 17:00     ` Peter Hurley
  -1 siblings, 0 replies; 60+ messages in thread
From: Peter Hurley @ 2015-12-16 17:00 UTC (permalink / raw)
  To: Anton Wuerfel
  Cc: linux-serial, Greg Kroah-Hartman, Jiri Slaby,
	James E.J. Bottomley, Helge Deller, Heikki Krogerus,
	Andy Shevchenko, Qipeng Zha, Desmond Liu, Wang Long,
	Matt Redfearn, Paul Burton, Ralf Baechle, Krzysztof Kozlowski,
	Peter Hung, Soeren Grunewald, Adam Lee, Maciej S. Szmigiero,
	Mans Rullgard, linux-kernel, linux-parisc, linux-kernel,
	Phillip Raffeck

Hi Anton,

On 12/16/2015 07:36 AM, Anton Wuerfel wrote:
> This patch replaces printk by the corresponding variant of pr_* in or=
der to
> fix checkpatch warnings.

Comments below.

> Signed-off-by: Anton W=C3=BCrfel <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  |  5 ++---
>  drivers/tty/serial/8250/8250_gsc.c   |  6 ++----
>  drivers/tty/serial/8250/8250_hp300.c | 14 +++++++-------
>  drivers/tty/serial/8250/8250_pnp.c   |  6 +++---
>  drivers/tty/serial/8250/8250_port.c  |  3 +--
>  5 files changed, 15 insertions(+), 19 deletions(-)
>=20
> diff --git a/drivers/tty/serial/8250/8250_core.c b/drivers/tty/serial=
/8250/8250_core.c
> index 2b3731f..b5e0c48 100644
> --- a/drivers/tty/serial/8250/8250_core.c
> +++ b/drivers/tty/serial/8250/8250_core.c
> @@ -1095,9 +1095,8 @@ static int __init serial8250_init(void)
> =20
>  	serial8250_isa_init_ports();
> =20
> -	printk(KERN_INFO "Serial: 8250/16550 driver, "
> -		"%d ports, IRQ sharing %sabled\n", nr_uarts,
> -		share_irqs ? "en" : "dis");
> +	pr_info("Serial: 8250/16550 driver, %d ports, IRQ sharing %sabled\n=
",
> +		nr_uarts, share_irqs ? "en" : "dis");
> =20
>  #ifdef CONFIG_SPARC
>  	ret =3D sunserial_register_minors(&serial8250_reg, UART_NR);
> diff --git a/drivers/tty/serial/8250/8250_gsc.c b/drivers/tty/serial/=
8250/8250_gsc.c
> index 2e3ea1a..a9b63d0 100644
> --- a/drivers/tty/serial/8250/8250_gsc.c
> +++ b/drivers/tty/serial/8250/8250_gsc.c
> @@ -42,8 +42,7 @@ static int __init serial_init_chip(struct parisc_de=
vice *dev)
>  		 * the user what they're missing.
>  		 */
>  		if (parisc_parent(dev)->id.hw_type !=3D HPHW_IOA)
> -			printk(KERN_INFO
> -				"Serial: device 0x%llx not configured.\n"
> +			pr_info("Serial: device 0x%llx not configured.\n"
>  				"Enable support for Wax, Lasi, Asp or Dino.\n",
>  				(unsigned long long)dev->hpa.start);
>  		return -ENODEV;
> @@ -66,8 +65,7 @@ static int __init serial_init_chip(struct parisc_de=
vice *dev)
> =20
>  	err =3D serial8250_register_8250_port(&uart);
>  	if (err < 0) {
> -		printk(KERN_WARNING
> -			"serial8250_register_8250_port returned error %d\n", err);
> +		pr_warn("serial8250_register_8250_port returned error %d\n", err);
>  		iounmap(uart.port.membase);
>  		return err;
>  	}
> diff --git a/drivers/tty/serial/8250/8250_hp300.c b/drivers/tty/seria=
l/8250/8250_hp300.c
> index 52c43da..85b574896 100644
> --- a/drivers/tty/serial/8250/8250_hp300.c
> +++ b/drivers/tty/serial/8250/8250_hp300.c
> @@ -110,7 +110,7 @@ int __init hp300_setup_serial_console(void)
>  	/* Check for APCI console */
>  	if (scode =3D=3D 256) {
>  #ifdef CONFIG_HPAPCI
> -		printk(KERN_INFO "Serial console is HP APCI 1\n");
> +		pr_info("Serial console is HP APCI 1\n");
> =20
>  		port.uartclk =3D HPAPCI_BAUD_BASE * 16;
>  		port.mapbase =3D (FRODO_BASE + FRODO_APCI_OFFSET(1));
> @@ -118,7 +118,7 @@ int __init hp300_setup_serial_console(void)
>  		port.regshift =3D 2;
>  		add_preferred_console("ttyS", port.line, "9600n8");
>  #else
> -		printk(KERN_WARNING "Serial console is APCI but support is disable=
d (CONFIG_HPAPCI)!\n");
> +		pr_warn("Serial console is APCI but support is disabled (CONFIG_HP=
APCI)!\n");
>  		return 0;
>  #endif
>  	} else {
> @@ -128,7 +128,7 @@ int __init hp300_setup_serial_console(void)
>  		if (!pa)
>  			return 0;
> =20
> -		printk(KERN_INFO "Serial console is HP DCA at select code %d\n", s=
code);
> +		pr_info("Serial console is HP DCA at select code %d\n", scode);
> =20
>  		port.uartclk =3D HPDCA_BAUD_BASE * 16;
>  		port.mapbase =3D (pa + UART_OFFSET);
> @@ -142,13 +142,13 @@ int __init hp300_setup_serial_console(void)
>  		if (DIO_ID(pa + DIO_VIRADDRBASE) & 0x80)
>  			add_preferred_console("ttyS", port.line, "9600n8");
>  #else
> -		printk(KERN_WARNING "Serial console is DCA but support is disabled=
 (CONFIG_HPDCA)!\n");
> +		pr_warn("Serial console is DCA but support is disabled (CONFIG_HPD=
CA)!\n");
>  		return 0;
>  #endif
>  	}
> =20
>  	if (early_serial_setup(&port) < 0)
> -		printk(KERN_WARNING "hp300_setup_serial_console(): early_serial_se=
tup() failed.\n");
> +		pr_warn("hp300_setup_serial_console(): early_serial_setup() failed=
=2E\n");
>  	return 0;
>  }
>  #endif /* CONFIG_SERIAL_8250_CONSOLE */




> @@ -180,7 +180,7 @@ static int hpdca_init_one(struct dio_dev *d,
>  	line =3D serial8250_register_8250_port(&uart);
> =20
>  	if (line < 0) {
> -		printk(KERN_NOTICE "8250_hp300: register_serial() DCA scode %d"
> +		pr_notice("8250_hp300: register_serial() DCA scode %d"
>  		       " irq %d failed\n", d->scode, uart.port.irq);
>  		return -ENOMEM;
>  	}
> @@ -261,7 +261,7 @@ static int __init hp300_8250_init(void)
>  		line =3D serial8250_register_8250_port(&uart);
> =20
>  		if (line < 0) {
> -			printk(KERN_NOTICE "8250_hp300: register_serial() APCI"
> +			pr_notice("8250_hp300: register_serial() APCI"
>  			       " %d irq %d failed\n", i, uart.port.irq);

Missed these multi-line strings in your previous patch
"tty: serial: 8250: Fix multi-line strings"


>  			kfree(port);
>  			continue;
> diff --git a/drivers/tty/serial/8250/8250_pnp.c b/drivers/tty/serial/=
8250/8250_pnp.c
> index 2731031..3811c67 100644
> --- a/drivers/tty/serial/8250/8250_pnp.c
> +++ b/drivers/tty/serial/8250/8250_pnp.c
> @@ -465,9 +465,9 @@ serial_pnp_probe(struct pnp_dev *dev, const struc=
t pnp_device_id *dev_id)
>  		return -ENODEV;
> =20
>  #ifdef SERIAL_DEBUG_PNP
> -	printk(KERN_DEBUG
> -		"Setup PNP port: port %x, mem 0x%lx, irq %d, type %d\n",
> -		       uart.port.iobase, uart.port.mapbase, uart.port.irq, uart.po=
rt.iotype);
> +	pr_debug("Setup PNP port: port %x, mem 0x%lx, irq %d, type %d\n",
> +		 uart.port.iobase, uart.port.mapbase,
> +		 uart.port.irq, uart.port.iotype);

Note that printk(KERN_DEBUG) and pr_debug() have different behavior;
you should note what the behavioral difference is in the changelog.


>  #endif
>  	if (flags & CIR_PORT) {
>  		uart.port.flags |=3D UPF_FIXED_PORT | UPF_FIXED_TYPE;
> diff --git a/drivers/tty/serial/8250/8250_port.c b/drivers/tty/serial=
/8250/8250_port.c
> index 0ec823e..1b2aaf9 100644
> --- a/drivers/tty/serial/8250/8250_port.c
> +++ b/drivers/tty/serial/8250/8250_port.c
> @@ -1222,8 +1222,7 @@ static void autoconfig(struct uart_8250_port *u=
p)
>  out_lock:
>  	spin_unlock_irqrestore(&port->lock, flags);
>  	if (up->capabilities !=3D old_capabilities) {
> -		printk(KERN_WARNING
> -		       "ttyS%d: detected caps %08x should be %08x\n",
> +		pr_warn("ttyS%d: detected caps %08x should be %08x\n",
>  		       serial_index(port), old_capabilities,
>  		       up->capabilities);
>  	}
>=20

--
To unsubscribe from this list: send the line "unsubscribe linux-parisc"=
 in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

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

* Re: [PATCH 10/11] tty: serial: 8250: Replace printk by pr_*
@ 2015-12-16 17:00     ` Peter Hurley
  0 siblings, 0 replies; 60+ messages in thread
From: Peter Hurley @ 2015-12-16 17:00 UTC (permalink / raw)
  To: Anton Wuerfel
  Cc: linux-serial, Greg Kroah-Hartman, Jiri Slaby,
	James E.J. Bottomley, Helge Deller, Heikki Krogerus,
	Andy Shevchenko, Qipeng Zha, Desmond Liu, Wang Long,
	Matt Redfearn, Paul Burton, Ralf Baechle, Krzysztof Kozlowski,
	Peter Hung, Soeren Grunewald, Adam Lee, Maciej S. Szmigiero,
	Mans Rullgard, linux-kernel, linux-parisc, linux-kernel,
	Phillip Raffeck

Hi Anton,

On 12/16/2015 07:36 AM, Anton Wuerfel wrote:
> This patch replaces printk by the corresponding variant of pr_* in order to
> fix checkpatch warnings.

Comments below.

> 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  |  5 ++---
>  drivers/tty/serial/8250/8250_gsc.c   |  6 ++----
>  drivers/tty/serial/8250/8250_hp300.c | 14 +++++++-------
>  drivers/tty/serial/8250/8250_pnp.c   |  6 +++---
>  drivers/tty/serial/8250/8250_port.c  |  3 +--
>  5 files changed, 15 insertions(+), 19 deletions(-)
> 
> diff --git a/drivers/tty/serial/8250/8250_core.c b/drivers/tty/serial/8250/8250_core.c
> index 2b3731f..b5e0c48 100644
> --- a/drivers/tty/serial/8250/8250_core.c
> +++ b/drivers/tty/serial/8250/8250_core.c
> @@ -1095,9 +1095,8 @@ static int __init serial8250_init(void)
>  
>  	serial8250_isa_init_ports();
>  
> -	printk(KERN_INFO "Serial: 8250/16550 driver, "
> -		"%d ports, IRQ sharing %sabled\n", nr_uarts,
> -		share_irqs ? "en" : "dis");
> +	pr_info("Serial: 8250/16550 driver, %d ports, IRQ sharing %sabled\n",
> +		nr_uarts, share_irqs ? "en" : "dis");
>  
>  #ifdef CONFIG_SPARC
>  	ret = sunserial_register_minors(&serial8250_reg, UART_NR);
> diff --git a/drivers/tty/serial/8250/8250_gsc.c b/drivers/tty/serial/8250/8250_gsc.c
> index 2e3ea1a..a9b63d0 100644
> --- a/drivers/tty/serial/8250/8250_gsc.c
> +++ b/drivers/tty/serial/8250/8250_gsc.c
> @@ -42,8 +42,7 @@ static int __init serial_init_chip(struct parisc_device *dev)
>  		 * the user what they're missing.
>  		 */
>  		if (parisc_parent(dev)->id.hw_type != HPHW_IOA)
> -			printk(KERN_INFO
> -				"Serial: device 0x%llx not configured.\n"
> +			pr_info("Serial: device 0x%llx not configured.\n"
>  				"Enable support for Wax, Lasi, Asp or Dino.\n",
>  				(unsigned long long)dev->hpa.start);
>  		return -ENODEV;
> @@ -66,8 +65,7 @@ static int __init serial_init_chip(struct parisc_device *dev)
>  
>  	err = serial8250_register_8250_port(&uart);
>  	if (err < 0) {
> -		printk(KERN_WARNING
> -			"serial8250_register_8250_port returned error %d\n", err);
> +		pr_warn("serial8250_register_8250_port returned error %d\n", err);
>  		iounmap(uart.port.membase);
>  		return err;
>  	}
> diff --git a/drivers/tty/serial/8250/8250_hp300.c b/drivers/tty/serial/8250/8250_hp300.c
> index 52c43da..85b574896 100644
> --- a/drivers/tty/serial/8250/8250_hp300.c
> +++ b/drivers/tty/serial/8250/8250_hp300.c
> @@ -110,7 +110,7 @@ int __init hp300_setup_serial_console(void)
>  	/* Check for APCI console */
>  	if (scode == 256) {
>  #ifdef CONFIG_HPAPCI
> -		printk(KERN_INFO "Serial console is HP APCI 1\n");
> +		pr_info("Serial console is HP APCI 1\n");
>  
>  		port.uartclk = HPAPCI_BAUD_BASE * 16;
>  		port.mapbase = (FRODO_BASE + FRODO_APCI_OFFSET(1));
> @@ -118,7 +118,7 @@ int __init hp300_setup_serial_console(void)
>  		port.regshift = 2;
>  		add_preferred_console("ttyS", port.line, "9600n8");
>  #else
> -		printk(KERN_WARNING "Serial console is APCI but support is disabled (CONFIG_HPAPCI)!\n");
> +		pr_warn("Serial console is APCI but support is disabled (CONFIG_HPAPCI)!\n");
>  		return 0;
>  #endif
>  	} else {
> @@ -128,7 +128,7 @@ int __init hp300_setup_serial_console(void)
>  		if (!pa)
>  			return 0;
>  
> -		printk(KERN_INFO "Serial console is HP DCA at select code %d\n", scode);
> +		pr_info("Serial console is HP DCA at select code %d\n", scode);
>  
>  		port.uartclk = HPDCA_BAUD_BASE * 16;
>  		port.mapbase = (pa + UART_OFFSET);
> @@ -142,13 +142,13 @@ int __init hp300_setup_serial_console(void)
>  		if (DIO_ID(pa + DIO_VIRADDRBASE) & 0x80)
>  			add_preferred_console("ttyS", port.line, "9600n8");
>  #else
> -		printk(KERN_WARNING "Serial console is DCA but support is disabled (CONFIG_HPDCA)!\n");
> +		pr_warn("Serial console is DCA but support is disabled (CONFIG_HPDCA)!\n");
>  		return 0;
>  #endif
>  	}
>  
>  	if (early_serial_setup(&port) < 0)
> -		printk(KERN_WARNING "hp300_setup_serial_console(): early_serial_setup() failed.\n");
> +		pr_warn("hp300_setup_serial_console(): early_serial_setup() failed.\n");
>  	return 0;
>  }
>  #endif /* CONFIG_SERIAL_8250_CONSOLE */




> @@ -180,7 +180,7 @@ static int hpdca_init_one(struct dio_dev *d,
>  	line = serial8250_register_8250_port(&uart);
>  
>  	if (line < 0) {
> -		printk(KERN_NOTICE "8250_hp300: register_serial() DCA scode %d"
> +		pr_notice("8250_hp300: register_serial() DCA scode %d"
>  		       " irq %d failed\n", d->scode, uart.port.irq);
>  		return -ENOMEM;
>  	}
> @@ -261,7 +261,7 @@ static int __init hp300_8250_init(void)
>  		line = serial8250_register_8250_port(&uart);
>  
>  		if (line < 0) {
> -			printk(KERN_NOTICE "8250_hp300: register_serial() APCI"
> +			pr_notice("8250_hp300: register_serial() APCI"
>  			       " %d irq %d failed\n", i, uart.port.irq);

Missed these multi-line strings in your previous patch
"tty: serial: 8250: Fix multi-line strings"


>  			kfree(port);
>  			continue;
> diff --git a/drivers/tty/serial/8250/8250_pnp.c b/drivers/tty/serial/8250/8250_pnp.c
> index 2731031..3811c67 100644
> --- a/drivers/tty/serial/8250/8250_pnp.c
> +++ b/drivers/tty/serial/8250/8250_pnp.c
> @@ -465,9 +465,9 @@ serial_pnp_probe(struct pnp_dev *dev, const struct pnp_device_id *dev_id)
>  		return -ENODEV;
>  
>  #ifdef SERIAL_DEBUG_PNP
> -	printk(KERN_DEBUG
> -		"Setup PNP port: port %x, mem 0x%lx, irq %d, type %d\n",
> -		       uart.port.iobase, uart.port.mapbase, uart.port.irq, uart.port.iotype);
> +	pr_debug("Setup PNP port: port %x, mem 0x%lx, irq %d, type %d\n",
> +		 uart.port.iobase, uart.port.mapbase,
> +		 uart.port.irq, uart.port.iotype);

Note that printk(KERN_DEBUG) and pr_debug() have different behavior;
you should note what the behavioral difference is in the changelog.


>  #endif
>  	if (flags & CIR_PORT) {
>  		uart.port.flags |= UPF_FIXED_PORT | UPF_FIXED_TYPE;
> diff --git a/drivers/tty/serial/8250/8250_port.c b/drivers/tty/serial/8250/8250_port.c
> index 0ec823e..1b2aaf9 100644
> --- a/drivers/tty/serial/8250/8250_port.c
> +++ b/drivers/tty/serial/8250/8250_port.c
> @@ -1222,8 +1222,7 @@ static void autoconfig(struct uart_8250_port *up)
>  out_lock:
>  	spin_unlock_irqrestore(&port->lock, flags);
>  	if (up->capabilities != old_capabilities) {
> -		printk(KERN_WARNING
> -		       "ttyS%d: detected caps %08x should be %08x\n",
> +		pr_warn("ttyS%d: detected caps %08x should be %08x\n",
>  		       serial_index(port), old_capabilities,
>  		       up->capabilities);
>  	}
> 


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

* Re: [PATCH 10/11] tty: serial: 8250: Replace printk by pr_*
@ 2015-12-16 17:00     ` Peter Hurley
  0 siblings, 0 replies; 60+ messages in thread
From: Peter Hurley @ 2015-12-16 17:00 UTC (permalink / raw)
  To: Anton Wuerfel
  Cc: linux-serial, Greg Kroah-Hartman, Jiri Slaby,
	James E.J. Bottomley, Helge Deller, Heikki Krogerus,
	Andy Shevchenko, Qipeng Zha, Desmond Liu, Wang Long,
	Matt Redfearn, Paul Burton, Ralf Baechle, Krzysztof Kozlowski,
	Peter Hung, Soeren Grunewald, Adam Lee, Maciej S. Szmigiero,
	Mans Rullgard, linux-kernel, linux-parisc, linux-kernel,
	Phillip Raffeck

Hi Anton,

On 12/16/2015 07:36 AM, Anton Wuerfel wrote:
> This patch replaces printk by the corresponding variant of pr_* in order to
> fix checkpatch warnings.

Comments below.

> 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  |  5 ++---
>  drivers/tty/serial/8250/8250_gsc.c   |  6 ++----
>  drivers/tty/serial/8250/8250_hp300.c | 14 +++++++-------
>  drivers/tty/serial/8250/8250_pnp.c   |  6 +++---
>  drivers/tty/serial/8250/8250_port.c  |  3 +--
>  5 files changed, 15 insertions(+), 19 deletions(-)
> 
> diff --git a/drivers/tty/serial/8250/8250_core.c b/drivers/tty/serial/8250/8250_core.c
> index 2b3731f..b5e0c48 100644
> --- a/drivers/tty/serial/8250/8250_core.c
> +++ b/drivers/tty/serial/8250/8250_core.c
> @@ -1095,9 +1095,8 @@ static int __init serial8250_init(void)
>  
>  	serial8250_isa_init_ports();
>  
> -	printk(KERN_INFO "Serial: 8250/16550 driver, "
> -		"%d ports, IRQ sharing %sabled\n", nr_uarts,
> -		share_irqs ? "en" : "dis");
> +	pr_info("Serial: 8250/16550 driver, %d ports, IRQ sharing %sabled\n",
> +		nr_uarts, share_irqs ? "en" : "dis");
>  
>  #ifdef CONFIG_SPARC
>  	ret = sunserial_register_minors(&serial8250_reg, UART_NR);
> diff --git a/drivers/tty/serial/8250/8250_gsc.c b/drivers/tty/serial/8250/8250_gsc.c
> index 2e3ea1a..a9b63d0 100644
> --- a/drivers/tty/serial/8250/8250_gsc.c
> +++ b/drivers/tty/serial/8250/8250_gsc.c
> @@ -42,8 +42,7 @@ static int __init serial_init_chip(struct parisc_device *dev)
>  		 * the user what they're missing.
>  		 */
>  		if (parisc_parent(dev)->id.hw_type != HPHW_IOA)
> -			printk(KERN_INFO
> -				"Serial: device 0x%llx not configured.\n"
> +			pr_info("Serial: device 0x%llx not configured.\n"
>  				"Enable support for Wax, Lasi, Asp or Dino.\n",
>  				(unsigned long long)dev->hpa.start);
>  		return -ENODEV;
> @@ -66,8 +65,7 @@ static int __init serial_init_chip(struct parisc_device *dev)
>  
>  	err = serial8250_register_8250_port(&uart);
>  	if (err < 0) {
> -		printk(KERN_WARNING
> -			"serial8250_register_8250_port returned error %d\n", err);
> +		pr_warn("serial8250_register_8250_port returned error %d\n", err);
>  		iounmap(uart.port.membase);
>  		return err;
>  	}
> diff --git a/drivers/tty/serial/8250/8250_hp300.c b/drivers/tty/serial/8250/8250_hp300.c
> index 52c43da..85b574896 100644
> --- a/drivers/tty/serial/8250/8250_hp300.c
> +++ b/drivers/tty/serial/8250/8250_hp300.c
> @@ -110,7 +110,7 @@ int __init hp300_setup_serial_console(void)
>  	/* Check for APCI console */
>  	if (scode == 256) {
>  #ifdef CONFIG_HPAPCI
> -		printk(KERN_INFO "Serial console is HP APCI 1\n");
> +		pr_info("Serial console is HP APCI 1\n");
>  
>  		port.uartclk = HPAPCI_BAUD_BASE * 16;
>  		port.mapbase = (FRODO_BASE + FRODO_APCI_OFFSET(1));
> @@ -118,7 +118,7 @@ int __init hp300_setup_serial_console(void)
>  		port.regshift = 2;
>  		add_preferred_console("ttyS", port.line, "9600n8");
>  #else
> -		printk(KERN_WARNING "Serial console is APCI but support is disabled (CONFIG_HPAPCI)!\n");
> +		pr_warn("Serial console is APCI but support is disabled (CONFIG_HPAPCI)!\n");
>  		return 0;
>  #endif
>  	} else {
> @@ -128,7 +128,7 @@ int __init hp300_setup_serial_console(void)
>  		if (!pa)
>  			return 0;
>  
> -		printk(KERN_INFO "Serial console is HP DCA at select code %d\n", scode);
> +		pr_info("Serial console is HP DCA at select code %d\n", scode);
>  
>  		port.uartclk = HPDCA_BAUD_BASE * 16;
>  		port.mapbase = (pa + UART_OFFSET);
> @@ -142,13 +142,13 @@ int __init hp300_setup_serial_console(void)
>  		if (DIO_ID(pa + DIO_VIRADDRBASE) & 0x80)
>  			add_preferred_console("ttyS", port.line, "9600n8");
>  #else
> -		printk(KERN_WARNING "Serial console is DCA but support is disabled (CONFIG_HPDCA)!\n");
> +		pr_warn("Serial console is DCA but support is disabled (CONFIG_HPDCA)!\n");
>  		return 0;
>  #endif
>  	}
>  
>  	if (early_serial_setup(&port) < 0)
> -		printk(KERN_WARNING "hp300_setup_serial_console(): early_serial_setup() failed.\n");
> +		pr_warn("hp300_setup_serial_console(): early_serial_setup() failed.\n");
>  	return 0;
>  }
>  #endif /* CONFIG_SERIAL_8250_CONSOLE */




> @@ -180,7 +180,7 @@ static int hpdca_init_one(struct dio_dev *d,
>  	line = serial8250_register_8250_port(&uart);
>  
>  	if (line < 0) {
> -		printk(KERN_NOTICE "8250_hp300: register_serial() DCA scode %d"
> +		pr_notice("8250_hp300: register_serial() DCA scode %d"
>  		       " irq %d failed\n", d->scode, uart.port.irq);
>  		return -ENOMEM;
>  	}
> @@ -261,7 +261,7 @@ static int __init hp300_8250_init(void)
>  		line = serial8250_register_8250_port(&uart);
>  
>  		if (line < 0) {
> -			printk(KERN_NOTICE "8250_hp300: register_serial() APCI"
> +			pr_notice("8250_hp300: register_serial() APCI"
>  			       " %d irq %d failed\n", i, uart.port.irq);

Missed these multi-line strings in your previous patch
"tty: serial: 8250: Fix multi-line strings"


>  			kfree(port);
>  			continue;
> diff --git a/drivers/tty/serial/8250/8250_pnp.c b/drivers/tty/serial/8250/8250_pnp.c
> index 2731031..3811c67 100644
> --- a/drivers/tty/serial/8250/8250_pnp.c
> +++ b/drivers/tty/serial/8250/8250_pnp.c
> @@ -465,9 +465,9 @@ serial_pnp_probe(struct pnp_dev *dev, const struct pnp_device_id *dev_id)
>  		return -ENODEV;
>  
>  #ifdef SERIAL_DEBUG_PNP
> -	printk(KERN_DEBUG
> -		"Setup PNP port: port %x, mem 0x%lx, irq %d, type %d\n",
> -		       uart.port.iobase, uart.port.mapbase, uart.port.irq, uart.port.iotype);
> +	pr_debug("Setup PNP port: port %x, mem 0x%lx, irq %d, type %d\n",
> +		 uart.port.iobase, uart.port.mapbase,
> +		 uart.port.irq, uart.port.iotype);

Note that printk(KERN_DEBUG) and pr_debug() have different behavior;
you should note what the behavioral difference is in the changelog.


>  #endif
>  	if (flags & CIR_PORT) {
>  		uart.port.flags |= UPF_FIXED_PORT | UPF_FIXED_TYPE;
> diff --git a/drivers/tty/serial/8250/8250_port.c b/drivers/tty/serial/8250/8250_port.c
> index 0ec823e..1b2aaf9 100644
> --- a/drivers/tty/serial/8250/8250_port.c
> +++ b/drivers/tty/serial/8250/8250_port.c
> @@ -1222,8 +1222,7 @@ static void autoconfig(struct uart_8250_port *up)
>  out_lock:
>  	spin_unlock_irqrestore(&port->lock, flags);
>  	if (up->capabilities != old_capabilities) {
> -		printk(KERN_WARNING
> -		       "ttyS%d: detected caps %08x should be %08x\n",
> +		pr_warn("ttyS%d: detected caps %08x should be %08x\n",
>  		       serial_index(port), old_capabilities,
>  		       up->capabilities);
>  	}
> 

--
To unsubscribe from this list: send the line "unsubscribe linux-parisc" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

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

* Re: [PATCH 11/11] tty: serial: 8250: Delete commented code
  2015-12-16 15:36   ` Anton Wuerfel
  (?)
@ 2015-12-16 17:05     ` Peter Hurley
  -1 siblings, 0 replies; 60+ messages in thread
From: Peter Hurley @ 2015-12-16 17:05 UTC (permalink / raw)
  To: Anton Wuerfel, linux-serial
  Cc: Greg Kroah-Hartman, Jiri Slaby, James E.J. Bottomley,
	Helge Deller, Heikki Krogerus, Andy Shevchenko, Qipeng Zha,
	Desmond Liu, Wang Long, Matt Redfearn, Paul Burton, Ralf Baechle,
	Krzysztof Kozlowski, Peter Hung, Soeren Grunewald, Adam Lee,
	Maciej S. Szmigiero, Mans Rullgard, linux-kernel, linux-parisc,
	linux-kernel, Phillip Raffeck

Hi Anton,

On 12/16/2015 07:36 AM, Anton Wuerfel wrote:
> This patch removes code which has been commented out. It serves no
> documentary purposes and decreases the readability of the remaining c=
ode.
> Furthermore the comment style causes checkpatch warnings. If this cod=
e
> should ever be needed again, git keeps track of it.

This is bad idea.

I can count on one hand the number of times I've tried to find deleted
code in git. How would you go about finding all deleted sub-vendor
ids in the 16.5M-line Linux source tree, say since 2.6.32?

Regards,
Peter Hurley

> Signed-off-by: Anton W=C3=BCrfel <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_pci.c | 7 -------
>  1 file changed, 7 deletions(-)
>=20
> diff --git a/drivers/tty/serial/8250/8250_pci.c b/drivers/tty/serial/=
8250/8250_pci.c
> index 3bc0303..9136f0f 100644
> --- a/drivers/tty/serial/8250/8250_pci.c
> +++ b/drivers/tty/serial/8250/8250_pci.c
> @@ -4928,16 +4928,9 @@ static struct pci_device_id serial_pci_tbl[] =3D=
 {
>  	{	PCI_VENDOR_ID_KORENIX, PCI_DEVICE_ID_KORENIX_JETCARDF0,
>  		0x1208, 0x0004, 0, 0,
>  		pbn_b0_4_921600 },
> -/*	{	PCI_VENDOR_ID_KORENIX, PCI_DEVICE_ID_KORENIX_JETCARDF0,
> -		0x1402, 0x0002, 0, 0,
> -		pbn_b0_2_921600 }, */
> -/*	{	PCI_VENDOR_ID_KORENIX, PCI_DEVICE_ID_KORENIX_JETCARDF0,
> -		0x1404, 0x0004, 0, 0,
> -		pbn_b0_4_921600 }, */
>  	{	PCI_VENDOR_ID_KORENIX, PCI_DEVICE_ID_KORENIX_JETCARDF1,
>  		0x1208, 0x0004, 0, 0,
>  		pbn_b0_4_921600 },
> -
>  	{	PCI_VENDOR_ID_KORENIX, PCI_DEVICE_ID_KORENIX_JETCARDF2,
>  		0x1204, 0x0004, 0, 0,
>  		pbn_b0_4_921600 },
>=20

--
To unsubscribe from this list: send the line "unsubscribe linux-parisc"=
 in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

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

* Re: [PATCH 11/11] tty: serial: 8250: Delete commented code
@ 2015-12-16 17:05     ` Peter Hurley
  0 siblings, 0 replies; 60+ messages in thread
From: Peter Hurley @ 2015-12-16 17:05 UTC (permalink / raw)
  To: Anton Wuerfel, linux-serial
  Cc: Greg Kroah-Hartman, Jiri Slaby, James E.J. Bottomley,
	Helge Deller, Heikki Krogerus, Andy Shevchenko, Qipeng Zha,
	Desmond Liu, Wang Long, Matt Redfearn, Paul Burton, Ralf Baechle,
	Krzysztof Kozlowski, Peter Hung, Soeren Grunewald, Adam Lee,
	Maciej S. Szmigiero, Mans Rullgard, linux-kernel, linux-parisc,
	linux-kernel, Phillip Raffeck

Hi Anton,

On 12/16/2015 07:36 AM, Anton Wuerfel wrote:
> This patch removes code which has been commented out. It serves no
> documentary purposes and decreases the readability of the remaining code.
> Furthermore the comment style causes checkpatch warnings. If this code
> should ever be needed again, git keeps track of it.

This is bad idea.

I can count on one hand the number of times I've tried to find deleted
code in git. How would you go about finding all deleted sub-vendor
ids in the 16.5M-line Linux source tree, say since 2.6.32?

Regards,
Peter Hurley

> 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_pci.c | 7 -------
>  1 file changed, 7 deletions(-)
> 
> diff --git a/drivers/tty/serial/8250/8250_pci.c b/drivers/tty/serial/8250/8250_pci.c
> index 3bc0303..9136f0f 100644
> --- a/drivers/tty/serial/8250/8250_pci.c
> +++ b/drivers/tty/serial/8250/8250_pci.c
> @@ -4928,16 +4928,9 @@ static struct pci_device_id serial_pci_tbl[] = {
>  	{	PCI_VENDOR_ID_KORENIX, PCI_DEVICE_ID_KORENIX_JETCARDF0,
>  		0x1208, 0x0004, 0, 0,
>  		pbn_b0_4_921600 },
> -/*	{	PCI_VENDOR_ID_KORENIX, PCI_DEVICE_ID_KORENIX_JETCARDF0,
> -		0x1402, 0x0002, 0, 0,
> -		pbn_b0_2_921600 }, */
> -/*	{	PCI_VENDOR_ID_KORENIX, PCI_DEVICE_ID_KORENIX_JETCARDF0,
> -		0x1404, 0x0004, 0, 0,
> -		pbn_b0_4_921600 }, */
>  	{	PCI_VENDOR_ID_KORENIX, PCI_DEVICE_ID_KORENIX_JETCARDF1,
>  		0x1208, 0x0004, 0, 0,
>  		pbn_b0_4_921600 },
> -
>  	{	PCI_VENDOR_ID_KORENIX, PCI_DEVICE_ID_KORENIX_JETCARDF2,
>  		0x1204, 0x0004, 0, 0,
>  		pbn_b0_4_921600 },
> 


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

* Re: [PATCH 11/11] tty: serial: 8250: Delete commented code
@ 2015-12-16 17:05     ` Peter Hurley
  0 siblings, 0 replies; 60+ messages in thread
From: Peter Hurley @ 2015-12-16 17:05 UTC (permalink / raw)
  To: Anton Wuerfel, linux-serial
  Cc: Greg Kroah-Hartman, Jiri Slaby, James E.J. Bottomley,
	Helge Deller, Heikki Krogerus, Andy Shevchenko, Qipeng Zha,
	Desmond Liu, Wang Long, Matt Redfearn, Paul Burton, Ralf Baechle,
	Krzysztof Kozlowski, Peter Hung, Soeren Grunewald, Adam Lee,
	Maciej S. Szmigiero, Mans Rullgard, linux-kernel, linux-parisc,
	linux-kernel, Phillip Raffeck

Hi Anton,

On 12/16/2015 07:36 AM, Anton Wuerfel wrote:
> This patch removes code which has been commented out. It serves no
> documentary purposes and decreases the readability of the remaining code.
> Furthermore the comment style causes checkpatch warnings. If this code
> should ever be needed again, git keeps track of it.

This is bad idea.

I can count on one hand the number of times I've tried to find deleted
code in git. How would you go about finding all deleted sub-vendor
ids in the 16.5M-line Linux source tree, say since 2.6.32?

Regards,
Peter Hurley

> 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_pci.c | 7 -------
>  1 file changed, 7 deletions(-)
> 
> diff --git a/drivers/tty/serial/8250/8250_pci.c b/drivers/tty/serial/8250/8250_pci.c
> index 3bc0303..9136f0f 100644
> --- a/drivers/tty/serial/8250/8250_pci.c
> +++ b/drivers/tty/serial/8250/8250_pci.c
> @@ -4928,16 +4928,9 @@ static struct pci_device_id serial_pci_tbl[] = {
>  	{	PCI_VENDOR_ID_KORENIX, PCI_DEVICE_ID_KORENIX_JETCARDF0,
>  		0x1208, 0x0004, 0, 0,
>  		pbn_b0_4_921600 },
> -/*	{	PCI_VENDOR_ID_KORENIX, PCI_DEVICE_ID_KORENIX_JETCARDF0,
> -		0x1402, 0x0002, 0, 0,
> -		pbn_b0_2_921600 }, */
> -/*	{	PCI_VENDOR_ID_KORENIX, PCI_DEVICE_ID_KORENIX_JETCARDF0,
> -		0x1404, 0x0004, 0, 0,
> -		pbn_b0_4_921600 }, */
>  	{	PCI_VENDOR_ID_KORENIX, PCI_DEVICE_ID_KORENIX_JETCARDF1,
>  		0x1208, 0x0004, 0, 0,
>  		pbn_b0_4_921600 },
> -
>  	{	PCI_VENDOR_ID_KORENIX, PCI_DEVICE_ID_KORENIX_JETCARDF2,
>  		0x1204, 0x0004, 0, 0,
>  		pbn_b0_4_921600 },
> 

--
To unsubscribe from this list: send the line "unsubscribe linux-parisc" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

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

* Re: [PATCH 06/11] tty: serial: 8250: Move EXPORT_SYMBOL to function
  2015-12-16 15:36   ` Anton Wuerfel
  (?)
@ 2015-12-16 17:06     ` Peter Hurley
  -1 siblings, 0 replies; 60+ messages in thread
From: Peter Hurley @ 2015-12-16 17:06 UTC (permalink / raw)
  To: Anton Wuerfel, linux-serial
  Cc: Greg Kroah-Hartman, Jiri Slaby, James E.J. Bottomley,
	Helge Deller, Heikki Krogerus, Andy Shevchenko, Qipeng Zha,
	Desmond Liu, Wang Long, Matt Redfearn, Paul Burton, Ralf Baechle,
	Krzysztof Kozlowski, Peter Hung, Soeren Grunewald, Adam Lee,
	Maciej S. Szmigiero, Mans Rullgard, linux-kernel, linux-parisc,
	linux-kernel, Phillip Raffeck

On 12/16/2015 07:36 AM, Anton Wuerfel wrote:
> This patch moves EXPORT_SYMBOL macros directly after the definition o=
f
> the corresponding symbol to remove checkpatch warnings.

Ok.


> Signed-off-by: Anton W=C3=BCrfel <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 | 5 ++---
>  1 file changed, 2 insertions(+), 3 deletions(-)
>=20
> diff --git a/drivers/tty/serial/8250/8250_core.c b/drivers/tty/serial=
/8250/8250_core.c
> index 89a20c9..67147b2 100644
> --- a/drivers/tty/serial/8250/8250_core.c
> +++ b/drivers/tty/serial/8250/8250_core.c
> @@ -764,6 +764,7 @@ void serial8250_suspend_port(int line)
> =20
>  	uart_suspend_port(&serial8250_reg, port);
>  }
> +EXPORT_SYMBOL(serial8250_suspend_port);
> =20
>  /**
>   *	serial8250_resume_port - resume one serial port
> @@ -789,6 +790,7 @@ void serial8250_resume_port(int line)
>  	}
>  	uart_resume_port(&serial8250_reg, port);
>  }
> +EXPORT_SYMBOL(serial8250_resume_port);
> =20
>  /*
>   * Register a set of serial devices attached to a platform device.  =
The
> @@ -1168,9 +1170,6 @@ static void __exit serial8250_exit(void)
>  module_init(serial8250_init);
>  module_exit(serial8250_exit);
> =20
> -EXPORT_SYMBOL(serial8250_suspend_port);
> -EXPORT_SYMBOL(serial8250_resume_port);
> -
>  MODULE_LICENSE("GPL");
>  MODULE_DESCRIPTION("Generic 8250/16x50 serial driver");
> =20
>=20

--
To unsubscribe from this list: send the line "unsubscribe linux-parisc"=
 in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

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

* Re: [PATCH 06/11] tty: serial: 8250: Move EXPORT_SYMBOL to function
@ 2015-12-16 17:06     ` Peter Hurley
  0 siblings, 0 replies; 60+ messages in thread
From: Peter Hurley @ 2015-12-16 17:06 UTC (permalink / raw)
  To: Anton Wuerfel, linux-serial
  Cc: Greg Kroah-Hartman, Jiri Slaby, James E.J. Bottomley,
	Helge Deller, Heikki Krogerus, Andy Shevchenko, Qipeng Zha,
	Desmond Liu, Wang Long, Matt Redfearn, Paul Burton, Ralf Baechle,
	Krzysztof Kozlowski, Peter Hung, Soeren Grunewald, Adam Lee,
	Maciej S. Szmigiero, Mans Rullgard, linux-kernel, linux-parisc,
	linux-kernel, Phillip Raffeck

On 12/16/2015 07:36 AM, Anton Wuerfel wrote:
> This patch moves EXPORT_SYMBOL macros directly after the definition of
> the corresponding symbol to remove checkpatch warnings.

Ok.


> 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 | 5 ++---
>  1 file changed, 2 insertions(+), 3 deletions(-)
> 
> diff --git a/drivers/tty/serial/8250/8250_core.c b/drivers/tty/serial/8250/8250_core.c
> index 89a20c9..67147b2 100644
> --- a/drivers/tty/serial/8250/8250_core.c
> +++ b/drivers/tty/serial/8250/8250_core.c
> @@ -764,6 +764,7 @@ void serial8250_suspend_port(int line)
>  
>  	uart_suspend_port(&serial8250_reg, port);
>  }
> +EXPORT_SYMBOL(serial8250_suspend_port);
>  
>  /**
>   *	serial8250_resume_port - resume one serial port
> @@ -789,6 +790,7 @@ void serial8250_resume_port(int line)
>  	}
>  	uart_resume_port(&serial8250_reg, port);
>  }
> +EXPORT_SYMBOL(serial8250_resume_port);
>  
>  /*
>   * Register a set of serial devices attached to a platform device.  The
> @@ -1168,9 +1170,6 @@ static void __exit serial8250_exit(void)
>  module_init(serial8250_init);
>  module_exit(serial8250_exit);
>  
> -EXPORT_SYMBOL(serial8250_suspend_port);
> -EXPORT_SYMBOL(serial8250_resume_port);
> -
>  MODULE_LICENSE("GPL");
>  MODULE_DESCRIPTION("Generic 8250/16x50 serial driver");
>  
> 


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

* Re: [PATCH 06/11] tty: serial: 8250: Move EXPORT_SYMBOL to function
@ 2015-12-16 17:06     ` Peter Hurley
  0 siblings, 0 replies; 60+ messages in thread
From: Peter Hurley @ 2015-12-16 17:06 UTC (permalink / raw)
  To: Anton Wuerfel, linux-serial
  Cc: Greg Kroah-Hartman, Jiri Slaby, James E.J. Bottomley,
	Helge Deller, Heikki Krogerus, Andy Shevchenko, Qipeng Zha,
	Desmond Liu, Wang Long, Matt Redfearn, Paul Burton, Ralf Baechle,
	Krzysztof Kozlowski, Peter Hung, Soeren Grunewald, Adam Lee,
	Maciej S. Szmigiero, Mans Rullgard, linux-kernel, linux-parisc,
	linux-kernel, Phillip Raffeck

On 12/16/2015 07:36 AM, Anton Wuerfel wrote:
> This patch moves EXPORT_SYMBOL macros directly after the definition of
> the corresponding symbol to remove checkpatch warnings.

Ok.


> 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 | 5 ++---
>  1 file changed, 2 insertions(+), 3 deletions(-)
> 
> diff --git a/drivers/tty/serial/8250/8250_core.c b/drivers/tty/serial/8250/8250_core.c
> index 89a20c9..67147b2 100644
> --- a/drivers/tty/serial/8250/8250_core.c
> +++ b/drivers/tty/serial/8250/8250_core.c
> @@ -764,6 +764,7 @@ void serial8250_suspend_port(int line)
>  
>  	uart_suspend_port(&serial8250_reg, port);
>  }
> +EXPORT_SYMBOL(serial8250_suspend_port);
>  
>  /**
>   *	serial8250_resume_port - resume one serial port
> @@ -789,6 +790,7 @@ void serial8250_resume_port(int line)
>  	}
>  	uart_resume_port(&serial8250_reg, port);
>  }
> +EXPORT_SYMBOL(serial8250_resume_port);
>  
>  /*
>   * Register a set of serial devices attached to a platform device.  The
> @@ -1168,9 +1170,6 @@ static void __exit serial8250_exit(void)
>  module_init(serial8250_init);
>  module_exit(serial8250_exit);
>  
> -EXPORT_SYMBOL(serial8250_suspend_port);
> -EXPORT_SYMBOL(serial8250_resume_port);
> -
>  MODULE_LICENSE("GPL");
>  MODULE_DESCRIPTION("Generic 8250/16x50 serial driver");
>  
> 

--
To unsubscribe from this list: send the line "unsubscribe linux-parisc" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

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

* Re: [PATCH 08/11] tty: serial: 8250: Add parentheses to macro
  2015-12-16 15:36   ` Anton Wuerfel
@ 2015-12-17 15:16     ` Andy Shevchenko
  -1 siblings, 0 replies; 60+ messages in thread
From: Andy Shevchenko @ 2015-12-17 15:16 UTC (permalink / raw)
  To: Anton Wuerfel, linux-serial
  Cc: Greg Kroah-Hartman, Jiri Slaby, James E.J. Bottomley,
	Helge Deller, Peter Hurley, Heikki Krogerus, Qipeng Zha,
	Desmond Liu, Wang Long, Matt Redfearn, Paul Burton, Ralf Baechle,
	Krzysztof Kozlowski, Peter Hung, Soeren Grunewald, Adam Lee,
	Maciej S. Szmigiero, Mans Rullgard, linux-kernel, linux-parisc,
	linux-kernel, Phillip Raffeck

On Wed, 2015-12-16 at 16:36 +0100, Anton Wuerfel wrote:
> This patch fixes a checkpatch warning caused by missing parentheses
> in the definition of a macro.
>=20
> Signed-off-by: Anton W=C3=BCrfel <anton.wuerfel@fau.de>
> Signed-off-by: Phillip Raffeck <phillip.raffeck@fau.de>
> CC: linux-kernel@i4.cs.fau.de
> ---
> =C2=A0drivers/tty/serial/8250/8250_core.c | 2 +-
> =C2=A01 file changed, 1 insertion(+), 1 deletion(-)
>=20
> diff --git a/drivers/tty/serial/8250/8250_core.c
> b/drivers/tty/serial/8250/8250_core.c
> index 67147b2..3c29530 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)
> =C2=A0}
> =C2=A0console_initcall(univ8250_console_init);
> =C2=A0
> -#define SERIAL8250_CONSOLE	&univ8250_console
> +#define SERIAL8250_CONSOLE	(&univ8250_console)

What about the rest of the drivers under drivers/tty/serial?

What do you propose to do with, for example, the following

drivers/tty/serial/cpm_uart/cpm_uart_core.c:1392:#define
CPM_UART_CONSOLE=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0&cpm_scc_uart=
_console
drivers/tty/serial/cpm_uart/cpm_uart_core.c:1394:#define
CPM_UART_CONSOLE=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0NULL

> =C2=A0#else
> =C2=A0#define SERIAL8250_CONSOLE	NULL
> =C2=A0#endif

--=20
Andy Shevchenko <andriy.shevchenko@linux.intel.com>
Intel Finland Oy

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

* Re: [PATCH 08/11] tty: serial: 8250: Add parentheses to macro
@ 2015-12-17 15:16     ` Andy Shevchenko
  0 siblings, 0 replies; 60+ messages in thread
From: Andy Shevchenko @ 2015-12-17 15:16 UTC (permalink / raw)
  To: Anton Wuerfel, linux-serial
  Cc: Greg Kroah-Hartman, Jiri Slaby, James E.J. Bottomley,
	Helge Deller, Peter Hurley, Heikki Krogerus, Qipeng Zha,
	Desmond Liu, Wang Long, Matt Redfearn, Paul Burton, Ralf Baechle,
	Krzysztof Kozlowski, Peter Hung, Soeren Grunewald, Adam Lee,
	Maciej S. Szmigiero, Mans Rullgard, linux-kernel, linux-parisc,
	linux-kernel, Phillip Raffeck

On Wed, 2015-12-16 at 16:36 +0100, Anton Wuerfel wrote:
> This patch fixes a checkpatch warning caused by missing parentheses
> in the definition of a macro.
> 
> 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 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/drivers/tty/serial/8250/8250_core.c
> b/drivers/tty/serial/8250/8250_core.c
> index 67147b2..3c29530 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)

What about the rest of the drivers under drivers/tty/serial?

What do you propose to do with, for example, the following

drivers/tty/serial/cpm_uart/cpm_uart_core.c:1392:#define
CPM_UART_CONSOLE       &cpm_scc_uart_console
drivers/tty/serial/cpm_uart/cpm_uart_core.c:1394:#define
CPM_UART_CONSOLE       NULL

>  #else
>  #define SERIAL8250_CONSOLE	NULL
>  #endif

-- 
Andy Shevchenko <andriy.shevchenko@linux.intel.com>
Intel Finland Oy


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

* Re: [PATCH 08/11] tty: serial: 8250: Add parentheses to macro
  2015-12-17 15:16     ` Andy Shevchenko
@ 2015-12-18 11:36       ` anton.wuerfel
  -1 siblings, 0 replies; 60+ messages in thread
From: anton.wuerfel @ 2015-12-18 11:36 UTC (permalink / raw)
  To: Andy Shevchenko
  Cc: linux-kernel, linux-parisc, linux-kernel, anton.wuerfel, phillip.raffeck

Hello Andy,

> What about the rest of the drivers under drivers/tty/serial?
>
> What do you propose to do with, for example, the following
>
> drivers/tty/serial/cpm_uart/cpm_uart_core.c:1392:#define
> CPM_UART_CONSOLE=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0&cpm_scc_ua=
rt_console
> drivers/tty/serial/cpm_uart/cpm_uart_core.c:1394:#define
> CPM_UART_CONSOLE=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0NULL
>
>> =C2=A0#else
>> =C2=A0#define SERIAL8250_CONSOLE	NULL
>> =C2=A0#endif
>

thanks for your reply. Phillip and me are newcomers to kernel developme=
nt,
so we tried to touch as few files as possible and gain some experience =
in
creating patches and communication on LKML. We will consider sending
further patches in the future.

Regards,
Phillip Raffeck
Anton Wuerfel

> --
> Andy Shevchenko <andriy.shevchenko@linux.intel.com>
> Intel Finland Oy
>
>


--
To unsubscribe from this list: send the line "unsubscribe linux-parisc"=
 in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

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

* Re: [PATCH 08/11] tty: serial: 8250: Add parentheses to macro
@ 2015-12-18 11:36       ` anton.wuerfel
  0 siblings, 0 replies; 60+ messages in thread
From: anton.wuerfel @ 2015-12-18 11:36 UTC (permalink / raw)
  To: Andy Shevchenko
  Cc: linux-kernel, linux-parisc, linux-kernel, anton.wuerfel, phillip.raffeck

Hello Andy,

> What about the rest of the drivers under drivers/tty/serial?
>
> What do you propose to do with, for example, the following
>
> drivers/tty/serial/cpm_uart/cpm_uart_core.c:1392:#define
> CPM_UART_CONSOLE       &cpm_scc_uart_console
> drivers/tty/serial/cpm_uart/cpm_uart_core.c:1394:#define
> CPM_UART_CONSOLE       NULL
>
>>  #else
>>  #define SERIAL8250_CONSOLE	NULL
>>  #endif
>

thanks for your reply. Phillip and me are newcomers to kernel development,
so we tried to touch as few files as possible and gain some experience in
creating patches and communication on LKML. We will consider sending
further patches in the future.

Regards,
Phillip Raffeck
Anton Wuerfel

> --
> Andy Shevchenko <andriy.shevchenko@linux.intel.com>
> Intel Finland Oy
>
>



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

* Re: [PATCH 08/11] tty: serial: 8250: Add parentheses to macro
  2015-12-18 11:36       ` anton.wuerfel
@ 2015-12-18 12:35         ` Andy Shevchenko
  -1 siblings, 0 replies; 60+ messages in thread
From: Andy Shevchenko @ 2015-12-18 12:35 UTC (permalink / raw)
  To: anton.wuerfel; +Cc: linux-kernel, linux-parisc, linux-kernel, phillip.raffeck

On Fri, 2015-12-18 at 12:36 +0100, anton.wuerfel@fau.de wrote:
> Hello Andy,
>=20
> > What about the rest of the drivers under drivers/tty/serial?
> >=20
> > What do you propose to do with, for example, the following
> >=20
> > drivers/tty/serial/cpm_uart/cpm_uart_core.c:1392:#define
> > CPM_UART_CONSOLE=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0&cpm_scc_=
uart_console
> > drivers/tty/serial/cpm_uart/cpm_uart_core.c:1394:#define
> > CPM_UART_CONSOLE=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0NULL
> >=20
> > > =C2=A0#else
> > > =C2=A0#define SERIAL8250_CONSOLE	NULL
> > > =C2=A0#endif
> >=20
>=20
> thanks for your reply. Phillip and me are newcomers to kernel
> development,

Welcome!

> so we tried to touch as few files as possible and gain some
> experience in
> creating patches and communication on LKML. We will consider sending
> further patches in the future.

I see.

I don't know which way is preferable for such patches, I think Greg
usually likes when one patch touches one driver. So, this one is okay,
and other drivers can be fixed later.



> Regards,
> Phillip Raffeck
> Anton Wuerfel
>=20
> > --
> > Andy Shevchenko <andriy.shevchenko@linux.intel.com>
> > Intel Finland Oy
> >=20
> >=20
>=20
>=20

--=20
Andy Shevchenko <andriy.shevchenko@linux.intel.com>
Intel Finland Oy

--
To unsubscribe from this list: send the line "unsubscribe linux-parisc"=
 in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

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

* Re: [PATCH 08/11] tty: serial: 8250: Add parentheses to macro
@ 2015-12-18 12:35         ` Andy Shevchenko
  0 siblings, 0 replies; 60+ messages in thread
From: Andy Shevchenko @ 2015-12-18 12:35 UTC (permalink / raw)
  To: anton.wuerfel; +Cc: linux-kernel, linux-parisc, linux-kernel, phillip.raffeck

On Fri, 2015-12-18 at 12:36 +0100, anton.wuerfel@fau.de wrote:
> Hello Andy,
> 
> > What about the rest of the drivers under drivers/tty/serial?
> > 
> > What do you propose to do with, for example, the following
> > 
> > drivers/tty/serial/cpm_uart/cpm_uart_core.c:1392:#define
> > CPM_UART_CONSOLE       &cpm_scc_uart_console
> > drivers/tty/serial/cpm_uart/cpm_uart_core.c:1394:#define
> > CPM_UART_CONSOLE       NULL
> > 
> > >  #else
> > >  #define SERIAL8250_CONSOLE	NULL
> > >  #endif
> > 
> 
> thanks for your reply. Phillip and me are newcomers to kernel
> development,

Welcome!

> so we tried to touch as few files as possible and gain some
> experience in
> creating patches and communication on LKML. We will consider sending
> further patches in the future.

I see.

I don't know which way is preferable for such patches, I think Greg
usually likes when one patch touches one driver. So, this one is okay,
and other drivers can be fixed later.



> Regards,
> Phillip Raffeck
> Anton Wuerfel
> 
> > --
> > Andy Shevchenko <andriy.shevchenko@linux.intel.com>
> > Intel Finland Oy
> > 
> > 
> 
> 

-- 
Andy Shevchenko <andriy.shevchenko@linux.intel.com>
Intel Finland Oy


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

end of thread, other threads:[~2015-12-18 12:37 UTC | newest]

Thread overview: 60+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2015-12-16 15:36 [PATCH 00/11] tty: serial: 8250: Fix checkpatch warnings Anton Wuerfel
2015-12-16 15:36 ` Anton Wuerfel
2015-12-16 15:36 ` Anton Wuerfel
2015-12-16 15:36 ` [PATCH 01/11] tty: serial: 8250: Fix whitespace errors Anton Wuerfel
2015-12-16 15:36   ` Anton Wuerfel
2015-12-16 15:36   ` Anton Wuerfel
2015-12-16 16:43   ` Peter Hurley
2015-12-16 16:43     ` Peter Hurley
2015-12-16 16:43     ` Peter Hurley
2015-12-16 15:36 ` [PATCH 02/11] tty: serial: 8250: Fix indentation warnings Anton Wuerfel
2015-12-16 15:36   ` Anton Wuerfel
2015-12-16 15:36   ` Anton Wuerfel
2015-12-16 16:49   ` Peter Hurley
2015-12-16 16:49     ` Peter Hurley
2015-12-16 16:49     ` Peter Hurley
2015-12-16 15:36 ` [PATCH 03/11] tty: serial: 8250: Fix braces after struct Anton Wuerfel
2015-12-16 15:36   ` Anton Wuerfel
2015-12-16 15:36   ` Anton Wuerfel
2015-12-16 15:36 ` [PATCH 04/11] tty: serial: 8250: Fix multiline comment style Anton Wuerfel
2015-12-16 15:36   ` Anton Wuerfel
2015-12-16 15:36   ` Anton Wuerfel
2015-12-16 16:52   ` Peter Hurley
2015-12-16 16:52     ` Peter Hurley
2015-12-16 16:52     ` Peter Hurley
2015-12-16 15:36 ` [PATCH 05/11] tty: serial: 8250: Remove else after return Anton Wuerfel
2015-12-16 15:36   ` Anton Wuerfel
2015-12-16 15:36   ` Anton Wuerfel
2015-12-16 15:36 ` [PATCH 06/11] tty: serial: 8250: Move EXPORT_SYMBOL to function Anton Wuerfel
2015-12-16 15:36   ` Anton Wuerfel
2015-12-16 15:36   ` Anton Wuerfel
2015-12-16 17:06   ` Peter Hurley
2015-12-16 17:06     ` Peter Hurley
2015-12-16 17:06     ` Peter Hurley
2015-12-16 15:36 ` [PATCH 07/11] tty: serial: 8250: Fix line continuation warning Anton Wuerfel
2015-12-16 15:36   ` Anton Wuerfel
2015-12-16 15:36   ` Anton Wuerfel
2015-12-16 15:36 ` [PATCH 08/11] tty: serial: 8250: Add parentheses to macro Anton Wuerfel
2015-12-16 15:36   ` Anton Wuerfel
2015-12-16 15:36   ` Anton Wuerfel
2015-12-17 15:16   ` Andy Shevchenko
2015-12-17 15:16     ` Andy Shevchenko
2015-12-18 11:36     ` anton.wuerfel
2015-12-18 11:36       ` anton.wuerfel
2015-12-18 12:35       ` Andy Shevchenko
2015-12-18 12:35         ` Andy Shevchenko
2015-12-16 15:36 ` [PATCH 09/11] tty: serial: 8250: Fix multi-line strings Anton Wuerfel
2015-12-16 15:36   ` Anton Wuerfel
2015-12-16 15:36   ` Anton Wuerfel
2015-12-16 15:36 ` [PATCH 10/11] tty: serial: 8250: Replace printk by pr_* Anton Wuerfel
2015-12-16 15:36   ` Anton Wuerfel
2015-12-16 15:36   ` Anton Wuerfel
2015-12-16 17:00   ` Peter Hurley
2015-12-16 17:00     ` Peter Hurley
2015-12-16 17:00     ` Peter Hurley
2015-12-16 15:36 ` [PATCH 11/11] tty: serial: 8250: Delete commented code Anton Wuerfel
2015-12-16 15:36   ` Anton Wuerfel
2015-12-16 15:36   ` Anton Wuerfel
2015-12-16 17:05   ` Peter Hurley
2015-12-16 17:05     ` Peter Hurley
2015-12-16 17:05     ` Peter Hurley

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.