From: maximilian attems <janitor@sternwelten.at>
To: Alan Cox <alan@redhat.com>
Cc: Andrew Morton <akpm@osdl.org>, linux-kernel@vger.kernel.org
Subject: [patch-kj] kernel_thread() audit return code i2o_core.c
Date: Mon, 21 Jun 2004 23:13:01 +0200 [thread overview]
Message-ID: <20040621211301.GN1545@sputnik.stro.at> (raw)
Audited for kernel_thread() return values. Did it backwards last
time. *^_^*
Oh, yeah; compiles just fine as module or built-in.
Description : Audited for kernel_thread() return code in i2o_sys_init()
Signed-off-by: MJK <mkemp@cs.nmsu.edu>
Signed-off-by: Maximilian Attems <janitor@sternwelten.at>
---
linux-2.6.7-max/drivers/message/i2o/i2o_core.c | 7 +++++++
1 files changed, 7 insertions(+)
diff -puN drivers/message/i2o/i2o_core.c~kernel_thread-i2o_core drivers/message/i2o/i2o_core.c
--- linux-2.6.7/drivers/message/i2o/i2o_core.c~kernel_thread-i2o_core 2004-06-18 10:30:08.000000000 +0200
+++ linux-2.6.7-max/drivers/message/i2o/i2o_core.c 2004-06-18 10:31:20.000000000 +0200
@@ -2234,6 +2234,13 @@ rebuild_sys_tab:
/* Create a kernel thread to deal with dynamic LCT updates */
iop->lct_pid = kernel_thread(i2o_dyn_lct, iop, CLONE_SIGHAND);
+ if (iop->lct_pid < 0) {
+ printk(KERN_ERR "Couldn't spawn thread for %s.\n",
+ iop->name);
+ i2o_sys_shutdown();
+ return;
+ }
+
/* Update change ind on DLCT */
iop->dlct->change_ind = iop->lct->change_ind;
_
reply other threads:[~2004-06-21 21:13 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=20040621211301.GN1545@sputnik.stro.at \
--to=janitor@sternwelten.at \
--cc=akpm@osdl.org \
--cc=alan@redhat.com \
--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®