Re: [PATCH 5/6] of: add infra to parse iommu-map per IOMMU cell count
From: Dan Carpenter
Date: Thu Nov 06 2025 - 10:03:57 EST
Hi Charan,
kernel test robot noticed the following build warnings:
https://git-scm.com/docs/git-format-patch#_base_tree_information]
url: https://github.com/intel-lab-lkp/linux/commits/Charan-Teja-Kalla/of-create-a-wrapper-for-of_map_id/20251104-170223
base: https://git.kernel.org/pub/scm/linux/kernel/git/robh/linux.git for-next
patch link: https://lore.kernel.org/r/74d4ddf90c0fb485fda1feec5116dc38e5fd23cf.1762235099.git.charan.kalla%40oss.qualcomm.com
patch subject: [PATCH 5/6] of: add infra to parse iommu-map per IOMMU cell count
config: hexagon-randconfig-r072-20251105 (https://download.01.org/0day-ci/archive/20251105/202511051256.fSouTFuY-lkp@xxxxxxxxx/config)
compiler: clang version 22.0.0git (https://github.com/llvm/llvm-project d2625a438020ad35330cda29c3def102c1687b1b)
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>
| Reported-by: Dan Carpenter <dan.carpenter@xxxxxxxxxx>
| Closes: https://lore.kernel.org/r/202511051256.fSouTFuY-lkp@xxxxxxxxx/
smatch warnings:
drivers/of/base.c:2130 of_iommu_map_id_cell_count() error: uninitialized symbol 'legacy_iommu_cells'.
vim +/legacy_iommu_cells +2130 drivers/of/base.c
5288ad2aeeeb419 Charan Teja Kalla 2025-11-04 2123 static int of_iommu_map_id_cell_count(const __be32 *map, int map_len, u32 cells)
c74d6f4acf99ef3 Charan Teja Kalla 2025-11-04 2124 {
5288ad2aeeeb419 Charan Teja Kalla 2025-11-04 2125 u32 legacy_iommu_cells;
5288ad2aeeeb419 Charan Teja Kalla 2025-11-04 2126
c74d6f4acf99ef3 Charan Teja Kalla 2025-11-04 2127 if (map_len % 4 != 0)
5288ad2aeeeb419 Charan Teja Kalla 2025-11-04 2128 legacy_iommu_cells = of_iommu_map_id_legacy_cell_count(map, map_len);
legacy_iommu_cells uninitialize on else path
c74d6f4acf99ef3 Charan Teja Kalla 2025-11-04 2129
5288ad2aeeeb419 Charan Teja Kalla 2025-11-04 @2130 return legacy_iommu_cells ? : of_iommu_map_id_actual_cell_count(map, map_len, cells);
c74d6f4acf99ef3 Charan Teja Kalla 2025-11-04 2131 }
--
0-DAY CI Kernel Test Service
https://github.com/intel/lkp-tests/wiki