public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
* [PATCH 0/5] jsm: cleaning up structures
@ 2009-09-29 18:16 Breno Leitao
  2009-09-29 18:16 ` [PATCH 1/5] jsm: remove the ch_custom_speed field Breno Leitao
                   ` (4 more replies)
  0 siblings, 5 replies; 6+ messages in thread
From: Breno Leitao @ 2009-09-29 18:16 UTC (permalink / raw)
  To: linux-kernel; +Cc: Scott.Kilau, greg

A serie of patches that clean the jsm structures.
There are a lot of fields there that were never used, 
and is now being removed

Breno Leitao (5):
  jsm: remove the ch_custom_speed field
  jsm: removing ch_old_baud field
  jsm: Remove ch_cpstime field
  jsm: Removing unused jsm_channel->ch_wopen field
  jsm: removing the field jsm_board->intr_count

 drivers/serial/jsm/jsm.h     |    8 --------
 drivers/serial/jsm/jsm_neo.c |    8 --------
 drivers/serial/jsm/jsm_tty.c |    2 --
 3 files changed, 0 insertions(+), 18 deletions(-)


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

* [PATCH 1/5] jsm: remove the ch_custom_speed field
  2009-09-29 18:16 [PATCH 0/5] jsm: cleaning up structures Breno Leitao
@ 2009-09-29 18:16 ` Breno Leitao
  2009-09-29 18:16 ` [PATCH 2/5] jsm: removing ch_old_baud field Breno Leitao
                   ` (3 subsequent siblings)
  4 siblings, 0 replies; 6+ messages in thread
From: Breno Leitao @ 2009-09-29 18:16 UTC (permalink / raw)
  To: linux-kernel; +Cc: Scott.Kilau, greg, Breno Leitão

Currently the ch_custom_speed field exists but is never used,
so, this patch removes it.

Signed-off-by: Breno Leitão <leitao@linux.vnet.ibm.com>
---
 drivers/serial/jsm/jsm.h     |    1 -
 drivers/serial/jsm/jsm_neo.c |    4 ----
 2 files changed, 0 insertions(+), 5 deletions(-)

diff --git a/drivers/serial/jsm/jsm.h b/drivers/serial/jsm/jsm.h
index 4e5f3bd..afcbee2 100644
--- a/drivers/serial/jsm/jsm.h
+++ b/drivers/serial/jsm/jsm.h
@@ -216,7 +216,6 @@ struct jsm_channel {
 	u8		ch_startc;	/* Start character		*/
 
 	u32		ch_old_baud;	/* Cache of the current baud */
-	u32		ch_custom_speed;/* Custom baud, if set */
 
 	u32		ch_wopen;	/* Waiting for open process cnt */
 
diff --git a/drivers/serial/jsm/jsm_neo.c b/drivers/serial/jsm/jsm_neo.c
index b4b124e..088e702 100644
--- a/drivers/serial/jsm/jsm_neo.c
+++ b/drivers/serial/jsm/jsm_neo.c
@@ -957,10 +957,6 @@ static void neo_param(struct jsm_channel *ch)
 		ch->ch_old_baud = 0;
 		return;
 
-	} else if (ch->ch_custom_speed) {
-			baud = ch->ch_custom_speed;
-			if (ch->ch_flags & CH_BAUD0)
-				ch->ch_flags &= ~(CH_BAUD0);
 	} else {
 		int i;
 		unsigned int cflag;
-- 
1.6.0.4


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

* [PATCH 2/5] jsm: removing ch_old_baud field
  2009-09-29 18:16 [PATCH 0/5] jsm: cleaning up structures Breno Leitao
  2009-09-29 18:16 ` [PATCH 1/5] jsm: remove the ch_custom_speed field Breno Leitao
@ 2009-09-29 18:16 ` Breno Leitao
  2009-09-29 18:16 ` [PATCH 3/5] jsm: Remove ch_cpstime field Breno Leitao
                   ` (2 subsequent siblings)
  4 siblings, 0 replies; 6+ messages in thread
From: Breno Leitao @ 2009-09-29 18:16 UTC (permalink / raw)
  To: linux-kernel; +Cc: Scott.Kilau, greg

Currently the field jsm_channel->ch_old_baud is not used, just
assigned in a lot of places but never used. This patches removes
this field.

Signed-off-by: Breno Leitao <leitao@linux.vnet.ibm.com>
---
 drivers/serial/jsm/jsm.h     |    2 --
 drivers/serial/jsm/jsm_neo.c |    2 --
 drivers/serial/jsm/jsm_tty.c |    2 --
 3 files changed, 0 insertions(+), 6 deletions(-)

diff --git a/drivers/serial/jsm/jsm.h b/drivers/serial/jsm/jsm.h
index afcbee2..d413e4a 100644
--- a/drivers/serial/jsm/jsm.h
+++ b/drivers/serial/jsm/jsm.h
@@ -215,8 +215,6 @@ struct jsm_channel {
 	u8		ch_stopc;	/* Stop character		*/
 	u8		ch_startc;	/* Start character		*/
 
-	u32		ch_old_baud;	/* Cache of the current baud */
-
 	u32		ch_wopen;	/* Waiting for open process cnt */
 
 	u8		ch_mostat;	/* FEP output modem status	*/
diff --git a/drivers/serial/jsm/jsm_neo.c b/drivers/serial/jsm/jsm_neo.c
index 088e702..bee3727 100644
--- a/drivers/serial/jsm/jsm_neo.c
+++ b/drivers/serial/jsm/jsm_neo.c
@@ -954,7 +954,6 @@ static void neo_param(struct jsm_channel *ch)
 		ch->ch_flags |= (CH_BAUD0);
 		ch->ch_mostat &= ~(UART_MCR_RTS | UART_MCR_DTR);
 		neo_assert_modem_signals(ch);
-		ch->ch_old_baud = 0;
 		return;
 
 	} else {
@@ -1041,7 +1040,6 @@ static void neo_param(struct jsm_channel *ch)
 	quot = ch->ch_bd->bd_dividend / baud;
 
 	if (quot != 0) {
-		ch->ch_old_baud = baud;
 		writeb(UART_LCR_DLAB, &ch->ch_neo_uart->lcr);
 		writeb((quot & 0xff), &ch->ch_neo_uart->txrx);
 		writeb((quot >> 8), &ch->ch_neo_uart->ier);
diff --git a/drivers/serial/jsm/jsm_tty.c b/drivers/serial/jsm/jsm_tty.c
index 6423dfb..1bcad59 100644
--- a/drivers/serial/jsm/jsm_tty.c
+++ b/drivers/serial/jsm/jsm_tty.c
@@ -296,8 +296,6 @@ static void jsm_tty_close(struct uart_port *port)
 		bd->bd_ops->assert_modem_signals(channel);
 	}
 
-	channel->ch_old_baud = 0;
-
 	/* Turn off UART interrupts for this port */
 	channel->ch_bd->bd_ops->uart_off(channel);
 
-- 
1.6.0.4


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

* [PATCH 3/5] jsm: Remove ch_cpstime field
  2009-09-29 18:16 [PATCH 0/5] jsm: cleaning up structures Breno Leitao
  2009-09-29 18:16 ` [PATCH 1/5] jsm: remove the ch_custom_speed field Breno Leitao
  2009-09-29 18:16 ` [PATCH 2/5] jsm: removing ch_old_baud field Breno Leitao
@ 2009-09-29 18:16 ` Breno Leitao
  2009-09-29 18:16 ` [PATCH 4/5] jsm: Removing unused jsm_channel->ch_wopen field Breno Leitao
  2009-09-29 18:16 ` [PATCH 5/5] jsm: removing the field jsm_board->intr_count Breno Leitao
  4 siblings, 0 replies; 6+ messages in thread
From: Breno Leitao @ 2009-09-29 18:16 UTC (permalink / raw)
  To: linux-kernel; +Cc: Scott.Kilau, greg

Currently the field jsm_channel->ch_cpstime is defined but never
used, so this patch removes it.

Signed-off-by: Breno Leitao <leitao@linux.vnet.ibm.com>
---
 drivers/serial/jsm/jsm.h |    2 --
 1 files changed, 0 insertions(+), 2 deletions(-)

diff --git a/drivers/serial/jsm/jsm.h b/drivers/serial/jsm/jsm.h
index d413e4a..8c14351 100644
--- a/drivers/serial/jsm/jsm.h
+++ b/drivers/serial/jsm/jsm.h
@@ -206,8 +206,6 @@ struct jsm_channel {
 
 	u64		ch_close_delay;	/* How long we should drop RTS/DTR for */
 
-	u64		ch_cpstime;	/* Time for CPS calculations	*/
-
 	tcflag_t	ch_c_iflag;	/* channel iflags		*/
 	tcflag_t	ch_c_cflag;	/* channel cflags		*/
 	tcflag_t	ch_c_oflag;	/* channel oflags		*/
-- 
1.6.0.4


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

* [PATCH 4/5] jsm: Removing unused jsm_channel->ch_wopen field
  2009-09-29 18:16 [PATCH 0/5] jsm: cleaning up structures Breno Leitao
                   ` (2 preceding siblings ...)
  2009-09-29 18:16 ` [PATCH 3/5] jsm: Remove ch_cpstime field Breno Leitao
@ 2009-09-29 18:16 ` Breno Leitao
  2009-09-29 18:16 ` [PATCH 5/5] jsm: removing the field jsm_board->intr_count Breno Leitao
  4 siblings, 0 replies; 6+ messages in thread
From: Breno Leitao @ 2009-09-29 18:16 UTC (permalink / raw)
  To: linux-kernel; +Cc: Scott.Kilau, greg

Currently the jsm_channel->ch_wopen field is defined and never
used. So, this patch removes it.

Signed-off-by: Breno Leitao <leitao@linux.vnet.ibm.com>
---
 drivers/serial/jsm/jsm.h |    2 --
 1 files changed, 0 insertions(+), 2 deletions(-)

diff --git a/drivers/serial/jsm/jsm.h b/drivers/serial/jsm/jsm.h
index 8c14351..484c927 100644
--- a/drivers/serial/jsm/jsm.h
+++ b/drivers/serial/jsm/jsm.h
@@ -213,8 +213,6 @@ struct jsm_channel {
 	u8		ch_stopc;	/* Stop character		*/
 	u8		ch_startc;	/* Start character		*/
 
-	u32		ch_wopen;	/* Waiting for open process cnt */
-
 	u8		ch_mostat;	/* FEP output modem status	*/
 	u8		ch_mistat;	/* FEP input modem status	*/
 
-- 
1.6.0.4


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

* [PATCH 5/5] jsm: removing the field jsm_board->intr_count
  2009-09-29 18:16 [PATCH 0/5] jsm: cleaning up structures Breno Leitao
                   ` (3 preceding siblings ...)
  2009-09-29 18:16 ` [PATCH 4/5] jsm: Removing unused jsm_channel->ch_wopen field Breno Leitao
@ 2009-09-29 18:16 ` Breno Leitao
  4 siblings, 0 replies; 6+ messages in thread
From: Breno Leitao @ 2009-09-29 18:16 UTC (permalink / raw)
  To: linux-kernel; +Cc: Scott.Kilau, greg

Currently there is a field in the jsm_board structure to cont
the number of interrupt that the card recevived, but it's not
working properly when the IRQ line is shared, and also nowhere
else this field is used. So, This patch is removing it.

Signed-off-by: Breno Leitao <leitao@linux.vnet.ibm.com>
---
 drivers/serial/jsm/jsm.h     |    1 -
 drivers/serial/jsm/jsm_neo.c |    2 --
 2 files changed, 0 insertions(+), 3 deletions(-)

diff --git a/drivers/serial/jsm/jsm.h b/drivers/serial/jsm/jsm.h
index 484c927..38a509c 100644
--- a/drivers/serial/jsm/jsm.h
+++ b/drivers/serial/jsm/jsm.h
@@ -138,7 +138,6 @@ struct jsm_board
 	u32		nasync;		/* Number of ports on card */
 
 	u32		irq;		/* Interrupt request number */
-	u64		intr_count;	/* Count of interrupts */
 
 	u64		membase;	/* Start of base memory of the card */
 	u64		membase_end;	/* End of base memory of the card */
diff --git a/drivers/serial/jsm/jsm_neo.c b/drivers/serial/jsm/jsm_neo.c
index bee3727..7960d96 100644
--- a/drivers/serial/jsm/jsm_neo.c
+++ b/drivers/serial/jsm/jsm_neo.c
@@ -1117,8 +1117,6 @@ static irqreturn_t neo_intr(int irq, void *voidbrd)
 	unsigned long lock_flags2;
 	int outofloop_count = 0;
 
-	brd->intr_count++;
-
 	/* Lock out the slow poller from running on this board. */
 	spin_lock_irqsave(&brd->bd_intr_lock, lock_flags);
 
-- 
1.6.0.4


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

end of thread, other threads:[~2009-09-29 18:17 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2009-09-29 18:16 [PATCH 0/5] jsm: cleaning up structures Breno Leitao
2009-09-29 18:16 ` [PATCH 1/5] jsm: remove the ch_custom_speed field Breno Leitao
2009-09-29 18:16 ` [PATCH 2/5] jsm: removing ch_old_baud field Breno Leitao
2009-09-29 18:16 ` [PATCH 3/5] jsm: Remove ch_cpstime field Breno Leitao
2009-09-29 18:16 ` [PATCH 4/5] jsm: Removing unused jsm_channel->ch_wopen field Breno Leitao
2009-09-29 18:16 ` [PATCH 5/5] jsm: removing the field jsm_board->intr_count Breno Leitao

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox