From: Dan Carpenter <dan.carpenter@oracle.com>
To: igor.mitsyanko.os@quantenna.com
Cc: linux-wireless@vger.kernel.org
Subject: [bug report] qtnfmac: introduce new FullMAC driver for Quantenna chipsets
Date: Mon, 19 Jun 2017 13:55:52 +0300 [thread overview]
Message-ID: <20170619105552.GB23995@elgon.mountain> (raw)
Hello Igor Mitsyanko,
The patch 98f44cb0655c: "qtnfmac: introduce new FullMAC driver for
Quantenna chipsets" from May 11, 2017, leads to the following static
checker warning:
drivers/net/wireless/quantenna/qtnfmac/pearl/pcie.c:285 qtnf_pcie_init_dma_mask()
info: return a literal instead of 'ret'
drivers/net/wireless/quantenna/qtnfmac/pearl/pcie.c
277 static int
278 qtnf_pcie_init_dma_mask(struct qtnf_pcie_bus_priv *priv, u64 dma_mask)
279 {
280 int ret;
281
282 ret = dma_supported(&priv->pdev->dev, dma_mask);
283 if (!ret) {
284 pr_err("DMA mask %llu not supported\n", dma_mask);
285 return ret;
We should probably return a negative? It's also possible that returning
zero is intended but then we should use a literal so it's more clearly
deliberate.
286 }
287
288 ret = pci_set_dma_mask(priv->pdev, dma_mask);
289 if (ret) {
290 pr_err("failed to set DMA mask %llu\n", dma_mask);
291 return ret;
292 }
293
294 ret = pci_set_consistent_dma_mask(priv->pdev, dma_mask);
295 if (ret) {
296 pr_err("failed to set consistent DMA mask %llu\n", dma_mask);
297 return ret;
298 }
299
300 return ret;
301 }
regards,
dan carpenter
next reply other threads:[~2017-06-19 10:56 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-06-19 10:55 Dan Carpenter [this message]
2017-06-19 21:35 ` [bug report] qtnfmac: introduce new FullMAC driver for Quantenna chipsets Igor Mitsyanko
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=20170619105552.GB23995@elgon.mountain \
--to=dan.carpenter@oracle.com \
--cc=igor.mitsyanko.os@quantenna.com \
--cc=linux-wireless@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