Hi Shubhrajyoti, First bad commit (maybe != root cause): tree: https://git.kernel.org/pub/scm/linux/kernel/git/next/linux-next.git master head: e47eb90a0a9ae20b82635b9b99a8d0979b757ad8 commit: c822490f52da4ae3ee5bf2b809c765ea9d8143f9 [1949/4736] clk: clocking-wizard: Move clocking-wizard out config: s390-randconfig-r015-20220902 (https://download.01.org/0day-ci/archive/20220903/202209031637.EBkVUuUJ-lkp@xxxxxxxxx/config) compiler: s390-linux-gcc (GCC) 12.1.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://git.kernel.org/pub/scm/linux/kernel/git/next/linux-next.git/commit/?id=c822490f52da4ae3ee5bf2b809c765ea9d8143f9 git remote add linux-next https://git.kernel.org/pub/scm/linux/kernel/git/next/linux-next.git git fetch --no-tags linux-next master git checkout c822490f52da4ae3ee5bf2b809c765ea9d8143f9 # save the config file mkdir build_dir && cp config build_dir/.config COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-12.1.0 make.cross W=1 O=build_dir ARCH=s390 SHELL=/bin/bash If you fix the issue, kindly add following tag where applicable Reported-by: kernel test robot <lkp@xxxxxxxxx> All errors (new ones prefixed by >>): s390-linux-ld: kernel/dma/coherent.o: in function `dma_init_coherent_memory': kernel/dma/coherent.c:48: undefined reference to `memremap' s390-linux-ld: kernel/dma/coherent.c:71: undefined reference to `memunmap' s390-linux-ld: kernel/dma/coherent.o: in function `_dma_release_coherent_memory': kernel/dma/coherent.c:82: undefined reference to `memunmap' s390-linux-ld: drivers/irqchip/irq-al-fic.o: in function `al_fic_init_dt': drivers/irqchip/irq-al-fic.c:252: undefined reference to `of_iomap' s390-linux-ld: drivers/irqchip/irq-al-fic.c:282: undefined reference to `iounmap' s390-linux-ld: drivers/clk/xilinx/clk-xlnx-clock-wizard.o: in function `clk_wzrd_probe': >> drivers/clk/xilinx/clk-xlnx-clock-wizard.c:431: undefined reference to `devm_platform_ioremap_resource' s390-linux-ld: drivers/char/xillybus/xillybus_of.o: in function `xilly_drv_probe': drivers/char/xillybus/xillybus_of.c:50: undefined reference to `devm_platform_ioremap_resource' s390-linux-ld: drivers/misc/open-dice.o: in function `open_dice_wipe': drivers/misc/open-dice.c:48: undefined reference to `devm_memremap' s390-linux-ld: drivers/misc/open-dice.c:56: undefined reference to `devm_memunmap' s390-linux-ld: drivers/crypto/ccree/cc_driver.o: in function `init_cc_resources': drivers/crypto/ccree/cc_driver.c:355: undefined reference to `devm_ioremap_resource' s390-linux-ld: drivers/crypto/ccree/cc_debugfs.o: in function `cc_debugfs_init': drivers/crypto/ccree/cc_debugfs.c:80: undefined reference to `debugfs_create_regset32' s390-linux-ld: drivers/crypto/ccree/cc_debugfs.c:100: undefined reference to `debugfs_create_regset32' vim +431 drivers/clk/xilinx/clk-xlnx-clock-wizard.c 812283cd546376 drivers/staging/clocking-wizard/clk-xlnx-clock-wizard.c Soren Brinkmann 2014-10-02 410 812283cd546376 drivers/staging/clocking-wizard/clk-xlnx-clock-wizard.c Soren Brinkmann 2014-10-02 411 static SIMPLE_DEV_PM_OPS(clk_wzrd_dev_pm_ops, clk_wzrd_suspend, 812283cd546376 drivers/staging/clocking-wizard/clk-xlnx-clock-wizard.c Soren Brinkmann 2014-10-02 412 clk_wzrd_resume); 812283cd546376 drivers/staging/clocking-wizard/clk-xlnx-clock-wizard.c Soren Brinkmann 2014-10-02 413 812283cd546376 drivers/staging/clocking-wizard/clk-xlnx-clock-wizard.c Soren Brinkmann 2014-10-02 414 static int clk_wzrd_probe(struct platform_device *pdev) 812283cd546376 drivers/staging/clocking-wizard/clk-xlnx-clock-wizard.c Soren Brinkmann 2014-10-02 415 { 812283cd546376 drivers/staging/clocking-wizard/clk-xlnx-clock-wizard.c Soren Brinkmann 2014-10-02 416 int i, ret; 91d695d71841ab drivers/staging/clocking-wizard/clk-xlnx-clock-wizard.c Shubhrajyoti Datta 2021-02-24 417 u32 reg, reg_f, mult; 812283cd546376 drivers/staging/clocking-wizard/clk-xlnx-clock-wizard.c Soren Brinkmann 2014-10-02 418 unsigned long rate; 812283cd546376 drivers/staging/clocking-wizard/clk-xlnx-clock-wizard.c Soren Brinkmann 2014-10-02 419 const char *clk_name; 87a40bfb09f213 drivers/staging/clocking-wizard/clk-xlnx-clock-wizard.c Shubhrajyoti Datta 2021-02-24 420 void __iomem *ctrl_reg; 812283cd546376 drivers/staging/clocking-wizard/clk-xlnx-clock-wizard.c Soren Brinkmann 2014-10-02 421 struct clk_wzrd *clk_wzrd; 812283cd546376 drivers/staging/clocking-wizard/clk-xlnx-clock-wizard.c Soren Brinkmann 2014-10-02 422 struct device_node *np = pdev->dev.of_node; 92a7590427d666 drivers/staging/clocking-wizard/clk-xlnx-clock-wizard.c Shubhrajyoti Datta 2021-02-24 423 int nr_outputs; 87a40bfb09f213 drivers/staging/clocking-wizard/clk-xlnx-clock-wizard.c Shubhrajyoti Datta 2021-02-24 424 unsigned long flags = 0; 812283cd546376 drivers/staging/clocking-wizard/clk-xlnx-clock-wizard.c Soren Brinkmann 2014-10-02 425 812283cd546376 drivers/staging/clocking-wizard/clk-xlnx-clock-wizard.c Soren Brinkmann 2014-10-02 426 clk_wzrd = devm_kzalloc(&pdev->dev, sizeof(*clk_wzrd), GFP_KERNEL); 812283cd546376 drivers/staging/clocking-wizard/clk-xlnx-clock-wizard.c Soren Brinkmann 2014-10-02 427 if (!clk_wzrd) 812283cd546376 drivers/staging/clocking-wizard/clk-xlnx-clock-wizard.c Soren Brinkmann 2014-10-02 428 return -ENOMEM; 812283cd546376 drivers/staging/clocking-wizard/clk-xlnx-clock-wizard.c Soren Brinkmann 2014-10-02 429 platform_set_drvdata(pdev, clk_wzrd); 812283cd546376 drivers/staging/clocking-wizard/clk-xlnx-clock-wizard.c Soren Brinkmann 2014-10-02 430 f595f03bfdfc3c drivers/staging/clocking-wizard/clk-xlnx-clock-wizard.c YueHaibing 2019-10-09 @431 clk_wzrd->base = devm_platform_ioremap_resource(pdev, 0); 812283cd546376 drivers/staging/clocking-wizard/clk-xlnx-clock-wizard.c Soren Brinkmann 2014-10-02 432 if (IS_ERR(clk_wzrd->base)) 812283cd546376 drivers/staging/clocking-wizard/clk-xlnx-clock-wizard.c Soren Brinkmann 2014-10-02 433 return PTR_ERR(clk_wzrd->base); 812283cd546376 drivers/staging/clocking-wizard/clk-xlnx-clock-wizard.c Soren Brinkmann 2014-10-02 434 17aa33ff569980 drivers/staging/clocking-wizard/clk-xlnx-clock-wizard.c Shubhrajyoti Datta 2021-02-24 435 ret = of_property_read_u32(np, "xlnx,speed-grade", &clk_wzrd->speed_grade); 812283cd546376 drivers/staging/clocking-wizard/clk-xlnx-clock-wizard.c Soren Brinkmann 2014-10-02 436 if (!ret) { 812283cd546376 drivers/staging/clocking-wizard/clk-xlnx-clock-wizard.c Soren Brinkmann 2014-10-02 437 if (clk_wzrd->speed_grade < 1 || clk_wzrd->speed_grade > 3) { 812283cd546376 drivers/staging/clocking-wizard/clk-xlnx-clock-wizard.c Soren Brinkmann 2014-10-02 438 dev_warn(&pdev->dev, "invalid speed grade '%d'\n", 812283cd546376 drivers/staging/clocking-wizard/clk-xlnx-clock-wizard.c Soren Brinkmann 2014-10-02 439 clk_wzrd->speed_grade); 812283cd546376 drivers/staging/clocking-wizard/clk-xlnx-clock-wizard.c Soren Brinkmann 2014-10-02 440 clk_wzrd->speed_grade = 0; 812283cd546376 drivers/staging/clocking-wizard/clk-xlnx-clock-wizard.c Soren Brinkmann 2014-10-02 441 } 812283cd546376 drivers/staging/clocking-wizard/clk-xlnx-clock-wizard.c Soren Brinkmann 2014-10-02 442 } 812283cd546376 drivers/staging/clocking-wizard/clk-xlnx-clock-wizard.c Soren Brinkmann 2014-10-02 443 812283cd546376 drivers/staging/clocking-wizard/clk-xlnx-clock-wizard.c Soren Brinkmann 2014-10-02 444 clk_wzrd->clk_in1 = devm_clk_get(&pdev->dev, "clk_in1"); 812283cd546376 drivers/staging/clocking-wizard/clk-xlnx-clock-wizard.c Soren Brinkmann 2014-10-02 445 if (IS_ERR(clk_wzrd->clk_in1)) { 812283cd546376 drivers/staging/clocking-wizard/clk-xlnx-clock-wizard.c Soren Brinkmann 2014-10-02 446 if (clk_wzrd->clk_in1 != ERR_PTR(-EPROBE_DEFER)) 812283cd546376 drivers/staging/clocking-wizard/clk-xlnx-clock-wizard.c Soren Brinkmann 2014-10-02 447 dev_err(&pdev->dev, "clk_in1 not found\n"); 812283cd546376 drivers/staging/clocking-wizard/clk-xlnx-clock-wizard.c Soren Brinkmann 2014-10-02 448 return PTR_ERR(clk_wzrd->clk_in1); 812283cd546376 drivers/staging/clocking-wizard/clk-xlnx-clock-wizard.c Soren Brinkmann 2014-10-02 449 } 812283cd546376 drivers/staging/clocking-wizard/clk-xlnx-clock-wizard.c Soren Brinkmann 2014-10-02 450 812283cd546376 drivers/staging/clocking-wizard/clk-xlnx-clock-wizard.c Soren Brinkmann 2014-10-02 451 clk_wzrd->axi_clk = devm_clk_get(&pdev->dev, "s_axi_aclk"); 812283cd546376 drivers/staging/clocking-wizard/clk-xlnx-clock-wizard.c Soren Brinkmann 2014-10-02 452 if (IS_ERR(clk_wzrd->axi_clk)) { 812283cd546376 drivers/staging/clocking-wizard/clk-xlnx-clock-wizard.c Soren Brinkmann 2014-10-02 453 if (clk_wzrd->axi_clk != ERR_PTR(-EPROBE_DEFER)) 812283cd546376 drivers/staging/clocking-wizard/clk-xlnx-clock-wizard.c Soren Brinkmann 2014-10-02 454 dev_err(&pdev->dev, "s_axi_aclk not found\n"); 812283cd546376 drivers/staging/clocking-wizard/clk-xlnx-clock-wizard.c Soren Brinkmann 2014-10-02 455 return PTR_ERR(clk_wzrd->axi_clk); 812283cd546376 drivers/staging/clocking-wizard/clk-xlnx-clock-wizard.c Soren Brinkmann 2014-10-02 456 } 812283cd546376 drivers/staging/clocking-wizard/clk-xlnx-clock-wizard.c Soren Brinkmann 2014-10-02 457 ret = clk_prepare_enable(clk_wzrd->axi_clk); 812283cd546376 drivers/staging/clocking-wizard/clk-xlnx-clock-wizard.c Soren Brinkmann 2014-10-02 458 if (ret) { 812283cd546376 drivers/staging/clocking-wizard/clk-xlnx-clock-wizard.c Soren Brinkmann 2014-10-02 459 dev_err(&pdev->dev, "enabling s_axi_aclk failed\n"); 812283cd546376 drivers/staging/clocking-wizard/clk-xlnx-clock-wizard.c Soren Brinkmann 2014-10-02 460 return ret; 812283cd546376 drivers/staging/clocking-wizard/clk-xlnx-clock-wizard.c Soren Brinkmann 2014-10-02 461 } 812283cd546376 drivers/staging/clocking-wizard/clk-xlnx-clock-wizard.c Soren Brinkmann 2014-10-02 462 rate = clk_get_rate(clk_wzrd->axi_clk); 812283cd546376 drivers/staging/clocking-wizard/clk-xlnx-clock-wizard.c Soren Brinkmann 2014-10-02 463 if (rate > WZRD_ACLK_MAX_FREQ) { 812283cd546376 drivers/staging/clocking-wizard/clk-xlnx-clock-wizard.c Soren Brinkmann 2014-10-02 464 dev_err(&pdev->dev, "s_axi_aclk frequency (%lu) too high\n", 812283cd546376 drivers/staging/clocking-wizard/clk-xlnx-clock-wizard.c Soren Brinkmann 2014-10-02 465 rate); 812283cd546376 drivers/staging/clocking-wizard/clk-xlnx-clock-wizard.c Soren Brinkmann 2014-10-02 466 ret = -EINVAL; 812283cd546376 drivers/staging/clocking-wizard/clk-xlnx-clock-wizard.c Soren Brinkmann 2014-10-02 467 goto err_disable_clk; 812283cd546376 drivers/staging/clocking-wizard/clk-xlnx-clock-wizard.c Soren Brinkmann 2014-10-02 468 } 812283cd546376 drivers/staging/clocking-wizard/clk-xlnx-clock-wizard.c Soren Brinkmann 2014-10-02 469 91d695d71841ab drivers/staging/clocking-wizard/clk-xlnx-clock-wizard.c Shubhrajyoti Datta 2021-02-24 470 reg = readl(clk_wzrd->base + WZRD_CLK_CFG_REG(0)); 91d695d71841ab drivers/staging/clocking-wizard/clk-xlnx-clock-wizard.c Shubhrajyoti Datta 2021-02-24 471 reg_f = reg & WZRD_CLKFBOUT_FRAC_MASK; 91d695d71841ab drivers/staging/clocking-wizard/clk-xlnx-clock-wizard.c Shubhrajyoti Datta 2021-02-24 472 reg_f = reg_f >> WZRD_CLKFBOUT_FRAC_SHIFT; 91d695d71841ab drivers/staging/clocking-wizard/clk-xlnx-clock-wizard.c Shubhrajyoti Datta 2021-02-24 473 91d695d71841ab drivers/staging/clocking-wizard/clk-xlnx-clock-wizard.c Shubhrajyoti Datta 2021-02-24 474 reg = reg & WZRD_CLKFBOUT_MULT_MASK; 91d695d71841ab drivers/staging/clocking-wizard/clk-xlnx-clock-wizard.c Shubhrajyoti Datta 2021-02-24 475 reg = reg >> WZRD_CLKFBOUT_MULT_SHIFT; 91d695d71841ab drivers/staging/clocking-wizard/clk-xlnx-clock-wizard.c Shubhrajyoti Datta 2021-02-24 476 mult = (reg * 1000) + reg_f; 812283cd546376 drivers/staging/clocking-wizard/clk-xlnx-clock-wizard.c Soren Brinkmann 2014-10-02 477 clk_name = kasprintf(GFP_KERNEL, "%s_mul", dev_name(&pdev->dev)); 812283cd546376 drivers/staging/clocking-wizard/clk-xlnx-clock-wizard.c Soren Brinkmann 2014-10-02 478 if (!clk_name) { 812283cd546376 drivers/staging/clocking-wizard/clk-xlnx-clock-wizard.c Soren Brinkmann 2014-10-02 479 ret = -ENOMEM; 812283cd546376 drivers/staging/clocking-wizard/clk-xlnx-clock-wizard.c Soren Brinkmann 2014-10-02 480 goto err_disable_clk; 812283cd546376 drivers/staging/clocking-wizard/clk-xlnx-clock-wizard.c Soren Brinkmann 2014-10-02 481 } 87a40bfb09f213 drivers/staging/clocking-wizard/clk-xlnx-clock-wizard.c Shubhrajyoti Datta 2021-02-24 482 92a7590427d666 drivers/staging/clocking-wizard/clk-xlnx-clock-wizard.c Shubhrajyoti Datta 2021-02-24 483 ret = of_property_read_u32(np, "nr-outputs", &nr_outputs); 92a7590427d666 drivers/staging/clocking-wizard/clk-xlnx-clock-wizard.c Shubhrajyoti Datta 2021-02-24 484 if (ret || nr_outputs > WZRD_NUM_OUTPUTS) { 92a7590427d666 drivers/staging/clocking-wizard/clk-xlnx-clock-wizard.c Shubhrajyoti Datta 2021-02-24 485 ret = -EINVAL; 92a7590427d666 drivers/staging/clocking-wizard/clk-xlnx-clock-wizard.c Shubhrajyoti Datta 2021-02-24 486 goto err_disable_clk; 92a7590427d666 drivers/staging/clocking-wizard/clk-xlnx-clock-wizard.c Shubhrajyoti Datta 2021-02-24 487 } 92a7590427d666 drivers/staging/clocking-wizard/clk-xlnx-clock-wizard.c Shubhrajyoti Datta 2021-02-24 488 if (nr_outputs == 1) 92a7590427d666 drivers/staging/clocking-wizard/clk-xlnx-clock-wizard.c Shubhrajyoti Datta 2021-02-24 489 flags = CLK_SET_RATE_PARENT; 92a7590427d666 drivers/staging/clocking-wizard/clk-xlnx-clock-wizard.c Shubhrajyoti Datta 2021-02-24 490 d5213236151ba6 drivers/staging/clocking-wizard/clk-xlnx-clock-wizard.c Ioannis Valasakis 2018-10-04 491 clk_wzrd->clks_internal[wzrd_clk_mul] = clk_register_fixed_factor d5213236151ba6 drivers/staging/clocking-wizard/clk-xlnx-clock-wizard.c Ioannis Valasakis 2018-10-04 492 (&pdev->dev, clk_name, 812283cd546376 drivers/staging/clocking-wizard/clk-xlnx-clock-wizard.c Soren Brinkmann 2014-10-02 493 __clk_get_name(clk_wzrd->clk_in1), 91d695d71841ab drivers/staging/clocking-wizard/clk-xlnx-clock-wizard.c Shubhrajyoti Datta 2021-02-24 494 0, mult, 1000); 812283cd546376 drivers/staging/clocking-wizard/clk-xlnx-clock-wizard.c Soren Brinkmann 2014-10-02 495 if (IS_ERR(clk_wzrd->clks_internal[wzrd_clk_mul])) { 812283cd546376 drivers/staging/clocking-wizard/clk-xlnx-clock-wizard.c Soren Brinkmann 2014-10-02 496 dev_err(&pdev->dev, "unable to register fixed-factor clock\n"); 812283cd546376 drivers/staging/clocking-wizard/clk-xlnx-clock-wizard.c Soren Brinkmann 2014-10-02 497 ret = PTR_ERR(clk_wzrd->clks_internal[wzrd_clk_mul]); 812283cd546376 drivers/staging/clocking-wizard/clk-xlnx-clock-wizard.c Soren Brinkmann 2014-10-02 498 goto err_disable_clk; 812283cd546376 drivers/staging/clocking-wizard/clk-xlnx-clock-wizard.c Soren Brinkmann 2014-10-02 499 } 812283cd546376 drivers/staging/clocking-wizard/clk-xlnx-clock-wizard.c Soren Brinkmann 2014-10-02 500 812283cd546376 drivers/staging/clocking-wizard/clk-xlnx-clock-wizard.c Soren Brinkmann 2014-10-02 501 clk_name = kasprintf(GFP_KERNEL, "%s_mul_div", dev_name(&pdev->dev)); 5f18611038f9c9 drivers/staging/clocking-wizard/clk-xlnx-clock-wizard.c Devendra Naga 2014-11-29 502 if (!clk_name) { 5f18611038f9c9 drivers/staging/clocking-wizard/clk-xlnx-clock-wizard.c Devendra Naga 2014-11-29 503 ret = -ENOMEM; 5f18611038f9c9 drivers/staging/clocking-wizard/clk-xlnx-clock-wizard.c Devendra Naga 2014-11-29 504 goto err_rm_int_clk; 5f18611038f9c9 drivers/staging/clocking-wizard/clk-xlnx-clock-wizard.c Devendra Naga 2014-11-29 505 } 5f18611038f9c9 drivers/staging/clocking-wizard/clk-xlnx-clock-wizard.c Devendra Naga 2014-11-29 506 87a40bfb09f213 drivers/staging/clocking-wizard/clk-xlnx-clock-wizard.c Shubhrajyoti Datta 2021-02-24 507 ctrl_reg = clk_wzrd->base + WZRD_CLK_CFG_REG(0); 87a40bfb09f213 drivers/staging/clocking-wizard/clk-xlnx-clock-wizard.c Shubhrajyoti Datta 2021-02-24 508 /* register div */ 87a40bfb09f213 drivers/staging/clocking-wizard/clk-xlnx-clock-wizard.c Shubhrajyoti Datta 2021-02-24 509 clk_wzrd->clks_internal[wzrd_clk_mul_div] = clk_register_divider d5213236151ba6 drivers/staging/clocking-wizard/clk-xlnx-clock-wizard.c Ioannis Valasakis 2018-10-04 510 (&pdev->dev, clk_name, 812283cd546376 drivers/staging/clocking-wizard/clk-xlnx-clock-wizard.c Soren Brinkmann 2014-10-02 511 __clk_get_name(clk_wzrd->clks_internal[wzrd_clk_mul]), 87a40bfb09f213 drivers/staging/clocking-wizard/clk-xlnx-clock-wizard.c Shubhrajyoti Datta 2021-02-24 512 flags, ctrl_reg, 0, 8, CLK_DIVIDER_ONE_BASED | 87a40bfb09f213 drivers/staging/clocking-wizard/clk-xlnx-clock-wizard.c Shubhrajyoti Datta 2021-02-24 513 CLK_DIVIDER_ALLOW_ZERO, &clkwzrd_lock); 812283cd546376 drivers/staging/clocking-wizard/clk-xlnx-clock-wizard.c Soren Brinkmann 2014-10-02 514 if (IS_ERR(clk_wzrd->clks_internal[wzrd_clk_mul_div])) { 812283cd546376 drivers/staging/clocking-wizard/clk-xlnx-clock-wizard.c Soren Brinkmann 2014-10-02 515 dev_err(&pdev->dev, "unable to register divider clock\n"); 812283cd546376 drivers/staging/clocking-wizard/clk-xlnx-clock-wizard.c Soren Brinkmann 2014-10-02 516 ret = PTR_ERR(clk_wzrd->clks_internal[wzrd_clk_mul_div]); 812283cd546376 drivers/staging/clocking-wizard/clk-xlnx-clock-wizard.c Soren Brinkmann 2014-10-02 517 goto err_rm_int_clk; 812283cd546376 drivers/staging/clocking-wizard/clk-xlnx-clock-wizard.c Soren Brinkmann 2014-10-02 518 } 812283cd546376 drivers/staging/clocking-wizard/clk-xlnx-clock-wizard.c Soren Brinkmann 2014-10-02 519 812283cd546376 drivers/staging/clocking-wizard/clk-xlnx-clock-wizard.c Soren Brinkmann 2014-10-02 520 /* register div per output */ a0d1a3864cad08 drivers/staging/clocking-wizard/clk-xlnx-clock-wizard.c Shubhrajyoti Datta 2021-02-24 521 for (i = nr_outputs - 1; i >= 0 ; i--) { 812283cd546376 drivers/staging/clocking-wizard/clk-xlnx-clock-wizard.c Soren Brinkmann 2014-10-02 522 const char *clkout_name; b6461b53e723ec drivers/staging/clocking-wizard/clk-xlnx-clock-wizard.c Athira Lekshmi 2014-12-07 523 a0d1a3864cad08 drivers/staging/clocking-wizard/clk-xlnx-clock-wizard.c Shubhrajyoti Datta 2021-02-24 524 clkout_name = kasprintf(GFP_KERNEL, "%s_out%d", dev_name(&pdev->dev), i); a0d1a3864cad08 drivers/staging/clocking-wizard/clk-xlnx-clock-wizard.c Shubhrajyoti Datta 2021-02-24 525 if (!clkout_name) { a0d1a3864cad08 drivers/staging/clocking-wizard/clk-xlnx-clock-wizard.c Shubhrajyoti Datta 2021-02-24 526 ret = -ENOMEM; a0d1a3864cad08 drivers/staging/clocking-wizard/clk-xlnx-clock-wizard.c Shubhrajyoti Datta 2021-02-24 527 goto err_rm_int_clk; 812283cd546376 drivers/staging/clocking-wizard/clk-xlnx-clock-wizard.c Soren Brinkmann 2014-10-02 528 } a0d1a3864cad08 drivers/staging/clocking-wizard/clk-xlnx-clock-wizard.c Shubhrajyoti Datta 2021-02-24 529 91d695d71841ab drivers/staging/clocking-wizard/clk-xlnx-clock-wizard.c Shubhrajyoti Datta 2021-02-24 530 if (!i) 91d695d71841ab drivers/staging/clocking-wizard/clk-xlnx-clock-wizard.c Shubhrajyoti Datta 2021-02-24 531 clk_wzrd->clkout[i] = clk_wzrd_register_divf 91d695d71841ab drivers/staging/clocking-wizard/clk-xlnx-clock-wizard.c Shubhrajyoti Datta 2021-02-24 532 (&pdev->dev, clkout_name, 91d695d71841ab drivers/staging/clocking-wizard/clk-xlnx-clock-wizard.c Shubhrajyoti Datta 2021-02-24 533 clk_name, flags, 91d695d71841ab drivers/staging/clocking-wizard/clk-xlnx-clock-wizard.c Shubhrajyoti Datta 2021-02-24 534 clk_wzrd->base, (WZRD_CLK_CFG_REG(2) + i * 12), 91d695d71841ab drivers/staging/clocking-wizard/clk-xlnx-clock-wizard.c Shubhrajyoti Datta 2021-02-24 535 WZRD_CLKOUT_DIVIDE_SHIFT, 91d695d71841ab drivers/staging/clocking-wizard/clk-xlnx-clock-wizard.c Shubhrajyoti Datta 2021-02-24 536 WZRD_CLKOUT_DIVIDE_WIDTH, 91d695d71841ab drivers/staging/clocking-wizard/clk-xlnx-clock-wizard.c Shubhrajyoti Datta 2021-02-24 537 CLK_DIVIDER_ONE_BASED | CLK_DIVIDER_ALLOW_ZERO, 91d695d71841ab drivers/staging/clocking-wizard/clk-xlnx-clock-wizard.c Shubhrajyoti Datta 2021-02-24 538 NULL, &clkwzrd_lock); 91d695d71841ab drivers/staging/clocking-wizard/clk-xlnx-clock-wizard.c Shubhrajyoti Datta 2021-02-24 539 else 91d695d71841ab drivers/staging/clocking-wizard/clk-xlnx-clock-wizard.c Shubhrajyoti Datta 2021-02-24 540 clk_wzrd->clkout[i] = clk_wzrd_register_divider 91d695d71841ab drivers/staging/clocking-wizard/clk-xlnx-clock-wizard.c Shubhrajyoti Datta 2021-02-24 541 (&pdev->dev, clkout_name, 5a853722eb3218 drivers/staging/clocking-wizard/clk-xlnx-clock-wizard.c Shubhrajyoti Datta 2021-02-24 542 clk_name, 0, 5a853722eb3218 drivers/staging/clocking-wizard/clk-xlnx-clock-wizard.c Shubhrajyoti Datta 2021-02-24 543 clk_wzrd->base, (WZRD_CLK_CFG_REG(2) + i * 12), 5a853722eb3218 drivers/staging/clocking-wizard/clk-xlnx-clock-wizard.c Shubhrajyoti Datta 2021-02-24 544 WZRD_CLKOUT_DIVIDE_SHIFT, 5a853722eb3218 drivers/staging/clocking-wizard/clk-xlnx-clock-wizard.c Shubhrajyoti Datta 2021-02-24 545 WZRD_CLKOUT_DIVIDE_WIDTH, 5a853722eb3218 drivers/staging/clocking-wizard/clk-xlnx-clock-wizard.c Shubhrajyoti Datta 2021-02-24 546 CLK_DIVIDER_ONE_BASED | CLK_DIVIDER_ALLOW_ZERO, 5a853722eb3218 drivers/staging/clocking-wizard/clk-xlnx-clock-wizard.c Shubhrajyoti Datta 2021-02-24 547 NULL, &clkwzrd_lock); 812283cd546376 drivers/staging/clocking-wizard/clk-xlnx-clock-wizard.c Soren Brinkmann 2014-10-02 548 if (IS_ERR(clk_wzrd->clkout[i])) { 812283cd546376 drivers/staging/clocking-wizard/clk-xlnx-clock-wizard.c Soren Brinkmann 2014-10-02 549 int j; e66f7a27521119 drivers/staging/clocking-wizard/clk-xlnx-clock-wizard.c Athira Sharikkal 2014-11-30 550 a0d1a3864cad08 drivers/staging/clocking-wizard/clk-xlnx-clock-wizard.c Shubhrajyoti Datta 2021-02-24 551 for (j = i + 1; j < nr_outputs; j++) 812283cd546376 drivers/staging/clocking-wizard/clk-xlnx-clock-wizard.c Soren Brinkmann 2014-10-02 552 clk_unregister(clk_wzrd->clkout[j]); 812283cd546376 drivers/staging/clocking-wizard/clk-xlnx-clock-wizard.c Soren Brinkmann 2014-10-02 553 dev_err(&pdev->dev, 812283cd546376 drivers/staging/clocking-wizard/clk-xlnx-clock-wizard.c Soren Brinkmann 2014-10-02 554 "unable to register divider clock\n"); 812283cd546376 drivers/staging/clocking-wizard/clk-xlnx-clock-wizard.c Soren Brinkmann 2014-10-02 555 ret = PTR_ERR(clk_wzrd->clkout[i]); 812283cd546376 drivers/staging/clocking-wizard/clk-xlnx-clock-wizard.c Soren Brinkmann 2014-10-02 556 goto err_rm_int_clks; 812283cd546376 drivers/staging/clocking-wizard/clk-xlnx-clock-wizard.c Soren Brinkmann 2014-10-02 557 } 812283cd546376 drivers/staging/clocking-wizard/clk-xlnx-clock-wizard.c Soren Brinkmann 2014-10-02 558 } 812283cd546376 drivers/staging/clocking-wizard/clk-xlnx-clock-wizard.c Soren Brinkmann 2014-10-02 559 812283cd546376 drivers/staging/clocking-wizard/clk-xlnx-clock-wizard.c Soren Brinkmann 2014-10-02 560 kfree(clk_name); 812283cd546376 drivers/staging/clocking-wizard/clk-xlnx-clock-wizard.c Soren Brinkmann 2014-10-02 561 812283cd546376 drivers/staging/clocking-wizard/clk-xlnx-clock-wizard.c Soren Brinkmann 2014-10-02 562 clk_wzrd->clk_data.clks = clk_wzrd->clkout; 812283cd546376 drivers/staging/clocking-wizard/clk-xlnx-clock-wizard.c Soren Brinkmann 2014-10-02 563 clk_wzrd->clk_data.clk_num = ARRAY_SIZE(clk_wzrd->clkout); 812283cd546376 drivers/staging/clocking-wizard/clk-xlnx-clock-wizard.c Soren Brinkmann 2014-10-02 564 of_clk_add_provider(np, of_clk_src_onecell_get, &clk_wzrd->clk_data); 812283cd546376 drivers/staging/clocking-wizard/clk-xlnx-clock-wizard.c Soren Brinkmann 2014-10-02 565 812283cd546376 drivers/staging/clocking-wizard/clk-xlnx-clock-wizard.c Soren Brinkmann 2014-10-02 566 if (clk_wzrd->speed_grade) { 812283cd546376 drivers/staging/clocking-wizard/clk-xlnx-clock-wizard.c Soren Brinkmann 2014-10-02 567 clk_wzrd->nb.notifier_call = clk_wzrd_clk_notifier; 812283cd546376 drivers/staging/clocking-wizard/clk-xlnx-clock-wizard.c Soren Brinkmann 2014-10-02 568 812283cd546376 drivers/staging/clocking-wizard/clk-xlnx-clock-wizard.c Soren Brinkmann 2014-10-02 569 ret = clk_notifier_register(clk_wzrd->clk_in1, 812283cd546376 drivers/staging/clocking-wizard/clk-xlnx-clock-wizard.c Soren Brinkmann 2014-10-02 570 &clk_wzrd->nb); 812283cd546376 drivers/staging/clocking-wizard/clk-xlnx-clock-wizard.c Soren Brinkmann 2014-10-02 571 if (ret) 812283cd546376 drivers/staging/clocking-wizard/clk-xlnx-clock-wizard.c Soren Brinkmann 2014-10-02 572 dev_warn(&pdev->dev, 812283cd546376 drivers/staging/clocking-wizard/clk-xlnx-clock-wizard.c Soren Brinkmann 2014-10-02 573 "unable to register clock notifier\n"); 812283cd546376 drivers/staging/clocking-wizard/clk-xlnx-clock-wizard.c Soren Brinkmann 2014-10-02 574 812283cd546376 drivers/staging/clocking-wizard/clk-xlnx-clock-wizard.c Soren Brinkmann 2014-10-02 575 ret = clk_notifier_register(clk_wzrd->axi_clk, &clk_wzrd->nb); 812283cd546376 drivers/staging/clocking-wizard/clk-xlnx-clock-wizard.c Soren Brinkmann 2014-10-02 576 if (ret) 812283cd546376 drivers/staging/clocking-wizard/clk-xlnx-clock-wizard.c Soren Brinkmann 2014-10-02 577 dev_warn(&pdev->dev, 812283cd546376 drivers/staging/clocking-wizard/clk-xlnx-clock-wizard.c Soren Brinkmann 2014-10-02 578 "unable to register clock notifier\n"); 812283cd546376 drivers/staging/clocking-wizard/clk-xlnx-clock-wizard.c Soren Brinkmann 2014-10-02 579 } 812283cd546376 drivers/staging/clocking-wizard/clk-xlnx-clock-wizard.c Soren Brinkmann 2014-10-02 580 812283cd546376 drivers/staging/clocking-wizard/clk-xlnx-clock-wizard.c Soren Brinkmann 2014-10-02 581 return 0; 812283cd546376 drivers/staging/clocking-wizard/clk-xlnx-clock-wizard.c Soren Brinkmann 2014-10-02 582 812283cd546376 drivers/staging/clocking-wizard/clk-xlnx-clock-wizard.c Soren Brinkmann 2014-10-02 583 err_rm_int_clks: 812283cd546376 drivers/staging/clocking-wizard/clk-xlnx-clock-wizard.c Soren Brinkmann 2014-10-02 584 clk_unregister(clk_wzrd->clks_internal[1]); 812283cd546376 drivers/staging/clocking-wizard/clk-xlnx-clock-wizard.c Soren Brinkmann 2014-10-02 585 err_rm_int_clk: 812283cd546376 drivers/staging/clocking-wizard/clk-xlnx-clock-wizard.c Soren Brinkmann 2014-10-02 586 kfree(clk_name); 812283cd546376 drivers/staging/clocking-wizard/clk-xlnx-clock-wizard.c Soren Brinkmann 2014-10-02 587 clk_unregister(clk_wzrd->clks_internal[0]); 812283cd546376 drivers/staging/clocking-wizard/clk-xlnx-clock-wizard.c Soren Brinkmann 2014-10-02 588 err_disable_clk: 812283cd546376 drivers/staging/clocking-wizard/clk-xlnx-clock-wizard.c Soren Brinkmann 2014-10-02 589 clk_disable_unprepare(clk_wzrd->axi_clk); 812283cd546376 drivers/staging/clocking-wizard/clk-xlnx-clock-wizard.c Soren Brinkmann 2014-10-02 590 812283cd546376 drivers/staging/clocking-wizard/clk-xlnx-clock-wizard.c Soren Brinkmann 2014-10-02 591 return ret; 812283cd546376 drivers/staging/clocking-wizard/clk-xlnx-clock-wizard.c Soren Brinkmann 2014-10-02 592 } 812283cd546376 drivers/staging/clocking-wizard/clk-xlnx-clock-wizard.c Soren Brinkmann 2014-10-02 593 :::::: The code at line 431 was first introduced by commit :::::: f595f03bfdfc3ce4526a653174024250d7287a8d staging: clocking-wizard: use devm_platform_ioremap_resource() to simplify code :::::: TO: YueHaibing <yuehaibing@xxxxxxxxxx> :::::: CC: Greg Kroah-Hartman <gregkh@xxxxxxxxxxxxxxxxxxx> -- 0-DAY CI Kernel Test Service https://01.org/lkp