From e7e1d221d7b4584bafff192106b0efc0c1fa2559 Mon Sep 17 00:00:00 2001 From: Memphiz Date: Sun, 18 Jan 2015 20:19:02 +0100 Subject: [PATCH] [WeTek_Play] - enable cpu temp readings --- projects/WeTek_Play/linux/linux.arm.conf | 4 +++- .../patches/linux/120-enable_cputemp.patch | 17 +++++++++++++++++ 2 files changed, 20 insertions(+), 1 deletion(-) create mode 100644 projects/WeTek_Play/patches/linux/120-enable_cputemp.patch diff --git a/projects/WeTek_Play/linux/linux.arm.conf b/projects/WeTek_Play/linux/linux.arm.conf index 0db7e5f218..603680a31d 100644 --- a/projects/WeTek_Play/linux/linux.arm.conf +++ b/projects/WeTek_Play/linux/linux.arm.conf @@ -912,7 +912,7 @@ CONFIG_I2C_AML=y # CONFIG_I2C_SW_AML is not set # CONFIG_BCM2079X_I2C is not set CONFIG_AM_INPUT=y -# CONFIG_SARADC_AM is not set +CONFIG_SARADC_AM=y CONFIG_MESON_INPUT_REMOTE=y CONFIG_AM_REMOTE=y # CONFIG_AM_IR_RECEIVER is not set @@ -921,11 +921,13 @@ CONFIG_MESON_NEW_INPUT_REMOTE=y # CONFIG_NEW_AM_REMOTE is not set # CONFIG_NEW_AM_IR_TX is not set CONFIG_MESON_INPUT_KEYBOARD=y +# CONFIG_ADC_KEYPADS_AM is not set CONFIG_KEY_INPUT_CUSTOM_AM=y # CONFIG_TOUCH_KEY_PAD_IT7230 is not set # CONFIG_TOUCH_KEY_PAD_SO340010 is not set # CONFIG_TOUCH_KEY_PAD_HA2605 is not set # CONFIG_MESON_INPUT_TOUCHSCREEN is not set +# CONFIG_SIMCARD_DETECT_AM is not set # CONFIG_AML_HOLD_KEY is not set # CONFIG_AML_CALL_KEY is not set # CONFIG_SENSOR_DEVICES is not set diff --git a/projects/WeTek_Play/patches/linux/120-enable_cputemp.patch b/projects/WeTek_Play/patches/linux/120-enable_cputemp.patch new file mode 100644 index 0000000000..8fb9019894 --- /dev/null +++ b/projects/WeTek_Play/patches/linux/120-enable_cputemp.patch @@ -0,0 +1,17 @@ +--- a/arch/arm/mach-meson6/cpu.c.orig 2015-01-18 19:50:04.897840428 +0100 ++++ b/arch/arm/mach-meson6/cpu.c 2015-01-18 19:50:30.241839679 +0100 +@@ -59,6 +59,14 @@ + int mali_revb_flag = -1; + //int mali_version(void) + ++int (*get_cpu_temperature_celius)(void) = NULL; ++EXPORT_SYMBOL_GPL(get_cpu_temperature_celius); ++ ++int get_cpu_temperature(void) ++{ ++ return get_cpu_temperature_celius ? get_cpu_temperature_celius() : -1; ++} ++ + EXPORT_SYMBOL_GPL(mali_revb_flag); + static int __init maliversion(char *str) + {