All of lore.kernel.org
 help / color / mirror / Atom feed
* Re: TCC cooling on Meteorlake
@ 2025-03-11 12:19 Gwara, Mateusz
  2025-03-13  5:29 ` Zhang, Rui
  0 siblings, 1 reply; 6+ messages in thread
From: Gwara, Mateusz @ 2025-03-11 12:19 UTC (permalink / raw)
  To: Gwara, Mateusz
  Cc: Wassenberg, Dennis, daniel.lezcano@linaro.org,
	linux-pm@vger.kernel.org, lukasz.luba@arm.com, rafael@kernel.org,
	rui.zhang@intel.com

Hi,

I wanted to make sure that there is no confusion because there seems to be two sets of drivers handling TCC.
As the workings of drivers/thermal/intel/int340x_thermal/int3403_thermal.c are visible in
/sys/bus/pci/devices/0000:00:04.0/tcc_offset_degree_celsius
and defined in drivers/thermal/intel/int340x_thermal/processor_thermal_device.c
do have a wrong offset, which does not take into account that Meteor Lake CPUs have a TJunction of 110°C instead of 100°C.

That's why I was wondering why the new definitions in
drivers/thermal/intel/intel_tcc_cooling.c
does not contain any Meteor Lake (or Arrow&Lunar Lake ) definitions.
Where the results should be visible in /sys/class/thermal as mentioned in the initial post.

Regards

MG

-- 
Mateusz Gwara
Senior Software Developer
Department Network & Client Security
Division Public Authorities
secunet Security Networks AG

Tel.: +49 201 54 54-2934
E-Mail: mateusz.gwara@secunet.com
Alt-Moabit 96, 10559 Berlin
www.secunet.com
______________________________________________________________________

secunet Security Networks AG
Sitz: Kurfürstenstraße 58, 45138 Essen, Deutschland
Amtsgericht Essen HRB 13615
Vorstand: Axel Deininger (Vors.), Torsten Henn, Dr. Kai Martius, Jessica Nospers
Aufsichtsratsvorsitzender: Dr. Ralf Wintergerst
______________________________________________________________________


^ permalink raw reply	[flat|nested] 6+ messages in thread
* Re: TCC cooling on Meteorlake
@ 2025-03-17 10:31 Gwara, Mateusz
  2025-03-24  0:17 ` Zhang, Rui
  0 siblings, 1 reply; 6+ messages in thread
From: Gwara, Mateusz @ 2025-03-17 10:31 UTC (permalink / raw)
  To: rui.zhang@intel.com
  Cc: 163ff391dc6d4f828ecff95e87f5003d@secunet.com,
	daniel.lezcano@linaro.org, Wassenberg, Dennis,
	linux-pm@vger.kernel.org, lukasz.luba@arm.com, Gwara, Mateusz,
	rafael@kernel.org, ricardo.neri@intel.com,
	srinivas.pandruvada@intel.com

> what do you see from
> /sys/bus/pci/devices/0000:00:04.0/tcc_offset_degree_celsius?

>It should return 0 if noone changes the offset.

The offset is set to 14°C on a Meteor Lake CPU.
This behavior applies to our custom kernel(based on vanilla 6.8) as well as the regular Ubuntu kernel builds (tested with 6.8 and 6.14)


> tcc offset is an offset to tjmax, no matter what the tjmax value is,
> right?

That's true.
We run our Raptor Lake devices with a TCC Offset of 3°C which is what is usually set for those and generations before on a regular Ubuntu for example.
This means we actively make sure this value is set to 3 as 0 would mean being too close to tjmax and risking an uncontrolled shutdown(i.e. actually reaching tjmax).
Having this value so close to tjmax allows to prevent premature thermal throttling.
So, the much higher default value for Meteor Lake TCC offset basically cancels out their higher temperature range.

> yeah. We should add this. Patch will be submitted soon.

Thanks in advance!

Mateusz


^ permalink raw reply	[flat|nested] 6+ messages in thread
* Re: TCC cooling on Meteorlake
@ 2025-03-26 17:46 Gwara, Mateusz
  0 siblings, 0 replies; 6+ messages in thread
From: Gwara, Mateusz @ 2025-03-26 17:46 UTC (permalink / raw)
  To: rui.zhang@intel.com
  Cc: 17a637f633a7560ca87d7461fc56632e5f9e41cc.camel@intel.com,
	daniel.lezcano@linaro.org, Wassenberg, Dennis,
	linux-pm@vger.kernel.org, lukasz.luba@arm.com, Gwara, Mateusz,
	rafael@kernel.org, ricardo.neri@intel.com,
	srinivas.pandruvada@intel.com

>> The offset is set to 14°C on a Meteor Lake CPU.

> do you know who sets it?

On most systems this value is being set in the BIOS by the OEM to match
the cooling system performance in which the CPU is used in.


>> We run our Raptor Lake devices with a TCC Offset of 3°C which is what
>> is usually set

> and who sets it?

This value is derived from what a OEM (in our case, Lenovo) sets in their BIOS,
but as we experienced problems that occur after thermal events or system suspend/recume cycles
we have our own service runnig on our custom linux based operating system
that makes sure the value is always set correctly.

> I have applied this patch on a couple of machines that I can access but
> unfortunately they all have TCC offset bit locked. So please check if
> it works as expected or not.

Will do gladly. Thanks for pointing this out. It's possible that other OEMs won't allow to change this value.

> And FYI, both intel_tcc_cooling and the proc_thermal
> "tcc_offset_degree_celsius" attribute are based on the same tcc
> helpers, so I don't think there is any difference between these two
> knobs.

That's true. I've seen that they point to the same address.

-- 
Mateusz Gwara
Senior Software Developer
Department Network & Client Security
Division Public Authorities
secunet Security Networks AG

Tel.: +49 201 54 54-2934
E-Mail: mateusz.gwara@secunet.com
Alt-Moabit 96, 10559 Berlin
www.secunet.com
______________________________________________________________________

secunet Security Networks AG
Sitz: Kurfürstenstraße 58, 45138 Essen, Deutschland
Amtsgericht Essen HRB 13615
Vorstand: Axel Deininger (Vors.), Torsten Henn, Dr. Kai Martius, Jessica Nospers
Aufsichtsratsvorsitzender: Dr. Ralf Wintergerst
______________________________________________________________________


^ permalink raw reply	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2025-03-26 17:46 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
     [not found] <f733005155e64d489ae18d7d357bada9@secunet.com>
2025-02-24 11:27 ` TCC cooling on Meteorlake Gwara, Mateusz
2025-03-11 12:19 Gwara, Mateusz
2025-03-13  5:29 ` Zhang, Rui
  -- strict thread matches above, loose matches on Subject: below --
2025-03-17 10:31 Gwara, Mateusz
2025-03-24  0:17 ` Zhang, Rui
2025-03-26 17:46 Gwara, Mateusz

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.