Skip to contentSkip to conversation

tty: drop unused iflag macro

PATCH In review Johan Hovold 3 participants 8 messages Apr 26, 2019 – May 23, 2019

Subsystems (2)
lore
Share & tools
lore
#0 lore raw

cover tty: drop unused iflag macro

I noticed that the RELEVANT_IFLAG() macro was unused in USB serial and turns out there were a few more instances that could be dropped.

I have some pending changes that may conflict with the corresponding change to USB serial so I'll take that one separately through my tree, but perhaps the rest could go through Greg's tty tree.

Johan

Johan Hovold (3):
tty: simserial: drop unused iflag macro
tty: ipoctal: drop unused iflag macro
tty: cpm_uart: drop unused iflag macro

 arch/ia64/hp/sim/simserial.c                | 2 --
 drivers/ipack/devices/ipoctal.h             | 1 -
 drivers/tty/serial/cpm_uart/cpm_uart_core.c | 2 --
 3 files changed, 5 deletions(-)
Signature · 1 line
2.21.0
#1 lore raw

PATCH 1/3 tty: simserial: drop unused iflag macro

Drop the RELEVANT_IFLAG() macro which hasn't been used for over a decade.

---
 arch/ia64/hp/sim/simserial.c | 2 --
 1 file changed, 2 deletions(-)
arch/ia64/hp/sim/simserial.c +0 -2
index 7aeb48a18576..1a338e541334 100644
@@ -324,8 +324,6 @@ static int rs_ioctl(struct tty_struct *tty, unsigned int cmd, unsigned long arg)
 	return -ENOIOCTLCMD;
 }
 
-#define RELEVANT_IFLAG(iflag) (iflag & (IGNBRK|BRKINT|IGNPAR|PARMRK|INPCK))
-
 /*
  * This routine will shutdown a serial port; interrupts are disabled, and
  * DTR is dropped if the hangup on close termio flag is on.
Signature · 1 line
2.21.0
#3 lore raw

PATCH 2/3 tty: ipoctal: drop unused iflag macro

In reply to Johan Hovold

Drop the RELEVANT_IFLAG() macro which has never been used.

Cc Samuel Iglesias Gonsalvez <[email protected]>
Cc Jens Taprogge <[email protected]>
---
 drivers/ipack/devices/ipoctal.h | 1 -
 1 file changed, 1 deletion(-)
drivers/ipack/devices/ipoctal.h +0 -1
index 7fede0eb6a0c..78e4fc81fb03 100644
@@ -18,7 +18,6 @@
 #define NR_CHANNELS		8
 #define IPOCTAL_MAX_BOARDS	16
 #define MAX_DEVICES		(NR_CHANNELS * IPOCTAL_MAX_BOARDS)
-#define RELEVANT_IFLAG(iflag) ((iflag) & (IGNBRK|BRKINT|IGNPAR|PARMRK|INPCK))
 
 /**
  * struct ipoctal_stats -- Stats since last reset
Signature · 1 line
2.21.0
#4 lore raw

PATCH 3/3 tty: cpm_uart: drop unused iflag macro

In reply to Johan Hovold

Drop the RELEVANT_IFLAG() macro which hasn't been used at least since the dawn of git.

---
 drivers/tty/serial/cpm_uart/cpm_uart_core.c | 2 --
 1 file changed, 2 deletions(-)
drivers/tty/serial/cpm_uart/cpm_uart_core.c +0 -2
index b929c7ae3a27..505262b1c6c2 100644
@@ -567,8 +567,6 @@ static void cpm_uart_set_termios(struct uart_port *port,
 	/*
 	 * Set up parity check flag
 	 */
-#define RELEVANT_IFLAG(iflag) (iflag & (IGNBRK|BRKINT|IGNPAR|PARMRK|INPCK))
-
 	port->read_status_mask = (BD_SC_EMPTY | BD_SC_OV);
 	if (termios->c_iflag & INPCK)
 		port->read_status_mask |= BD_SC_FR | BD_SC_PR;
Signature · 1 line
2.21.0
#5 lore raw
In reply to Johan Hovold
Quoted 12 lines · Johan Hovold

I noticed that the RELEVANT_IFLAG() macro was unused in USB serial and turns out there were a few more instances that could be dropped.

I have some pending changes that may conflict with the corresponding change to USB serial so I'll take that one separately through my tree, but perhaps the rest could go through Greg's tty tree.

Johan Hovold (3):
tty: simserial: drop unused iflag macro
tty: ipoctal: drop unused iflag macro
tty: cpm_uart: drop unused iflag macro

Quoted 4 lines
 arch/ia64/hp/sim/simserial.c                | 2 --
 drivers/ipack/devices/ipoctal.h             | 1 -
 drivers/tty/serial/cpm_uart/cpm_uart_core.c | 2 --
 3 files changed, 5 deletions(-)

Greg, do you still have these clean-ups in your queue? Want me to resend with Tony's ack?

Johan

#6 lore raw
Quoted 13 lines · Johan Hovold
Quoted 12 lines · Johan Hovold

I noticed that the RELEVANT_IFLAG() macro was unused in USB serial and turns out there were a few more instances that could be dropped.

I have some pending changes that may conflict with the corresponding change to USB serial so I'll take that one separately through my tree, but perhaps the rest could go through Greg's tty tree.

Johan Hovold (3):
tty: simserial: drop unused iflag macro
tty: ipoctal: drop unused iflag macro
tty: cpm_uart: drop unused iflag macro

Quoted 7 lines
Quoted 4 lines
 arch/ia64/hp/sim/simserial.c                | 2 --
 drivers/ipack/devices/ipoctal.h             | 1 -
 drivers/tty/serial/cpm_uart/cpm_uart_core.c | 2 --
 3 files changed, 5 deletions(-)

Greg, do you still have these clean-ups in your queue? Want me to resend with Tony's ack?

They are still in my to-review queue. Let me dig out from some more stable patches before I tackle the tty/serial stuff later today or tomorrow.

thanks,

greg k-h

#7 lore raw
Quoted 19 lines · Greg Kroah-Hartman
Quoted 18 lines · Johan Hovold
Quoted 16 lines · Johan Hovold

I noticed that the RELEVANT_IFLAG() macro was unused in USB serial and turns out there were a few more instances that could be dropped.

I have some pending changes that may conflict with the corresponding change to USB serial so I'll take that one separately through my tree, but perhaps the rest could go through Greg's tty tree.

Johan Hovold (3):
tty: simserial: drop unused iflag macro
tty: ipoctal: drop unused iflag macro
tty: cpm_uart: drop unused iflag macro

 arch/ia64/hp/sim/simserial.c                | 2 --
 drivers/ipack/devices/ipoctal.h             | 1 -
 drivers/tty/serial/cpm_uart/cpm_uart_core.c | 2 --
 3 files changed, 5 deletions(-)
Quoted 6 lines
Quoted 2 lines

Greg, do you still have these clean-ups in your queue? Want me to resend with Tony's ack?

They are still in my to-review queue. Let me dig out from some more stable patches before I tackle the tty/serial stuff later today or tomorrow.

No rush. Just saw you applying some tty patches the other day so figured I'd ask. Thanks.

Johan