Linux Kernel  3.7.1
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Groups Pages
Data Structures | Macros | Functions
thermal.c File Reference
#include <linux/kernel.h>
#include <linux/module.h>
#include <linux/dmi.h>
#include <linux/init.h>
#include <linux/slab.h>
#include <linux/types.h>
#include <linux/jiffies.h>
#include <linux/kmod.h>
#include <linux/reboot.h>
#include <linux/device.h>
#include <asm/uaccess.h>
#include <linux/thermal.h>
#include <acpi/acpi_bus.h>
#include <acpi/acpi_drivers.h>

Go to the source code of this file.

Data Structures

struct  acpi_thermal_state
 
struct  acpi_thermal_state_flags
 
struct  acpi_thermal_critical
 
struct  acpi_thermal_hot
 
struct  acpi_thermal_passive
 
struct  acpi_thermal_active
 
struct  acpi_thermal_trips
 
struct  acpi_thermal_flags
 
struct  acpi_thermal
 

Macros

#define PREFIX   "ACPI: "
 
#define ACPI_THERMAL_CLASS   "thermal_zone"
 
#define ACPI_THERMAL_DEVICE_NAME   "Thermal Zone"
 
#define ACPI_THERMAL_FILE_STATE   "state"
 
#define ACPI_THERMAL_FILE_TEMPERATURE   "temperature"
 
#define ACPI_THERMAL_FILE_TRIP_POINTS   "trip_points"
 
#define ACPI_THERMAL_FILE_COOLING_MODE   "cooling_mode"
 
#define ACPI_THERMAL_FILE_POLLING_FREQ   "polling_frequency"
 
#define ACPI_THERMAL_NOTIFY_TEMPERATURE   0x80
 
#define ACPI_THERMAL_NOTIFY_THRESHOLDS   0x81
 
#define ACPI_THERMAL_NOTIFY_DEVICES   0x82
 
#define ACPI_THERMAL_NOTIFY_CRITICAL   0xF0
 
#define ACPI_THERMAL_NOTIFY_HOT   0xF1
 
#define ACPI_THERMAL_MODE_ACTIVE   0x00
 
#define ACPI_THERMAL_MAX_ACTIVE   10
 
#define ACPI_THERMAL_MAX_LIMIT_STR_LEN   65
 
#define _COMPONENT   ACPI_THERMAL_COMPONENT
 
#define ACPI_TRIPS_CRITICAL   0x01
 
#define ACPI_TRIPS_HOT   0x02
 
#define ACPI_TRIPS_PASSIVE   0x04
 
#define ACPI_TRIPS_ACTIVE   0x08
 
#define ACPI_TRIPS_DEVICES   0x10
 
#define ACPI_TRIPS_REFRESH_THRESHOLDS   (ACPI_TRIPS_PASSIVE | ACPI_TRIPS_ACTIVE)
 
#define ACPI_TRIPS_REFRESH_DEVICES   ACPI_TRIPS_DEVICES
 
#define ACPI_TRIPS_INIT
 
#define ACPI_THERMAL_TRIPS_EXCEPTION(flags, str)
 
#define KELVIN_TO_MILLICELSIUS(t, off)   (((t) - (off)) * 100)
 

Functions

 ACPI_MODULE_NAME ("thermal")
 
 MODULE_AUTHOR ("Paul Diefenbaugh")
 
 MODULE_DESCRIPTION ("ACPI Thermal Zone Driver")
 
 MODULE_LICENSE ("GPL")
 
 module_param (act, int, 0644)
 
 MODULE_PARM_DESC (act,"Disable or override all lowest active trip points.")
 
 module_param (crt, int, 0644)
 
 MODULE_PARM_DESC (crt,"Disable or lower all critical trip points.")
 
 module_param (tzp, int, 0444)
 
 MODULE_PARM_DESC (tzp,"Thermal zone polling frequency, in 1/10 seconds.")
 
 module_param (nocrt, int, 0)
 
 MODULE_PARM_DESC (nocrt,"Set to take no action upon ACPI thermal zone critical trips points.")
 
 module_param (off, int, 0)
 
 MODULE_PARM_DESC (off,"Set to disable ACPI thermal support.")
 
 module_param (psv, int, 0644)
 
 MODULE_PARM_DESC (psv,"Disable or override all passive trip points.")
 
 MODULE_DEVICE_TABLE (acpi, thermal_device_ids)
 
 module_init (acpi_thermal_init)
 
 module_exit (acpi_thermal_exit)
 

Macro Definition Documentation

#define _COMPONENT   ACPI_THERMAL_COMPONENT

Definition at line 68 of file thermal.c.

#define ACPI_THERMAL_CLASS   "thermal_zone"

Definition at line 51 of file thermal.c.

#define ACPI_THERMAL_DEVICE_NAME   "Thermal Zone"

Definition at line 52 of file thermal.c.

#define ACPI_THERMAL_FILE_COOLING_MODE   "cooling_mode"

Definition at line 56 of file thermal.c.

#define ACPI_THERMAL_FILE_POLLING_FREQ   "polling_frequency"

Definition at line 57 of file thermal.c.

#define ACPI_THERMAL_FILE_STATE   "state"

Definition at line 53 of file thermal.c.

#define ACPI_THERMAL_FILE_TEMPERATURE   "temperature"

Definition at line 54 of file thermal.c.

#define ACPI_THERMAL_FILE_TRIP_POINTS   "trip_points"

Definition at line 55 of file thermal.c.

#define ACPI_THERMAL_MAX_ACTIVE   10

Definition at line 65 of file thermal.c.

#define ACPI_THERMAL_MAX_LIMIT_STR_LEN   65

Definition at line 66 of file thermal.c.

#define ACPI_THERMAL_MODE_ACTIVE   0x00

Definition at line 63 of file thermal.c.

#define ACPI_THERMAL_NOTIFY_CRITICAL   0xF0

Definition at line 61 of file thermal.c.

#define ACPI_THERMAL_NOTIFY_DEVICES   0x82

Definition at line 60 of file thermal.c.

#define ACPI_THERMAL_NOTIFY_HOT   0xF1

Definition at line 62 of file thermal.c.

#define ACPI_THERMAL_NOTIFY_TEMPERATURE   0x80

Definition at line 58 of file thermal.c.

#define ACPI_THERMAL_NOTIFY_THRESHOLDS   0x81

Definition at line 59 of file thermal.c.

#define ACPI_THERMAL_TRIPS_EXCEPTION (   flags,
  str 
)
Value:
do { \
ACPI_EXCEPTION((AE_INFO, AE_ERROR, \
"ACPI thermal trip point %s changed\n" \
"Please send acpidump to [email protected]\n", str)); \
} while (0)

Definition at line 286 of file thermal.c.

#define ACPI_TRIPS_ACTIVE   0x08

Definition at line 269 of file thermal.c.

#define ACPI_TRIPS_CRITICAL   0x01

Definition at line 266 of file thermal.c.

#define ACPI_TRIPS_DEVICES   0x10

Definition at line 270 of file thermal.c.

#define ACPI_TRIPS_HOT   0x02

Definition at line 267 of file thermal.c.

#define ACPI_TRIPS_INIT
Value:
ACPI_TRIPS_PASSIVE | ACPI_TRIPS_ACTIVE | \
ACPI_TRIPS_DEVICES)

Definition at line 275 of file thermal.c.

#define ACPI_TRIPS_PASSIVE   0x04

Definition at line 268 of file thermal.c.

#define ACPI_TRIPS_REFRESH_DEVICES   ACPI_TRIPS_DEVICES

Definition at line 273 of file thermal.c.

#define ACPI_TRIPS_REFRESH_THRESHOLDS   (ACPI_TRIPS_PASSIVE | ACPI_TRIPS_ACTIVE)

Definition at line 272 of file thermal.c.

#define KELVIN_TO_MILLICELSIUS (   t,
  off 
)    (((t) - (off)) * 100)

Definition at line 538 of file thermal.c.

#define PREFIX   "ACPI: "

Definition at line 49 of file thermal.c.

Function Documentation

ACPI_MODULE_NAME ( "thermal"  )
MODULE_AUTHOR ( "Paul Diefenbaugh"  )
MODULE_DESCRIPTION ( "ACPI Thermal Zone Driver"  )
MODULE_DEVICE_TABLE ( acpi  ,
thermal_device_ids   
)
module_exit ( acpi_thermal_exit  )
module_init ( acpi_thermal_init  )
MODULE_LICENSE ( "GPL"  )
module_param ( act  ,
int  ,
0644   
)
module_param ( crt  ,
int  ,
0644   
)
module_param ( tzp  ,
int  ,
0444   
)
module_param ( nocrt  ,
int  ,
 
)
module_param ( off  ,
int  ,
 
)
module_param ( psv  ,
int  ,
0644   
)
MODULE_PARM_DESC ( act  ,
"Disable or override all lowest active trip points."   
)
MODULE_PARM_DESC ( crt  ,
"Disable or lower all critical trip points."   
)
MODULE_PARM_DESC ( tzp  ,
"Thermal zone polling  frequency,
in 1/10 seconds."   
)
MODULE_PARM_DESC ( nocrt  ,
"Set to take no action upon ACPI thermal zone critical trips points."   
)
MODULE_PARM_DESC ( off  ,
"Set to disable ACPI thermal support."   
)
MODULE_PARM_DESC ( psv  ,
"Disable or override all passive trip points."   
)