From: Thomas Hellstrom <thellstrom@vmware.com>
To: <greg@kroah.com>
Cc: <linux-kernel@vger.kernel.org>,
Thomas Hellstrom <thellstrom@vmware.com>,
Roel Kluin <roel.kluin@gmail.com>,
Randy Dunlap <randy.dunlap@oracle.com>,
KrishnamRaju raju <ekraju@gmail.com>
Subject: [PATCH] Revert "kref: double kref_put() in my_data_handler()"
Date: Mon, 6 Mar 2017 08:19:27 +0100 [thread overview]
Message-ID: <1488784767-5521-1-git-send-email-thellstrom@vmware.com> (raw)
This reverts commit 8f1ecc9fbc5b223e4f5d5bb8bcd6f5672c4bc4b6.
The correction is incorrect, see discussion at
http://stackoverflow.com/questions/20093127/why-kref-doc-of-linux-kernel-omits-kref-put-when-kthread-run-fail
Reported-by: KrishnamRaju raju <ekraju@gmail.com>
Cc: Roel Kluin <roel.kluin@gmail.com>
Cc: Randy Dunlap <randy.dunlap@oracle.com>
Cc: KrishnamRaju raju <ekraju@gmail.com>
Signed-off-by: Thomas Hellstrom <thellstrom@vmware.com>
---
Documentation/kref.txt | 1 +
1 file changed, 1 insertion(+)
diff --git a/Documentation/kref.txt b/Documentation/kref.txt
index ddf85a5..d26a27c 100644
--- a/Documentation/kref.txt
+++ b/Documentation/kref.txt
@@ -84,6 +84,7 @@ int my_data_handler(void)
task = kthread_run(more_data_handling, data, "more_data_handling");
if (task == ERR_PTR(-ENOMEM)) {
rv = -ENOMEM;
+ kref_put(&data->refcount, data_release);
goto out;
}
--
2.4.11
reply other threads:[~2017-03-06 7:20 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=1488784767-5521-1-git-send-email-thellstrom@vmware.com \
--to=thellstrom@vmware.com \
--cc=ekraju@gmail.com \
--cc=greg@kroah.com \
--cc=linux-kernel@vger.kernel.org \
--cc=randy.dunlap@oracle.com \
--cc=roel.kluin@gmail.com \
/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®