From: David Binderman <linuxdev.baldrick@gmail.com>
To: ath9k-devel@lists.ath9k.org
Subject: [ath9k-devel] linux-4.7-rc3/drivers/net/wireless/ath/ath9k/htc_drv_main.c: 2 * strange tests ?
Date: Mon, 13 Jun 2016 16:55:53 -0000 [thread overview]
Message-ID: <CAMzoamZjA4XfL1b5Hqo7F+97PY-MEaijJ24iY+53L9ntNZromw@mail.gmail.com> (raw)
Hello there,
1.
linux-4.7-rc3/drivers/net/wireless/ath/ath9k/htc_drv_main.c:798]:
(warning) Comparison of a boolean expression with an integer other
than 0 or 1.
Source code is
if (common->ani.caldone <= 0) {
but
drivers/net/wireless/ath/ath.h: bool caldone;
Maybe better code
if (!(common->ani.caldone)) {
2.
linux-4.7-rc3/drivers/net/wireless/ath/ath9k/htc_drv_main.c:851]:
(warning) Comparison of a boolean expression with an integer other
than 0 or 1.
if (common->ani.caldone <= 0)
Duplicate. Also in the same file:
drivers/net/wireless/ath/ath9k/htc_drv_main.c:228]: (style) Variable
'ret' is assigned a value that is never used.
This might be a case where a function return value is not checked.
Regards
David Binderman
reply other threads:[~2016-06-13 16:55 UTC|newest]
Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
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=CAMzoamZjA4XfL1b5Hqo7F+97PY-MEaijJ24iY+53L9ntNZromw@mail.gmail.com \
--to=linuxdev.baldrick@gmail.com \
--cc=ath9k-devel@lists.ath9k.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 read-only IMAP folder(s) and NNTP newsgroup(s).