Commit 0a6c8ec4 authored by Tong Tiangen's avatar Tong Tiangen Committed by Yang Yingliang
Browse files

uce: cow scenario support kernel recovery

hulk inclusion
category: feature
bugzilla: https://gitee.com/openeuler/kernel/issues/I44R9D


CVE: NA

---------------------------

During kernel COW processing, the kernel triggers a RAS exception when reading
pages. In this solution, we identify this scenario in the kernel do_sea processing
process, send SIGBUS signals to the process that triggers COW and isolate memory
pages, preventing kernel panic.

At the same time, we use both cmdline(uce_kernel_recovery) and proc(/proc/sys/
kernel/uce_kernel_recovery) to control this feature on/off.

We use customized functions to distinguish scenarios that need kernel recovery,
specifically copy_page_cow(). When hardware error occurs in this function, we
killing the process that triggers the hardware error to replace the kernel die.

Signed-off-by: default avatarTong Tiangen <tongtiangen@huawei.com>
Signed-off-by: default avatarChen Huang <chenhuang5@huawei.com>
Reviewed-by: default avatarKefeng Wang <wangkefeng.wang@huawei.com>
Reviewed-by: default avatarXie XiuQi <xiexiuqi@huawei.com>
Signed-off-by: default avatarYang Yingliang <yangyingliang@huawei.com>
parent f06de526
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment