Skip to contentSkip to conversation

staging: dgnc: remove redundant variable null check

PATCH New Daeseok Youn 1 participant 1 message May 12, 2016

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

PATCH 2/3 staging: dgnc: remove redundant variable null check

The unit struct(un_t) was not used in dgnc_tty_hangup().

---
 drivers/staging/dgnc/dgnc_tty.c | 6 ------
 1 file changed, 6 deletions(-)
drivers/staging/dgnc/dgnc_tty.c +0 -6
index 52a1613..5119bcb 100644
@@ -1294,15 +1294,9 @@ static int dgnc_block_til_ready(struct tty_struct *tty,
  */
 static void dgnc_tty_hangup(struct tty_struct *tty)
 {
-	struct un_t	*un;
-
 	if (!tty || tty->magic != TTY_MAGIC)
 		return;
 
-	un = tty->driver_data;
-	if (!un || un->magic != DGNC_UNIT_MAGIC)
-		return;
-
 	/* flush the transmit queues */
 	dgnc_tty_flush_buffer(tty);
 }
Signature · 1 line
2.8.2