Hi Dmitry,
I love your patch! Yet something to improve:
[auto build test ERROR on tegra/for-next]
[also build test ERROR on v5.12-rc2 next-20210311]
[If your patch is applied to the wrong git tree, kindly drop us a note.
And when submitting patch, we suggest to use '--base' as documented in
https://git-scm.com/docs/git-format-patch]
url:
https://github.com/0day-ci/linux/commits/Dmitry-Osipenko/soc-tegra-Add-de...
base:
https://git.kernel.org/pub/scm/linux/kernel/git/tegra/linux.git for-next
config: arm-defconfig (attached as .config)
compiler: arm-linux-gnueabi-gcc (GCC) 9.3.0
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
#
https://github.com/0day-ci/linux/commit/8d5ea5b946a1399d7490fa992733a737c...
git remote add linux-review
https://github.com/0day-ci/linux
git fetch --no-tags linux-review
Dmitry-Osipenko/soc-tegra-Add-devm_tegra_core_dev_init_opp_table/20210312-081244
git checkout 8d5ea5b946a1399d7490fa992733a737c4bbd594
# save the attached .config to linux build tree
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-9.3.0 make.cross ARCH=arm
If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp(a)intel.com>
All errors (new ones prefixed by >>):
drivers/soc/tegra/common.c: In function 'devm_tegra_core_dev_init_opp_table':
> drivers/soc/tegra/common.c:123:14: error: implicit declaration of
function 'devm_pm_opp_set_clkname'; did you mean 'dev_pm_opp_set_clkname'?
[-Werror=implicit-function-declaration]
123 | opp_table =
devm_pm_opp_set_clkname(dev, NULL);
| ^~~~~~~~~~~~~~~~~~~~~~~
| dev_pm_opp_set_clkname
drivers/soc/tegra/common.c:123:12: warning: assignment to 'struct opp_table *'
from 'int' makes pointer from integer without a cast [-Wint-conversion]
123 | opp_table = devm_pm_opp_set_clkname(dev, NULL);
| ^
> drivers/soc/tegra/common.c:139:14: error: implicit declaration of
function 'devm_pm_opp_set_supported_hw'; did you mean
'dev_pm_opp_set_supported_hw'? [-Werror=implicit-function-declaration]
139 | opp_table = devm_pm_opp_set_supported_hw(dev, &hw_version, 1);
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~
| dev_pm_opp_set_supported_hw
drivers/soc/tegra/common.c:139:12: warning: assignment to 'struct opp_table *'
from 'int' makes pointer from integer without a cast [-Wint-conversion]
139 | opp_table = devm_pm_opp_set_supported_hw(dev, &hw_version, 1);
| ^
> drivers/soc/tegra/common.c:153:8: error: implicit declaration of
function 'devm_pm_opp_of_add_table'; did you mean
'dev_pm_opp_of_add_table'? [-Werror=implicit-function-declaration]
153
| err = devm_pm_opp_of_add_table(dev);
| ^~~~~~~~~~~~~~~~~~~~~~~~
| dev_pm_opp_of_add_table
cc1: some warnings being treated as errors
vim +123 drivers/soc/tegra/common.c
105
106 /**
107 * devm_tegra_core_dev_init_opp_table() - initialize OPP table
108 * @dev: device for which OPP table is initialized
109 * @params: pointer to the OPP table configuration
110 *
111 * This function will initialize OPP table and sync OPP state of a Tegra SoC
112 * core device.
113 *
114 * Return: 0 on success or errorno.
115 */
116 int devm_tegra_core_dev_init_opp_table(struct device *dev,
117 struct tegra_core_opp_params *params)
118 {
119 struct opp_table *opp_table;
120 u32 hw_version;
121 int err;
122
123 opp_table = devm_pm_opp_set_clkname(dev, NULL);
124 if
(IS_ERR(opp_table)) {
125 dev_err(dev, "failed to set OPP clk %pe\n", opp_table);
126 return PTR_ERR(opp_table);
127 }
128
129 /* Tegra114+ doesn't support OPP yet */
130 if (!of_machine_is_compatible("nvidia,tegra20") &&
131 !of_machine_is_compatible("nvidia,tegra30"))
132 return -ENODEV;
133
134 if (of_machine_is_compatible("nvidia,tegra20"))
135 hw_version = BIT(tegra_sku_info.soc_process_id);
136 else
137 hw_version = BIT(tegra_sku_info.soc_speedo_id);
138
139 opp_table = devm_pm_opp_set_supported_hw(dev, &hw_version,
1);
140 if (IS_ERR(opp_table)) {
141 dev_err(dev, "failed to set OPP supported HW: %pe\n", opp_table);
142 return PTR_ERR(opp_table);
143 }
144
145 /*
146 * Older device-trees have an empty OPP table, hence we will get
147 * -ENODEV from devm_pm_opp_of_add_table() for the older DTBs.
148 *
149 * The OPP table presence also varies per-device and depending
150 * on a SoC generation, hence -ENODEV is expected to happen for
151 * the newer DTs as well.
152 */
153 err = devm_pm_opp_of_add_table(dev);
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org