From: Dorothea Ehrl <dorothea.ehrl@fau.de>
To: manishc@marvell.com, GR-Linux-NIC-Dev@marvell.com,
gregkh@linuxfoundation.org, netdev@vger.kernel.org,
devel@driverdev.osuosl.org, linux-kernel@vger.kernel.org
Cc: Vanessa Hack <vanessa.hack@fau.de>,
Dorothea Ehrl <dorothea.ehrl@fau.de>,
linux-kernel@i4.cs.fau.de
Subject: [PATCH 4/5] staging/qlge: remove braces in conditional statement
Date: Wed, 27 Nov 2019 13:30:51 +0100 [thread overview]
Message-ID: <20191127123052.16424-4-dorothea.ehrl@fau.de> (raw)
In-Reply-To: <20191127123052.16424-1-dorothea.ehrl@fau.de>
This patch fixes "WARNING: braces {} are not necessary for single
statement blocks" and "WARNING: braces {} are not necessary for any arm
of this statement" by checkpatch.pl.
Signed-off-by: Dorothea Ehrl <dorothea.ehrl@fau.de>
Co-developed-by: Vanessa Hack <vanessa.hack@fau.de>
Signed-off-by: Vanessa Hack <vanessa.hack@fau.de>
---
drivers/staging/qlge/qlge_main.c | 9 ++++-----
1 file changed, 4 insertions(+), 5 deletions(-)
diff --git a/drivers/staging/qlge/qlge_main.c b/drivers/staging/qlge/qlge_main.c
index f5ab6cc7050a..d19709bcdc20 100644
--- a/drivers/staging/qlge/qlge_main.c
+++ b/drivers/staging/qlge/qlge_main.c
@@ -4101,11 +4101,11 @@ static int qlge_change_mtu(struct net_device *ndev, int new_mtu)
struct ql_adapter *qdev = netdev_priv(ndev);
int status;
- if (ndev->mtu == 1500 && new_mtu == 9000) {
+ if (ndev->mtu == 1500 && new_mtu == 9000)
netif_err(qdev, ifup, qdev->ndev, "Changing to jumbo MTU.\n");
- } else if (ndev->mtu == 9000 && new_mtu == 1500) {
+ else if (ndev->mtu == 9000 && new_mtu == 1500)
netif_err(qdev, ifup, qdev->ndev, "Changing to normal MTU.\n");
- } else
+ else
return -EINVAL;
queue_delayed_work(qdev->workqueue,
@@ -4113,9 +4113,8 @@ static int qlge_change_mtu(struct net_device *ndev, int new_mtu)
ndev->mtu = new_mtu;
- if (!netif_running(qdev->ndev)) {
+ if (!netif_running(qdev->ndev))
return 0;
- }
status = ql_change_rx_buffers(qdev);
if (status) {
--
2.20.1
_______________________________________________
devel mailing list
devel@linuxdriverproject.org
http://driverdev.linuxdriverproject.org/mailman/listinfo/driverdev-devel
next prev parent reply other threads:[~2019-11-27 12:40 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2019-11-27 12:30 [PATCH 1/5] staging/qlge: remove initialising of static local variable Dorothea Ehrl
2019-11-27 12:30 ` [PATCH 2/5] staging/qlge: add blank lines after declarations Dorothea Ehrl
2019-11-27 12:30 ` [PATCH 3/5] staging/qlge: add braces to conditional statement Dorothea Ehrl
2019-11-27 12:30 ` Dorothea Ehrl [this message]
2019-11-27 12:30 ` [PATCH 5/5] staging/qlge: fix block comment coding style Dorothea Ehrl
2019-11-29 7:17 ` [i4passt] [PATCH 1/5] staging/qlge: remove initialising of static local variable Tobias Langer
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=20191127123052.16424-4-dorothea.ehrl@fau.de \
--to=dorothea.ehrl@fau.de \
--cc=GR-Linux-NIC-Dev@marvell.com \
--cc=devel@driverdev.osuosl.org \
--cc=gregkh@linuxfoundation.org \
--cc=linux-kernel@i4.cs.fau.de \
--cc=linux-kernel@vger.kernel.org \
--cc=manishc@marvell.com \
--cc=netdev@vger.kernel.org \
--cc=vanessa.hack@fau.de \
/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).