From: Johan Hovold <johan@kernel.org>
To: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Cc: Juergen Stuber <starblue@users.sourceforge.net>,
legousb-devel@lists.sourceforge.net, linux-usb@vger.kernel.org,
Johan Hovold <johan@kernel.org>
Subject: [PATCH 14/14] USB: legousbtower: drop superfluous newlines
Date: Tue, 5 Nov 2019 09:41:52 +0100 [thread overview]
Message-ID: <20191105084152.16322-15-johan@kernel.org> (raw)
In-Reply-To: <20191105084152.16322-1-johan@kernel.org>
Drop some superfluous newlines before conditionals which made the code
harder to read.
Signed-off-by: Johan Hovold <johan@kernel.org>
---
drivers/usb/misc/legousbtower.c | 5 -----
1 file changed, 5 deletions(-)
diff --git a/drivers/usb/misc/legousbtower.c b/drivers/usb/misc/legousbtower.c
index 6b7ea80d5876..ab4b98b04115 100644
--- a/drivers/usb/misc/legousbtower.c
+++ b/drivers/usb/misc/legousbtower.c
@@ -312,7 +312,6 @@ static int tower_open(struct inode *inode, struct file *file)
int result;
reset_reply = kmalloc(sizeof(*reset_reply), GFP_KERNEL);
-
if (!reset_reply) {
retval = -ENOMEM;
goto exit;
@@ -322,7 +321,6 @@ static int tower_open(struct inode *inode, struct file *file)
subminor = iminor(inode);
interface = usb_find_interface(&tower_driver, subminor);
-
if (!interface) {
pr_err("error, can't find device for minor %d\n", subminor);
retval = -ENODEV;
@@ -409,7 +407,6 @@ static int tower_release(struct inode *inode, struct file *file)
int retval = 0;
dev = file->private_data;
-
if (dev == NULL) {
retval = -ENODEV;
goto exit;
@@ -802,7 +799,6 @@ static int tower_probe(struct usb_interface *interface, const struct usb_device_
dev->interrupt_out_interval = interrupt_out_interval ? interrupt_out_interval : dev->interrupt_out_endpoint->bInterval;
get_version_reply = kmalloc(sizeof(*get_version_reply), GFP_KERNEL);
-
if (!get_version_reply) {
retval = -ENOMEM;
goto error;
@@ -835,7 +831,6 @@ static int tower_probe(struct usb_interface *interface, const struct usb_device_
usb_set_intfdata(interface, dev);
retval = usb_register_dev(interface, &tower_class);
-
if (retval) {
/* something prevented us from registering this driver */
dev_err(idev, "Not able to get a minor for this device.\n");
--
2.23.0
prev parent reply other threads:[~2019-11-05 8:42 UTC|newest]
Thread overview: 15+ messages / expand[flat|nested] mbox.gz Atom feed top
2019-11-05 8:41 [PATCH 00/14] USB: legousbtower: misc cleanups Johan Hovold
2019-11-05 8:41 ` [PATCH 01/14] USB: legousbtower: drop redundant MODULE_LICENSE ifdef Johan Hovold
2019-11-05 8:41 ` [PATCH 02/14] USB: legousbtower: drop redundant NULL check Johan Hovold
2019-11-05 8:41 ` [PATCH 03/14] USB: legousbtower: zero driver data at allocation Johan Hovold
2019-11-05 8:41 ` [PATCH 04/14] USB: legousbtower: drop redundant open_count check Johan Hovold
2019-11-05 8:41 ` [PATCH 05/14] USB: legousbtower: drop noisy disconnect messages Johan Hovold
2019-11-05 8:41 ` [PATCH 06/14] USB: legousbtower: drop redundant interrupt-in running flag Johan Hovold
2019-11-05 8:41 ` [PATCH 07/14] USB: legousbtower: stop interrupt-out URB unconditionally Johan Hovold
2019-11-05 8:41 ` [PATCH 08/14] USB: legousbtower: remove tower_abort_transfers() Johan Hovold
2019-11-05 8:41 ` [PATCH 09/14] USB: legousbtower: clean up pointer declarations in driver data Johan Hovold
2019-11-05 8:41 ` [PATCH 10/14] USB: legousbtower: drop unnecessary packed attributes Johan Hovold
2019-11-05 8:41 ` [PATCH 11/14] USB: legousbtower: drop redundant endianness comments Johan Hovold
2019-11-05 8:41 ` [PATCH 12/14] USB: legousbtower: clean up runaway white space Johan Hovold
2019-11-05 8:41 ` [PATCH 13/14] USB: legousbtower: drop superfluous brackets Johan Hovold
2019-11-05 8:41 ` Johan Hovold [this message]
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=20191105084152.16322-15-johan@kernel.org \
--to=johan@kernel.org \
--cc=gregkh@linuxfoundation.org \
--cc=legousb-devel@lists.sourceforge.net \
--cc=linux-usb@vger.kernel.org \
--cc=starblue@users.sourceforge.net \
/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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.