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>] [day] [month] [year] [list]
Message-ID: <202205260656.mE4aquA1-lkp@intel.com>
Date:   Thu, 26 May 2022 06:53:39 +0800
From:   kernel test robot <lkp@...el.com>
To:     Viresh Kumar <viresh.kumar@...aro.org>
Cc:     llvm@...ts.linux.dev, kbuild-all@...ts.01.org,
        linux-kernel@...r.kernel.org
Subject: [vireshk-pm:opp/config 17/33] drivers/cpufreq/ti-cpufreq.c:331:19:
 error: incompatible pointer types initializing 'const u32 *' (aka 'const
 unsigned int *') with an expression of type 'u32 (*)[2]' (aka 'unsigned int
 (*)[2]')

tree:   https://git.kernel.org/pub/scm/linux/kernel/git/vireshk/pm.git opp/config
head:   d730dc101c586defb49eeafd8eea9b7bb0baa01b
commit: f834c0b7a54d96f6322c544479bbe897309b4a0a [17/33] cpufreq: ti: Migrate to dev_pm_opp_set_config()
config: arm-defconfig (https://download.01.org/0day-ci/archive/20220526/202205260656.mE4aquA1-lkp@intel.com/config)
compiler: clang version 15.0.0 (https://github.com/llvm/llvm-project d52a6e75b0c402c7f3b42a2b1b2873f151220947)
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://git.kernel.org/pub/scm/linux/kernel/git/vireshk/pm.git/commit/?id=f834c0b7a54d96f6322c544479bbe897309b4a0a
        git remote add vireshk-pm https://git.kernel.org/pub/scm/linux/kernel/git/vireshk/pm.git
        git fetch --no-tags vireshk-pm opp/config
        git checkout f834c0b7a54d96f6322c544479bbe897309b4a0a
        # 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 SHELL=/bin/bash drivers/

If you fix the issue, kindly add following tag where applicable
Reported-by: kernel test robot <lkp@...el.com>

All errors (new ones prefixed by >>):

>> drivers/cpufreq/ti-cpufreq.c:331:19: error: incompatible pointer types initializing 'const u32 *' (aka 'const unsigned int *') with an expression of type 'u32 (*)[2]' (aka 'unsigned int (*)[2]') [-Werror,-Wincompatible-pointer-types]
                   .supported_hw = &version,
                                   ^~~~~~~~
>> drivers/cpufreq/ti-cpufreq.c:360:8: error: use of undeclared label 'fail_put_node'
                   goto fail_put_node;
                        ^
   2 errors generated.


vim +331 drivers/cpufreq/ti-cpufreq.c

   322	
   323	static int ti_cpufreq_probe(struct platform_device *pdev)
   324	{
   325		u32 version[VERSION_COUNT];
   326		const struct of_device_id *match;
   327		struct ti_cpufreq_data *opp_data;
   328		const char * const default_reg_names[] = {"vdd", "vbb"};
   329		int ret;
   330		struct dev_pm_opp_config config = {
 > 331			.supported_hw = &version,
   332			.supported_hw_count = ARRAY_SIZE(version),
   333		};
   334	
   335		match = dev_get_platdata(&pdev->dev);
   336		if (!match)
   337			return -ENODEV;
   338	
   339		opp_data = devm_kzalloc(&pdev->dev, sizeof(*opp_data), GFP_KERNEL);
   340		if (!opp_data)
   341			return -ENOMEM;
   342	
   343		opp_data->soc_data = match->data;
   344	
   345		opp_data->cpu_dev = get_cpu_device(0);
   346		if (!opp_data->cpu_dev) {
   347			pr_err("%s: Failed to get device for CPU0\n", __func__);
   348			return -ENODEV;
   349		}
   350	
   351		opp_data->opp_node = dev_pm_opp_of_get_opp_desc_node(opp_data->cpu_dev);
   352		if (!opp_data->opp_node) {
   353			dev_info(opp_data->cpu_dev,
   354				 "OPP-v2 not supported, cpufreq-dt will attempt to use legacy tables.\n");
   355			goto register_cpufreq_dt;
   356		}
   357	
   358		ret = ti_cpufreq_setup_syscon_register(opp_data);
   359		if (ret)
 > 360			goto fail_put_node;
   361	
   362		/*
   363		 * OPPs determine whether or not they are supported based on
   364		 * two metrics:
   365		 *	0 - SoC Revision
   366		 *	1 - eFuse value
   367		 */
   368		ret = ti_cpufreq_get_rev(opp_data, &version[0]);
   369		if (ret)
   370			goto fail_put_node;
   371	
   372		ret = ti_cpufreq_get_efuse(opp_data, &version[1]);
   373		if (ret)
   374			goto fail_put_node;
   375	
   376		if (opp_data->soc_data->multi_regulator) {
   377			config.regulator_count = ARRAY_SIZE(default_reg_names);
   378	
   379			if (opp_data->soc_data->reg_names)
   380				config.regulator_names = opp_data->soc_data->reg_names;
   381			else
   382				config.regulator_names = default_reg_names;
   383		}
   384	
   385		opp_data->opp_table = dev_pm_opp_set_config(opp_data->cpu_dev, &config);
   386		of_node_put(opp_data->opp_node);
   387	
   388		if (IS_ERR(opp_data->opp_table)) {
   389			dev_err(opp_data->cpu_dev, "Failed to set OPP config\n");
   390			return PTR_ERR(opp_data->opp_table);
   391		}
   392	
   393	register_cpufreq_dt:
   394		platform_device_register_simple("cpufreq-dt", -1, NULL, 0);
   395	
   396		return 0;
   397	}
   398	

-- 
0-DAY CI Kernel Test Service
https://01.org/lkp

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ