From: Jiri Slaby <jirislaby@gmail.com>
To: Andrew Morton <akpm@linux-foundation.org>
Cc: <linux-kernel@vger.kernel.org>
Cc: Adrian Bunk <bunk@kernel.org>
Subject: [PATCH 1/1] Char: cyclades, fix potential NULL dereference
Date: Mon, 22 Oct 2007 15:04:44 -0400 [thread overview]
Message-ID: <1238327807808324409@pripojeni.net> (raw)
cyclades, fix potential NULL dereference
to ztxdone is jumped even if tty is NULL and tty_wakeup placed after this
label doesn't expect NULLed parameter, so this will cause an oops in some
situations (why they scheduled a wakeup there before remove bottom half
processing patch?). wakeup only in the case when we have non-null tty
struct.
Spotted by Adrian Bunk.
Signed-off-by: Jiri Slaby <jirislaby@gmail.com>
Cc: Adrian Bunk <bunk@kernel.org>
---
commit d5e700a2247a9dc66cda09e6d89d1dc284bda40b
tree e0ba44e65a2026e4cba1e158580eaf492a1bfa35
parent bd9d07361314f393c7686466687c0a7aa8e88109
author Jiri Slaby <jirislaby@gmail.com> Mon, 22 Oct 2007 20:47:01 +0200
committer Jiri Slaby <jirislaby@gmail.com> Mon, 22 Oct 2007 20:47:01 +0200
drivers/char/cyclades.c | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
diff --git a/drivers/char/cyclades.c b/drivers/char/cyclades.c
index d15234c..710c056 100644
--- a/drivers/char/cyclades.c
+++ b/drivers/char/cyclades.c
@@ -1604,8 +1604,8 @@ static void cyz_handle_tx(struct cyclades_port *info,
info->icount.tx++;
}
#endif
-ztxdone:
tty_wakeup(tty);
+ztxdone:
/* Update tx_put */
cy_writel(&buf_ctrl->tx_put, tx_put);
}
reply other threads:[~2007-10-22 19:04 UTC|newest]
Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1238327807808324409@pripojeni.net \
--to=jirislaby@gmail.com \
--cc=akpm@linux-foundation.org \
--cc=linux-kernel@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®