From: Julia Lawall <julia.lawall@lip6.fr>
To: Dmitry Torokhov <dtor@chromium.org>
Cc: kbuild-all@01.org, devel@driverdev.osuosl.org,
Greg Kroah-Hartman <gregkh@linuxfoundation.org>,
Olof Johansson <olofj@chromium.org>,
Guenter Roeck <groeck@chromium.org>,
Thierry Escande <thierry.escande@collabora.com>,
linux-kernel@vger.kernel.org
Subject: [PATCH] driver-core: fix odd_ptr_err.cocci warnings
Date: Thu, 10 Nov 2016 21:16:13 +0100 (CET) [thread overview]
Message-ID: <alpine.DEB.2.20.1611102113460.1970@hadrien> (raw)
PTR_ERR should access the value just tested by IS_ERR
Generated by: scripts/coccinelle/tests/odd_ptr_err.cocci
CC: Dmitry Torokhov <dtor@chromium.org>
Signed-off-by: Julia Lawall <julia.lawall@lip6.fr>
Signed-off-by: Fengguang Wu <fengguang.wu@intel.com>
---
0-day warning related to the following commit:
tree: https://git.kernel.org/pub/scm/linux/kernel/git/gregkh/driver-core.git driver-core-testing
head: dfea747d2aba77443acf7ce6fa37caa729bd034c
commit: 79543cf2b18ea4a35f8864849d7ad8882ea8a23d [10/14] driver-core: add test module for asynchronous probing
I haven't checked the context in detail.
test_async_driver_probe.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
--- a/drivers/base/test/test_async_driver_probe.c
+++ b/drivers/base/test/test_async_driver_probe.c
@@ -119,7 +119,7 @@ static int __init test_async_probe_init(
sync_dev_1 = platform_device_register_simple("test_sync_driver", 1,
NULL, 0);
if (IS_ERR(async_dev_1)) {
- error = PTR_ERR(sync_dev_1);
+ error = PTR_ERR(async_dev_1);
pr_err("failed to create sync_dev_1: %d", error);
goto err_unregister_sync_driver;
}
next reply other threads:[~2016-11-10 20:16 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-11-10 20:16 Julia Lawall [this message]
[not found] ` <CAE_wzQ_st6sBugdFRGX8VgSXcRqNCo3QcPwr5B8XpR-cQft6Eg@mail.gmail.com>
2016-11-10 20:19 ` Dmitry Torokhov
2016-11-10 20:22 ` Julia Lawall
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=alpine.DEB.2.20.1611102113460.1970@hadrien \
--to=julia.lawall@lip6.fr \
--cc=devel@driverdev.osuosl.org \
--cc=dtor@chromium.org \
--cc=gregkh@linuxfoundation.org \
--cc=groeck@chromium.org \
--cc=kbuild-all@01.org \
--cc=linux-kernel@vger.kernel.org \
--cc=olofj@chromium.org \
--cc=thierry.escande@collabora.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®