linux-pm.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH v1] thermal: intel: int340x_thermal: Use thermal zone accessor functions
@ 2024-03-05 11:32 Rafael J. Wysocki
  2024-03-05 14:58 ` srinivas pandruvada
  0 siblings, 1 reply; 2+ messages in thread
From: Rafael J. Wysocki @ 2024-03-05 11:32 UTC (permalink / raw)
  To: Linux PM
  Cc: LKML, Rafael J. Wysocki, Lukasz Luba, Daniel Lezcano, Zhang Rui,
	Srinivas Pandruvada, Stanislaw Gruszka

From: Rafael J. Wysocki <rafael.j.wysocki@intel.com>

Make int340x_thermal use the dedicated accessor functions for the
thermal zone device object address and the thermal zone type string.

This is requisite for future thermal core improvements.

Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
---
 drivers/thermal/intel/int340x_thermal/int340x_thermal_zone.c |    3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

Index: linux-pm/drivers/thermal/intel/int340x_thermal/int340x_thermal_zone.c
===================================================================
--- linux-pm.orig/drivers/thermal/intel/int340x_thermal/int340x_thermal_zone.c
+++ linux-pm/drivers/thermal/intel/int340x_thermal/int340x_thermal_zone.c
@@ -58,7 +58,8 @@ static int int340x_thermal_set_trip_temp
 
 static void int340x_thermal_critical(struct thermal_zone_device *zone)
 {
-	dev_dbg(&zone->device, "%s: critical temperature reached\n", zone->type);
+	dev_dbg(thermal_zone_device(zone), "%s: critical temperature reached\n",
+		thermal_zone_device_type(zone));
 }
 
 static inline void *int_to_trip_priv(int i)




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

* Re: [PATCH v1] thermal: intel: int340x_thermal: Use thermal zone accessor functions
  2024-03-05 11:32 [PATCH v1] thermal: intel: int340x_thermal: Use thermal zone accessor functions Rafael J. Wysocki
@ 2024-03-05 14:58 ` srinivas pandruvada
  0 siblings, 0 replies; 2+ messages in thread
From: srinivas pandruvada @ 2024-03-05 14:58 UTC (permalink / raw)
  To: Rafael J. Wysocki, Linux PM
  Cc: LKML, Rafael J. Wysocki, Lukasz Luba, Daniel Lezcano, Zhang Rui,
	Stanislaw Gruszka

On Tue, 2024-03-05 at 12:32 +0100, Rafael J. Wysocki wrote:
> From: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
> 
> Make int340x_thermal use the dedicated accessor functions for the
> thermal zone device object address and the thermal zone type string.
> 
> This is requisite for future thermal core improvements.
> 
> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
 Reviewed-by: Srinivas Pandruvada <srinivas.pandruvada@linux.intel.com>

> ---
>  drivers/thermal/intel/int340x_thermal/int340x_thermal_zone.c |    3
> ++-
>  1 file changed, 2 insertions(+), 1 deletion(-)
> 
> Index: linux-
> pm/drivers/thermal/intel/int340x_thermal/int340x_thermal_zone.c
> ===================================================================
> --- linux-
> pm.orig/drivers/thermal/intel/int340x_thermal/int340x_thermal_zone.c
> +++ linux-
> pm/drivers/thermal/intel/int340x_thermal/int340x_thermal_zone.c
> @@ -58,7 +58,8 @@ static int int340x_thermal_set_trip_temp
>  
>  static void int340x_thermal_critical(struct thermal_zone_device
> *zone)
>  {
> -       dev_dbg(&zone->device, "%s: critical temperature reached\n",
> zone->type);
> +       dev_dbg(thermal_zone_device(zone), "%s: critical temperature
> reached\n",
> +               thermal_zone_device_type(zone));
>  }
>  
>  static inline void *int_to_trip_priv(int i)
> 
> 
> 


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

end of thread, other threads:[~2024-03-05 14:58 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2024-03-05 11:32 [PATCH v1] thermal: intel: int340x_thermal: Use thermal zone accessor functions Rafael J. Wysocki
2024-03-05 14:58 ` srinivas pandruvada

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).