Building the Linux kernel with Clang and LLVM
 help / color / mirror / Atom feed
* Re: [PATCH v4 4/4] drivers/thermal/exymos: Use guard notation when acquiring mutex
       [not found] <20250310143450.8276-5-linux.amoon@gmail.com>
@ 2025-03-11 16:56 ` kernel test robot
  0 siblings, 0 replies; only message in thread
From: kernel test robot @ 2025-03-11 16:56 UTC (permalink / raw)
  To: Anand Moon, Bartlomiej Zolnierkiewicz, Krzysztof Kozlowski,
	Rafael J. Wysocki, Daniel Lezcano, Zhang Rui, Lukasz Luba,
	Alim Akhtar, linux-pm, linux-samsung-soc, linux-kernel
  Cc: llvm, oe-kbuild-all, Anand Moon

Hi Anand,

kernel test robot noticed the following build errors:

[auto build test ERROR on 80e54e84911a923c40d7bee33a34c1b4be148d7a]

url:    https://github.com/intel-lab-lkp/linux/commits/Anand-Moon/drivers-thermal-exynos-Refactor-clk_sec-initialization-inside-SOC-specific-case/20250310-223732
base:   80e54e84911a923c40d7bee33a34c1b4be148d7a
patch link:    https://lore.kernel.org/r/20250310143450.8276-5-linux.amoon%40gmail.com
patch subject: [PATCH v4 4/4] drivers/thermal/exymos: Use guard notation when acquiring mutex
config: s390-randconfig-001-20250311 (https://download.01.org/0day-ci/archive/20250312/202503120028.ZL9zhHXe-lkp@intel.com/config)
compiler: clang version 15.0.7 (https://github.com/llvm/llvm-project 8dfdcc7b7bf66834a761bd8de445840ef68e4d1a)
reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20250312/202503120028.ZL9zhHXe-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@intel.com>
| Closes: https://lore.kernel.org/oe-kbuild-all/202503120028.ZL9zhHXe-lkp@intel.com/

All errors (new ones prefixed by >>):

>> drivers/thermal/samsung/exynos_tmu.c:721:3: error: cannot jump from this goto statement to its label
                   goto out;
                   ^
   drivers/thermal/samsung/exynos_tmu.c:723:2: note: jump bypasses initialization of variable with __attribute__((cleanup))
           guard(mutex)(&data->lock);
           ^
   include/linux/cleanup.h:309:15: note: expanded from macro 'guard'
           CLASS(_name, __UNIQUE_ID(guard))
                        ^
   include/linux/compiler.h:166:29: note: expanded from macro '__UNIQUE_ID'
   #define __UNIQUE_ID(prefix) __PASTE(__PASTE(__UNIQUE_ID_, prefix), __COUNTER__)
                               ^
   include/linux/compiler_types.h:84:22: note: expanded from macro '__PASTE'
   #define __PASTE(a,b) ___PASTE(a,b)
                        ^
   include/linux/compiler_types.h:83:23: note: expanded from macro '___PASTE'
   #define ___PASTE(a,b) a##b
                         ^
   <scratch space>:78:1: note: expanded from here
   __UNIQUE_ID_guard398
   ^
   drivers/thermal/samsung/exynos_tmu.c:718:3: error: cannot jump from this goto statement to its label
                   goto out;
                   ^
   drivers/thermal/samsung/exynos_tmu.c:723:2: note: jump bypasses initialization of variable with __attribute__((cleanup))
           guard(mutex)(&data->lock);
           ^
   include/linux/cleanup.h:309:15: note: expanded from macro 'guard'
           CLASS(_name, __UNIQUE_ID(guard))
                        ^
   include/linux/compiler.h:166:29: note: expanded from macro '__UNIQUE_ID'
   #define __UNIQUE_ID(prefix) __PASTE(__PASTE(__UNIQUE_ID_, prefix), __COUNTER__)
                               ^
   include/linux/compiler_types.h:84:22: note: expanded from macro '__PASTE'
   #define __PASTE(a,b) ___PASTE(a,b)
                        ^
   include/linux/compiler_types.h:83:23: note: expanded from macro '___PASTE'
   #define ___PASTE(a,b) a##b
                         ^
   <scratch space>:78:1: note: expanded from here
   __UNIQUE_ID_guard398
   ^
   2 errors generated.


vim +721 drivers/thermal/samsung/exynos_tmu.c

285d994a51e45ca drivers/thermal/samsung/exynos_tmu.c Bartlomiej Zolnierkiewicz 2014-11-13  711  
7ea98f70c73ea37 drivers/thermal/samsung/exynos_tmu.c Daniel Lezcano            2022-08-05  712  static int exynos_tmu_set_emulation(struct thermal_zone_device *tz, int temp)
bffd1f8ac87a798 drivers/thermal/exynos_thermal.c     Amit Daniel Kachhap       2013-02-11  713  {
5f68d0785e5258a drivers/thermal/samsung/exynos_tmu.c Daniel Lezcano            2023-03-01  714  	struct exynos_tmu_data *data = thermal_zone_device_priv(tz);
bffd1f8ac87a798 drivers/thermal/exynos_thermal.c     Amit Daniel Kachhap       2013-02-11  715  	int ret = -EINVAL;
bffd1f8ac87a798 drivers/thermal/exynos_thermal.c     Amit Daniel Kachhap       2013-02-11  716  
ef3f80fc7f79c32 drivers/thermal/samsung/exynos_tmu.c Bartlomiej Zolnierkiewicz 2014-11-13  717  	if (data->soc == SOC_ARCH_EXYNOS4210)
bffd1f8ac87a798 drivers/thermal/exynos_thermal.c     Amit Daniel Kachhap       2013-02-11  718  		goto out;
bffd1f8ac87a798 drivers/thermal/exynos_thermal.c     Amit Daniel Kachhap       2013-02-11  719  
bffd1f8ac87a798 drivers/thermal/exynos_thermal.c     Amit Daniel Kachhap       2013-02-11  720  	if (temp && temp < MCELSIUS)
bffd1f8ac87a798 drivers/thermal/exynos_thermal.c     Amit Daniel Kachhap       2013-02-11 @721  		goto out;
bffd1f8ac87a798 drivers/thermal/exynos_thermal.c     Amit Daniel Kachhap       2013-02-11  722  
0c7c68a34f7d0f7 drivers/thermal/samsung/exynos_tmu.c Anand Moon                2025-03-10  723  	guard(mutex)(&data->lock);
bffd1f8ac87a798 drivers/thermal/exynos_thermal.c     Amit Daniel Kachhap       2013-02-11  724  	clk_enable(data->clk);
285d994a51e45ca drivers/thermal/samsung/exynos_tmu.c Bartlomiej Zolnierkiewicz 2014-11-13  725  	data->tmu_set_emulation(data, temp);
bffd1f8ac87a798 drivers/thermal/exynos_thermal.c     Amit Daniel Kachhap       2013-02-11  726  	clk_disable(data->clk);
bffd1f8ac87a798 drivers/thermal/exynos_thermal.c     Amit Daniel Kachhap       2013-02-11  727  	return 0;
bffd1f8ac87a798 drivers/thermal/exynos_thermal.c     Amit Daniel Kachhap       2013-02-11  728  out:
bffd1f8ac87a798 drivers/thermal/exynos_thermal.c     Amit Daniel Kachhap       2013-02-11  729  	return ret;
bffd1f8ac87a798 drivers/thermal/exynos_thermal.c     Amit Daniel Kachhap       2013-02-11  730  }
bffd1f8ac87a798 drivers/thermal/exynos_thermal.c     Amit Daniel Kachhap       2013-02-11  731  #else
285d994a51e45ca drivers/thermal/samsung/exynos_tmu.c Bartlomiej Zolnierkiewicz 2014-11-13  732  #define exynos4412_tmu_set_emulation NULL
7ea98f70c73ea37 drivers/thermal/samsung/exynos_tmu.c Daniel Lezcano            2022-08-05  733  static int exynos_tmu_set_emulation(struct thermal_zone_device *tz, int temp)
bffd1f8ac87a798 drivers/thermal/exynos_thermal.c     Amit Daniel Kachhap       2013-02-11  734  	{ return -EINVAL; }
bffd1f8ac87a798 drivers/thermal/exynos_thermal.c     Amit Daniel Kachhap       2013-02-11  735  #endif /* CONFIG_THERMAL_EMULATION */
bffd1f8ac87a798 drivers/thermal/exynos_thermal.c     Amit Daniel Kachhap       2013-02-11  736  

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

^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2025-03-11 16:57 UTC | newest]

Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
     [not found] <20250310143450.8276-5-linux.amoon@gmail.com>
2025-03-11 16:56 ` [PATCH v4 4/4] drivers/thermal/exymos: Use guard notation when acquiring mutex kernel test robot

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox