summaryrefslogtreecommitdiff
path: root/drivers/tty
diff options
context:
space:
mode:
authorJiri Slaby <jslaby@suse.cz>2011-03-23 09:49:56 +0100
committerGreg Kroah-Hartman <gregkh@suse.de>2011-04-19 14:41:47 -0700
commit0e7f4194a0ef70c1d0d40152fa480a63719f35d5 (patch)
treef3e105725b7983416def79d7b3fa7d8260de7465 /drivers/tty
parent4fd53ef5c97ef7ce909c18bf7fb8b5cdd72b08c1 (diff)
Char: cyclades, fix unused variable
drivers/tty/cyclades.c:1454:2: warning: Value stored to 'channel' is never read channel = info->line - card->first_line; ^ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ Fix it by moving it to the appropriate debug section where it is used. Signed-off-by: Jiri Slaby <jslaby@suse.cz> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Diffstat (limited to 'drivers/tty')
-rw-r--r--drivers/tty/cyclades.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/drivers/tty/cyclades.c b/drivers/tty/cyclades.c
index c99728f0cd9f..e6f20d24e263 100644
--- a/drivers/tty/cyclades.c
+++ b/drivers/tty/cyclades.c
@@ -1445,13 +1445,11 @@ static void cy_shutdown(struct cyclades_port *info, struct tty_struct *tty)
{
struct cyclades_card *card;
unsigned long flags;
- int channel;
if (!(info->port.flags & ASYNC_INITIALIZED))
return;
card = info->card;
- channel = info->line - card->first_line;
if (!cy_is_Z(card)) {
spin_lock_irqsave(&card->card_lock, flags);
@@ -1476,6 +1474,7 @@ static void cy_shutdown(struct cyclades_port *info, struct tty_struct *tty)
spin_unlock_irqrestore(&card->card_lock, flags);
} else {
#ifdef CY_DEBUG_OPEN
+ int channel = info->line - card->first_line;
printk(KERN_DEBUG "cyc shutdown Z card %d, channel %d, "
"base_addr %p\n", card, channel, card->base_addr);
#endif