lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <202507111841.QdQ2DVpT-lkp@intel.com>
Date: Fri, 11 Jul 2025 18:52:33 +0800
From: kernel test robot <lkp@...el.com>
To: Andrei Stefanescu <andrei.stefanescu@....nxp.com>,
	linus.walleij@...aro.org, brgl@...ev.pl, robh@...nel.org,
	krzk+dt@...nel.org, conor+dt@...nel.org, chester62515@...il.com,
	mbrugger@...e.com, Ghennadi.Procopciuc@....com,
	larisa.grigore@....com, lee@...nel.org, shawnguo@...nel.org,
	s.hauer@...gutronix.de, festevam@...il.com, aisheng.dong@....com,
	ping.bai@....com, gregkh@...uxfoundation.org, rafael@...nel.org,
	srini@...nel.org
Cc: oe-kbuild-all@...ts.linux.dev, linux-gpio@...r.kernel.org,
	devicetree@...r.kernel.org, linux-kernel@...r.kernel.org,
	linux-arm-kernel@...ts.infradead.org, s32@....com,
	clizzi@...hat.com, aruizrui@...hat.com, eballetb@...hat.com,
	echanude@...hat.com, kernel@...gutronix.de, imx@...ts.linux.dev,
	vincent.guittot@...aro.org
Subject: Re: [PATCH v7 07/12] pinctrl: s32g2: change the driver to also be
 probed as an MFD cell

Hi Andrei,

kernel test robot noticed the following build warnings:

[auto build test WARNING on linusw-pinctrl/devel]
[also build test WARNING on linusw-pinctrl/for-next lee-mfd/for-mfd-next lee-mfd/for-mfd-fixes linus/master v6.16-rc5]
[cannot apply to shawnguo/for-next next-20250710]
[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/Andrei-Stefanescu/dt-bindings-mfd-add-support-for-the-NXP-SIUL2-module/20250710-222538
base:   https://git.kernel.org/pub/scm/linux/kernel/git/linusw/linux-pinctrl.git devel
patch link:    https://lore.kernel.org/r/20250710142038.1986052-8-andrei.stefanescu%40oss.nxp.com
patch subject: [PATCH v7 07/12] pinctrl: s32g2: change the driver to also be probed as an MFD cell
config: arm64-randconfig-003-20250711 (https://download.01.org/0day-ci/archive/20250711/202507111841.QdQ2DVpT-lkp@intel.com/config)
compiler: aarch64-linux-gcc (GCC) 12.3.0
reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20250711/202507111841.QdQ2DVpT-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/202507111841.QdQ2DVpT-lkp@intel.com/

All warnings (new ones prefixed by >>):

   In file included from include/linux/bits.h:32,
                    from include/linux/bitops.h:6,
                    from drivers/pinctrl/nxp/pinctrl-s32cc.c:10:
   drivers/pinctrl/nxp/pinctrl-s32cc.c: In function 'to_s32_pinctrl':
   include/linux/container_of.h:20:54: error: 'struct s32_pinctrl' has no member named 'gc'
      20 |         static_assert(__same_type(*(ptr), ((type *)0)->member) ||       \
         |                                                      ^~
   include/linux/build_bug.h:78:56: note: in definition of macro '__static_assert'
      78 | #define __static_assert(expr, msg, ...) _Static_assert(expr, msg)
         |                                                        ^~~~
   include/linux/container_of.h:20:9: note: in expansion of macro 'static_assert'
      20 |         static_assert(__same_type(*(ptr), ((type *)0)->member) ||       \
         |         ^~~~~~~~~~~~~
   include/linux/container_of.h:20:23: note: in expansion of macro '__same_type'
      20 |         static_assert(__same_type(*(ptr), ((type *)0)->member) ||       \
         |                       ^~~~~~~~~~~
   drivers/pinctrl/nxp/pinctrl-s32cc.c:706:16: note: in expansion of macro 'container_of'
     706 |         return container_of(chip, struct s32_pinctrl, gc);
         |                ^~~~~~~~~~~~
   include/linux/compiler_types.h:503:27: error: expression in static assertion is not an integer
     503 | #define __same_type(a, b) __builtin_types_compatible_p(typeof(a), typeof(b))
         |                           ^~~~~~~~~~~~~~~~~~~~~~~~~~~~
   include/linux/build_bug.h:78:56: note: in definition of macro '__static_assert'
      78 | #define __static_assert(expr, msg, ...) _Static_assert(expr, msg)
         |                                                        ^~~~
   include/linux/container_of.h:20:9: note: in expansion of macro 'static_assert'
      20 |         static_assert(__same_type(*(ptr), ((type *)0)->member) ||       \
         |         ^~~~~~~~~~~~~
   include/linux/container_of.h:20:23: note: in expansion of macro '__same_type'
      20 |         static_assert(__same_type(*(ptr), ((type *)0)->member) ||       \
         |                       ^~~~~~~~~~~
   drivers/pinctrl/nxp/pinctrl-s32cc.c:706:16: note: in expansion of macro 'container_of'
     706 |         return container_of(chip, struct s32_pinctrl, gc);
         |                ^~~~~~~~~~~~
   In file included from include/uapi/linux/posix_types.h:5,
                    from include/uapi/linux/types.h:14,
                    from include/linux/types.h:6,
                    from include/linux/kasan-checks.h:5,
                    from include/asm-generic/rwonce.h:26,
                    from arch/arm64/include/asm/rwonce.h:67,
                    from include/linux/compiler.h:390,
                    from include/linux/build_bug.h:5:
   include/linux/stddef.h:16:33: error: 'struct s32_pinctrl' has no member named 'gc'
      16 | #define offsetof(TYPE, MEMBER)  __builtin_offsetof(TYPE, MEMBER)
         |                                 ^~~~~~~~~~~~~~~~~~
   include/linux/container_of.h:23:28: note: in expansion of macro 'offsetof'
      23 |         ((type *)(__mptr - offsetof(type, member))); })
         |                            ^~~~~~~~
   drivers/pinctrl/nxp/pinctrl-s32cc.c:706:16: note: in expansion of macro 'container_of'
     706 |         return container_of(chip, struct s32_pinctrl, gc);
         |                ^~~~~~~~~~~~
   drivers/pinctrl/nxp/pinctrl-s32cc.c: In function 'legacy_s32_pinctrl_regmap_init':
>> drivers/pinctrl/nxp/pinctrl-s32cc.c:873:44: warning: variable 'soc_data' set but not used [-Wunused-but-set-variable]
     873 |         const struct s32_pinctrl_soc_data *soc_data;
         |                                            ^~~~~~~~
   drivers/pinctrl/nxp/pinctrl-s32cc.c: In function 's32_pinctrl_mfd_regmap_init':
   drivers/pinctrl/nxp/pinctrl-s32cc.c:920:44: warning: variable 'soc_data' set but not used [-Wunused-but-set-variable]
     920 |         const struct s32_pinctrl_soc_data *soc_data;
         |                                            ^~~~~~~~
   drivers/pinctrl/nxp/pinctrl-s32cc.c: At top level:
   drivers/pinctrl/nxp/pinctrl-s32cc.c:704:28: warning: 'to_s32_pinctrl' defined but not used [-Wunused-function]
     704 | static struct s32_pinctrl *to_s32_pinctrl(struct gpio_chip *chip)
         |                            ^~~~~~~~~~~~~~


vim +/soc_data +873 drivers/pinctrl/nxp/pinctrl-s32cc.c

   868	
   869	static int legacy_s32_pinctrl_regmap_init(struct platform_device *pdev,
   870						  struct s32_pinctrl *ipctl)
   871	{
   872		struct s32_pinctrl_soc_info *info = ipctl->info;
 > 873		const struct s32_pinctrl_soc_data *soc_data;
   874		unsigned int mem_regions;
   875		struct resource *res;
   876		struct regmap *map;
   877		void __iomem *base;
   878		u32 i = 0;
   879	
   880		soc_data = info->soc_data;
   881	
   882		mem_regions = info->soc_data->mem_regions;
   883		if (mem_regions == 0 || mem_regions >= 10000)
   884			return dev_err_probe(&pdev->dev, -EINVAL,
   885					     "mem_regions is invalid: %u\n",
   886					     mem_regions);
   887	
   888		for (i = 0; i < mem_regions; i++) {
   889			base = devm_platform_get_and_ioremap_resource(pdev, i, &res);
   890			if (IS_ERR(base))
   891				return PTR_ERR(base);
   892	
   893			snprintf(ipctl->regions[i].name,
   894				 sizeof(ipctl->regions[i].name), "map%u", i);
   895	
   896			s32_regmap_config.name = ipctl->regions[i].name;
   897			s32_regmap_config.max_register = resource_size(res) -
   898							 s32_regmap_config.reg_stride;
   899	
   900			map = devm_regmap_init_mmio(&pdev->dev, base,
   901						    &s32_regmap_config);
   902			if (IS_ERR(map)) {
   903				dev_err(&pdev->dev, "Failed to init regmap[%u]\n", i);
   904				return PTR_ERR(map);
   905			}
   906	
   907			ipctl->regions[i].map = map;
   908			ipctl->regions[i].pin_range = &info->soc_data->mem_pin_ranges[i];
   909		}
   910	
   911		return 0;
   912	}
   913	

-- 
0-DAY CI Kernel Test Service
https://github.com/intel/lkp-tests/wiki

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ