From: Silviu-Mihai Popescu <silviupopescu1990-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>
To: linux-bluetooth-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
Cc: marcel-kz+m5ild9QBg9hUCZPvPmw@public.gmane.org,
gustavo-THi1TnShQwVAfugRpC6u6w@public.gmane.org,
johan.hedberg-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org,
davem-fT/PcQaiUtIeIZ0/mPfg9Q@public.gmane.org,
netdev-u79uwXL29TY76Z2rM5mHXA@public.gmane.org,
linux-kernel-u79uwXL29TY76Z2rM5mHXA@public.gmane.org,
Silviu-Mihai Popescu
<silviupopescu1990-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>
Subject: [PATCH] bluetooth: use PTR_RET instead of IS_ERR + PTR_ERR
Date: Tue, 12 Mar 2013 20:13:15 +0200 [thread overview]
Message-ID: <1363111995-26866-1-git-send-email-silviupopescu1990@gmail.com> (raw)
This uses PTR_RET instead of IS_ERR and PTR_ERR in order to increase
readability.
Signed-off-by: Silviu-Mihai Popescu <silviupopescu1990-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>
---
net/bluetooth/hci_sysfs.c | 5 +----
1 file changed, 1 insertion(+), 4 deletions(-)
diff --git a/net/bluetooth/hci_sysfs.c b/net/bluetooth/hci_sysfs.c
index 23b4e24..6fb5065 100644
--- a/net/bluetooth/hci_sysfs.c
+++ b/net/bluetooth/hci_sysfs.c
@@ -590,10 +590,7 @@ int __init bt_sysfs_init(void)
bt_debugfs = debugfs_create_dir("bluetooth", NULL);
bt_class = class_create(THIS_MODULE, "bluetooth");
- if (IS_ERR(bt_class))
- return PTR_ERR(bt_class);
-
- return 0;
+ return PTR_RET(bt_class)
}
void bt_sysfs_cleanup(void)
--
1.7.9.5
next reply other threads:[~2013-03-12 18:13 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-03-12 18:13 Silviu-Mihai Popescu [this message]
2013-03-13 9:31 ` [PATCH] bluetooth: use PTR_RET instead of IS_ERR + PTR_ERR David Miller
[not found] ` <20130313.053145.2200448840921851390.davem-fT/PcQaiUtIeIZ0/mPfg9Q@public.gmane.org>
2013-03-18 18:05 ` Silviu Popescu
[not found] ` <CAPWTe+JzznuWYKksAfxkD=u9kv8DuAF4v2AWVxd2OUeDtCYKBA-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
2013-03-18 18:08 ` David Miller
2013-03-18 18:13 ` Joe Perches
2013-03-18 18:13 ` Silviu Popescu
[not found] ` <CAPWTe+Kfr=zD6oJsfX3W8Ze1iH+CoEHx5FXo4YaVtQuMHD5k_g-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
2013-03-18 18:19 ` Gustavo Padovan
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=1363111995-26866-1-git-send-email-silviupopescu1990@gmail.com \
--to=silviupopescu1990-re5jqeeqqe8avxtiumwx3w@public.gmane.org \
--cc=davem-fT/PcQaiUtIeIZ0/mPfg9Q@public.gmane.org \
--cc=gustavo-THi1TnShQwVAfugRpC6u6w@public.gmane.org \
--cc=johan.hedberg-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org \
--cc=linux-bluetooth-u79uwXL29TY76Z2rM5mHXA@public.gmane.org \
--cc=linux-kernel-u79uwXL29TY76Z2rM5mHXA@public.gmane.org \
--cc=marcel-kz+m5ild9QBg9hUCZPvPmw@public.gmane.org \
--cc=netdev-u79uwXL29TY76Z2rM5mHXA@public.gmane.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;
as well as URLs for NNTP newsgroup(s).