[<prev] [next>] [day] [month] [year] [list]
Message-ID: <202601191830.UT3aY6bo-lkp@intel.com>
Date: Mon, 19 Jan 2026 18:50:12 +0800
From: kernel test robot <lkp@...el.com>
To: Ryan Wanner <Ryan.Wanner@...rochip.com>
Cc: oe-kbuild-all@...ts.linux.dev, linux-kernel@...r.kernel.org,
Claudiu Beznea <claudiu.beznea@...on.dev>
Subject: arch/arm/mach-at91/pm.c:1005:30: sparse: sparse: incorrect
type in assignment (different address spaces)
Hi Ryan,
First bad commit (maybe != root cause):
tree: https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git master
head: 24d479d26b25bce5faea3ddd9fa8f3a6c3129ea7
commit: 452d18c78a469cd18b3f7bc7bc9427f9af390f7e ARM: at91: add new SoC sama7d65
date: 1 year, 1 month ago
config: arm-randconfig-r112-20260119 (https://download.01.org/0day-ci/archive/20260119/202601191830.UT3aY6bo-lkp@intel.com/config)
compiler: clang version 20.1.8 (https://github.com/llvm/llvm-project 87f0227cb60147a26a1eeb4fb06e3b505e9c7261)
reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20260119/202601191830.UT3aY6bo-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@...el.com>
| Closes: https://lore.kernel.org/oe-kbuild-all/202601191830.UT3aY6bo-lkp@intel.com/
sparse warnings: (new ones prefixed by >>)
>> arch/arm/mach-at91/pm.c:1005:30: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected void ( *static [assigned] [toplevel] at91_suspend_sram_fn )( ... ) @@ got void [noderef] __iomem * @@
arch/arm/mach-at91/pm.c:1005:30: sparse: expected void ( *static [assigned] [toplevel] at91_suspend_sram_fn )( ... )
arch/arm/mach-at91/pm.c:1005:30: sparse: got void [noderef] __iomem *
vim +1005 arch/arm/mach-at91/pm.c
fbc7edca5a7dd4 Alexandre Belloni 2015-09-30 970
d2e46790559676 Alexandre Belloni 2015-01-15 971 static void __init at91_pm_sram_init(void)
d2e46790559676 Alexandre Belloni 2015-01-15 972 {
d2e46790559676 Alexandre Belloni 2015-01-15 973 struct gen_pool *sram_pool;
d2e46790559676 Alexandre Belloni 2015-01-15 974 phys_addr_t sram_pbase;
d2e46790559676 Alexandre Belloni 2015-01-15 975 unsigned long sram_base;
d2e46790559676 Alexandre Belloni 2015-01-15 976 struct device_node *node;
4a031f7dbe497a Alexandre Belloni 2015-03-03 977 struct platform_device *pdev = NULL;
d2e46790559676 Alexandre Belloni 2015-01-15 978
4a031f7dbe497a Alexandre Belloni 2015-03-03 979 for_each_compatible_node(node, NULL, "mmio-sram") {
4a031f7dbe497a Alexandre Belloni 2015-03-03 980 pdev = of_find_device_by_node(node);
4a031f7dbe497a Alexandre Belloni 2015-03-03 981 if (pdev) {
4a031f7dbe497a Alexandre Belloni 2015-03-03 982 of_node_put(node);
4a031f7dbe497a Alexandre Belloni 2015-03-03 983 break;
4a031f7dbe497a Alexandre Belloni 2015-03-03 984 }
d2e46790559676 Alexandre Belloni 2015-01-15 985 }
d2e46790559676 Alexandre Belloni 2015-01-15 986
d2e46790559676 Alexandre Belloni 2015-01-15 987 if (!pdev) {
d2e46790559676 Alexandre Belloni 2015-01-15 988 pr_warn("%s: failed to find sram device!\n", __func__);
4a031f7dbe497a Alexandre Belloni 2015-03-03 989 return;
d2e46790559676 Alexandre Belloni 2015-01-15 990 }
d2e46790559676 Alexandre Belloni 2015-01-15 991
73858173593c31 Vladimir Zapolskiy 2015-09-04 992 sram_pool = gen_pool_get(&pdev->dev, NULL);
d2e46790559676 Alexandre Belloni 2015-01-15 993 if (!sram_pool) {
d2e46790559676 Alexandre Belloni 2015-01-15 994 pr_warn("%s: sram pool unavailable!\n", __func__);
f87a4f022c44e5 yu kuai 2020-06-04 995 goto out_put_device;
d2e46790559676 Alexandre Belloni 2015-01-15 996 }
d2e46790559676 Alexandre Belloni 2015-01-15 997
5726a8b9686348 Wenyou Yang 2015-03-09 998 sram_base = gen_pool_alloc(sram_pool, at91_pm_suspend_in_sram_sz);
d2e46790559676 Alexandre Belloni 2015-01-15 999 if (!sram_base) {
5726a8b9686348 Wenyou Yang 2015-03-09 1000 pr_warn("%s: unable to alloc sram!\n", __func__);
f87a4f022c44e5 yu kuai 2020-06-04 1001 goto out_put_device;
d2e46790559676 Alexandre Belloni 2015-01-15 1002 }
d2e46790559676 Alexandre Belloni 2015-01-15 1003
d2e46790559676 Alexandre Belloni 2015-01-15 1004 sram_pbase = gen_pool_virt_to_phys(sram_pool, sram_base);
5726a8b9686348 Wenyou Yang 2015-03-09 @1005 at91_suspend_sram_fn = __arm_ioremap_exec(sram_pbase,
5726a8b9686348 Wenyou Yang 2015-03-09 1006 at91_pm_suspend_in_sram_sz, false);
5726a8b9686348 Wenyou Yang 2015-03-09 1007 if (!at91_suspend_sram_fn) {
d94e688cae5661 Wenyou Yang 2015-03-09 1008 pr_warn("SRAM: Could not map\n");
f87a4f022c44e5 yu kuai 2020-06-04 1009 goto out_put_device;
d94e688cae5661 Wenyou Yang 2015-03-09 1010 }
d94e688cae5661 Wenyou Yang 2015-03-09 1011
5726a8b9686348 Wenyou Yang 2015-03-09 1012 /* Copy the pm suspend handler to SRAM */
5726a8b9686348 Wenyou Yang 2015-03-09 1013 at91_suspend_sram_fn = fncpy(at91_suspend_sram_fn,
5726a8b9686348 Wenyou Yang 2015-03-09 1014 &at91_pm_suspend_in_sram, at91_pm_suspend_in_sram_sz);
f87a4f022c44e5 yu kuai 2020-06-04 1015 return;
f87a4f022c44e5 yu kuai 2020-06-04 1016
f87a4f022c44e5 yu kuai 2020-06-04 1017 out_put_device:
f87a4f022c44e5 yu kuai 2020-06-04 1018 put_device(&pdev->dev);
f87a4f022c44e5 yu kuai 2020-06-04 1019 return;
d2e46790559676 Alexandre Belloni 2015-01-15 1020 }
d2e46790559676 Alexandre Belloni 2015-01-15 1021
:::::: The code at line 1005 was first introduced by commit
:::::: 5726a8b9686348e8d203f1bbf9d5fc1bb5899518 ARM: at91/pm: rename function name: at91_slow_clock() --> at91_pm_suspend_sram_fn()
:::::: TO: Wenyou Yang <wenyou.yang@...el.com>
:::::: CC: Nicolas Ferre <nicolas.ferre@...el.com>
--
0-DAY CI Kernel Test Service
https://github.com/intel/lkp-tests/wiki
Powered by blists - more mailing lists