函数逻辑报告 |
Source Code:arch\x86\kernel\cpu\mce\therm_throt.c |
Create Date:2022-07-27 09:04:39 |
Last Modify:2020-03-12 14:18:49 | Copyright©Brick |
首页 | 函数Tree |
注解内核,赢得工具 | 下载SCCT | English |
函数名称:intel_init_thermal
函数原型:void intel_init_thermal(struct cpuinfo_x86 *c)
返回类型:void
参数:
类型 | 参数 | 名称 |
---|---|---|
struct cpuinfo_x86 * | c |
646 | tm2等于0 |
659 | h等于lvtthmr_init |
670 | 如果h按位与APIC_DM_FIXED_MASK的值不等于APIC_DM_FIXED则apic_write(APIC_LVTTHMR, lvtthmr_init) |
674 | 如果l按位与MSR_IA32_MISC_ENABLE_TM1且h按位与APIC_DM_SMI则 |
675 | 如果Values used for system_state. Ordering of the states must not be changed* as code checks for <, <=, >, >= STATE.恒等于SYSTEM_BOOTING则pr_debug("CPU%d: Thermal monitoring handled by SMI\n", cpu) |
677 | 返回 |
681 | 如果cpu_has(c, Thermal Monitor 2 )则 |
682 | 如果CPU family 恒等于6且x86_model恒等于9或x86_model恒等于13的值则 |
684 | 如果l按位与MSR_THERM2_CTL_TM_SELECT则tm2等于1 |
686 | 否则如果l按位与MSR_IA32_MISC_ENABLE_TM2则tm2等于1 |
691 | h等于THERMAL_APIC_VECTOR按位或APIC_DM_FIXED按位或APIC_LVT_MASKED |
692 | apic_write(APIC_LVTTHMR, h) |
695 | 如果cpu_has(c, Intel Power Limit Notification )且非int_pln_enable则wrmsr(MSR_IA32_THERM_INTERRUPT, (l | (THERM_INT_LOW_ENABLE | THERM_INT_HIGH_ENABLE)) & ~THERM_INT_PLN_ENABLE, h) |
699 | 否则如果cpu_has(c, Intel Power Limit Notification )且int_pln_enable则wrmsr(MSR_IA32_THERM_INTERRUPT, l | (THERM_INT_LOW_ENABLE | THERM_INT_HIGH_ENABLE | THERM_INT_PLN_ENABLE), h) |
703 | 否则wrmsr(MSR_IA32_THERM_INTERRUPT, l | (THERM_INT_LOW_ENABLE | THERM_INT_HIGH_ENABLE), h) |
707 | 如果cpu_has(c, Intel Package Thermal Status )则 |
728 | wrmsr(MSR_IA32_MISC_ENABLE, l | MSR_IA32_MISC_ENABLE_TM1, h) |
730 | pr_info_once("CPU0: Thermal monitoring enabled (%s)\n", tm2 ? "TM2" : "TM1") |
734 | atomic_set( & therm_throt_en, 1) |
名称 | 描述 |
---|---|
mce_intel_feature_init |
源代码转换工具 开放的插件接口 | X |
---|---|
支持:c/c++/esqlc/java Oracle/Informix/Mysql 插件可实现:逻辑报告 代码生成和批量转换代码 |