From: Zheng Yongjun <zhengyongjun3@huawei.com>
To: <davem@davemloft.net>, <netdev@vger.kernel.org>
Cc: <kuba@kernel.org>, <linux-kernel@vger.kernel.org>,
<madalin.bucur@nxp.com>, Zheng Yongjun <zhengyongjun3@huawei.com>
Subject: [PATCH net-next] net: freescale: dpaa: simplify the return dpaa_eth_refill_bpools()
Date: Wed, 9 Dec 2020 17:21:07 +0800 [thread overview]
Message-ID: <20201209092107.20306-1-zhengyongjun3@huawei.com> (raw)
Simplify the return expression.
Signed-off-by: Zheng Yongjun <zhengyongjun3@huawei.com>
---
drivers/net/ethernet/freescale/dpaa/dpaa_eth.c | 6 +-----
1 file changed, 1 insertion(+), 5 deletions(-)
diff --git a/drivers/net/ethernet/freescale/dpaa/dpaa_eth.c b/drivers/net/ethernet/freescale/dpaa/dpaa_eth.c
index cb7c028b1bf5..edc8222d96dc 100644
--- a/drivers/net/ethernet/freescale/dpaa/dpaa_eth.c
+++ b/drivers/net/ethernet/freescale/dpaa/dpaa_eth.c
@@ -1599,17 +1599,13 @@ static int dpaa_eth_refill_bpools(struct dpaa_priv *priv)
{
struct dpaa_bp *dpaa_bp;
int *countptr;
- int res;
dpaa_bp = priv->dpaa_bp;
if (!dpaa_bp)
return -EINVAL;
countptr = this_cpu_ptr(dpaa_bp->percpu_count);
- res = dpaa_eth_refill_bpool(dpaa_bp, countptr);
- if (res)
- return res;
- return 0;
+ return dpaa_eth_refill_bpool(dpaa_bp, countptr);
}
/* Cleanup function for outgoing frame descriptors that were built on Tx path,
--
2.22.0
next reply other threads:[~2020-12-09 9:21 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-12-09 9:21 Zheng Yongjun [this message]
2020-12-09 9:24 ` [PATCH net-next] net: freescale: dpaa: simplify the return dpaa_eth_refill_bpools() Madalin Bucur (OSS)
2020-12-10 1:12 ` David Miller
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=20201209092107.20306-1-zhengyongjun3@huawei.com \
--to=zhengyongjun3@huawei.com \
--cc=davem@davemloft.net \
--cc=kuba@kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=madalin.bucur@nxp.com \
--cc=netdev@vger.kernel.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).