File tree Expand file tree Collapse file tree 1 file changed +11
-2
lines changed Expand file tree Collapse file tree 1 file changed +11
-2
lines changed Original file line number Diff line number Diff line change @@ -3999,12 +3999,21 @@ static void Core_Thermal_Temp(CORE_RO *Core)
39993999{
40004000#ifdef CONFIG_THERMAL
40014001 if (!IS_ERR (PRIVATE (OF (Core , AT (Core -> Bind )))-> ThermalZone )) {
4002- int mcelsius ;
4002+ #if LINUX_VERSION_CODE >= KERNEL_VERSION (4 , 3 , 0 )
4003+ unsigned int mcelsius ;
40034004 if (thermal_zone_get_temp (PRIVATE (OF (Core , AT (Core -> Bind )))-> ThermalZone ,
4004- & mcelsius ) == 0 )
4005+ ( int * ) & mcelsius ) == 0 )
40054006 {
40064007 Core -> PowerThermal .Sensor = mcelsius ;
40074008 }
4009+ #else
4010+ unsigned long mcelsius ;
4011+ if (thermal_zone_get_temp (PRIVATE (OF (Core , AT (Core -> Bind )))-> ThermalZone ,
4012+ & mcelsius ) == 0 )
4013+ {
4014+ Core -> PowerThermal .Sensor = (unsigned int ) mcelsius ;
4015+ }
4016+ #endif
40084017 }
40094018#endif /* CONFIG_THERMAL */
40104019}
You can’t perform that action at this time.
0 commit comments