diff mbox

Thermal: thermal API cleanup

Message ID 1366211920.2091.55.camel@rzhang1-mobl4 (mailing list archive)
State Accepted, archived
Delegated to: Zhang Rui
Headers show

Commit Message

Zhang, Rui April 17, 2013, 3:18 p.m. UTC
From d6db6ba9831d07338e11d4821febec4ef3cdf8f6 Mon Sep 17 00:00:00 2001
From: Zhang Rui <rui.zhang@intel.com>
Date: Wed, 17 Apr 2013 23:12:40 +0800
Subject: [PATCH] Thermal: thermal API cleanup

We build all the thermal governors into thermal module,
thus a couple of APIs should be cleaned up as they are used
by thermal governors only.

Cleanup for get_tz_trend(), get_thermal_instance(),
and thermal_cdev_update(), in this patch.

Signed-off-by: Zhang Rui <rui.zhang@intel.com>
---
 Documentation/thermal/sysfs-api.txt |   19 +------------------
 drivers/thermal/thermal_core.c      |    3 ---
 drivers/thermal/thermal_core.h      |    5 +++++
 include/linux/thermal.h             |    4 ----
 4 files changed, 6 insertions(+), 25 deletions(-)

Comments

durgadoss.r@intel.com April 17, 2013, 4:17 p.m. UTC | #1
PiAtLS0tLU9yaWdpbmFsIE1lc3NhZ2UtLS0tLQ0KPiBGcm9tOiBsaW51eC1wbS1vd25lckB2Z2Vy
Lmtlcm5lbC5vcmcgW21haWx0bzpsaW51eC1wbS0NCj4gb3duZXJAdmdlci5rZXJuZWwub3JnXSBP
biBCZWhhbGYgT2YgWmhhbmcgUnVpDQo+IFNlbnQ6IFdlZG5lc2RheSwgQXByaWwgMTcsIDIwMTMg
ODo0OSBQTQ0KPiBUbzogTGludXggUE0gbGlzdA0KPiBDYzogZWR1YXJkbzsgWmhhbmcsIFJ1aQ0K
PiBTdWJqZWN0OiBbUEFUQ0hdIFRoZXJtYWw6IHRoZXJtYWwgQVBJIGNsZWFudXANCj4gDQo+IEZy
b20gZDZkYjZiYTk4MzFkMDczMzhlMTFkNDgyMWZlYmVjNGVmM2NkZjhmNiBNb24gU2VwIDE3IDAw
OjAwOjAwDQo+IDIwMDENCj4gRnJvbTogWmhhbmcgUnVpIDxydWk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7DQo+IC1zdHJ1Y3QgdGhlcm1h
bF9pbnN0YW5jZSAqZ2V0X3RoZXJtYWxfaW5zdGFuY2Uoc3RydWN0DQo+IHRoZXJtYWxfem9uZV9k
ZXZpY2UgKiwNCj4gLQkJc3RydWN0IHRoZXJtYWxfY29vbGluZ19kZXZpY2UgKiwgaW50KTsNCj4g
LXZvaWQgdGhlcm1hbF9jZGV2X3VwZGF0ZShzdHJ1Y3QgdGhlcm1hbF9jb29saW5nX2RldmljZSAq
KTsNCj4gIHZvaWQgbm90aWZ5X3RoZXJtYWxfZnJhbWV3b3JrKHN0cnVjdCB0aGVybWFsX3pvbmVf
ZGV2aWNlICosIGludCk7DQo+IA0KPiAgI2lmZGVmIENPTkZJR19ORVQNCj4gLS0NCj4gMS43Ljku
NQ0KPiANCj4gDQo+IA0KPiAtLQ0KPiBUbyB1bnN1YnNjcmliZSBmcm9tIHRoaXMgbGlzdDogc2Vu
ZCB0aGUgbGluZSAidW5zdWJzY3JpYmUgbGludXgtcG0iIGluDQo+IHRoZSBib2R5IG9mIGEgbWVz
c2FnZSB0byBtYWpvcmRvbW9Admdlci5rZXJuZWwub3JnDQo+IE1vcmUgbWFqb3Jkb21vIGluZm8g
YXQgIGh0dHA6Ly92Z2VyLmtlcm5lbC5vcmcvbWFqb3Jkb21vLWluZm8uaHRtbA0K
--
To unsubscribe from this list: send the line "unsubscribe linux-pm" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Eduardo Valentin April 17, 2013, 5:13 p.m. UTC | #2
Rui,

On 17-04-2013 11:18, Zhang Rui wrote:
>>From d6db6ba9831d07338e11d4821febec4ef3cdf8f6 Mon Sep 17 00:00:00 2001
> From: Zhang Rui <rui.zhang@intel.com>
> Date: Wed, 17 Apr 2013 23:12:40 +0800
> Subject: [PATCH] Thermal: thermal API cleanup
>
> We build all the thermal governors into thermal module,
> thus a couple of APIs should be cleaned up as they are used
> by thermal governors only.
>
> Cleanup for get_tz_trend(), get_thermal_instance(),
> and thermal_cdev_update(), in this patch.
>
> Signed-off-by: Zhang Rui <rui.zhang@intel.com>

Acked-by: Eduardo Valentin <eduardo.valentin@ti.com>

> ---
>   Documentation/thermal/sysfs-api.txt |   19 +------------------
>   drivers/thermal/thermal_core.c      |    3 ---
>   drivers/thermal/thermal_core.h      |    5 +++++
>   include/linux/thermal.h             |    4 ----
>   4 files changed, 6 insertions(+), 25 deletions(-)
>
> diff --git a/Documentation/thermal/sysfs-api.txt b/Documentation/thermal/sysfs-api.txt
> index b2ffe98..4dcc4c7 100644
> --- a/Documentation/thermal/sysfs-api.txt
> +++ b/Documentation/thermal/sysfs-api.txt
> @@ -355,27 +355,10 @@ crosses any of the configured thresholds.
>
>   5. Export Symbol APIs:
>
> -5.1: get_tz_trend:
> -This function returns the trend of a thermal zone, i.e the rate of change
> -of temperature of the thermal zone. Ideally, the thermal sensor drivers
> -are supposed to implement the callback. If they don't, the thermal
> -framework calculated the trend by comparing the previous and the current
> -temperature values.
> -
> -5.2:get_thermal_instance:
> -This function returns the thermal_instance corresponding to a given
> -{thermal_zone, cooling_device, trip_point} combination. Returns NULL
> -if such an instance does not exist.
> -
> -5.3:notify_thermal_framework:
> +5.1:notify_thermal_framework:
>   This function handles the trip events from sensor drivers. It starts
>   throttling the cooling devices according to the policy configured.
>   For CRITICAL and HOT trip points, this notifies the respective drivers,
>   and does actual throttling for other trip points i.e ACTIVE and PASSIVE.
>   The throttling policy is based on the configured platform data; if no
>   platform data is provided, this uses the step_wise throttling policy.
> -
> -5.4:thermal_cdev_update:
> -This function serves as an arbitrator to set the state of a cooling
> -device. It sets the cooling device to the deepest cooling state if
> -possible.
> diff --git a/drivers/thermal/thermal_core.c b/drivers/thermal/thermal_core.c
> index 4cdc3e3..ac380fc 100644
> --- a/drivers/thermal/thermal_core.c
> +++ b/drivers/thermal/thermal_core.c
> @@ -166,7 +166,6 @@ int get_tz_trend(struct thermal_zone_device *tz, int trip)
>
>   	return trend;
>   }
> -EXPORT_SYMBOL(get_tz_trend);
>
>   struct thermal_instance *get_thermal_instance(struct thermal_zone_device *tz,
>   			struct thermal_cooling_device *cdev, int trip)
> @@ -189,7 +188,6 @@ struct thermal_instance *get_thermal_instance(struct thermal_zone_device *tz,
>
>   	return target_instance;
>   }
> -EXPORT_SYMBOL(get_thermal_instance);
>
>   static void print_bind_err_msg(struct thermal_zone_device *tz,
>   			struct thermal_cooling_device *cdev, int ret)
> @@ -1415,7 +1413,6 @@ void thermal_cdev_update(struct thermal_cooling_device *cdev)
>   	cdev->ops->set_cur_state(cdev, target);
>   	cdev->updated = true;
>   }
> -EXPORT_SYMBOL(thermal_cdev_update);
>
>   /**
>    * notify_thermal_framework - Sensor drivers use this API to notify framework
> diff --git a/drivers/thermal/thermal_core.h b/drivers/thermal/thermal_core.h
> index 7cf2f66..0bb98d2 100644
> --- a/drivers/thermal/thermal_core.h
> +++ b/drivers/thermal/thermal_core.h
> @@ -50,6 +50,11 @@ struct thermal_instance {
>   	struct list_head cdev_node; /* node in cdev->thermal_instances */
>   };
>
> +int get_tz_trend(struct thermal_zone_device *, int);
> +struct thermal_instance *get_thermal_instance(struct thermal_zone_device *,
> +                struct thermal_cooling_device *, int);
> +void thermal_cdev_update(struct thermal_cooling_device *);
> +
>   int thermal_register_governor(struct thermal_governor *);
>   void thermal_unregister_governor(struct thermal_governor *);
>
> diff --git a/include/linux/thermal.h b/include/linux/thermal.h
> index 4445b95..097e674 100644
> --- a/include/linux/thermal.h
> +++ b/include/linux/thermal.h
> @@ -240,10 +240,6 @@ struct thermal_cooling_device *thermal_cooling_device_register(char *, void *,
>   		const struct thermal_cooling_device_ops *);
>   void thermal_cooling_device_unregister(struct thermal_cooling_device *);
>
> -int get_tz_trend(struct thermal_zone_device *, int);
> -struct thermal_instance *get_thermal_instance(struct thermal_zone_device *,
> -		struct thermal_cooling_device *, int);
> -void thermal_cdev_update(struct thermal_cooling_device *);
>   void notify_thermal_framework(struct thermal_zone_device *, int);
>
>   #ifdef CONFIG_NET
>

--
To unsubscribe from this list: send the line "unsubscribe linux-pm" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
diff mbox

Patch

diff --git a/Documentation/thermal/sysfs-api.txt b/Documentation/thermal/sysfs-api.txt
index b2ffe98..4dcc4c7 100644
--- a/Documentation/thermal/sysfs-api.txt
+++ b/Documentation/thermal/sysfs-api.txt
@@ -355,27 +355,10 @@  crosses any of the configured thresholds.
 
 5. Export Symbol APIs:
 
-5.1: get_tz_trend:
-This function returns the trend of a thermal zone, i.e the rate of change
-of temperature of the thermal zone. Ideally, the thermal sensor drivers
-are supposed to implement the callback. If they don't, the thermal
-framework calculated the trend by comparing the previous and the current
-temperature values.
-
-5.2:get_thermal_instance:
-This function returns the thermal_instance corresponding to a given
-{thermal_zone, cooling_device, trip_point} combination. Returns NULL
-if such an instance does not exist.
-
-5.3:notify_thermal_framework:
+5.1:notify_thermal_framework:
 This function handles the trip events from sensor drivers. It starts
 throttling the cooling devices according to the policy configured.
 For CRITICAL and HOT trip points, this notifies the respective drivers,
 and does actual throttling for other trip points i.e ACTIVE and PASSIVE.
 The throttling policy is based on the configured platform data; if no
 platform data is provided, this uses the step_wise throttling policy.
-
-5.4:thermal_cdev_update:
-This function serves as an arbitrator to set the state of a cooling
-device. It sets the cooling device to the deepest cooling state if
-possible.
diff --git a/drivers/thermal/thermal_core.c b/drivers/thermal/thermal_core.c
index 4cdc3e3..ac380fc 100644
--- a/drivers/thermal/thermal_core.c
+++ b/drivers/thermal/thermal_core.c
@@ -166,7 +166,6 @@  int get_tz_trend(struct thermal_zone_device *tz, int trip)
 
 	return trend;
 }
-EXPORT_SYMBOL(get_tz_trend);
 
 struct thermal_instance *get_thermal_instance(struct thermal_zone_device *tz,
 			struct thermal_cooling_device *cdev, int trip)
@@ -189,7 +188,6 @@  struct thermal_instance *get_thermal_instance(struct thermal_zone_device *tz,
 
 	return target_instance;
 }
-EXPORT_SYMBOL(get_thermal_instance);
 
 static void print_bind_err_msg(struct thermal_zone_device *tz,
 			struct thermal_cooling_device *cdev, int ret)
@@ -1415,7 +1413,6 @@  void thermal_cdev_update(struct thermal_cooling_device *cdev)
 	cdev->ops->set_cur_state(cdev, target);
 	cdev->updated = true;
 }
-EXPORT_SYMBOL(thermal_cdev_update);
 
 /**
  * notify_thermal_framework - Sensor drivers use this API to notify framework
diff --git a/drivers/thermal/thermal_core.h b/drivers/thermal/thermal_core.h
index 7cf2f66..0bb98d2 100644
--- a/drivers/thermal/thermal_core.h
+++ b/drivers/thermal/thermal_core.h
@@ -50,6 +50,11 @@  struct thermal_instance {
 	struct list_head cdev_node; /* node in cdev->thermal_instances */
 };
 
+int get_tz_trend(struct thermal_zone_device *, int);
+struct thermal_instance *get_thermal_instance(struct thermal_zone_device *,
+                struct thermal_cooling_device *, int);
+void thermal_cdev_update(struct thermal_cooling_device *);
+
 int thermal_register_governor(struct thermal_governor *);
 void thermal_unregister_governor(struct thermal_governor *);
 
diff --git a/include/linux/thermal.h b/include/linux/thermal.h
index 4445b95..097e674 100644
--- a/include/linux/thermal.h
+++ b/include/linux/thermal.h
@@ -240,10 +240,6 @@  struct thermal_cooling_device *thermal_cooling_device_register(char *, void *,
 		const struct thermal_cooling_device_ops *);
 void thermal_cooling_device_unregister(struct thermal_cooling_device *);
 
-int get_tz_trend(struct thermal_zone_device *, int);
-struct thermal_instance *get_thermal_instance(struct thermal_zone_device *,
-		struct thermal_cooling_device *, int);
-void thermal_cdev_update(struct thermal_cooling_device *);
 void notify_thermal_framework(struct thermal_zone_device *, int);
 
 #ifdef CONFIG_NET