From: Dan Carpenter <dan.carpenter@oracle.com>
To: zajec5@gmail.com
Cc: b43-dev@lists.infradead.org, linux-wireless@vger.kernel.org
Subject: (bug report) b43: precendence error
Date: Thu, 26 Nov 2015 14:58:43 +0300 [thread overview]
Message-ID: <20151126115843.GH10556@mwanda> (raw)
[ All the old wireless Smatch warnings are showing up as new ones
because of the path reshuffle in linux-next. I'm going through and
reporting the extra suspicious ones. -dan ]
Hello Rafał Miłecki,
The patch 6f98e62a9f1b: "b43: update cordic code to match current
specs" from Jan 25, 2010, leads to the following static checker
warning:
drivers/net/wireless/broadcom/b43/phy_lp.c:1803 lpphy_start_tx_tone()
warn: mask and shift to zero
drivers/net/wireless/broadcom/b43/phy_lp.c
1800 for (i = 0; i < samples; i++) {
1801 sample = b43_cordic(angle);
1802 angle += rotation;
1803 buf[i] = CORDIC_CONVERT((sample.i * max) & 0xFF) << 8;
1804 buf[i] |= CORDIC_CONVERT((sample.q * max) & 0xFF);
Maybe the intention was:
buf[i] = (CORDIC_CONVERT(sample.i * max) & 0xFF) << 8;
buf[i] |= CORDIC_CONVERT((sample.q * max) & 0xFF;
1805 }
1806
regards,
dan carpenter
next reply other threads:[~2015-11-26 11:59 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-11-26 11:58 Dan Carpenter [this message]
2015-11-26 12:40 ` (bug report) b43: precendence error Michael Büsch
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=20151126115843.GH10556@mwanda \
--to=dan.carpenter@oracle.com \
--cc=b43-dev@lists.infradead.org \
--cc=linux-wireless@vger.kernel.org \
--cc=zajec5@gmail.com \
/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).