[rafael-pm:bleeding-edge 65/77] drivers/thermal/intel/intel_quark_dts_thermal.c:353:17: error: 'trips' undeclared

[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 bleeding-edge
head:   2bc44535ed4f6a6013ec53b505c4c381e166f0ce
commit: fdb07e113a91652cc3adf07a8e1ca7da3445f493 [65/77] thermal: intel: Set THERMAL_TRIP_WRITABLE_TEMP directly
config: i386-allmodconfig (https://download.01.org/0day-ci/archive/20240209/202402092329.W4VIvzU0-lkp@xxxxxxxxx/config)
compiler: gcc-12 (Debian 12.2.0-14) 12.2.0
reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20240209/202402092329.W4VIvzU0-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/202402092329.W4VIvzU0-lkp@xxxxxxxxx/

All errors (new ones prefixed by >>):

   drivers/thermal/intel/intel_quark_dts_thermal.c: In function 'alloc_soc_dts':
>> drivers/thermal/intel/intel_quark_dts_thermal.c:353:17: error: 'trips' undeclared (first use in this function)
     353 |                 trips[QRK_DTS_ID_TP_CRITICAL].flags |= THERMAL_TRIP_WRITABLE_TEMP;
         |                 ^~~~~
   drivers/thermal/intel/intel_quark_dts_thermal.c:353:17: note: each undeclared identifier is reported only once for each function it appears in


vim +/trips +353 drivers/thermal/intel/intel_quark_dts_thermal.c

   316	
   317	static struct soc_sensor_entry *alloc_soc_dts(void)
   318	{
   319		struct soc_sensor_entry *aux_entry;
   320		int err;
   321		u32 out;
   322	
   323		aux_entry = kzalloc(sizeof(*aux_entry), GFP_KERNEL);
   324		if (!aux_entry) {
   325			err = -ENOMEM;
   326			return ERR_PTR(-ENOMEM);
   327		}
   328	
   329		/* Check if DTS register is locked */
   330		err = iosf_mbi_read(QRK_MBI_UNIT_RMU, MBI_REG_READ,
   331				    QRK_DTS_REG_OFFSET_LOCK, &out);
   332		if (err)
   333			goto err_ret;
   334	
   335		aux_entry->locked = !!(out & QRK_DTS_LOCK_BIT);
   336	
   337		/* Store DTS default state if DTS registers are not locked */
   338		if (!aux_entry->locked) {
   339			/* Store DTS default enable for restore on exit */
   340			err = iosf_mbi_read(QRK_MBI_UNIT_RMU, MBI_REG_READ,
   341					    QRK_DTS_REG_OFFSET_ENABLE,
   342					    &aux_entry->store_dts_enable);
   343			if (err)
   344				goto err_ret;
   345	
   346			/* Store DTS default PTPS register for restore on exit */
   347			err = iosf_mbi_read(QRK_MBI_UNIT_RMU, MBI_REG_READ,
   348					    QRK_DTS_REG_OFFSET_PTPS,
   349					    &aux_entry->store_ptps);
   350			if (err)
   351				goto err_ret;
   352	
 > 353			trips[QRK_DTS_ID_TP_CRITICAL].flags |= THERMAL_TRIP_WRITABLE_TEMP;
   354			trips[QRK_DTS_ID_TP_HOT].flags |= THERMAL_TRIP_WRITABLE_TEMP;
   355		}
   356	
   357		aux_entry->trips[QRK_DTS_ID_TP_CRITICAL].temperature = get_trip_temp(QRK_DTS_ID_TP_CRITICAL);
   358		aux_entry->trips[QRK_DTS_ID_TP_CRITICAL].type = THERMAL_TRIP_CRITICAL;
   359	
   360		aux_entry->trips[QRK_DTS_ID_TP_HOT].temperature = get_trip_temp(QRK_DTS_ID_TP_HOT);
   361		aux_entry->trips[QRK_DTS_ID_TP_HOT].type = THERMAL_TRIP_HOT;
   362	
   363		aux_entry->tzone = thermal_zone_device_register_with_trips("quark_dts",
   364									   aux_entry->trips,
   365									   QRK_MAX_DTS_TRIPS,
   366									   0, aux_entry,
   367									   &tzone_ops,
   368									   NULL, 0, polling_delay);
   369		if (IS_ERR(aux_entry->tzone)) {
   370			err = PTR_ERR(aux_entry->tzone);
   371			goto err_ret;
   372		}
   373	
   374		err = thermal_zone_device_enable(aux_entry->tzone);
   375		if (err)
   376			goto err_aux_status;
   377	
   378		return aux_entry;
   379	
   380	err_aux_status:
   381		thermal_zone_device_unregister(aux_entry->tzone);
   382	err_ret:
   383		kfree(aux_entry);
   384		return ERR_PTR(err);
   385	}
   386	

-- 
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