lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:   Tue, 3 Jul 2018 23:30:35 +0800
From:   kbuild test robot <lkp@...el.com>
To:     Aapo Vienamo <avienamo@...dia.com>
Cc:     kbuild-all@...org, Peter De Schrijver <pdeschrijver@...dia.com>,
        Prashant Gaikwad <pgaikwad@...dia.com>,
        Michael Turquette <mturquette@...libre.com>,
        Stephen Boyd <sboyd@...nel.org>,
        Thierry Reding <thierry.reding@...il.com>,
        Jonathan Hunter <jonathanh@...dia.com>,
        linux-kernel@...r.kernel.org, linux-clk@...r.kernel.org,
        linux-tegra@...r.kernel.org, Aapo Vienamo <avienamo@...dia.com>
Subject: Re: [PATCH 1/3] clk: tegra: refactor 7.1 div calculation

Hi Peter,

I love your patch! Perhaps something to improve:

[auto build test WARNING on tegra/for-next]
[also build test WARNING on v4.18-rc3 next-20180703]
[if your patch is applied to the wrong git tree, please drop us a note to help improve the system]

url:    https://github.com/0day-ci/linux/commits/Aapo-Vienamo/clk-tegra-refactor-7-1-div-calculation/20180703-205606
base:   https://git.kernel.org/pub/scm/linux/kernel/git/tegra/linux.git for-next
config: arm-allmodconfig (attached as .config)
compiler: arm-linux-gnueabi-gcc (Debian 7.2.0-11) 7.2.0
reproduce:
        wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross
        chmod +x ~/bin/make.cross
        # save the attached .config to linux build tree
        GCC_VERSION=7.2.0 make.cross ARCH=arm 

All warnings (new ones prefixed by >>):

   In file included from arch/arm/include/asm/div64.h:127:0,
                    from include/linux/kernel.h:174,
                    from drivers/clk/tegra/div71.c:17:
   drivers/clk/tegra/div71.c: In function 'div71_get':
   include/asm-generic/div64.h:222:28: warning: comparison of distinct pointer types lacks a cast
     (void)(((typeof((n)) *)0) == ((uint64_t *)0)); \
                               ^
>> drivers/clk/tegra/div71.c:40:2: note: in expansion of macro 'do_div'
     do_div(divider_ux1, rate);
     ^~~~~~

vim +/do_div +40 drivers/clk/tegra/div71.c

  > 17	#include <linux/kernel.h>
    18	
    19	#include "clk.h"
    20	
    21	#define div_mask(w) ((1 << (w)) - 1)
    22	
    23	int div71_get(unsigned long rate, unsigned parent_rate, u8 width,
    24		      u8 frac_width, u8 flags)
    25	{
    26		s64 divider_ux1 = parent_rate;
    27		int mul;
    28	
    29		if (!rate)
    30			return 0;
    31	
    32		mul = 1 << frac_width;
    33	
    34		if (!(flags & TEGRA_DIVIDER_INT))
    35			divider_ux1 *= mul;
    36	
    37		if (flags & TEGRA_DIVIDER_ROUND_UP)
    38			divider_ux1 += rate - 1;
    39	
  > 40		do_div(divider_ux1, rate);

---
0-DAY kernel test infrastructure                Open Source Technology Center
https://lists.01.org/pipermail/kbuild-all                   Intel Corporation

Download attachment ".config.gz" of type "application/gzip" (66170 bytes)

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ