Commit b06349fc authored by Cyrill Gorcunov's avatar Cyrill Gorcunov

prctl: Rename PR_ entries

Tejun Heo proposed to use more general names
unrelated to checkpoint-restore procedure.

So be it (maybe someone else will need this
entries as well).
Signed-off-by: 's avatarCyrill Gorcunov <gorcunov@gmail.com>
parent 777dc994
...@@ -49,16 +49,16 @@ ...@@ -49,16 +49,16 @@
#define PR_SET_NAME 15 #define PR_SET_NAME 15
#define PR_GET_NAME 16 #define PR_GET_NAME 16
#define PR_CKPT_CTL 35 #define PR_SET_MM 35
# define PR_CKPT_CTL_SETUP_VDSO_AT 1 # define PR_SET_MM_START_CODE 1
# define PR_CKPT_CTL_SET_TASK_FLAGS 2 # define PR_SET_MM_END_CODE 2
# define PR_CKPT_CTL_SET_MM_START_CODE 3 # define PR_SET_MM_START_DATA 3
# define PR_CKPT_CTL_SET_MM_END_CODE 4 # define PR_SET_MM_END_DATA 4
# define PR_CKPT_CTL_SET_MM_START_DATA 5 # define PR_SET_MM_START_STACK 5
# define PR_CKPT_CTL_SET_MM_END_DATA 6 # define PR_SET_MM_START_BRK 6
# define PR_CKPT_CTL_SET_MM_START_STACK 7 # define PR_SET_MM_BRK 7
# define PR_CKPT_CTL_SET_MM_START_BRK 8
# define PR_CKPT_CTL_SET_MM_BRK 9 #define SETUP_VDSO_AT 36
/* fcntl */ /* fcntl */
#ifndef F_LINUX_SPECIFIC_BASE #ifndef F_LINUX_SPECIFIC_BASE
......
...@@ -221,8 +221,8 @@ self_len_end: ...@@ -221,8 +221,8 @@ self_len_end:
break; break;
if (vma_entry_is(vma_entry, VMA_AREA_VDSO)) { if (vma_entry_is(vma_entry, VMA_AREA_VDSO)) {
ret = sys_prctl(PR_CKPT_CTL, PR_CKPT_CTL_SETUP_VDSO_AT, ret = sys_prctl(SETUP_VDSO_AT, vma_entry->start,
vma_entry->start, 0, 0); 0, 0, 0);
if (ret) { if (ret) {
write_hex_n(__LINE__); write_hex_n(__LINE__);
write_hex_n(ret); write_hex_n(ret);
...@@ -331,19 +331,19 @@ self_len_end: ...@@ -331,19 +331,19 @@ self_len_end:
* Tune up the task fields. * Tune up the task fields.
*/ */
sys_prctl(PR_SET_NAME, (long)core_entry->task_comm, 0, 0, 0); sys_prctl(PR_SET_NAME, (long)core_entry->task_comm, 0, 0, 0);
sys_prctl(PR_CKPT_CTL, PR_CKPT_CTL_SET_MM_START_CODE, sys_prctl(PR_SET_MM, PR_SET_MM_START_CODE,
(long)core_entry->mm_start_code, 0, 0); (long)core_entry->mm_start_code, 0, 0);
sys_prctl(PR_CKPT_CTL, PR_CKPT_CTL_SET_MM_END_CODE, sys_prctl(PR_SET_MM, PR_SET_MM_END_CODE,
(long)core_entry->mm_end_code, 0, 0); (long)core_entry->mm_end_code, 0, 0);
sys_prctl(PR_CKPT_CTL, PR_CKPT_CTL_SET_MM_START_DATA, sys_prctl(PR_SET_MM, PR_SET_MM_START_DATA,
(long)core_entry->mm_start_data, 0, 0); (long)core_entry->mm_start_data, 0, 0);
sys_prctl(PR_CKPT_CTL, PR_CKPT_CTL_SET_MM_END_DATA, sys_prctl(PR_SET_MM, PR_SET_MM_END_DATA,
(long)core_entry->mm_end_data, 0, 0); (long)core_entry->mm_end_data, 0, 0);
sys_prctl(PR_CKPT_CTL, PR_CKPT_CTL_SET_MM_START_STACK, sys_prctl(PR_SET_MM, PR_SET_MM_START_STACK,
(long)core_entry->mm_start_stack, 0, 0); (long)core_entry->mm_start_stack, 0, 0);
sys_prctl(PR_CKPT_CTL, PR_CKPT_CTL_SET_MM_START_BRK, sys_prctl(PR_SET_MM, PR_SET_MM_START_BRK,
(long)core_entry->mm_start_brk, 0, 0); (long)core_entry->mm_start_brk, 0, 0);
sys_prctl(PR_CKPT_CTL, PR_CKPT_CTL_SET_MM_BRK, sys_prctl(PR_SET_MM, PR_SET_MM_BRK,
(long)core_entry->mm_brk, 0, 0); (long)core_entry->mm_brk, 0, 0);
/* /*
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment