tty has already been dereferenced at least twice in these functions,
so checking for null here seems a bit unnecessary.
Signed-off-by: Chris Malley <mail@chrismalley.co.uk>
---
drivers/char/riscom8.c | 4 ++--
1 files changed, 2 insertions(+), 2 deletions(-)
diff --git a/drivers/char/riscom8.c b/drivers/char/riscom8.c
index f073c71..9643a49 100644
--- a/drivers/char/riscom8.c
+++ b/drivers/char/riscom8.c
@@ -1108,7 +1108,7 @@ static int rc_write(struct tty_struct *tty,
bp = port_Board(port);
- if (!tty || !port->xmit_buf)
+ if (!port->xmit_buf)
return 0;
while (1) {
@@ -1151,7 +1151,7 @@ static int rc_put_char(struct tty_struct *tty, unsigned char ch)
if (rc_paranoia_check(port, tty->name, "rc_put_char"))
return 0;
- if (!tty || !port->xmit_buf)
+ if (!port->xmit_buf)
return 0;
spin_lock_irqsave(&riscom_lock, flags);
--
--
| monstr | [PATCH 27/56] microblaze_v2: support for a.out |
| Tarkan Erimer | Re: Dual-Licensing Linux Kernel with GPL V2 and GPL V3 |
| Greg KH | [GIT PATCH] driver core patches against 2.6.24 |
| Rafael J. Wysocki | [Bug #10493] mips BCM47XX compile error |
git: | |
| Jarek Poplawski | [PATCH] pkt_sched: Destroy gen estimators under rtnl_lock(). |
| Gerrit Renker | [PATCH 27/37] dccp: Integration of dynamic feature activation - part 2 (server side) |
| David Miller | [GIT]: Networking |
| Frans Pop | svc: failed to register lockdv1 RPC service (errno 97). |
