blob: c065c90662d8d81443b9b14bd142605a48fe0daf
1 | /* |
2 | * amlogic_thermal.c - Samsung amlogic thermal (Thermal Management Unit) |
3 | * |
4 | * Copyright (C) 2011 Samsung Electronics |
5 | * Donggeun Kim <dg77.kim@samsung.com> |
6 | * Amit Daniel Kachhap <amit.kachhap@linaro.org> |
7 | * |
8 | * This program is free software; you can redistribute it and/or modify |
9 | * it under the terms of the GNU General Public License as published by |
10 | * the Free Software Foundation; either version 2 of the License, or |
11 | * (at your option) any later version. |
12 | * |
13 | * This program is distributed in the hope that it will be useful, |
14 | * but WITHOUT ANY WARRANTY; without even the implied warranty of |
15 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
16 | * GNU General Public License for more details. |
17 | * |
18 | * You should have received a copy of the GNU General Public License |
19 | * along with this program; if not, write to the Free Software |
20 | * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA |
21 | * |
22 | */ |
23 | |
24 | #include <linux/module.h> |
25 | #include <linux/err.h> |
26 | #include <linux/kernel.h> |
27 | #include <linux/slab.h> |
28 | #include <linux/platform_device.h> |
29 | #include <linux/interrupt.h> |
30 | #include <linux/clk.h> |
31 | #include <linux/workqueue.h> |
32 | #include <linux/sysfs.h> |
33 | #include <linux/kobject.h> |
34 | #include <linux/io.h> |
35 | #include <linux/mutex.h> |
36 | #include <linux/thermal.h> |
37 | #include <linux/cpufreq.h> |
38 | #include <linux/cpu_cooling.h> |
39 | #include <linux/of.h> |
40 | #include <linux/amlogic/saradc.h> |
41 | #include <plat/cpu.h> |
42 | #include <linux/random.h> |
43 | #include <linux/gpu_cooling.h> |
44 | #include <linux/cpucore_cooling.h> |
45 | #include <linux/gpucore_cooling.h> |
46 | #include <linux/thermal_core.h> |
47 | #include <mach/thermal.h> |
48 | extern struct platform_driver amlogic_thermal_driver; |
49 | |
50 | static int __init amlogic_thermal_driver_init(void) |
51 | { |
52 | return platform_driver_register(&(amlogic_thermal_driver)); |
53 | } |
54 | late_initcall(amlogic_thermal_driver_init); |
55 | static void __exit amlogic_thermal_driver_exit(void) |
56 | { |
57 | platform_driver_unregister(&(amlogic_thermal_driver) ); |
58 | } |
59 | module_exit(amlogic_thermal_driver_exit); |
60 | |
61 | MODULE_DESCRIPTION("amlogic thermal Driver"); |
62 | MODULE_AUTHOR("Amlogic SH platform team"); |
63 | MODULE_ALIAS("platform:amlogic-thermal"); |
64 | MODULE_LICENSE("GPL"); |
65 | |
66 |