[rafael-pm:thermal-core-testing 5/28] drivers/thermal/tegra/tegra30-tsensor.c:326:22: warning: unused variable 'i'

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



tree:   https://git.kernel.org/pub/scm/linux/kernel/git/rafael/linux-pm.git thermal-core-testing
head:   7fd1b071fe42b890c55ac5e735fb39d3d46c1e4d
commit: 52f97fa22ebcf77f8a19cb39932c3069f90c428d [5/28] thermal: tegra: Use thermal_zone_for_each_trip() for walking trip points
config: xtensa-allyesconfig (https://download.01.org/0day-ci/archive/20240801/202408010519.LbMLx3ZP-lkp@xxxxxxxxx/config)
compiler: xtensa-linux-gcc (GCC) 14.1.0
reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20240801/202408010519.LbMLx3ZP-lkp@xxxxxxxxx/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@xxxxxxxxx>
| Closes: https://lore.kernel.org/oe-kbuild-all/202408010519.LbMLx3ZP-lkp@xxxxxxxxx/

All warnings (new ones prefixed by >>):

   drivers/thermal/tegra/tegra30-tsensor.c: In function 'tegra_tsensor_get_hw_channel_trips':
>> drivers/thermal/tegra/tegra30-tsensor.c:326:22: warning: unused variable 'i' [-Wunused-variable]
     326 |         unsigned int i;
         |                      ^


vim +/i +326 drivers/thermal/tegra/tegra30-tsensor.c

52f97fa22ebcf7 Rafael J. Wysocki 2024-07-29  322  
3747e4263ff6d6 Dmitry Osipenko   2021-06-16  323  static void tegra_tsensor_get_hw_channel_trips(struct thermal_zone_device *tzd,
e45ebb38c6b589 Rafael J. Wysocki 2024-07-29  324  					       struct trip_temps *temps)
3747e4263ff6d6 Dmitry Osipenko   2021-06-16  325  {
3747e4263ff6d6 Dmitry Osipenko   2021-06-16 @326  	unsigned int i;
3747e4263ff6d6 Dmitry Osipenko   2021-06-16  327  
3747e4263ff6d6 Dmitry Osipenko   2021-06-16  328  	/*
3747e4263ff6d6 Dmitry Osipenko   2021-06-16  329  	 * 90C is the maximal critical temperature of all Tegra30 SoC variants,
3747e4263ff6d6 Dmitry Osipenko   2021-06-16  330  	 * use it for the default trip if unspecified in a device-tree.
3747e4263ff6d6 Dmitry Osipenko   2021-06-16  331  	 */
e45ebb38c6b589 Rafael J. Wysocki 2024-07-29  332  	temps->hot_trip  = 85000;
e45ebb38c6b589 Rafael J. Wysocki 2024-07-29  333  	temps->crit_trip = 90000;
3747e4263ff6d6 Dmitry Osipenko   2021-06-16  334  
52f97fa22ebcf7 Rafael J. Wysocki 2024-07-29  335  	thermal_zone_for_each_trip(tzd, tegra_tsensor_get_trips_cb, temps);
3747e4263ff6d6 Dmitry Osipenko   2021-06-16  336  
3747e4263ff6d6 Dmitry Osipenko   2021-06-16  337  	/* clamp hardware trips to the calibration limits */
e45ebb38c6b589 Rafael J. Wysocki 2024-07-29  338  	temps->hot_trip = clamp(temps->hot_trip, 25000, 90000);
3747e4263ff6d6 Dmitry Osipenko   2021-06-16  339  
3747e4263ff6d6 Dmitry Osipenko   2021-06-16  340  	/*
3747e4263ff6d6 Dmitry Osipenko   2021-06-16  341  	 * Kernel will perform a normal system shut down if it will
3747e4263ff6d6 Dmitry Osipenko   2021-06-16  342  	 * see that critical temperature is breached, hence set the
3747e4263ff6d6 Dmitry Osipenko   2021-06-16  343  	 * hardware limit by 5C higher in order to allow system to
3747e4263ff6d6 Dmitry Osipenko   2021-06-16  344  	 * shut down gracefully before sending signal to the Power
3747e4263ff6d6 Dmitry Osipenko   2021-06-16  345  	 * Management controller.
3747e4263ff6d6 Dmitry Osipenko   2021-06-16  346  	 */
e45ebb38c6b589 Rafael J. Wysocki 2024-07-29  347  	temps->crit_trip = clamp(temps->crit_trip + 5000, 25000, 90000);
3747e4263ff6d6 Dmitry Osipenko   2021-06-16  348  }
3747e4263ff6d6 Dmitry Osipenko   2021-06-16  349  

:::::: The code at line 326 was first introduced by commit
:::::: 3747e4263ff6d6085507a32946f8236c62dd2495 thermal/drivers/tegra: Add driver for Tegra30 thermal sensor

:::::: TO: Dmitry Osipenko <digetx@xxxxxxxxx>
:::::: CC: Daniel Lezcano <daniel.lezcano@xxxxxxxxxx>

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




[Index of Archives]     [Linux IBM ACPI]     [Linux Power Management]     [Linux Kernel]     [Linux Laptop]     [Kernel Newbies]     [Share Photos]     [Security]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Samba]     [Video 4 Linux]     [Device Mapper]     [Linux Resources]
  Powered by Linux