From: kbuild test robot <lkp@intel.com>
To: kbuild-all@lists.01.org
Subject: [snawrocki:for-v5.4/fixes 1/2] drivers/clk/samsung/clk-exynos5433.c:5598:4: error: implicit declaration of function 'kfree'; did you mean 'ida_free'?
Date: Thu, 24 Oct 2019 00:03:57 +0800 [thread overview]
Message-ID: <201910240049.zv4Bnr6f%lkp@intel.com> (raw)
[-- Attachment #1: Type: text/plain, Size: 4971 bytes --]
tree: https://git.kernel.org/pub/scm/linux/kernel/git/snawrocki/clk.git for-v5.4/fixes
head: 12a8ee2dc890686ab917d757e5d9379dd6943cc1
commit: 4265a77ed90d7a7ae3fb9c8e424a9f8e8ea77889 [1/2] clk: samsung: exynos5433: Fix error paths
config: mips-allyesconfig (attached as .config)
compiler: mips-linux-gcc (GCC) 7.4.0
reproduce:
wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross
chmod +x ~/bin/make.cross
git checkout 4265a77ed90d7a7ae3fb9c8e424a9f8e8ea77889
# save the attached .config to linux build tree
GCC_VERSION=7.4.0 make.cross ARCH=mips
If you fix the issue, kindly add following tag
Reported-by: kbuild test robot <lkp@intel.com>
All errors (new ones prefixed by >>):
drivers/clk/samsung/clk-exynos5433.c: In function 'exynos5433_cmu_probe':
>> drivers/clk/samsung/clk-exynos5433.c:5598:4: error: implicit declaration of function 'kfree'; did you mean 'ida_free'? [-Werror=implicit-function-declaration]
kfree(data->clk_save);
^~~~~
ida_free
cc1: some warnings being treated as errors
vim +5598 drivers/clk/samsung/clk-exynos5433.c
5552
5553 static int __init exynos5433_cmu_probe(struct platform_device *pdev)
5554 {
5555 const struct samsung_cmu_info *info;
5556 struct exynos5433_cmu_data *data;
5557 struct samsung_clk_provider *ctx;
5558 struct device *dev = &pdev->dev;
5559 struct resource *res;
5560 void __iomem *reg_base;
5561 int i;
5562
5563 info = of_device_get_match_data(dev);
5564
5565 data = devm_kzalloc(dev,
5566 struct_size(data, ctx.clk_data.hws, info->nr_clk_ids),
5567 GFP_KERNEL);
5568 if (!data)
5569 return -ENOMEM;
5570 ctx = &data->ctx;
5571
5572 res = platform_get_resource(pdev, IORESOURCE_MEM, 0);
5573 reg_base = devm_ioremap_resource(dev, res);
5574 if (IS_ERR(reg_base))
5575 return PTR_ERR(reg_base);
5576
5577 for (i = 0; i < info->nr_clk_ids; ++i)
5578 ctx->clk_data.hws[i] = ERR_PTR(-ENOENT);
5579
5580 ctx->clk_data.num = info->nr_clk_ids;
5581 ctx->reg_base = reg_base;
5582 ctx->dev = dev;
5583 spin_lock_init(&ctx->lock);
5584
5585 data->clk_save = samsung_clk_alloc_reg_dump(info->clk_regs,
5586 info->nr_clk_regs);
5587 if (!data->clk_save)
5588 return -ENOMEM;
5589 data->nr_clk_save = info->nr_clk_regs;
5590 data->clk_suspend = info->suspend_regs;
5591 data->nr_clk_suspend = info->nr_suspend_regs;
5592 data->nr_pclks = of_clk_get_parent_count(dev->of_node);
5593
5594 if (data->nr_pclks > 0) {
5595 data->pclks = devm_kcalloc(dev, sizeof(struct clk *),
5596 data->nr_pclks, GFP_KERNEL);
5597 if (!data->pclks) {
> 5598 kfree(data->clk_save);
5599 return -ENOMEM;
5600 }
5601 for (i = 0; i < data->nr_pclks; i++) {
5602 struct clk *clk = of_clk_get(dev->of_node, i);
5603
5604 if (IS_ERR(clk)) {
5605 kfree(data->clk_save);
5606 while (--i >= 0)
5607 clk_put(data->pclks[i]);
5608 return PTR_ERR(clk);
5609 }
5610 data->pclks[i] = clk;
5611 }
5612 }
5613
5614 if (info->clk_name)
5615 data->clk = clk_get(dev, info->clk_name);
5616 clk_prepare_enable(data->clk);
5617
5618 platform_set_drvdata(pdev, data);
5619
5620 /*
5621 * Enable runtime PM here to allow the clock core using runtime PM
5622 * for the registered clocks. Additionally, we increase the runtime
5623 * PM usage count before registering the clocks, to prevent the
5624 * clock core from runtime suspending the device.
5625 */
5626 pm_runtime_get_noresume(dev);
5627 pm_runtime_set_active(dev);
5628 pm_runtime_enable(dev);
5629
5630 if (info->pll_clks)
5631 samsung_clk_register_pll(ctx, info->pll_clks, info->nr_pll_clks,
5632 reg_base);
5633 if (info->mux_clks)
5634 samsung_clk_register_mux(ctx, info->mux_clks,
5635 info->nr_mux_clks);
5636 if (info->div_clks)
5637 samsung_clk_register_div(ctx, info->div_clks,
5638 info->nr_div_clks);
5639 if (info->gate_clks)
5640 samsung_clk_register_gate(ctx, info->gate_clks,
5641 info->nr_gate_clks);
5642 if (info->fixed_clks)
5643 samsung_clk_register_fixed_rate(ctx, info->fixed_clks,
5644 info->nr_fixed_clks);
5645 if (info->fixed_factor_clks)
5646 samsung_clk_register_fixed_factor(ctx, info->fixed_factor_clks,
5647 info->nr_fixed_factor_clks);
5648
5649 samsung_clk_of_add_provider(dev->of_node, ctx);
5650 pm_runtime_put_sync(dev);
5651
5652 return 0;
5653 }
5654
---
0-DAY kernel test infrastructure Open Source Technology Center
https://lists.01.org/pipermail/kbuild-all Intel Corporation
[-- Attachment #2: config.gz --]
[-- Type: application/gzip, Size: 62270 bytes --]
reply other threads:[~2019-10-23 16:03 UTC|newest]
Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=201910240049.zv4Bnr6f%lkp@intel.com \
--to=lkp@intel.com \
--cc=kbuild-all@lists.01.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.