[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <202007031331.URWCsE7w%lkp@intel.com>
Date: Fri, 3 Jul 2020 13:43:05 +0800
From: kernel test robot <lkp@...el.com>
To: Alim Akhtar <alim.akhtar@...sung.com>, vkoul@...nel.org
Cc: kbuild-all@...ts.01.org, clang-built-linux@...glegroups.com,
robh+dt@...nel.org, krzk@...nel.org, kwmad.kim@...sung.com,
devicetree@...r.kernel.org, linux-arm-kernel@...ts.infradead.org,
linux-kernel@...r.kernel.org, linux-samsung-soc@...r.kernel.org,
kishon@...com, Alim Akhtar <alim.akhtar@...sung.com>
Subject: Re: [PATCH v11 2/2] phy: samsung-ufs: add UFS PHY driver for samsung
SoC
Hi Alim,
I love your patch! Perhaps something to improve:
[auto build test WARNING on robh/for-next]
[also build test WARNING on soc/for-next linus/master v5.8-rc3 next-20200702]
[If your patch is applied to the wrong git tree, kindly drop us a note.
And when submitting patch, we suggest to use as documented in
https://git-scm.com/docs/git-format-patch]
url: https://github.com/0day-ci/linux/commits/Alim-Akhtar/dt-bindings-phy-Document-Samsung-UFS-PHY-bindings/20200703-104336
base: https://git.kernel.org/pub/scm/linux/kernel/git/robh/linux.git for-next
config: x86_64-allyesconfig (attached as .config)
compiler: clang version 11.0.0 (https://github.com/llvm/llvm-project ca464639a1c9dd3944eb055ffd2796e8c2e7639f)
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 x86_64 cross compiling tool for clang build
# apt-get install binutils-x86-64-linux-gnu
# save the attached .config to linux build tree
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=clang make.cross ARCH=x86_64
If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp@...el.com>
All warnings (new ones prefixed by >>):
>> drivers/phy/samsung/phy-samsung-ufs.c:150:6: warning: variable 'ret' is used uninitialized whenever 'if' condition is true [-Wsometimes-uninitialized]
if (IS_ERR(phy->rx0_symbol_clk)) {
^~~~~~~~~~~~~~~~~~~~~~~~~~~
drivers/phy/samsung/phy-samsung-ufs.c:173:9: note: uninitialized use occurs here
return ret;
^~~
drivers/phy/samsung/phy-samsung-ufs.c:150:2: note: remove the 'if' if its condition is always false
if (IS_ERR(phy->rx0_symbol_clk)) {
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
drivers/phy/samsung/phy-samsung-ufs.c:144:6: warning: variable 'ret' is used uninitialized whenever 'if' condition is true [-Wsometimes-uninitialized]
if (IS_ERR(phy->rx0_symbol_clk)) {
^~~~~~~~~~~~~~~~~~~~~~~~~~~
drivers/phy/samsung/phy-samsung-ufs.c:173:9: note: uninitialized use occurs here
return ret;
^~~
drivers/phy/samsung/phy-samsung-ufs.c:144:2: note: remove the 'if' if its condition is always false
if (IS_ERR(phy->rx0_symbol_clk)) {
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
drivers/phy/samsung/phy-samsung-ufs.c:138:6: warning: variable 'ret' is used uninitialized whenever 'if' condition is true [-Wsometimes-uninitialized]
if (IS_ERR(phy->tx0_symbol_clk)) {
^~~~~~~~~~~~~~~~~~~~~~~~~~~
drivers/phy/samsung/phy-samsung-ufs.c:173:9: note: uninitialized use occurs here
return ret;
^~~
drivers/phy/samsung/phy-samsung-ufs.c:138:2: note: remove the 'if' if its condition is always false
if (IS_ERR(phy->tx0_symbol_clk)) {
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
drivers/phy/samsung/phy-samsung-ufs.c:135:9: note: initialize the variable 'ret' to silence this warning
int ret;
^
= 0
3 warnings generated.
vim +150 drivers/phy/samsung/phy-samsung-ufs.c
132
133 static int samsung_ufs_phy_symbol_clk_init(struct samsung_ufs_phy *phy)
134 {
135 int ret;
136
137 phy->tx0_symbol_clk = devm_clk_get(phy->dev, "tx0_symbol_clk");
138 if (IS_ERR(phy->tx0_symbol_clk)) {
139 dev_err(phy->dev, "failed to get tx0_symbol_clk clock\n");
140 goto out;
141 }
142
143 phy->rx0_symbol_clk = devm_clk_get(phy->dev, "rx0_symbol_clk");
144 if (IS_ERR(phy->rx0_symbol_clk)) {
145 dev_err(phy->dev, "failed to get rx0_symbol_clk clock\n");
146 goto out;
147 }
148
149 phy->rx1_symbol_clk = devm_clk_get(phy->dev, "rx1_symbol_clk");
> 150 if (IS_ERR(phy->rx0_symbol_clk)) {
151 dev_err(phy->dev, "failed to get rx1_symbol_clk clock\n");
152 goto out;
153 }
154
155 ret = clk_prepare_enable(phy->tx0_symbol_clk);
156 if (ret) {
157 dev_err(phy->dev, "%s: tx0_symbol_clk enable failed %d\n", __func__, ret);
158 goto out;
159 }
160 ret = clk_prepare_enable(phy->rx0_symbol_clk);
161 if (ret) {
162 dev_err(phy->dev, "%s: rx0_symbol_clk enable failed %d\n", __func__, ret);
163 clk_disable_unprepare(phy->tx0_symbol_clk);
164 goto out;
165 }
166 ret = clk_prepare_enable(phy->rx1_symbol_clk);
167 if (ret) {
168 dev_err(phy->dev, "%s: rx1_symbol_clk enable failed %d\n", __func__, ret);
169 clk_disable_unprepare(phy->tx0_symbol_clk);
170 clk_disable_unprepare(phy->rx0_symbol_clk);
171 }
172 out:
173 return ret;
174 }
175
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org
Download attachment ".config.gz" of type "application/gzip" (75302 bytes)
Powered by blists - more mailing lists