diff options
Diffstat (limited to 'drivers/acpi/thermal.c')
-rw-r--r-- | drivers/acpi/thermal.c | 30 |
1 files changed, 15 insertions, 15 deletions
diff --git a/drivers/acpi/thermal.c b/drivers/acpi/thermal.c index 5753d06b7860..4d75085ca2d2 100644 --- a/drivers/acpi/thermal.c +++ b/drivers/acpi/thermal.c | |||
@@ -663,7 +663,7 @@ static void acpi_thermal_run(unsigned long data) | |||
663 | static void acpi_thermal_check(void *data) | 663 | static void acpi_thermal_check(void *data) |
664 | { | 664 | { |
665 | int result = 0; | 665 | int result = 0; |
666 | struct acpi_thermal *tz = (struct acpi_thermal *)data; | 666 | struct acpi_thermal *tz = data; |
667 | unsigned long sleep_time = 0; | 667 | unsigned long sleep_time = 0; |
668 | int i = 0; | 668 | int i = 0; |
669 | struct acpi_thermal_state state; | 669 | struct acpi_thermal_state state; |
@@ -778,7 +778,7 @@ static struct proc_dir_entry *acpi_thermal_dir; | |||
778 | 778 | ||
779 | static int acpi_thermal_state_seq_show(struct seq_file *seq, void *offset) | 779 | static int acpi_thermal_state_seq_show(struct seq_file *seq, void *offset) |
780 | { | 780 | { |
781 | struct acpi_thermal *tz = (struct acpi_thermal *)seq->private; | 781 | struct acpi_thermal *tz = seq->private; |
782 | 782 | ||
783 | 783 | ||
784 | if (!tz) | 784 | if (!tz) |
@@ -813,7 +813,7 @@ static int acpi_thermal_state_open_fs(struct inode *inode, struct file *file) | |||
813 | static int acpi_thermal_temp_seq_show(struct seq_file *seq, void *offset) | 813 | static int acpi_thermal_temp_seq_show(struct seq_file *seq, void *offset) |
814 | { | 814 | { |
815 | int result = 0; | 815 | int result = 0; |
816 | struct acpi_thermal *tz = (struct acpi_thermal *)seq->private; | 816 | struct acpi_thermal *tz = seq->private; |
817 | 817 | ||
818 | 818 | ||
819 | if (!tz) | 819 | if (!tz) |
@@ -837,7 +837,7 @@ static int acpi_thermal_temp_open_fs(struct inode *inode, struct file *file) | |||
837 | 837 | ||
838 | static int acpi_thermal_trip_seq_show(struct seq_file *seq, void *offset) | 838 | static int acpi_thermal_trip_seq_show(struct seq_file *seq, void *offset) |
839 | { | 839 | { |
840 | struct acpi_thermal *tz = (struct acpi_thermal *)seq->private; | 840 | struct acpi_thermal *tz = seq->private; |
841 | int i = 0; | 841 | int i = 0; |
842 | int j = 0; | 842 | int j = 0; |
843 | 843 | ||
@@ -893,8 +893,8 @@ acpi_thermal_write_trip_points(struct file *file, | |||
893 | const char __user * buffer, | 893 | const char __user * buffer, |
894 | size_t count, loff_t * ppos) | 894 | size_t count, loff_t * ppos) |
895 | { | 895 | { |
896 | struct seq_file *m = (struct seq_file *)file->private_data; | 896 | struct seq_file *m = file->private_data; |
897 | struct acpi_thermal *tz = (struct acpi_thermal *)m->private; | 897 | struct acpi_thermal *tz = m->private; |
898 | 898 | ||
899 | char *limit_string; | 899 | char *limit_string; |
900 | int num, critical, hot, passive; | 900 | int num, critical, hot, passive; |
@@ -953,7 +953,7 @@ acpi_thermal_write_trip_points(struct file *file, | |||
953 | 953 | ||
954 | static int acpi_thermal_cooling_seq_show(struct seq_file *seq, void *offset) | 954 | static int acpi_thermal_cooling_seq_show(struct seq_file *seq, void *offset) |
955 | { | 955 | { |
956 | struct acpi_thermal *tz = (struct acpi_thermal *)seq->private; | 956 | struct acpi_thermal *tz = seq->private; |
957 | 957 | ||
958 | 958 | ||
959 | if (!tz) | 959 | if (!tz) |
@@ -984,8 +984,8 @@ acpi_thermal_write_cooling_mode(struct file *file, | |||
984 | const char __user * buffer, | 984 | const char __user * buffer, |
985 | size_t count, loff_t * ppos) | 985 | size_t count, loff_t * ppos) |
986 | { | 986 | { |
987 | struct seq_file *m = (struct seq_file *)file->private_data; | 987 | struct seq_file *m = file->private_data; |
988 | struct acpi_thermal *tz = (struct acpi_thermal *)m->private; | 988 | struct acpi_thermal *tz = m->private; |
989 | int result = 0; | 989 | int result = 0; |
990 | char mode_string[12] = { '\0' }; | 990 | char mode_string[12] = { '\0' }; |
991 | 991 | ||
@@ -1014,7 +1014,7 @@ acpi_thermal_write_cooling_mode(struct file *file, | |||
1014 | 1014 | ||
1015 | static int acpi_thermal_polling_seq_show(struct seq_file *seq, void *offset) | 1015 | static int acpi_thermal_polling_seq_show(struct seq_file *seq, void *offset) |
1016 | { | 1016 | { |
1017 | struct acpi_thermal *tz = (struct acpi_thermal *)seq->private; | 1017 | struct acpi_thermal *tz = seq->private; |
1018 | 1018 | ||
1019 | 1019 | ||
1020 | if (!tz) | 1020 | if (!tz) |
@@ -1043,8 +1043,8 @@ acpi_thermal_write_polling(struct file *file, | |||
1043 | const char __user * buffer, | 1043 | const char __user * buffer, |
1044 | size_t count, loff_t * ppos) | 1044 | size_t count, loff_t * ppos) |
1045 | { | 1045 | { |
1046 | struct seq_file *m = (struct seq_file *)file->private_data; | 1046 | struct seq_file *m = file->private_data; |
1047 | struct acpi_thermal *tz = (struct acpi_thermal *)m->private; | 1047 | struct acpi_thermal *tz = m->private; |
1048 | int result = 0; | 1048 | int result = 0; |
1049 | char polling_string[12] = { '\0' }; | 1049 | char polling_string[12] = { '\0' }; |
1050 | int seconds = 0; | 1050 | int seconds = 0; |
@@ -1170,7 +1170,7 @@ static int acpi_thermal_remove_fs(struct acpi_device *device) | |||
1170 | 1170 | ||
1171 | static void acpi_thermal_notify(acpi_handle handle, u32 event, void *data) | 1171 | static void acpi_thermal_notify(acpi_handle handle, u32 event, void *data) |
1172 | { | 1172 | { |
1173 | struct acpi_thermal *tz = (struct acpi_thermal *)data; | 1173 | struct acpi_thermal *tz = data; |
1174 | struct acpi_device *device = NULL; | 1174 | struct acpi_device *device = NULL; |
1175 | 1175 | ||
1176 | 1176 | ||
@@ -1324,7 +1324,7 @@ static int acpi_thermal_remove(struct acpi_device *device, int type) | |||
1324 | if (!device || !acpi_driver_data(device)) | 1324 | if (!device || !acpi_driver_data(device)) |
1325 | return -EINVAL; | 1325 | return -EINVAL; |
1326 | 1326 | ||
1327 | tz = (struct acpi_thermal *)acpi_driver_data(device); | 1327 | tz = acpi_driver_data(device); |
1328 | 1328 | ||
1329 | /* avoid timer adding new defer task */ | 1329 | /* avoid timer adding new defer task */ |
1330 | tz->zombie = 1; | 1330 | tz->zombie = 1; |
@@ -1364,7 +1364,7 @@ static int acpi_thermal_resume(struct acpi_device *device, int state) | |||
1364 | if (!device || !acpi_driver_data(device)) | 1364 | if (!device || !acpi_driver_data(device)) |
1365 | return -EINVAL; | 1365 | return -EINVAL; |
1366 | 1366 | ||
1367 | tz = (struct acpi_thermal *)acpi_driver_data(device); | 1367 | tz = acpi_driver_data(device); |
1368 | 1368 | ||
1369 | acpi_thermal_get_temperature(tz); | 1369 | acpi_thermal_get_temperature(tz); |
1370 | 1370 | ||