]> git.baikalelectronics.ru Git - kernel.git/commit
clk: ls1028a: Fix warning on clamp() usage
authorStephen Boyd <sboyd@kernel.org>
Mon, 3 Feb 2020 05:25:06 +0000 (21:25 -0800)
committerStephen Boyd <sboyd@kernel.org>
Mon, 3 Feb 2020 18:33:34 +0000 (10:33 -0800)
commit850a72a753534d071d7606efa8723397d1b64202
tree029c9a8c862703b0b39715df647adff918437216
parentf034ae2d91f22fa021162c0ba1ea84ec03274b4c
clk: ls1028a: Fix warning on clamp() usage

These constants are used in clamp() with the value being clamped an
unsigned long. Make them unsigned long defines so that clamp() doesn't
complain about comparing different types.

In file included from include/linux/list.h:9,
                 from include/linux/kobject.h:19,
                 from include/linux/of.h:17,
                 from include/linux/clk-provider.h:9,
                 from drivers/clk/clk-plldig.c:8:
drivers/clk/clk-plldig.c: In function 'plldig_determine_rate':
include/linux/kernel.h:835:29: warning: comparison of distinct pointer types lacks a cast
  835 |   (!!(sizeof((typeof(x) *)1 == (typeof(y) *)1)))
      |

Reported-by: Stephen Rothwell <sfr@canb.auug.org.au>
Cc: Wen He <wen.he_1@nxp.com>
Fixes: a1dbd9aa8d75 ("clk: ls1028a: Add clock driver for Display output interface")
Signed-off-by: Stephen Boyd <sboyd@kernel.org>
Link: https://lkml.kernel.org/r/20200203052507.93215-1-sboyd@kernel.org
drivers/clk/clk-plldig.c