Commit 9f86f28d authored by Roberto De Ioris's avatar Roberto De Ioris Committed by Linus Torvalds

applesmc: support for Intel iMac

This adds support for fans and temperature sensors on intel iMac.

Tested on iMac 24" 2.8ghz (iMac8,1), it supports the following sensors:

cpu A
ambient
gpu
gpu diode
gpu heatsink
hd bay 1
memory controller
optical drive
power
Signed-off-by: default avatarRoberto De Ioris <roberto@unbit.it>
Cc: Nicolas Boichat <nicolas@boichat.ch>
Cc: Jean Delvare <khali@linux-fr.org>
Cc: Mark M. Hoffman <mhoffman@lightlink.com>
Signed-off-by: default avatarAndrew Morton <akpm@linux-foundation.org>
Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
parent fdfaa483
...@@ -98,6 +98,9 @@ static const char* temperature_sensors_sets[][36] = { ...@@ -98,6 +98,9 @@ static const char* temperature_sensors_sets[][36] = {
"TH1P", "TH2P", "TH3P", "TMAP", "TMAS", "TMBS", "TM0P", "TM0S", "TH1P", "TH2P", "TH3P", "TMAP", "TMAS", "TMBS", "TM0P", "TM0S",
"TM1P", "TM1S", "TM2P", "TM2S", "TM3S", "TM8P", "TM8S", "TM9P", "TM1P", "TM1S", "TM2P", "TM2S", "TM3S", "TM8P", "TM8S", "TM9P",
"TM9S", "TN0H", "TS0C", NULL }, "TM9S", "TN0H", "TS0C", NULL },
/* Set 5: iMac */
{ "TC0D", "TA0P", "TG0P", "TG0D", "TG0H", "TH0P", "Tm0P", "TO0P",
"Tp0C", NULL },
}; };
/* List of keys used to read/write fan speeds */ /* List of keys used to read/write fan speeds */
...@@ -1223,6 +1226,8 @@ static __initdata struct dmi_match_data applesmc_dmi_data[] = { ...@@ -1223,6 +1226,8 @@ static __initdata struct dmi_match_data applesmc_dmi_data[] = {
{ .accelerometer = 0, .light = 0, .temperature_set = 3 }, { .accelerometer = 0, .light = 0, .temperature_set = 3 },
/* MacPro: temperature set 4 */ /* MacPro: temperature set 4 */
{ .accelerometer = 0, .light = 0, .temperature_set = 4 }, { .accelerometer = 0, .light = 0, .temperature_set = 4 },
/* iMac: temperature set 5 */
{ .accelerometer = 0, .light = 0, .temperature_set = 5 },
}; };
/* Note that DMI_MATCH(...,"MacBook") will match "MacBookPro1,1". /* Note that DMI_MATCH(...,"MacBook") will match "MacBookPro1,1".
...@@ -1248,6 +1253,10 @@ static __initdata struct dmi_system_id applesmc_whitelist[] = { ...@@ -1248,6 +1253,10 @@ static __initdata struct dmi_system_id applesmc_whitelist[] = {
DMI_MATCH(DMI_BOARD_VENDOR,"Apple"), DMI_MATCH(DMI_BOARD_VENDOR,"Apple"),
DMI_MATCH(DMI_PRODUCT_NAME,"MacPro2") }, DMI_MATCH(DMI_PRODUCT_NAME,"MacPro2") },
(void*)&applesmc_dmi_data[4]}, (void*)&applesmc_dmi_data[4]},
{ applesmc_dmi_match, "Apple iMac", {
DMI_MATCH(DMI_BOARD_VENDOR,"Apple"),
DMI_MATCH(DMI_PRODUCT_NAME,"iMac") },
(void*)&applesmc_dmi_data[5]},
{ .ident = NULL } { .ident = NULL }
}; };
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment