函数逻辑报告

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

Source Code:arch\x86\kernel\cpu\mce\therm_throt.c Create Date:2022-07-27 09:04:31
Last Modify:2020-03-12 14:18:49 Copyright©Brick
首页 函数Tree
注解内核,赢得工具下载SCCTEnglish

函数名称:herm_throt_process - Process thermal throttling event from interrupt*@curr: Whether the condition is current or not (boolean), since the* thermal interrupt normally gets called both when the thermal* event begins and once the event has ended

函数原型:static void therm_throt_process(bool new_event, int event, int level)

返回类型:void

参数:

类型参数名称
boolnew_event
intevent
intlevel
315  this_cpu等于当前cpu ID()
318  pstate等于per_cpu(thermal_state, this_cpu)
320  now等于get_jiffies_64()
321  如果level恒等于CORE_LEVEL
322  如果event恒等于THERMAL_THROTTLING_EVENTstate等于core_throttle
324  否则如果event恒等于POWER_LIMIT_EVENTstate等于core_power_limit
326  否则返回
328  否则如果level恒等于PACKAGE_LEVEL
329  如果event恒等于THERMAL_THROTTLING_EVENTstate等于package_throttle
331  否则如果event恒等于POWER_LIMIT_EVENTstate等于package_power_limit
333  否则返回
335  否则返回
338  old_event等于new_event
339  new_event等于new_event
341  如果new_eventcount自加
344  如果event不等于THERMAL_THROTTLING_EVENT则返回
347  如果new_event且非last_interrupt_time
351  get_therm_status(level, & hot, & temp)
357  如果temp大于10则返回
360  baseline_temp等于temp
361  last_interrupt_time等于now
362  schedule_delayed_work_on - queue work in global workqueue on CPU after delay*@cpu: cpu to use*@dwork: job to be done*@delay: number of jiffies to wait* After waiting for a given time this puts a job in the kernel-global* workqueue on the specified CPU.
363  否则如果old_eventlast_interrupt_time
366  throttle_time等于jiffies_delta_to_msecs(now - last_interrupt_time)
367  如果throttle_time大于max_time_msmax_time_ms等于throttle_time
369  total_time_ms加等于throttle_time
370  last_interrupt_time等于0
调用者
名称描述
intel_thermal_interruptThermal transition interrupt handler