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] [day] [month] [year] [list]
Date:   Mon, 27 Mar 2023 10:11:38 +0800
From:   kernel test robot <lkp@...el.com>
To:     David Yang <mmyangfl@...il.com>, linux-clk@...r.kernel.org
Cc:     llvm@...ts.linux.dev, oe-kbuild-all@...ts.linux.dev,
        David Yang <mmyangfl@...il.com>,
        Michael Turquette <mturquette@...libre.com>,
        Stephen Boyd <sboyd@...nel.org>, linux-kernel@...r.kernel.org,
        Conor Dooley <conor.dooley@...rochip.com>,
        Nick Alcock <nick.alcock@...cle.com>
Subject: Re: [PATCH 4/4] clk: hisilicon: Migrate devm APIs

Hi David,

Thank you for the patch! Yet something to improve:

[auto build test ERROR on fff5a5e7f528b2ed2c335991399a766c2cf01103]

url:    https://github.com/intel-lab-lkp/linux/commits/David-Yang/clk-hisilicon-Add-helper-functions-for-platform-driver/20230326-133108
base:   fff5a5e7f528b2ed2c335991399a766c2cf01103
patch link:    https://lore.kernel.org/r/20230326052757.297551-5-mmyangfl%40gmail.com
patch subject: [PATCH 4/4] clk: hisilicon: Migrate devm APIs
config: arm-defconfig (https://download.01.org/0day-ci/archive/20230327/202303271023.do1t8Cfa-lkp@intel.com/config)
compiler: clang version 17.0.0 (https://github.com/llvm/llvm-project 67409911353323ca5edf2049ef0df54132fa1ca7)
reproduce (this is a W=1 build):
        wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross
        chmod +x ~/bin/make.cross
        # install arm cross compiling tool for clang build
        # apt-get install binutils-arm-linux-gnueabi
        # https://github.com/intel-lab-lkp/linux/commit/7fd49da57e4d2205c1f5842dc29fc79c0f89263e
        git remote add linux-review https://github.com/intel-lab-lkp/linux
        git fetch --no-tags linux-review David-Yang/clk-hisilicon-Add-helper-functions-for-platform-driver/20230326-133108
        git checkout 7fd49da57e4d2205c1f5842dc29fc79c0f89263e
        # save the config file
        mkdir build_dir && cp config build_dir/.config
        COMPILER_INSTALL_PATH=$HOME/0day COMPILER=clang make.cross W=1 O=build_dir ARCH=arm olddefconfig
        COMPILER_INSTALL_PATH=$HOME/0day COMPILER=clang make.cross W=1 O=build_dir ARCH=arm SHELL=/bin/bash drivers/clk/

If you fix the issue, kindly add following tag where applicable
| Reported-by: kernel test robot <lkp@...el.com>
| Link: https://lore.kernel.org/oe-kbuild-all/202303271023.do1t8Cfa-lkp@intel.com/

All errors (new ones prefixed by >>):

>> drivers/clk/hisilicon/clk-hi3620.c:435:14: error: use of undeclared identifier 'clks'
                           __func__, clks[i].name);
                                     ^
>> drivers/clk/hisilicon/clk-hi3620.c:435:19: error: use of undeclared identifier 'i'
                           __func__, clks[i].name);
                                          ^
>> drivers/clk/hisilicon/clk-hi3620.c:436:10: error: incompatible integer to pointer conversion returning 'int' from a function with result type 'struct clk_hw *' [-Wint-conversion]
                   return ret;
                          ^~~
   3 errors generated.
--
>> drivers/clk/hisilicon/clk-hix5hd2.c:300:17: error: member reference type 'struct clk_hw_onecell_data *' is a pointer; did you mean to use '->'?
                   data->clk_data.clks[clks[i].id] = clk;
                   ~~~~~~~~~~~~~~^
                                 ->
>> drivers/clk/hisilicon/clk-hix5hd2.c:300:18: error: no member named 'clks' in 'struct clk_hw_onecell_data'
                   data->clk_data.clks[clks[i].id] = clk;
                   ~~~~~~~~~~~~~~ ^
   2 errors generated.


vim +/clks +435 drivers/clk/hisilicon/clk-hi3620.c

   399	
   400	static struct clk_hw *
   401	clk_register_hisi_mmc(struct device *dev, const struct hisi_mmc_clock *mmc_clk,
   402			      void __iomem *base)
   403	{
   404		struct clk_mmc *mclk;
   405		struct clk_init_data init;
   406		int ret;
   407	
   408		mclk = devm_kzalloc(dev, sizeof(*mclk), GFP_KERNEL);
   409		if (!mclk)
   410			return ERR_PTR(-ENOMEM);
   411	
   412		init.name = mmc_clk->name;
   413		init.ops = &clk_mmc_ops;
   414		init.flags = mmc_clk->flags;
   415		init.parent_names = (mmc_clk->parent_name ? &mmc_clk->parent_name : NULL);
   416		init.num_parents = (mmc_clk->parent_name ? 1 : 0);
   417		mclk->hw.init = &init;
   418	
   419		mclk->id = mmc_clk->id;
   420		mclk->clken_reg = base + mmc_clk->clken_reg;
   421		mclk->clken_bit = mmc_clk->clken_bit;
   422		mclk->div_reg = base + mmc_clk->div_reg;
   423		mclk->div_off = mmc_clk->div_off;
   424		mclk->div_bits = mmc_clk->div_bits;
   425		mclk->drv_reg = base + mmc_clk->drv_reg;
   426		mclk->drv_off = mmc_clk->drv_off;
   427		mclk->drv_bits = mmc_clk->drv_bits;
   428		mclk->sam_reg = base + mmc_clk->sam_reg;
   429		mclk->sam_off = mmc_clk->sam_off;
   430		mclk->sam_bits = mmc_clk->sam_bits;
   431	
   432		ret = devm_clk_hw_register(dev, &mclk->hw);
   433		if (ret) {
   434			dev_err(dev, "%s: failed to register clock %s\n",
 > 435				__func__, clks[i].name);
 > 436			return ret;
   437		}
   438	
   439		return &mclk->hw;
   440	}
   441	

-- 
0-DAY CI Kernel Test Service
https://github.com/intel/lkp-tests

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ