Upload
stanley-chang
View
108
Download
2
Embed Size (px)
Citation preview
Tegra3 Thermal Management cont.
Thermal
SensorCPU PMU
Get data from CPU (D+/D-)
Feedback external temperature
Monitoring if temperature is greater
than Throttle threshold
Change power control to reduce
CPU clock and low frequency
Feedback external temperature
Update DVFS table
Get data from CPU (D+/D-)
Notify to start Throttling task
Tegra3 Thermal Management cont.
Thermal
SensorCPU PMU
Get data from CPU (D+/D-)
Feedback external temperature
Clear DEV_ON bit to prepare to
shutdown power for CPU
Disable peripheral driver
Monitoring if temperature is greater
than Shutdown threshold
Configure IRQ as Low-level trigger. HW sends interrupt according to initial threshold stored
in thermal sensor register (FW).
Acer-specific initial value were set as follow:
Implementation was done in file: nct1008.c (Driver layer configuration)
board-acer-t30.c (NV default value for vendor customization)
board-acer-t30-sensors.c (set into nct1008 non-violate flash)
Pin Function Threshold
TEMP_ALERT Throttling 85 ℃
AP_OVERHEAT Shutdown 90 ℃
Verification for specific value by commands as follow, cat /sys/class/i2c-dev/i2c-4/device/4-004c/tempaerature_alert
cat /sys/class/i2c-dev/i2c-4/device/4-004c/tempaerature_overheat
The ALERT output deasserts only when:
1. Temperature has fallen below the high temperature limit.
2. Master has read the device address.
3. Cleared the status register.
Thermal Sensor
T30
Throttlenode
Monitor
DVFS
AdjustDVFS
Cooling device N
.
.
.
Cooling device 1
Update
Update
CPU EDP Table1400/1300/1200/1100
Switch
ALERT
Update
Bind
Monitor
Bind
UpdateUpdateUpdate
nct1008.c
configure_sensor ()
configure_irq ()
get_temp ()
show_temp ()
set alert ()
show alert ()
work_func ()
SW Code Flow cont.
tegra3_thermal.c
tegra_thermal_alert_unlocked ()
tegra_edp_update_thermal_zone ()
cpu_tegra.c edp.c
tegra3_throttle.c
thermal_sys.c
edp_update_limit ()
tegra_cpu_set_speed
show_throttle
tegra_system_edp
_map[]
SW Code Flow cont.
Thermal threshold initialization
board-acer-t30.c
board-acer-t30-sensors.c
SW Code Flow cont.
HW interrupt triggers work_func to proceed throttling task!
Master has read the device address
Cleared the status register
SW Code Flow cont.
Stop charging if throttling starts.
After finish each throttling call, update temperature to T30.
SW Code Flow cont.
Check if temperature is over limit stored in EDP table.
Update index for new temperature to mapping EDP table.
Update CPU rate according to the temperature which was reported by nct1008 work function.
Adjust and update DVFS latest setting for CPU clock.
SW Code Flow cont.
Throttle sysfs node is the “answer” for CPU to know when throttling process ends.
Sysfs node stores in path:sys/devices/system/cpu/cpu0/cpufreq/throttle
SW Code Flow cont.
tegra3_throttle.c will report the latest status of throttling process.
SW Code Flow cont.
thermal_sys.c (cooling device) write TRUE/FALSE TO sysfs node “throttle” to update for tegra3_throttle.c and cpu-tegra.c
SW Code Flow cont.
CPU frequency adjustment mapping table with throttling stage.
Interrupt will be send to notify when temperature isn’t within limit,
45~60: 1.3GHz
60~75: 1.3GHz
75~85: 1.2GHz
over 85: 1.1GHz
StageCore On (cpu0 to 3)
SW Code Flow cont.
CPU frequency adjustment mapping table
SW verification step
HW verification step
Throttling
Shutdown