linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Lars-Peter Clausen <lars@metafoo.de>
To: Stephen Boyd <sboyd@codeaurora.org>,
	Mike Turquette <mturquette@baylibre.com>
Cc: linux-kernel@vger.kernel.org, linux-clk@vger.kernel.org
Subject: Re: [PATCH] clk: axi-clkgen: Remove sometimes impossible check
Date: Sat, 30 Jan 2016 15:59:37 +0100	[thread overview]
Message-ID: <56ACCFD9.3080300@metafoo.de> (raw)
In-Reply-To: <1454116408-28866-1-git-send-email-sboyd@codeaurora.org>

On 01/30/2016 02:13 AM, Stephen Boyd wrote:
> The size of unsigned long on 64-bit architectures is equal to the
> size of u64, so this check is impossible there. This throws off
> static checkers:
> 
> drivers/clk/clk-axi-clkgen.c:331 axi_clkgen_recalc_rate() warn:
> impossible condition '(tmp > (~0)) => (0-u64max > u64max)'
> 
> Let's change this code to use min_t() instead so that we
> get the same effect on architectures where sizeof(unsigned long)
> doesn't equal sizeof(u64).
> 
> Cc: Lars-Peter Clausen <lars@metafoo.de>
> Signed-off-by: Stephen Boyd <sboyd@codeaurora.org>

Thanks.

Acked-by: Lars-Peter Clausen <lars@metafoo.de>

      reply	other threads:[~2016-01-30 16:07 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-01-30  1:13 [PATCH] clk: axi-clkgen: Remove sometimes impossible check Stephen Boyd
2016-01-30 14:59 ` Lars-Peter Clausen [this message]

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=56ACCFD9.3080300@metafoo.de \
    --to=lars@metafoo.de \
    --cc=linux-clk@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mturquette@baylibre.com \
    --cc=sboyd@codeaurora.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).