* Re: [PATCH] spi: atcspi200: Use helper function devm_clk_get_enabled()
[not found] <9f6e31608a24f3cdbd6e1429c1e006ccf9f7d9c1.1773132237.git.xiaopei01@kylinos.cn>
@ 2026-03-10 20:43 ` kernel test robot
0 siblings, 0 replies; only message in thread
From: kernel test robot @ 2026-03-10 20:43 UTC (permalink / raw)
To: Pei Xiao, cl634, broonie, linux-spi, linux-kernel
Cc: llvm, oe-kbuild-all, Pei Xiao
Hi Pei,
kernel test robot noticed the following build warnings:
[auto build test WARNING on broonie-spi/for-next]
[also build test WARNING on linus/master v7.0-rc3 next-20260309]
[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#_base_tree_information]
url: https://github.com/intel-lab-lkp/linux/commits/Pei-Xiao/spi-atcspi200-Use-helper-function-devm_clk_get_enabled/20260310-165916
base: https://git.kernel.org/pub/scm/linux/kernel/git/broonie/spi.git for-next
patch link: https://lore.kernel.org/r/9f6e31608a24f3cdbd6e1429c1e006ccf9f7d9c1.1773132237.git.xiaopei01%40kylinos.cn
patch subject: [PATCH] spi: atcspi200: Use helper function devm_clk_get_enabled()
config: riscv-randconfig-001-20260310 (https://download.01.org/0day-ci/archive/20260311/202603110449.mxLAYdGU-lkp@intel.com/config)
compiler: clang version 19.1.7 (https://github.com/llvm/llvm-project cd708029e0b2869e80abe31ddb175f7c35361f90)
reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20260311/202603110449.mxLAYdGU-lkp@intel.com/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@intel.com>
| Closes: https://lore.kernel.org/oe-kbuild-all/202603110449.mxLAYdGU-lkp@intel.com/
All warnings (new ones prefixed by >>):
>> drivers/spi/spi-atcspi200.c:510:6: warning: unused variable 'ret' [-Wunused-variable]
510 | int ret;
| ^~~
1 warning generated.
vim +/ret +510 drivers/spi/spi-atcspi200.c
34e3815ea459713 CL Wang 2025-12-15 507
34e3815ea459713 CL Wang 2025-12-15 508 static int atcspi_enable_clk(struct atcspi_dev *spi)
34e3815ea459713 CL Wang 2025-12-15 509 {
34e3815ea459713 CL Wang 2025-12-15 @510 int ret;
34e3815ea459713 CL Wang 2025-12-15 511
7dd262df6a0fc29 Pei Xiao 2026-03-10 512 spi->clk = devm_clk_get_enabled(spi->dev, NULL);
7dd262df6a0fc29 Pei Xiao 2026-03-10 513 if (IS_ERR(spi->clk))
7dd262df6a0fc29 Pei Xiao 2026-03-10 514 return dev_err_probe(spi->dev, PTR_ERR(spi->clk),
7dd262df6a0fc29 Pei Xiao 2026-03-10 515 "Failed to get SPI clock\n");
34e3815ea459713 CL Wang 2025-12-15 516 spi->clk_rate = clk_get_rate(spi->clk);
34e3815ea459713 CL Wang 2025-12-15 517 if (!spi->clk_rate)
34e3815ea459713 CL Wang 2025-12-15 518 return dev_err_probe(spi->dev, -EINVAL,
34e3815ea459713 CL Wang 2025-12-15 519 "Failed to get SPI clock rate\n");
34e3815ea459713 CL Wang 2025-12-15 520
34e3815ea459713 CL Wang 2025-12-15 521 return 0;
34e3815ea459713 CL Wang 2025-12-15 522 }
34e3815ea459713 CL Wang 2025-12-15 523
--
0-DAY CI Kernel Test Service
https://github.com/intel/lkp-tests/wiki
^ permalink raw reply [flat|nested] only message in thread