Hi Peter, kernel test robot noticed the following build warnings: [auto build test WARNING on 43c3c17f0c805882d1b48818b1085747a68c80ec] url: https://github.com/intel-lab-lkp/linux/commits/Peter-Griffin/phy-add-new-phy_notify_state-api/20250813-231312 base: 43c3c17f0c805882d1b48818b1085747a68c80ec patch link: https://lore.kernel.org/r/20250813-phy-notify-pmstate-v3-2-3bda59055dd3%40linaro.org patch subject: [PATCH v3 2/2] phy: samsung: gs101-ufs: Add .notify_phystate() & hibern8 enter/exit values config: arm-randconfig-001-20250814 (https://download.01.org/0day-ci/archive/20250814/202508141555.NJvU2oYQ-lkp@xxxxxxxxx/config) compiler: clang version 22.0.0git (https://github.com/llvm/llvm-project 3769ce013be2879bf0b329c14a16f5cb766f26ce) reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20250814/202508141555.NJvU2oYQ-lkp@xxxxxxxxx/reproduce) If you fix the issue in a separate patch/commit (i.e. not just a new version of the same patch/commit), kindly add following tags | Reported-by: kernel test robot <lkp@xxxxxxxxx> | Closes: https://lore.kernel.org/oe-kbuild-all/202508141555.NJvU2oYQ-lkp@xxxxxxxxx/ All warnings (new ones prefixed by >>): >> drivers/phy/samsung/phy-samsung-ufs.c:232:11: warning: variable 'cfg' is used uninitialized whenever 'if' condition is false [-Wsometimes-uninitialized] 232 | else if (state.ufs_state == PHY_UFS_HIBERN8_EXIT) | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ drivers/phy/samsung/phy-samsung-ufs.c:235:19: note: uninitialized use occurs here 235 | for_each_phy_cfg(cfg) { | ^~~ drivers/phy/samsung/phy-samsung-ufs.c:232:7: note: remove the 'if' if its condition is always true 232 | else if (state.ufs_state == PHY_UFS_HIBERN8_EXIT) | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ 233 | cfg = ufs_phy->cfgs_hibern8[CFG_PRE_HIBERN8_EXIT]; drivers/phy/samsung/phy-samsung-ufs.c:224:39: note: initialize the variable 'cfg' to silence this warning 224 | const struct samsung_ufs_phy_cfg *cfg; | ^ | = NULL 1 warning generated. vim +232 drivers/phy/samsung/phy-samsung-ufs.c 219 220 static int samsung_ufs_phy_notify_state(struct phy *phy, 221 union phy_notify state) 222 { 223 struct samsung_ufs_phy *ufs_phy = get_samsung_ufs_phy(phy); 224 const struct samsung_ufs_phy_cfg *cfg; 225 int i, err; 226 227 if (!ufs_phy->cfgs_hibern8) 228 return 0; 229 230 if (state.ufs_state == PHY_UFS_HIBERN8_ENTER) 231 cfg = ufs_phy->cfgs_hibern8[CFG_POST_HIBERN8_ENTER]; > 232 else if (state.ufs_state == PHY_UFS_HIBERN8_EXIT) 233 cfg = ufs_phy->cfgs_hibern8[CFG_PRE_HIBERN8_EXIT]; 234 235 for_each_phy_cfg(cfg) { 236 for_each_phy_lane(ufs_phy, i) { 237 samsung_ufs_phy_config(ufs_phy, cfg, i); 238 } 239 } 240 241 if (state.ufs_state == PHY_UFS_HIBERN8_EXIT) { 242 for_each_phy_lane(ufs_phy, i) { 243 if (ufs_phy->drvdata->wait_for_cdr) { 244 err = ufs_phy->drvdata->wait_for_cdr(phy, i); 245 if (err) 246 goto err_out; 247 } 248 } 249 } 250 251 return 0; 252 err_out: 253 return err; 254 } 255 -- 0-DAY CI Kernel Test Service https://github.com/intel/lkp-tests/wiki