Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
openeuler
raspberrypi-kernel
提交
8fbd4ade
R
raspberrypi-kernel
项目概览
openeuler
/
raspberrypi-kernel
通知
13
Star
1
Fork
0
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
0
列表
看板
标记
里程碑
合并请求
0
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
R
raspberrypi-kernel
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
0
Issue
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
Pages
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
提交
Issue看板
提交
8fbd4ade
编写于
4月 02, 2016
作者:
R
Rafael J. Wysocki
浏览文件
操作
浏览文件
下载
差异文件
Merge branch 'acpi-processor'
* acpi-processor: ACPI / processor: Request native thermal interrupt handling via _OSC
上级
f55532a0
a2121167
变更
4
显示空白变更内容
内联
并排
Showing
4 changed file
with
64 addition
and
0 deletion
+64
-0
arch/x86/kernel/cpu/mcheck/therm_throt.c
arch/x86/kernel/cpu/mcheck/therm_throt.c
+3
-0
drivers/acpi/acpi_processor.c
drivers/acpi/acpi_processor.c
+52
-0
drivers/acpi/bus.c
drivers/acpi/bus.c
+3
-0
drivers/acpi/internal.h
drivers/acpi/internal.h
+6
-0
未找到文件。
arch/x86/kernel/cpu/mcheck/therm_throt.c
浏览文件 @
8fbd4ade
...
...
@@ -384,6 +384,9 @@ static void intel_thermal_interrupt(void)
{
__u64
msr_val
;
if
(
static_cpu_has
(
X86_FEATURE_HWP
))
wrmsrl_safe
(
MSR_HWP_STATUS
,
0
);
rdmsrl
(
MSR_IA32_THERM_STATUS
,
msr_val
);
/* Check for violation of core thermal thresholds*/
...
...
drivers/acpi/acpi_processor.c
浏览文件 @
8fbd4ade
...
...
@@ -491,6 +491,58 @@ static void acpi_processor_remove(struct acpi_device *device)
}
#endif
/* CONFIG_ACPI_HOTPLUG_CPU */
#ifdef CONFIG_X86
static
bool
acpi_hwp_native_thermal_lvt_set
;
static
acpi_status
__init
acpi_hwp_native_thermal_lvt_osc
(
acpi_handle
handle
,
u32
lvl
,
void
*
context
,
void
**
rv
)
{
u8
sb_uuid_str
[]
=
"4077A616-290C-47BE-9EBD-D87058713953"
;
u32
capbuf
[
2
];
struct
acpi_osc_context
osc_context
=
{
.
uuid_str
=
sb_uuid_str
,
.
rev
=
1
,
.
cap
.
length
=
8
,
.
cap
.
pointer
=
capbuf
,
};
if
(
acpi_hwp_native_thermal_lvt_set
)
return
AE_CTRL_TERMINATE
;
capbuf
[
0
]
=
0x0000
;
capbuf
[
1
]
=
0x1000
;
/* set bit 12 */
if
(
ACPI_SUCCESS
(
acpi_run_osc
(
handle
,
&
osc_context
)))
{
if
(
osc_context
.
ret
.
pointer
&&
osc_context
.
ret
.
length
>
1
)
{
u32
*
capbuf_ret
=
osc_context
.
ret
.
pointer
;
if
(
capbuf_ret
[
1
]
&
0x1000
)
{
acpi_handle_info
(
handle
,
"_OSC native thermal LVT Acked
\n
"
);
acpi_hwp_native_thermal_lvt_set
=
true
;
}
}
kfree
(
osc_context
.
ret
.
pointer
);
}
return
AE_OK
;
}
void
__init
acpi_early_processor_osc
(
void
)
{
if
(
boot_cpu_has
(
X86_FEATURE_HWP
))
{
acpi_walk_namespace
(
ACPI_TYPE_PROCESSOR
,
ACPI_ROOT_OBJECT
,
ACPI_UINT32_MAX
,
acpi_hwp_native_thermal_lvt_osc
,
NULL
,
NULL
,
NULL
);
acpi_get_devices
(
ACPI_PROCESSOR_DEVICE_HID
,
acpi_hwp_native_thermal_lvt_osc
,
NULL
,
NULL
);
}
}
#endif
/*
* The following ACPI IDs are known to be suitable for representing as
* processor devices.
...
...
drivers/acpi/bus.c
浏览文件 @
8fbd4ade
...
...
@@ -1019,6 +1019,9 @@ static int __init acpi_bus_init(void)
goto
error1
;
}
/* Set capability bits for _OSC under processor scope */
acpi_early_processor_osc
();
/*
* _OSC method may exist in module level code,
* so it must be run after ACPI_FULL_INITIALIZATION
...
...
drivers/acpi/internal.h
浏览文件 @
8fbd4ade
...
...
@@ -145,6 +145,12 @@ void acpi_early_processor_set_pdc(void);
static
inline
void
acpi_early_processor_set_pdc
(
void
)
{}
#endif
#ifdef CONFIG_X86
void
acpi_early_processor_osc
(
void
);
#else
static
inline
void
acpi_early_processor_osc
(
void
)
{}
#endif
/* --------------------------------------------------------------------------
Embedded Controller
-------------------------------------------------------------------------- */
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录