From: Axel Lin <axel.lin@gmail.com>
To: Borislav Petkov <borislav.petkov@amd.com>
Cc: linux-kernel <linux-kernel@vger.kernel.org>
Subject: [PATCH] EDAC, MCE: Fix edac_init_mce_inject error handling
Date: Fri, 19 Nov 2010 11:05:43 +0800 [thread overview]
Message-ID: <1290135943.23599.1.camel@mola> (raw)
Otherwise, variable i will be -1 inside the latest iteration of the while loop.
Signed-off-by: Axel Lin <axel.lin@gmail.com>
---
drivers/edac/mce_amd_inj.c | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
diff --git a/drivers/edac/mce_amd_inj.c b/drivers/edac/mce_amd_inj.c
index 6db494f..733a7e7 100644
--- a/drivers/edac/mce_amd_inj.c
+++ b/drivers/edac/mce_amd_inj.c
@@ -140,7 +140,7 @@ static int __init edac_init_mce_inject(void)
return 0;
err_sysfs_create:
- while (i-- >= 0)
+ while (--i >= 0)
sysfs_remove_file(mce_kobj, &sysfs_attrs[i]->attr);
kobject_del(mce_kobj);
--
1.7.2
next reply other threads:[~2010-11-19 3:01 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2010-11-19 3:05 Axel Lin [this message]
2010-11-19 5:09 ` Borislav Petkov
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=1290135943.23599.1.camel@mola \
--to=axel.lin@gmail.com \
--cc=borislav.petkov@amd.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
Powered by JetHome