]>
Commit | Line | Data |
---|---|---|
bd427b06 AM |
1 | diff -NurpP --minimal linux-2.6.27.33/arch/alpha/Kconfig linux-2.6.27.33-vs2.3.0.36.6/arch/alpha/Kconfig |
2 | --- linux-2.6.27.33/arch/alpha/Kconfig 2008-10-13 14:51:51.000000000 +0200 | |
3 | +++ linux-2.6.27.33-vs2.3.0.36.6/arch/alpha/Kconfig 2008-10-13 14:54:20.000000000 +0200 | |
4 | @@ -667,6 +667,8 @@ config DUMMY_CONSOLE | |
2380c486 JR |
5 | depends on VGA_HOSE |
6 | default y | |
d337f35e JR |
7 | |
8 | +source "kernel/vserver/Kconfig" | |
9 | + | |
10 | source "security/Kconfig" | |
11 | ||
12 | source "crypto/Kconfig" | |
bd427b06 AM |
13 | diff -NurpP --minimal linux-2.6.27.33/arch/alpha/kernel/entry.S linux-2.6.27.33-vs2.3.0.36.6/arch/alpha/kernel/entry.S |
14 | --- linux-2.6.27.33/arch/alpha/kernel/entry.S 2009-09-13 16:16:49.000000000 +0200 | |
15 | +++ linux-2.6.27.33-vs2.3.0.36.6/arch/alpha/kernel/entry.S 2009-02-03 17:59:04.000000000 +0100 | |
16 | @@ -872,24 +872,15 @@ sys_getxgid: | |
d337f35e JR |
17 | .globl sys_getxpid |
18 | .ent sys_getxpid | |
19 | sys_getxpid: | |
20 | + lda $sp, -16($sp) | |
21 | + stq $26, 0($sp) | |
22 | .prologue 0 | |
23 | - ldq $2, TI_TASK($8) | |
24 | ||
25 | - /* See linux/kernel/timer.c sys_getppid for discussion | |
26 | - about this loop. */ | |
27 | - ldq $3, TASK_GROUP_LEADER($2) | |
28 | - ldq $4, TASK_REAL_PARENT($3) | |
29 | - ldl $0, TASK_TGID($2) | |
30 | -1: ldl $1, TASK_TGID($4) | |
31 | -#ifdef CONFIG_SMP | |
32 | - mov $4, $5 | |
33 | - mb | |
34 | - ldq $3, TASK_GROUP_LEADER($2) | |
35 | - ldq $4, TASK_REAL_PARENT($3) | |
36 | - cmpeq $4, $5, $5 | |
37 | - beq $5, 1b | |
38 | -#endif | |
39 | - stq $1, 80($sp) | |
40 | + lda $16, 96($sp) | |
41 | + jsr $26, do_getxpid | |
42 | + ldq $26, 0($sp) | |
43 | + | |
44 | + lda $sp, 16($sp) | |
45 | ret | |
46 | .end sys_getxpid | |
47 | ||
bd427b06 AM |
48 | diff -NurpP --minimal linux-2.6.27.33/arch/alpha/kernel/osf_sys.c linux-2.6.27.33-vs2.3.0.36.6/arch/alpha/kernel/osf_sys.c |
49 | --- linux-2.6.27.33/arch/alpha/kernel/osf_sys.c 2008-10-13 14:51:51.000000000 +0200 | |
50 | +++ linux-2.6.27.33-vs2.3.0.36.6/arch/alpha/kernel/osf_sys.c 2008-10-13 14:54:20.000000000 +0200 | |
51 | @@ -888,7 +888,7 @@ osf_gettimeofday(struct timeval32 __user | |
d337f35e JR |
52 | { |
53 | if (tv) { | |
54 | struct timeval ktv; | |
55 | - do_gettimeofday(&ktv); | |
56 | + vx_gettimeofday(&ktv); | |
57 | if (put_tv32(tv, &ktv)) | |
58 | return -EFAULT; | |
59 | } | |
bd427b06 AM |
60 | diff -NurpP --minimal linux-2.6.27.33/arch/alpha/kernel/ptrace.c linux-2.6.27.33-vs2.3.0.36.6/arch/alpha/kernel/ptrace.c |
61 | --- linux-2.6.27.33/arch/alpha/kernel/ptrace.c 2008-07-13 23:51:29.000000000 +0200 | |
62 | +++ linux-2.6.27.33-vs2.3.0.36.6/arch/alpha/kernel/ptrace.c 2008-10-13 14:54:20.000000000 +0200 | |
63 | @@ -15,6 +15,7 @@ | |
d337f35e JR |
64 | #include <linux/slab.h> |
65 | #include <linux/security.h> | |
66 | #include <linux/signal.h> | |
67 | +#include <linux/vs_base.h> | |
68 | ||
69 | #include <asm/uaccess.h> | |
70 | #include <asm/pgtable.h> | |
bd427b06 AM |
71 | diff -NurpP --minimal linux-2.6.27.33/arch/alpha/kernel/systbls.S linux-2.6.27.33-vs2.3.0.36.6/arch/alpha/kernel/systbls.S |
72 | --- linux-2.6.27.33/arch/alpha/kernel/systbls.S 2009-09-13 16:16:49.000000000 +0200 | |
73 | +++ linux-2.6.27.33-vs2.3.0.36.6/arch/alpha/kernel/systbls.S 2009-02-03 17:59:04.000000000 +0100 | |
d337f35e JR |
74 | @@ -446,7 +446,7 @@ sys_call_table: |
75 | .quad sys_stat64 /* 425 */ | |
76 | .quad sys_lstat64 | |
77 | .quad sys_fstat64 | |
78 | - .quad sys_ni_syscall /* sys_vserver */ | |
79 | + .quad sys_vserver /* sys_vserver */ | |
80 | .quad sys_ni_syscall /* sys_mbind */ | |
81 | .quad sys_ni_syscall /* sys_get_mempolicy */ | |
82 | .quad sys_ni_syscall /* sys_set_mempolicy */ | |
bd427b06 AM |
83 | diff -NurpP --minimal linux-2.6.27.33/arch/alpha/kernel/traps.c linux-2.6.27.33-vs2.3.0.36.6/arch/alpha/kernel/traps.c |
84 | --- linux-2.6.27.33/arch/alpha/kernel/traps.c 2008-07-13 23:51:29.000000000 +0200 | |
85 | +++ linux-2.6.27.33-vs2.3.0.36.6/arch/alpha/kernel/traps.c 2008-10-13 14:54:20.000000000 +0200 | |
2380c486 | 86 | @@ -183,7 +183,8 @@ die_if_kernel(char * str, struct pt_regs |
d337f35e JR |
87 | #ifdef CONFIG_SMP |
88 | printk("CPU %d ", hard_smp_processor_id()); | |
89 | #endif | |
2380c486 | 90 | - printk("%s(%d): %s %ld\n", current->comm, task_pid_nr(current), str, err); |
d337f35e | 91 | + printk("%s(%d[#%u]): %s %ld\n", current->comm, |
2380c486 | 92 | + task_pid_nr(current), current->xid, str, err); |
d337f35e | 93 | dik_show_regs(regs, r9_15); |
2380c486 | 94 | add_taint(TAINT_DIE); |
d337f35e | 95 | dik_show_trace((unsigned long *)(regs+1)); |
bd427b06 AM |
96 | diff -NurpP --minimal linux-2.6.27.33/arch/alpha/mm/fault.c linux-2.6.27.33-vs2.3.0.36.6/arch/alpha/mm/fault.c |
97 | --- linux-2.6.27.33/arch/alpha/mm/fault.c 2008-07-13 23:51:29.000000000 +0200 | |
98 | +++ linux-2.6.27.33-vs2.3.0.36.6/arch/alpha/mm/fault.c 2008-10-13 14:54:20.000000000 +0200 | |
2380c486 JR |
99 | @@ -193,8 +193,8 @@ do_page_fault(unsigned long address, uns |
100 | down_read(&mm->mmap_sem); | |
101 | goto survive; | |
102 | } | |
103 | - printk(KERN_ALERT "VM: killing process %s(%d)\n", | |
104 | - current->comm, task_pid_nr(current)); | |
105 | + printk(KERN_ALERT "VM: killing process %s(%d:#%u)\n", | |
106 | + current->comm, task_pid_nr(current), current->xid); | |
107 | if (!user_mode(regs)) | |
108 | goto no_context; | |
109 | do_group_exit(SIGKILL); | |
bd427b06 AM |
110 | diff -NurpP --minimal linux-2.6.27.33/arch/arm/Kconfig linux-2.6.27.33-vs2.3.0.36.6/arch/arm/Kconfig |
111 | --- linux-2.6.27.33/arch/arm/Kconfig 2008-10-13 14:51:51.000000000 +0200 | |
112 | +++ linux-2.6.27.33-vs2.3.0.36.6/arch/arm/Kconfig 2008-10-13 14:54:20.000000000 +0200 | |
113 | @@ -1240,6 +1240,8 @@ source "fs/Kconfig" | |
d337f35e JR |
114 | |
115 | source "arch/arm/Kconfig.debug" | |
116 | ||
117 | +source "kernel/vserver/Kconfig" | |
118 | + | |
119 | source "security/Kconfig" | |
120 | ||
121 | source "crypto/Kconfig" | |
bd427b06 AM |
122 | diff -NurpP --minimal linux-2.6.27.33/arch/arm/kernel/calls.S linux-2.6.27.33-vs2.3.0.36.6/arch/arm/kernel/calls.S |
123 | --- linux-2.6.27.33/arch/arm/kernel/calls.S 2009-09-13 16:16:49.000000000 +0200 | |
124 | +++ linux-2.6.27.33-vs2.3.0.36.6/arch/arm/kernel/calls.S 2009-02-03 17:59:04.000000000 +0100 | |
d337f35e JR |
125 | @@ -322,7 +322,7 @@ |
126 | /* 310 */ CALL(sys_request_key) | |
127 | CALL(sys_keyctl) | |
128 | CALL(ABI(sys_semtimedop, sys_oabi_semtimedop)) | |
129 | -/* vserver */ CALL(sys_ni_syscall) | |
130 | + CALL(sys_vserver) | |
131 | CALL(sys_ioprio_set) | |
132 | /* 315 */ CALL(sys_ioprio_get) | |
133 | CALL(sys_inotify_init) | |
bd427b06 AM |
134 | diff -NurpP --minimal linux-2.6.27.33/arch/arm/kernel/process.c linux-2.6.27.33-vs2.3.0.36.6/arch/arm/kernel/process.c |
135 | --- linux-2.6.27.33/arch/arm/kernel/process.c 2008-10-13 14:51:52.000000000 +0200 | |
136 | +++ linux-2.6.27.33-vs2.3.0.36.6/arch/arm/kernel/process.c 2008-10-13 14:54:20.000000000 +0200 | |
137 | @@ -262,7 +262,8 @@ void __show_regs(struct pt_regs *regs) | |
d337f35e JR |
138 | void show_regs(struct pt_regs * regs) |
139 | { | |
140 | printk("\n"); | |
2380c486 | 141 | - printk("Pid: %d, comm: %20s\n", task_pid_nr(current), current->comm); |
d337f35e | 142 | + printk("Pid: %d[#%u], comm: %20s\n", |
2380c486 | 143 | + task_pid_nr(current), current->xid, current->comm); |
d337f35e JR |
144 | __show_regs(regs); |
145 | __backtrace(); | |
146 | } | |
bd427b06 AM |
147 | diff -NurpP --minimal linux-2.6.27.33/arch/arm/kernel/traps.c linux-2.6.27.33-vs2.3.0.36.6/arch/arm/kernel/traps.c |
148 | --- linux-2.6.27.33/arch/arm/kernel/traps.c 2008-10-13 14:51:52.000000000 +0200 | |
149 | +++ linux-2.6.27.33-vs2.3.0.36.6/arch/arm/kernel/traps.c 2008-10-13 14:54:20.000000000 +0200 | |
150 | @@ -214,8 +214,8 @@ static void __die(const char *str, int e | |
2380c486 | 151 | str, err, ++die_counter); |
d337f35e JR |
152 | print_modules(); |
153 | __show_regs(regs); | |
154 | - printk("Process %s (pid: %d, stack limit = 0x%p)\n", | |
2380c486 | 155 | - tsk->comm, task_pid_nr(tsk), thread + 1); |
d337f35e | 156 | + printk("Process %s (pid: %d:#%u, stack limit = 0x%p)\n", |
2380c486 | 157 | + tsk->comm, task_pid_nr(tsk), tsk->xid, thread + 1); |
d337f35e JR |
158 | |
159 | if (!user_mode(regs) || in_interrupt()) { | |
160 | dump_mem("Stack: ", regs->ARM_sp, | |
bd427b06 AM |
161 | diff -NurpP --minimal linux-2.6.27.33/arch/arm/mm/fault.c linux-2.6.27.33-vs2.3.0.36.6/arch/arm/mm/fault.c |
162 | --- linux-2.6.27.33/arch/arm/mm/fault.c 2008-07-13 23:51:29.000000000 +0200 | |
163 | +++ linux-2.6.27.33-vs2.3.0.36.6/arch/arm/mm/fault.c 2008-10-13 14:54:20.000000000 +0200 | |
164 | @@ -292,7 +292,8 @@ do_page_fault(unsigned long addr, unsign | |
2380c486 JR |
165 | * happened to us that made us unable to handle |
166 | * the page fault gracefully. | |
167 | */ | |
168 | - printk("VM: killing process %s\n", tsk->comm); | |
169 | + printk("VM: killing process %s(%d:#%u)\n", | |
170 | + tsk->comm, task_pid_nr(tsk), tsk->xid); | |
171 | do_group_exit(SIGKILL); | |
172 | return 0; | |
173 | } | |
bd427b06 AM |
174 | diff -NurpP --minimal linux-2.6.27.33/arch/cris/Kconfig linux-2.6.27.33-vs2.3.0.36.6/arch/cris/Kconfig |
175 | --- linux-2.6.27.33/arch/cris/Kconfig 2008-07-13 23:51:29.000000000 +0200 | |
176 | +++ linux-2.6.27.33-vs2.3.0.36.6/arch/cris/Kconfig 2008-10-13 14:54:20.000000000 +0200 | |
177 | @@ -679,6 +679,8 @@ source "drivers/usb/Kconfig" | |
d337f35e JR |
178 | |
179 | source "arch/cris/Kconfig.debug" | |
180 | ||
181 | +source "kernel/vserver/Kconfig" | |
182 | + | |
183 | source "security/Kconfig" | |
184 | ||
185 | source "crypto/Kconfig" | |
bd427b06 AM |
186 | diff -NurpP --minimal linux-2.6.27.33/arch/frv/kernel/kernel_thread.S linux-2.6.27.33-vs2.3.0.36.6/arch/frv/kernel/kernel_thread.S |
187 | --- linux-2.6.27.33/arch/frv/kernel/kernel_thread.S 2008-07-13 23:51:29.000000000 +0200 | |
188 | +++ linux-2.6.27.33-vs2.3.0.36.6/arch/frv/kernel/kernel_thread.S 2008-10-13 14:54:20.000000000 +0200 | |
2380c486 | 189 | @@ -37,7 +37,7 @@ kernel_thread: |
d337f35e JR |
190 | |
191 | # start by forking the current process, but with shared VM | |
192 | setlos.p #__NR_clone,gr7 ; syscall number | |
193 | - ori gr10,#CLONE_VM,gr8 ; first syscall arg [clone_flags] | |
194 | + ori gr10,#CLONE_KT,gr8 ; first syscall arg [clone_flags] | |
195 | sethi.p #0xe4e4,gr9 ; second syscall arg [newsp] | |
196 | setlo #0xe4e4,gr9 | |
197 | setlos.p #0,gr10 ; third syscall arg [parent_tidptr] | |
bd427b06 AM |
198 | diff -NurpP --minimal linux-2.6.27.33/arch/h8300/Kconfig linux-2.6.27.33-vs2.3.0.36.6/arch/h8300/Kconfig |
199 | --- linux-2.6.27.33/arch/h8300/Kconfig 2008-10-13 14:51:55.000000000 +0200 | |
200 | +++ linux-2.6.27.33-vs2.3.0.36.6/arch/h8300/Kconfig 2008-10-13 14:54:20.000000000 +0200 | |
201 | @@ -219,6 +219,8 @@ source "fs/Kconfig" | |
d337f35e JR |
202 | |
203 | source "arch/h8300/Kconfig.debug" | |
204 | ||
205 | +source "kernel/vserver/Kconfig" | |
206 | + | |
207 | source "security/Kconfig" | |
208 | ||
209 | source "crypto/Kconfig" | |
bd427b06 AM |
210 | diff -NurpP --minimal linux-2.6.27.33/arch/ia64/ia32/ia32_entry.S linux-2.6.27.33-vs2.3.0.36.6/arch/ia64/ia32/ia32_entry.S |
211 | --- linux-2.6.27.33/arch/ia64/ia32/ia32_entry.S 2009-09-13 16:16:49.000000000 +0200 | |
212 | +++ linux-2.6.27.33-vs2.3.0.36.6/arch/ia64/ia32/ia32_entry.S 2009-02-03 17:59:04.000000000 +0100 | |
213 | @@ -446,7 +446,7 @@ ia32_syscall_table: | |
2380c486 JR |
214 | data8 sys_tgkill /* 270 */ |
215 | data8 compat_sys_utimes | |
216 | data8 sys32_fadvise64_64 | |
217 | - data8 sys_ni_syscall | |
218 | + data8 sys32_vserver | |
219 | data8 sys_ni_syscall | |
220 | data8 sys_ni_syscall /* 275 */ | |
221 | data8 sys_ni_syscall | |
bd427b06 AM |
222 | diff -NurpP --minimal linux-2.6.27.33/arch/ia64/ia32/sys_ia32.c linux-2.6.27.33-vs2.3.0.36.6/arch/ia64/ia32/sys_ia32.c |
223 | --- linux-2.6.27.33/arch/ia64/ia32/sys_ia32.c 2008-10-13 14:51:55.000000000 +0200 | |
224 | +++ linux-2.6.27.33-vs2.3.0.36.6/arch/ia64/ia32/sys_ia32.c 2008-10-13 14:54:20.000000000 +0200 | |
225 | @@ -1178,7 +1178,7 @@ sys32_gettimeofday (struct compat_timeva | |
226 | { | |
227 | if (tv) { | |
228 | struct timeval ktv; | |
229 | - do_gettimeofday(&ktv); | |
230 | + vx_gettimeofday(&ktv); | |
231 | if (put_tv32(tv, &ktv)) | |
232 | return -EFAULT; | |
233 | } | |
234 | diff -NurpP --minimal linux-2.6.27.33/arch/ia64/Kconfig linux-2.6.27.33-vs2.3.0.36.6/arch/ia64/Kconfig | |
235 | --- linux-2.6.27.33/arch/ia64/Kconfig 2009-09-13 16:16:49.000000000 +0200 | |
236 | +++ linux-2.6.27.33-vs2.3.0.36.6/arch/ia64/Kconfig 2009-03-25 14:32:29.000000000 +0100 | |
237 | @@ -639,6 +639,8 @@ source "arch/ia64/hp/sim/Kconfig" | |
2380c486 JR |
238 | |
239 | source "arch/ia64/Kconfig.debug" | |
d337f35e JR |
240 | |
241 | +source "kernel/vserver/Kconfig" | |
242 | + | |
243 | source "security/Kconfig" | |
244 | ||
245 | source "crypto/Kconfig" | |
bd427b06 AM |
246 | diff -NurpP --minimal linux-2.6.27.33/arch/ia64/kernel/entry.S linux-2.6.27.33-vs2.3.0.36.6/arch/ia64/kernel/entry.S |
247 | --- linux-2.6.27.33/arch/ia64/kernel/entry.S 2009-09-13 16:16:49.000000000 +0200 | |
248 | +++ linux-2.6.27.33-vs2.3.0.36.6/arch/ia64/kernel/entry.S 2009-02-03 17:59:04.000000000 +0100 | |
249 | @@ -1647,7 +1647,7 @@ sys_call_table: | |
2380c486 JR |
250 | data8 sys_mq_notify |
251 | data8 sys_mq_getsetattr | |
252 | data8 sys_kexec_load | |
253 | - data8 sys_ni_syscall // reserved for vserver | |
254 | + data8 sys_vserver | |
255 | data8 sys_waitid // 1270 | |
256 | data8 sys_add_key | |
257 | data8 sys_request_key | |
bd427b06 AM |
258 | diff -NurpP --minimal linux-2.6.27.33/arch/ia64/kernel/perfmon.c linux-2.6.27.33-vs2.3.0.36.6/arch/ia64/kernel/perfmon.c |
259 | --- linux-2.6.27.33/arch/ia64/kernel/perfmon.c 2008-10-13 14:51:55.000000000 +0200 | |
260 | +++ linux-2.6.27.33-vs2.3.0.36.6/arch/ia64/kernel/perfmon.c 2008-10-13 14:54:20.000000000 +0200 | |
261 | @@ -40,6 +40,7 @@ | |
262 | #include <linux/capability.h> | |
2380c486 JR |
263 | #include <linux/rcupdate.h> |
264 | #include <linux/completion.h> | |
2380c486 | 265 | +#include <linux/vs_memory.h> |
d337f35e | 266 | |
2380c486 JR |
267 | #include <asm/errno.h> |
268 | #include <asm/intrinsics.h> | |
bd427b06 | 269 | @@ -2376,7 +2377,7 @@ pfm_smpl_buffer_alloc(struct task_struct |
2380c486 JR |
270 | */ |
271 | insert_vm_struct(mm, vma); | |
d337f35e | 272 | |
2380c486 JR |
273 | - mm->total_vm += size >> PAGE_SHIFT; |
274 | + vx_vmpages_add(mm, size >> PAGE_SHIFT); | |
275 | vm_stat_account(vma->vm_mm, vma->vm_flags, vma->vm_file, | |
276 | vma_pages(vma)); | |
277 | up_write(&task->mm->mmap_sem); | |
bd427b06 AM |
278 | diff -NurpP --minimal linux-2.6.27.33/arch/ia64/kernel/process.c linux-2.6.27.33-vs2.3.0.36.6/arch/ia64/kernel/process.c |
279 | --- linux-2.6.27.33/arch/ia64/kernel/process.c 2008-10-13 14:51:55.000000000 +0200 | |
280 | +++ linux-2.6.27.33-vs2.3.0.36.6/arch/ia64/kernel/process.c 2008-10-13 14:54:20.000000000 +0200 | |
281 | @@ -109,8 +109,8 @@ show_regs (struct pt_regs *regs) | |
2380c486 | 282 | unsigned long ip = regs->cr_iip + ia64_psr(regs)->ri; |
d337f35e | 283 | |
2380c486 JR |
284 | print_modules(); |
285 | - printk("\nPid: %d, CPU %d, comm: %20s\n", task_pid_nr(current), | |
286 | - smp_processor_id(), current->comm); | |
287 | + printk("\nPid: %d[#%u], CPU %d, comm: %20s\n", task_pid_nr(current), | |
288 | + current->xid, smp_processor_id(), current->comm); | |
289 | printk("psr : %016lx ifs : %016lx ip : [<%016lx>] %s (%s)\n", | |
290 | regs->cr_ipsr, regs->cr_ifs, ip, print_tainted(), | |
291 | init_utsname()->release); | |
bd427b06 AM |
292 | diff -NurpP --minimal linux-2.6.27.33/arch/ia64/kernel/ptrace.c linux-2.6.27.33-vs2.3.0.36.6/arch/ia64/kernel/ptrace.c |
293 | --- linux-2.6.27.33/arch/ia64/kernel/ptrace.c 2008-07-13 23:51:29.000000000 +0200 | |
294 | +++ linux-2.6.27.33-vs2.3.0.36.6/arch/ia64/kernel/ptrace.c 2008-10-13 14:54:20.000000000 +0200 | |
23f740c4 | 295 | @@ -22,6 +22,7 @@ |
bd427b06 | 296 | #include <linux/signal.h> |
2380c486 | 297 | #include <linux/regset.h> |
d337f35e | 298 | #include <linux/elf.h> |
d337f35e JR |
299 | +#include <linux/vs_base.h> |
300 | ||
301 | #include <asm/pgtable.h> | |
302 | #include <asm/processor.h> | |
bd427b06 AM |
303 | diff -NurpP --minimal linux-2.6.27.33/arch/ia64/kernel/traps.c linux-2.6.27.33-vs2.3.0.36.6/arch/ia64/kernel/traps.c |
304 | --- linux-2.6.27.33/arch/ia64/kernel/traps.c 2008-07-13 23:51:29.000000000 +0200 | |
305 | +++ linux-2.6.27.33-vs2.3.0.36.6/arch/ia64/kernel/traps.c 2008-10-13 14:54:20.000000000 +0200 | |
2380c486 | 306 | @@ -60,8 +60,9 @@ die (const char *str, struct pt_regs *re |
d337f35e JR |
307 | put_cpu(); |
308 | ||
309 | if (++die.lock_owner_depth < 3) { | |
310 | - printk("%s[%d]: %s %ld [%d]\n", | |
2380c486 | 311 | - current->comm, task_pid_nr(current), str, err, ++die_counter); |
d337f35e | 312 | + printk("%s[%d[#%u]]: %s %ld [%d]\n", |
2380c486 | 313 | + current->comm, task_pid_nr(current), current->xid, |
d337f35e | 314 | + str, err, ++die_counter); |
2380c486 JR |
315 | if (notify_die(DIE_OOPS, str, regs, err, 255, SIGSEGV) |
316 | != NOTIFY_STOP) | |
317 | show_regs(regs); | |
318 | @@ -324,8 +325,9 @@ handle_fpu_swa (int fp_fault, struct pt_ | |
319 | if ((last.count & 15) < 5 && (ia64_fetchadd(1, &last.count, acq) & 15) < 5) { | |
320 | last.time = current_jiffies + 5 * HZ; | |
321 | printk(KERN_WARNING | |
322 | - "%s(%d): floating-point assist fault at ip %016lx, isr %016lx\n", | |
323 | - current->comm, task_pid_nr(current), regs->cr_iip + ia64_psr(regs)->ri, isr); | |
324 | + "%s(%d[#%u]): floating-point assist fault at ip %016lx, isr %016lx\n", | |
325 | + current->comm, task_pid_nr(current), current->xid, | |
326 | + regs->cr_iip + ia64_psr(regs)->ri, isr); | |
327 | } | |
328 | } | |
d337f35e | 329 | } |
bd427b06 AM |
330 | diff -NurpP --minimal linux-2.6.27.33/arch/ia64/mm/fault.c linux-2.6.27.33-vs2.3.0.36.6/arch/ia64/mm/fault.c |
331 | --- linux-2.6.27.33/arch/ia64/mm/fault.c 2008-07-13 23:51:29.000000000 +0200 | |
332 | +++ linux-2.6.27.33-vs2.3.0.36.6/arch/ia64/mm/fault.c 2008-10-13 14:54:20.000000000 +0200 | |
d337f35e | 333 | @@ -10,6 +10,7 @@ |
d337f35e JR |
334 | #include <linux/interrupt.h> |
335 | #include <linux/kprobes.h> | |
2380c486 | 336 | #include <linux/kdebug.h> |
d337f35e JR |
337 | +#include <linux/vs_memory.h> |
338 | ||
339 | #include <asm/pgtable.h> | |
340 | #include <asm/processor.h> | |
bd427b06 AM |
341 | diff -NurpP --minimal linux-2.6.27.33/arch/m32r/kernel/traps.c linux-2.6.27.33-vs2.3.0.36.6/arch/m32r/kernel/traps.c |
342 | --- linux-2.6.27.33/arch/m32r/kernel/traps.c 2008-10-13 14:51:55.000000000 +0200 | |
343 | +++ linux-2.6.27.33-vs2.3.0.36.6/arch/m32r/kernel/traps.c 2008-10-13 14:54:20.000000000 +0200 | |
2380c486 | 344 | @@ -196,8 +196,9 @@ static void show_registers(struct pt_reg |
d337f35e JR |
345 | } else { |
346 | printk("SPI: %08lx\n", sp); | |
347 | } | |
348 | - printk("Process %s (pid: %d, process nr: %d, stackpage=%08lx)", | |
2380c486 | 349 | - current->comm, task_pid_nr(current), 0xffff & i, 4096+(unsigned long)current); |
d337f35e | 350 | + printk("Process %s (pid: %d[#%u], process nr: %d, stackpage=%08lx)", |
2380c486 | 351 | + current->comm, task_pid_nr(current), current->xid, |
d337f35e JR |
352 | + 0xffff & i, 4096+(unsigned long)current); |
353 | ||
354 | /* | |
355 | * When in-kernel, we also print out the stack and code at the | |
bd427b06 AM |
356 | diff -NurpP --minimal linux-2.6.27.33/arch/m68k/Kconfig linux-2.6.27.33-vs2.3.0.36.6/arch/m68k/Kconfig |
357 | --- linux-2.6.27.33/arch/m68k/Kconfig 2008-10-13 14:51:55.000000000 +0200 | |
358 | +++ linux-2.6.27.33-vs2.3.0.36.6/arch/m68k/Kconfig 2008-10-13 14:54:20.000000000 +0200 | |
359 | @@ -633,6 +633,8 @@ source "fs/Kconfig" | |
d337f35e JR |
360 | |
361 | source "arch/m68k/Kconfig.debug" | |
362 | ||
363 | +source "kernel/vserver/Kconfig" | |
364 | + | |
365 | source "security/Kconfig" | |
366 | ||
367 | source "crypto/Kconfig" | |
bd427b06 AM |
368 | diff -NurpP --minimal linux-2.6.27.33/arch/m68k/kernel/ptrace.c linux-2.6.27.33-vs2.3.0.36.6/arch/m68k/kernel/ptrace.c |
369 | --- linux-2.6.27.33/arch/m68k/kernel/ptrace.c 2008-07-13 23:51:29.000000000 +0200 | |
370 | +++ linux-2.6.27.33-vs2.3.0.36.6/arch/m68k/kernel/ptrace.c 2008-10-13 14:54:20.000000000 +0200 | |
2380c486 | 371 | @@ -18,6 +18,7 @@ |
d337f35e JR |
372 | #include <linux/ptrace.h> |
373 | #include <linux/user.h> | |
374 | #include <linux/signal.h> | |
375 | +#include <linux/vs_base.h> | |
376 | ||
377 | #include <asm/uaccess.h> | |
378 | #include <asm/page.h> | |
2380c486 | 379 | @@ -269,6 +270,8 @@ long arch_ptrace(struct task_struct *chi |
d337f35e JR |
380 | ret = ptrace_request(child, request, addr, data); |
381 | break; | |
382 | } | |
2380c486 | 383 | + if (!vx_check(vx_task_xid(child), VS_WATCH_P | VS_IDENT)) |
d337f35e JR |
384 | + goto out_tsk; |
385 | ||
386 | return ret; | |
387 | out_eio: | |
bd427b06 AM |
388 | diff -NurpP --minimal linux-2.6.27.33/arch/m68k/kernel/traps.c linux-2.6.27.33-vs2.3.0.36.6/arch/m68k/kernel/traps.c |
389 | --- linux-2.6.27.33/arch/m68k/kernel/traps.c 2008-07-13 23:51:29.000000000 +0200 | |
390 | +++ linux-2.6.27.33-vs2.3.0.36.6/arch/m68k/kernel/traps.c 2008-10-13 14:54:20.000000000 +0200 | |
391 | @@ -909,8 +909,8 @@ void show_registers(struct pt_regs *regs | |
d337f35e JR |
392 | printk("d4: %08lx d5: %08lx a0: %08lx a1: %08lx\n", |
393 | regs->d4, regs->d5, regs->a0, regs->a1); | |
394 | ||
395 | - printk("Process %s (pid: %d, task=%p)\n", | |
2380c486 | 396 | - current->comm, task_pid_nr(current), current); |
d337f35e | 397 | + printk("Process %s (pid: %d[#%u], task=%p)\n", |
2380c486 | 398 | + current->comm, task_pid_nr(current), current->xid, current); |
d337f35e JR |
399 | addr = (unsigned long)&fp->un; |
400 | printk("Frame format=%X ", regs->format); | |
401 | switch (regs->format) { | |
bd427b06 AM |
402 | diff -NurpP --minimal linux-2.6.27.33/arch/m68knommu/Kconfig linux-2.6.27.33-vs2.3.0.36.6/arch/m68knommu/Kconfig |
403 | --- linux-2.6.27.33/arch/m68knommu/Kconfig 2009-09-13 16:16:50.000000000 +0200 | |
404 | +++ linux-2.6.27.33-vs2.3.0.36.6/arch/m68knommu/Kconfig 2009-02-22 22:58:32.000000000 +0100 | |
405 | @@ -744,6 +744,8 @@ source "fs/Kconfig" | |
d337f35e JR |
406 | |
407 | source "arch/m68knommu/Kconfig.debug" | |
408 | ||
409 | +source "kernel/vserver/Kconfig" | |
410 | + | |
411 | source "security/Kconfig" | |
412 | ||
413 | source "crypto/Kconfig" | |
bd427b06 AM |
414 | diff -NurpP --minimal linux-2.6.27.33/arch/m68knommu/kernel/traps.c linux-2.6.27.33-vs2.3.0.36.6/arch/m68knommu/kernel/traps.c |
415 | --- linux-2.6.27.33/arch/m68knommu/kernel/traps.c 2008-10-13 14:51:55.000000000 +0200 | |
416 | +++ linux-2.6.27.33-vs2.3.0.36.6/arch/m68knommu/kernel/traps.c 2008-10-13 14:54:20.000000000 +0200 | |
417 | @@ -79,8 +79,9 @@ void die_if_kernel(char *str, struct pt_ | |
d337f35e JR |
418 | printk(KERN_EMERG "d4: %08lx d5: %08lx a0: %08lx a1: %08lx\n", |
419 | fp->d4, fp->d5, fp->a0, fp->a1); | |
420 | ||
421 | - printk(KERN_EMERG "Process %s (pid: %d, stackpage=%08lx)\n", | |
422 | - current->comm, current->pid, PAGE_SIZE+(unsigned long)current); | |
423 | + printk(KERN_EMERG "Process %s (pid: %d[#%u], stackpage=%08lx)\n", | |
2380c486 | 424 | + current->comm, task_pid_nr(current), current->xid, |
d337f35e | 425 | + PAGE_SIZE+(unsigned long)current); |
2380c486 JR |
426 | show_stack(NULL, (unsigned long *)(fp + 1)); |
427 | add_taint(TAINT_DIE); | |
d337f35e | 428 | do_exit(SIGSEGV); |
bd427b06 AM |
429 | diff -NurpP --minimal linux-2.6.27.33/arch/mips/Kconfig linux-2.6.27.33-vs2.3.0.36.6/arch/mips/Kconfig |
430 | --- linux-2.6.27.33/arch/mips/Kconfig 2009-09-13 16:16:50.000000000 +0200 | |
431 | +++ linux-2.6.27.33-vs2.3.0.36.6/arch/mips/Kconfig 2009-05-15 22:57:04.000000000 +0200 | |
432 | @@ -2032,6 +2032,8 @@ source "fs/Kconfig" | |
d337f35e JR |
433 | |
434 | source "arch/mips/Kconfig.debug" | |
435 | ||
436 | +source "kernel/vserver/Kconfig" | |
437 | + | |
438 | source "security/Kconfig" | |
439 | ||
440 | source "crypto/Kconfig" | |
bd427b06 AM |
441 | diff -NurpP --minimal linux-2.6.27.33/arch/mips/kernel/linux32.c linux-2.6.27.33-vs2.3.0.36.6/arch/mips/kernel/linux32.c |
442 | --- linux-2.6.27.33/arch/mips/kernel/linux32.c 2009-09-13 16:16:50.000000000 +0200 | |
443 | +++ linux-2.6.27.33-vs2.3.0.36.6/arch/mips/kernel/linux32.c 2009-05-15 22:57:04.000000000 +0200 | |
444 | @@ -192,7 +192,7 @@ sys32_gettimeofday(struct compat_timeval | |
445 | { | |
446 | if (tv) { | |
447 | struct timeval ktv; | |
448 | - do_gettimeofday(&ktv); | |
449 | + vx_gettimeofday(&ktv); | |
450 | if (put_tv32(tv, &ktv)) | |
451 | return -EFAULT; | |
452 | } | |
453 | diff -NurpP --minimal linux-2.6.27.33/arch/mips/kernel/ptrace.c linux-2.6.27.33-vs2.3.0.36.6/arch/mips/kernel/ptrace.c | |
454 | --- linux-2.6.27.33/arch/mips/kernel/ptrace.c 2008-10-13 14:51:56.000000000 +0200 | |
455 | +++ linux-2.6.27.33-vs2.3.0.36.6/arch/mips/kernel/ptrace.c 2008-10-13 14:54:20.000000000 +0200 | |
2380c486 | 456 | @@ -25,6 +25,7 @@ |
d337f35e | 457 | #include <linux/security.h> |
2380c486 JR |
458 | #include <linux/audit.h> |
459 | #include <linux/seccomp.h> | |
d337f35e JR |
460 | +#include <linux/vs_base.h> |
461 | ||
462 | #include <asm/byteorder.h> | |
463 | #include <asm/cpu.h> | |
bd427b06 | 464 | @@ -171,6 +172,9 @@ long arch_ptrace(struct task_struct *chi |
d337f35e JR |
465 | { |
466 | int ret; | |
467 | ||
2380c486 | 468 | + if (!vx_check(vx_task_xid(child), VS_WATCH_P | VS_IDENT)) |
d337f35e JR |
469 | + goto out; |
470 | + | |
471 | switch (request) { | |
472 | /* when I and D space are separate, these will need to be fixed. */ | |
473 | case PTRACE_PEEKTEXT: /* read word at location addr. */ | |
bd427b06 AM |
474 | diff -NurpP --minimal linux-2.6.27.33/arch/mips/kernel/scall32-o32.S linux-2.6.27.33-vs2.3.0.36.6/arch/mips/kernel/scall32-o32.S |
475 | --- linux-2.6.27.33/arch/mips/kernel/scall32-o32.S 2009-09-13 16:16:50.000000000 +0200 | |
476 | +++ linux-2.6.27.33-vs2.3.0.36.6/arch/mips/kernel/scall32-o32.S 2009-05-15 22:57:04.000000000 +0200 | |
477 | @@ -600,7 +600,7 @@ einval: li v0, -EINVAL | |
d337f35e JR |
478 | sys sys_mq_timedreceive 5 |
479 | sys sys_mq_notify 2 /* 4275 */ | |
480 | sys sys_mq_getsetattr 3 | |
481 | - sys sys_ni_syscall 0 /* sys_vserver */ | |
482 | + sys sys_vserver 3 | |
483 | sys sys_waitid 5 | |
484 | sys sys_ni_syscall 0 /* available, was setaltroot */ | |
485 | sys sys_add_key 5 /* 4280 */ | |
bd427b06 AM |
486 | diff -NurpP --minimal linux-2.6.27.33/arch/mips/kernel/scall64-64.S linux-2.6.27.33-vs2.3.0.36.6/arch/mips/kernel/scall64-64.S |
487 | --- linux-2.6.27.33/arch/mips/kernel/scall64-64.S 2009-09-13 16:16:50.000000000 +0200 | |
488 | +++ linux-2.6.27.33-vs2.3.0.36.6/arch/mips/kernel/scall64-64.S 2009-05-15 22:57:04.000000000 +0200 | |
d337f35e JR |
489 | @@ -434,7 +434,7 @@ sys_call_table: |
490 | PTR sys_mq_timedreceive | |
491 | PTR sys_mq_notify | |
492 | PTR sys_mq_getsetattr /* 5235 */ | |
493 | - PTR sys_ni_syscall /* sys_vserver */ | |
494 | + PTR sys_vserver | |
495 | PTR sys_waitid | |
496 | PTR sys_ni_syscall /* available, was setaltroot */ | |
497 | PTR sys_add_key | |
bd427b06 AM |
498 | diff -NurpP --minimal linux-2.6.27.33/arch/mips/kernel/scall64-n32.S linux-2.6.27.33-vs2.3.0.36.6/arch/mips/kernel/scall64-n32.S |
499 | --- linux-2.6.27.33/arch/mips/kernel/scall64-n32.S 2009-09-13 16:16:50.000000000 +0200 | |
500 | +++ linux-2.6.27.33-vs2.3.0.36.6/arch/mips/kernel/scall64-n32.S 2009-05-15 22:57:04.000000000 +0200 | |
d337f35e JR |
501 | @@ -360,7 +360,7 @@ EXPORT(sysn32_call_table) |
502 | PTR compat_sys_mq_timedreceive | |
503 | PTR compat_sys_mq_notify | |
504 | PTR compat_sys_mq_getsetattr | |
505 | - PTR sys_ni_syscall /* 6240, sys_vserver */ | |
506 | + PTR sys32_vserver /* 6240 */ | |
2380c486 | 507 | PTR compat_sys_waitid |
d337f35e JR |
508 | PTR sys_ni_syscall /* available, was setaltroot */ |
509 | PTR sys_add_key | |
bd427b06 AM |
510 | diff -NurpP --minimal linux-2.6.27.33/arch/mips/kernel/scall64-o32.S linux-2.6.27.33-vs2.3.0.36.6/arch/mips/kernel/scall64-o32.S |
511 | --- linux-2.6.27.33/arch/mips/kernel/scall64-o32.S 2009-09-13 16:16:50.000000000 +0200 | |
512 | +++ linux-2.6.27.33-vs2.3.0.36.6/arch/mips/kernel/scall64-o32.S 2009-05-15 22:57:46.000000000 +0200 | |
513 | @@ -482,7 +482,7 @@ sys_call_table: | |
d337f35e JR |
514 | PTR compat_sys_mq_timedreceive |
515 | PTR compat_sys_mq_notify /* 4275 */ | |
516 | PTR compat_sys_mq_getsetattr | |
517 | - PTR sys_ni_syscall /* sys_vserver */ | |
518 | + PTR sys32_vserver | |
2380c486 | 519 | PTR sys_32_waitid |
d337f35e JR |
520 | PTR sys_ni_syscall /* available, was setaltroot */ |
521 | PTR sys_add_key /* 4280 */ | |
bd427b06 AM |
522 | diff -NurpP --minimal linux-2.6.27.33/arch/mips/kernel/traps.c linux-2.6.27.33-vs2.3.0.36.6/arch/mips/kernel/traps.c |
523 | --- linux-2.6.27.33/arch/mips/kernel/traps.c 2008-10-13 14:51:56.000000000 +0200 | |
524 | +++ linux-2.6.27.33-vs2.3.0.36.6/arch/mips/kernel/traps.c 2008-10-13 14:54:20.000000000 +0200 | |
525 | @@ -328,9 +328,10 @@ void show_registers(const struct pt_regs | |
2380c486 JR |
526 | |
527 | __show_regs(regs); | |
d337f35e | 528 | print_modules(); |
2380c486 JR |
529 | - printk("Process %s (pid: %d, threadinfo=%p, task=%p, tls=%0*lx)\n", |
530 | - current->comm, current->pid, current_thread_info(), current, | |
531 | - field, current_thread_info()->tp_value); | |
532 | + printk("Process %s (pid: %d:#%u, threadinfo=%p, task=%p, tls=%0*lx)\n", | |
533 | + current->comm, task_pid_nr(current), current->xid, | |
534 | + current_thread_info(), current, | |
535 | + field, current_thread_info()->tp_value); | |
536 | if (cpu_has_userlocal) { | |
537 | unsigned long tls; | |
538 | ||
bd427b06 AM |
539 | diff -NurpP --minimal linux-2.6.27.33/arch/mips/mm/fault.c linux-2.6.27.33-vs2.3.0.36.6/arch/mips/mm/fault.c |
540 | --- linux-2.6.27.33/arch/mips/mm/fault.c 2008-07-13 23:51:29.000000000 +0200 | |
541 | +++ linux-2.6.27.33-vs2.3.0.36.6/arch/mips/mm/fault.c 2008-10-13 14:54:20.000000000 +0200 | |
542 | @@ -178,7 +178,8 @@ out_of_memory: | |
543 | down_read(&mm->mmap_sem); | |
544 | goto survive; | |
545 | } | |
546 | - printk("VM: killing process %s\n", tsk->comm); | |
547 | + printk("VM: killing process %s(%d:#%u)\n", | |
548 | + tsk->comm, tsk->pid, tsk->xid); | |
549 | if (user_mode(regs)) | |
550 | do_group_exit(SIGKILL); | |
551 | goto no_context; | |
552 | diff -NurpP --minimal linux-2.6.27.33/arch/parisc/Kconfig linux-2.6.27.33-vs2.3.0.36.6/arch/parisc/Kconfig | |
553 | --- linux-2.6.27.33/arch/parisc/Kconfig 2008-10-13 14:51:56.000000000 +0200 | |
554 | +++ linux-2.6.27.33-vs2.3.0.36.6/arch/parisc/Kconfig 2008-10-13 14:54:20.000000000 +0200 | |
555 | @@ -279,6 +279,8 @@ source "fs/Kconfig" | |
d337f35e JR |
556 | |
557 | source "arch/parisc/Kconfig.debug" | |
558 | ||
559 | +source "kernel/vserver/Kconfig" | |
560 | + | |
561 | source "security/Kconfig" | |
562 | ||
563 | source "crypto/Kconfig" | |
bd427b06 AM |
564 | diff -NurpP --minimal linux-2.6.27.33/arch/parisc/kernel/syscall_table.S linux-2.6.27.33-vs2.3.0.36.6/arch/parisc/kernel/syscall_table.S |
565 | --- linux-2.6.27.33/arch/parisc/kernel/syscall_table.S 2008-07-13 23:51:29.000000000 +0200 | |
566 | +++ linux-2.6.27.33-vs2.3.0.36.6/arch/parisc/kernel/syscall_table.S 2008-10-13 14:54:20.000000000 +0200 | |
2380c486 | 567 | @@ -361,7 +361,7 @@ |
d337f35e JR |
568 | ENTRY_COMP(mbind) /* 260 */ |
569 | ENTRY_COMP(get_mempolicy) | |
570 | ENTRY_COMP(set_mempolicy) | |
571 | - ENTRY_SAME(ni_syscall) /* 263: reserved for vserver */ | |
572 | + ENTRY_DIFF(vserver) | |
573 | ENTRY_SAME(add_key) | |
574 | ENTRY_SAME(request_key) /* 265 */ | |
575 | ENTRY_SAME(keyctl) | |
bd427b06 AM |
576 | diff -NurpP --minimal linux-2.6.27.33/arch/parisc/kernel/sys_parisc32.c linux-2.6.27.33-vs2.3.0.36.6/arch/parisc/kernel/sys_parisc32.c |
577 | --- linux-2.6.27.33/arch/parisc/kernel/sys_parisc32.c 2008-07-13 23:51:29.000000000 +0200 | |
578 | +++ linux-2.6.27.33-vs2.3.0.36.6/arch/parisc/kernel/sys_parisc32.c 2008-10-13 14:54:20.000000000 +0200 | |
579 | @@ -203,11 +203,11 @@ static inline long get_ts32(struct times | |
580 | asmlinkage int | |
581 | sys32_gettimeofday(struct compat_timeval __user *tv, struct timezone __user *tz) | |
582 | { | |
583 | - extern void do_gettimeofday(struct timeval *tv); | |
584 | + extern void vx_gettimeofday(struct timeval *tv); | |
585 | ||
586 | if (tv) { | |
587 | struct timeval ktv; | |
588 | - do_gettimeofday(&ktv); | |
589 | + vx_gettimeofday(&ktv); | |
590 | if (put_compat_timeval(tv, &ktv)) | |
591 | return -EFAULT; | |
592 | } | |
593 | diff -NurpP --minimal linux-2.6.27.33/arch/parisc/kernel/traps.c linux-2.6.27.33-vs2.3.0.36.6/arch/parisc/kernel/traps.c | |
594 | --- linux-2.6.27.33/arch/parisc/kernel/traps.c 2009-09-13 16:16:50.000000000 +0200 | |
595 | +++ linux-2.6.27.33-vs2.3.0.36.6/arch/parisc/kernel/traps.c 2009-02-03 17:59:04.000000000 +0100 | |
2380c486 | 596 | @@ -236,8 +236,9 @@ void die_if_kernel(char *str, struct pt_ |
d337f35e JR |
597 | if (err == 0) |
598 | return; /* STFU */ | |
599 | ||
600 | - printk(KERN_CRIT "%s (pid %d): %s (code %ld) at " RFMT "\n", | |
2380c486 | 601 | - current->comm, task_pid_nr(current), str, err, regs->iaoq[0]); |
d337f35e | 602 | + printk(KERN_CRIT "%s (pid %d:#%u): %s (code %ld) at " RFMT "\n", |
2380c486 | 603 | + current->comm, task_pid_nr(current), current->xid, |
d337f35e JR |
604 | + str, err, regs->iaoq[0]); |
605 | #ifdef PRINT_USER_FAULTS | |
606 | /* XXX for debugging only */ | |
607 | show_regs(regs); | |
bd427b06 | 608 | @@ -269,8 +270,8 @@ KERN_CRIT " || | |
d337f35e JR |
609 | pdc_console_restart(); |
610 | ||
2380c486 JR |
611 | if (err) |
612 | - printk(KERN_CRIT "%s (pid %d): %s (code %ld)\n", | |
613 | - current->comm, task_pid_nr(current), str, err); | |
614 | + printk(KERN_CRIT "%s (pid %d:#%u): %s (code %ld)\n", | |
615 | + current->comm, task_pid_nr(current), current->xid, str, err); | |
616 | ||
617 | /* Wot's wrong wif bein' racy? */ | |
618 | if (current->thread.flags & PARISC_KERNEL_DEATH) { | |
bd427b06 AM |
619 | diff -NurpP --minimal linux-2.6.27.33/arch/parisc/mm/fault.c linux-2.6.27.33-vs2.3.0.36.6/arch/parisc/mm/fault.c |
620 | --- linux-2.6.27.33/arch/parisc/mm/fault.c 2008-07-13 23:51:29.000000000 +0200 | |
621 | +++ linux-2.6.27.33-vs2.3.0.36.6/arch/parisc/mm/fault.c 2008-10-13 14:54:20.000000000 +0200 | |
622 | @@ -210,8 +210,9 @@ bad_area: | |
d337f35e JR |
623 | |
624 | #ifdef PRINT_USER_FAULTS | |
625 | printk(KERN_DEBUG "\n"); | |
626 | - printk(KERN_DEBUG "do_page_fault() pid=%d command='%s' type=%lu address=0x%08lx\n", | |
2380c486 | 627 | - task_pid_nr(tsk), tsk->comm, code, address); |
d337f35e JR |
628 | + printk(KERN_DEBUG "do_page_fault() pid=%d:#%u " |
629 | + "command='%s' type=%lu address=0x%08lx\n", | |
2380c486 | 630 | + task_pid_nr(tsk), tsk->xid, tsk->comm, code, address); |
d337f35e JR |
631 | if (vma) { |
632 | printk(KERN_DEBUG "vm_start = 0x%08lx, vm_end = 0x%08lx\n", | |
633 | vma->vm_start, vma->vm_end); | |
bd427b06 | 634 | @@ -261,7 +262,8 @@ no_context: |
2380c486 JR |
635 | |
636 | out_of_memory: | |
637 | up_read(&mm->mmap_sem); | |
638 | - printk(KERN_CRIT "VM: killing process %s\n", current->comm); | |
639 | + printk(KERN_CRIT "VM: killing process %s(%d:#%u)\n", | |
640 | + current->comm, current->pid, current->xid); | |
641 | if (user_mode(regs)) | |
642 | do_group_exit(SIGKILL); | |
643 | goto no_context; | |
bd427b06 AM |
644 | diff -NurpP --minimal linux-2.6.27.33/arch/powerpc/Kconfig linux-2.6.27.33-vs2.3.0.36.6/arch/powerpc/Kconfig |
645 | --- linux-2.6.27.33/arch/powerpc/Kconfig 2009-09-13 16:16:50.000000000 +0200 | |
646 | +++ linux-2.6.27.33-vs2.3.0.36.6/arch/powerpc/Kconfig 2009-02-03 17:59:04.000000000 +0100 | |
647 | @@ -836,6 +836,8 @@ source "lib/Kconfig" | |
d337f35e JR |
648 | |
649 | source "arch/powerpc/Kconfig.debug" | |
650 | ||
651 | +source "kernel/vserver/Kconfig" | |
652 | + | |
653 | source "security/Kconfig" | |
654 | ||
655 | config KEYS_COMPAT | |
bd427b06 AM |
656 | diff -NurpP --minimal linux-2.6.27.33/arch/powerpc/kernel/irq.c linux-2.6.27.33-vs2.3.0.36.6/arch/powerpc/kernel/irq.c |
657 | --- linux-2.6.27.33/arch/powerpc/kernel/irq.c 2008-10-13 14:51:56.000000000 +0200 | |
658 | +++ linux-2.6.27.33-vs2.3.0.36.6/arch/powerpc/kernel/irq.c 2008-10-13 14:54:20.000000000 +0200 | |
659 | @@ -53,6 +53,7 @@ | |
660 | #include <linux/bootmem.h> | |
d337f35e | 661 | #include <linux/pci.h> |
2380c486 | 662 | #include <linux/debugfs.h> |
d337f35e JR |
663 | +#include <linux/vs_context.h> |
664 | ||
665 | #include <asm/uaccess.h> | |
666 | #include <asm/system.h> | |
bd427b06 AM |
667 | diff -NurpP --minimal linux-2.6.27.33/arch/powerpc/kernel/process.c linux-2.6.27.33-vs2.3.0.36.6/arch/powerpc/kernel/process.c |
668 | --- linux-2.6.27.33/arch/powerpc/kernel/process.c 2008-10-13 14:51:56.000000000 +0200 | |
669 | +++ linux-2.6.27.33-vs2.3.0.36.6/arch/powerpc/kernel/process.c 2008-10-13 14:54:20.000000000 +0200 | |
670 | @@ -513,8 +513,9 @@ void show_regs(struct pt_regs * regs) | |
2380c486 | 671 | #else |
d337f35e | 672 | printk("DAR: "REG", DSISR: "REG"\n", regs->dar, regs->dsisr); |
2380c486 | 673 | #endif |
d337f35e | 674 | - printk("TASK = %p[%d] '%s' THREAD: %p", |
2380c486 | 675 | - current, task_pid_nr(current), current->comm, task_thread_info(current)); |
d337f35e | 676 | + printk("TASK = %p[%d,#%u] '%s' THREAD: %p", |
2380c486 | 677 | + current, task_pid_nr(current), current->xid, |
d337f35e JR |
678 | + current->comm, task_thread_info(current)); |
679 | ||
680 | #ifdef CONFIG_SMP | |
2380c486 | 681 | printk(" CPU: %d", raw_smp_processor_id()); |
bd427b06 AM |
682 | diff -NurpP --minimal linux-2.6.27.33/arch/powerpc/kernel/sys_ppc32.c linux-2.6.27.33-vs2.3.0.36.6/arch/powerpc/kernel/sys_ppc32.c |
683 | --- linux-2.6.27.33/arch/powerpc/kernel/sys_ppc32.c 2008-10-13 14:51:56.000000000 +0200 | |
684 | +++ linux-2.6.27.33-vs2.3.0.36.6/arch/powerpc/kernel/sys_ppc32.c 2008-10-13 14:54:20.000000000 +0200 | |
685 | @@ -147,7 +147,7 @@ asmlinkage long compat_sys_gettimeofday( | |
686 | { | |
687 | if (tv) { | |
688 | struct timeval ktv; | |
689 | - do_gettimeofday(&ktv); | |
690 | + vx_gettimeofday(&ktv); | |
691 | if (put_tv32(tv, &ktv)) | |
692 | return -EFAULT; | |
693 | } | |
694 | diff -NurpP --minimal linux-2.6.27.33/arch/powerpc/kernel/traps.c linux-2.6.27.33-vs2.3.0.36.6/arch/powerpc/kernel/traps.c | |
695 | --- linux-2.6.27.33/arch/powerpc/kernel/traps.c 2008-10-13 14:51:56.000000000 +0200 | |
696 | +++ linux-2.6.27.33-vs2.3.0.36.6/arch/powerpc/kernel/traps.c 2008-10-13 14:54:20.000000000 +0200 | |
697 | @@ -941,8 +941,9 @@ void nonrecoverable_exception(struct pt_ | |
d337f35e JR |
698 | |
699 | void trace_syscall(struct pt_regs *regs) | |
700 | { | |
701 | - printk("Task: %p(%d), PC: %08lX/%08lX, Syscall: %3ld, Result: %s%ld %s\n", | |
2380c486 | 702 | - current, task_pid_nr(current), regs->nip, regs->link, regs->gpr[0], |
d337f35e | 703 | + printk("Task: %p(%d[#%u]), PC: %08lX/%08lX, Syscall: %3ld, Result: %s%ld %s\n", |
2380c486 | 704 | + current, task_pid_nr(current), current->xid, |
d337f35e JR |
705 | + regs->nip, regs->link, regs->gpr[0], |
706 | regs->ccr&0x10000000?"Error=":"", regs->gpr[3], print_tainted()); | |
707 | } | |
708 | ||
bd427b06 AM |
709 | diff -NurpP --minimal linux-2.6.27.33/arch/powerpc/kernel/vdso.c linux-2.6.27.33-vs2.3.0.36.6/arch/powerpc/kernel/vdso.c |
710 | --- linux-2.6.27.33/arch/powerpc/kernel/vdso.c 2008-10-13 14:51:56.000000000 +0200 | |
711 | +++ linux-2.6.27.33-vs2.3.0.36.6/arch/powerpc/kernel/vdso.c 2008-10-13 14:54:20.000000000 +0200 | |
d337f35e | 712 | @@ -22,6 +22,7 @@ |
d337f35e JR |
713 | #include <linux/security.h> |
714 | #include <linux/bootmem.h> | |
2380c486 | 715 | #include <linux/lmb.h> |
d337f35e JR |
716 | +#include <linux/vs_memory.h> |
717 | ||
718 | #include <asm/pgtable.h> | |
719 | #include <asm/system.h> | |
bd427b06 AM |
720 | diff -NurpP --minimal linux-2.6.27.33/arch/powerpc/mm/fault.c linux-2.6.27.33-vs2.3.0.36.6/arch/powerpc/mm/fault.c |
721 | --- linux-2.6.27.33/arch/powerpc/mm/fault.c 2008-10-13 14:51:56.000000000 +0200 | |
722 | +++ linux-2.6.27.33-vs2.3.0.36.6/arch/powerpc/mm/fault.c 2008-10-13 14:54:20.000000000 +0200 | |
723 | @@ -354,7 +354,8 @@ out_of_memory: | |
2380c486 JR |
724 | down_read(&mm->mmap_sem); |
725 | goto survive; | |
726 | } | |
727 | - printk("VM: killing process %s\n", current->comm); | |
728 | + printk("VM: killing process %s(%d:#%u)\n", | |
729 | + current->comm, current->pid, current->xid); | |
730 | if (user_mode(regs)) | |
731 | do_group_exit(SIGKILL); | |
732 | return SIGKILL; | |
bd427b06 AM |
733 | diff -NurpP --minimal linux-2.6.27.33/arch/s390/Kconfig linux-2.6.27.33-vs2.3.0.36.6/arch/s390/Kconfig |
734 | --- linux-2.6.27.33/arch/s390/Kconfig 2009-09-13 16:16:50.000000000 +0200 | |
735 | +++ linux-2.6.27.33-vs2.3.0.36.6/arch/s390/Kconfig 2009-02-03 17:59:04.000000000 +0100 | |
736 | @@ -588,6 +588,8 @@ source "fs/Kconfig" | |
d337f35e JR |
737 | |
738 | source "arch/s390/Kconfig.debug" | |
739 | ||
740 | +source "kernel/vserver/Kconfig" | |
741 | + | |
742 | source "security/Kconfig" | |
743 | ||
744 | source "crypto/Kconfig" | |
bd427b06 AM |
745 | diff -NurpP --minimal linux-2.6.27.33/arch/s390/kernel/compat_linux.c linux-2.6.27.33-vs2.3.0.36.6/arch/s390/kernel/compat_linux.c |
746 | --- linux-2.6.27.33/arch/s390/kernel/compat_linux.c 2008-07-13 23:51:29.000000000 +0200 | |
747 | +++ linux-2.6.27.33-vs2.3.0.36.6/arch/s390/kernel/compat_linux.c 2008-10-13 14:54:20.000000000 +0200 | |
748 | @@ -566,7 +566,7 @@ asmlinkage long sys32_gettimeofday(struc | |
749 | { | |
750 | if (tv) { | |
751 | struct timeval ktv; | |
752 | - do_gettimeofday(&ktv); | |
753 | + vx_gettimeofday(&ktv); | |
754 | if (put_tv32(tv, &ktv)) | |
755 | return -EFAULT; | |
756 | } | |
757 | diff -NurpP --minimal linux-2.6.27.33/arch/s390/kernel/ptrace.c linux-2.6.27.33-vs2.3.0.36.6/arch/s390/kernel/ptrace.c | |
758 | --- linux-2.6.27.33/arch/s390/kernel/ptrace.c 2008-10-13 14:51:57.000000000 +0200 | |
759 | +++ linux-2.6.27.33-vs2.3.0.36.6/arch/s390/kernel/ptrace.c 2008-10-13 14:54:20.000000000 +0200 | |
760 | @@ -35,6 +35,7 @@ | |
761 | #include <linux/signal.h> | |
762 | #include <linux/elf.h> | |
2380c486 | 763 | #include <linux/regset.h> |
d337f35e | 764 | +#include <linux/vs_base.h> |
bd427b06 | 765 | |
d337f35e | 766 | #include <asm/segment.h> |
bd427b06 AM |
767 | #include <asm/page.h> |
768 | diff -NurpP --minimal linux-2.6.27.33/arch/s390/kernel/syscalls.S linux-2.6.27.33-vs2.3.0.36.6/arch/s390/kernel/syscalls.S | |
769 | --- linux-2.6.27.33/arch/s390/kernel/syscalls.S 2009-09-13 16:16:50.000000000 +0200 | |
770 | +++ linux-2.6.27.33-vs2.3.0.36.6/arch/s390/kernel/syscalls.S 2009-02-03 17:59:04.000000000 +0100 | |
d337f35e JR |
771 | @@ -271,7 +271,7 @@ SYSCALL(sys_clock_settime,sys_clock_sett |
772 | SYSCALL(sys_clock_gettime,sys_clock_gettime,sys32_clock_gettime_wrapper) /* 260 */ | |
773 | SYSCALL(sys_clock_getres,sys_clock_getres,sys32_clock_getres_wrapper) | |
774 | SYSCALL(sys_clock_nanosleep,sys_clock_nanosleep,sys32_clock_nanosleep_wrapper) | |
775 | -NI_SYSCALL /* reserved for vserver */ | |
776 | +SYSCALL(sys_vserver,sys_vserver,sys32_vserver) | |
2380c486 | 777 | SYSCALL(sys_s390_fadvise64_64,sys_ni_syscall,sys32_fadvise64_64_wrapper) |
d337f35e JR |
778 | SYSCALL(sys_statfs64,sys_statfs64,compat_sys_statfs64_wrapper) |
779 | SYSCALL(sys_fstatfs64,sys_fstatfs64,compat_sys_fstatfs64_wrapper) | |
bd427b06 AM |
780 | diff -NurpP --minimal linux-2.6.27.33/arch/s390/mm/fault.c linux-2.6.27.33-vs2.3.0.36.6/arch/s390/mm/fault.c |
781 | --- linux-2.6.27.33/arch/s390/mm/fault.c 2008-07-13 23:51:29.000000000 +0200 | |
782 | +++ linux-2.6.27.33-vs2.3.0.36.6/arch/s390/mm/fault.c 2008-10-13 14:54:20.000000000 +0200 | |
783 | @@ -216,7 +216,8 @@ static int do_out_of_memory(struct pt_re | |
784 | down_read(&mm->mmap_sem); | |
785 | return 1; | |
786 | } | |
787 | - printk("VM: killing process %s\n", tsk->comm); | |
788 | + printk("VM: killing process %s(%d:#%u)\n", | |
789 | + tsk->comm, tsk->pid, tsk->xid); | |
790 | if (regs->psw.mask & PSW_MASK_PSTATE) | |
791 | do_group_exit(SIGKILL); | |
792 | do_no_context(regs, error_code, address); | |
793 | diff -NurpP --minimal linux-2.6.27.33/arch/sh/Kconfig linux-2.6.27.33-vs2.3.0.36.6/arch/sh/Kconfig | |
794 | --- linux-2.6.27.33/arch/sh/Kconfig 2008-10-13 14:51:57.000000000 +0200 | |
795 | +++ linux-2.6.27.33-vs2.3.0.36.6/arch/sh/Kconfig 2008-10-13 14:54:20.000000000 +0200 | |
796 | @@ -747,6 +747,8 @@ source "fs/Kconfig" | |
d337f35e JR |
797 | |
798 | source "arch/sh/Kconfig.debug" | |
799 | ||
800 | +source "kernel/vserver/Kconfig" | |
801 | + | |
802 | source "security/Kconfig" | |
803 | ||
804 | source "crypto/Kconfig" | |
bd427b06 AM |
805 | diff -NurpP --minimal linux-2.6.27.33/arch/sh/kernel/irq.c linux-2.6.27.33-vs2.3.0.36.6/arch/sh/kernel/irq.c |
806 | --- linux-2.6.27.33/arch/sh/kernel/irq.c 2008-10-13 14:51:57.000000000 +0200 | |
807 | +++ linux-2.6.27.33-vs2.3.0.36.6/arch/sh/kernel/irq.c 2008-10-13 14:54:20.000000000 +0200 | |
2380c486 JR |
808 | @@ -11,6 +11,7 @@ |
809 | #include <linux/module.h> | |
d337f35e JR |
810 | #include <linux/kernel_stat.h> |
811 | #include <linux/seq_file.h> | |
d337f35e | 812 | +#include <linux/vs_context.h> |
d337f35e | 813 | #include <asm/processor.h> |
2380c486 | 814 | #include <asm/machvec.h> |
d337f35e | 815 | #include <asm/uaccess.h> |
bd427b06 AM |
816 | diff -NurpP --minimal linux-2.6.27.33/arch/sh/kernel/vsyscall/vsyscall.c linux-2.6.27.33-vs2.3.0.36.6/arch/sh/kernel/vsyscall/vsyscall.c |
817 | --- linux-2.6.27.33/arch/sh/kernel/vsyscall/vsyscall.c 2008-07-13 23:51:29.000000000 +0200 | |
818 | +++ linux-2.6.27.33-vs2.3.0.36.6/arch/sh/kernel/vsyscall/vsyscall.c 2008-10-13 14:54:20.000000000 +0200 | |
2380c486 | 819 | @@ -19,6 +19,7 @@ |
d337f35e | 820 | #include <linux/elf.h> |
2380c486 JR |
821 | #include <linux/sched.h> |
822 | #include <linux/err.h> | |
d337f35e JR |
823 | +#include <linux/vs_memory.h> |
824 | ||
825 | /* | |
826 | * Should the kernel map a VDSO page into processes and pass its | |
bd427b06 AM |
827 | diff -NurpP --minimal linux-2.6.27.33/arch/sparc/Kconfig linux-2.6.27.33-vs2.3.0.36.6/arch/sparc/Kconfig |
828 | --- linux-2.6.27.33/arch/sparc/Kconfig 2008-10-13 14:51:58.000000000 +0200 | |
829 | +++ linux-2.6.27.33-vs2.3.0.36.6/arch/sparc/Kconfig 2008-10-13 14:54:20.000000000 +0200 | |
830 | @@ -305,6 +305,8 @@ source "fs/Kconfig" | |
d337f35e JR |
831 | |
832 | source "arch/sparc/Kconfig.debug" | |
833 | ||
834 | +source "kernel/vserver/Kconfig" | |
835 | + | |
836 | source "security/Kconfig" | |
837 | ||
838 | source "crypto/Kconfig" | |
bd427b06 AM |
839 | diff -NurpP --minimal linux-2.6.27.33/arch/sparc/kernel/ptrace.c linux-2.6.27.33-vs2.3.0.36.6/arch/sparc/kernel/ptrace.c |
840 | --- linux-2.6.27.33/arch/sparc/kernel/ptrace.c 2008-10-13 14:51:58.000000000 +0200 | |
841 | +++ linux-2.6.27.33-vs2.3.0.36.6/arch/sparc/kernel/ptrace.c 2008-10-13 14:54:20.000000000 +0200 | |
842 | @@ -22,6 +22,7 @@ | |
843 | #include <linux/regset.h> | |
844 | #include <linux/elf.h> | |
845 | #include <linux/tracehook.h> | |
846 | +#include <linux/vs_base.h> | |
847 | ||
848 | #include <asm/pgtable.h> | |
849 | #include <asm/system.h> | |
850 | diff -NurpP --minimal linux-2.6.27.33/arch/sparc/kernel/systbls.S linux-2.6.27.33-vs2.3.0.36.6/arch/sparc/kernel/systbls.S | |
851 | --- linux-2.6.27.33/arch/sparc/kernel/systbls.S 2009-09-13 16:16:51.000000000 +0200 | |
852 | +++ linux-2.6.27.33-vs2.3.0.36.6/arch/sparc/kernel/systbls.S 2009-02-03 17:59:04.000000000 +0100 | |
50e68740 JR |
853 | @@ -70,7 +70,7 @@ sys_call_table: |
854 | /*250*/ .long sparc_mremap, sys_sysctl, sys_getsid, sys_fdatasync, sys_nfsservctl | |
855 | /*255*/ .long sys_sync_file_range, sys_clock_settime, sys_clock_gettime, sys_clock_getres, sys_clock_nanosleep | |
856 | /*260*/ .long sys_sched_getaffinity, sys_sched_setaffinity, sys_timer_settime, sys_timer_gettime, sys_timer_getoverrun | |
857 | -/*265*/ .long sys_timer_delete, sys_timer_create, sys_nis_syscall, sys_io_setup, sys_io_destroy | |
858 | +/*265*/ .long sys_timer_delete, sys_timer_create, sys_vserver, sys_io_setup, sys_io_destroy | |
859 | /*270*/ .long sys_io_submit, sys_io_cancel, sys_io_getevents, sys_mq_open, sys_mq_unlink | |
860 | /*275*/ .long sys_mq_timedsend, sys_mq_timedreceive, sys_mq_notify, sys_mq_getsetattr, sys_waitid | |
861 | /*280*/ .long sys_tee, sys_add_key, sys_request_key, sys_keyctl, sys_openat | |
bd427b06 AM |
862 | diff -NurpP --minimal linux-2.6.27.33/arch/sparc/kernel/traps.c linux-2.6.27.33-vs2.3.0.36.6/arch/sparc/kernel/traps.c |
863 | --- linux-2.6.27.33/arch/sparc/kernel/traps.c 2008-10-13 14:51:58.000000000 +0200 | |
864 | +++ linux-2.6.27.33-vs2.3.0.36.6/arch/sparc/kernel/traps.c 2008-10-13 14:54:20.000000000 +0200 | |
865 | @@ -95,7 +95,8 @@ void die_if_kernel(char *str, struct pt_ | |
866 | " /_| \\__/ |_\\\n" | |
867 | " \\__U_/\n"); | |
868 | ||
869 | - printk("%s(%d): %s [#%d]\n", current->comm, task_pid_nr(current), str, ++die_counter); | |
870 | + printk("%s(%d[#%u]): %s [#%d]\n", current->comm, | |
871 | + task_pid_nr(current), current->xid, str, ++die_counter); | |
872 | show_regs(regs); | |
873 | add_taint(TAINT_DIE); | |
874 | ||
875 | diff -NurpP --minimal linux-2.6.27.33/arch/sparc/mm/fault.c linux-2.6.27.33-vs2.3.0.36.6/arch/sparc/mm/fault.c | |
876 | --- linux-2.6.27.33/arch/sparc/mm/fault.c 2008-10-13 14:51:58.000000000 +0200 | |
877 | +++ linux-2.6.27.33-vs2.3.0.36.6/arch/sparc/mm/fault.c 2008-10-13 14:54:20.000000000 +0200 | |
878 | @@ -318,7 +318,8 @@ no_context: | |
879 | */ | |
880 | out_of_memory: | |
881 | up_read(&mm->mmap_sem); | |
882 | - printk("VM: killing process %s\n", tsk->comm); | |
883 | + printk("VM: killing process %s(%d:#%u)\n", | |
884 | + tsk->comm, tsk->pid, tsk->xid); | |
885 | if (from_user) | |
886 | do_group_exit(SIGKILL); | |
887 | goto no_context; | |
888 | diff -NurpP --minimal linux-2.6.27.33/arch/sparc64/Kconfig linux-2.6.27.33-vs2.3.0.36.6/arch/sparc64/Kconfig | |
889 | --- linux-2.6.27.33/arch/sparc64/Kconfig 2009-09-13 16:16:51.000000000 +0200 | |
890 | +++ linux-2.6.27.33-vs2.3.0.36.6/arch/sparc64/Kconfig 2009-02-22 22:58:32.000000000 +0100 | |
891 | @@ -404,6 +404,8 @@ source "fs/Kconfig" | |
892 | ||
893 | source "arch/sparc64/Kconfig.debug" | |
894 | ||
895 | +source "kernel/vserver/Kconfig" | |
896 | + | |
897 | source "security/Kconfig" | |
898 | ||
899 | source "crypto/Kconfig" | |
900 | diff -NurpP --minimal linux-2.6.27.33/arch/sparc64/kernel/ptrace.c linux-2.6.27.33-vs2.3.0.36.6/arch/sparc64/kernel/ptrace.c | |
901 | --- linux-2.6.27.33/arch/sparc64/kernel/ptrace.c 2009-09-13 16:16:51.000000000 +0200 | |
902 | +++ linux-2.6.27.33-vs2.3.0.36.6/arch/sparc64/kernel/ptrace.c 2009-02-03 17:59:04.000000000 +0100 | |
903 | @@ -26,6 +26,7 @@ | |
904 | #include <linux/tracehook.h> | |
905 | #include <linux/compat.h> | |
906 | #include <linux/elf.h> | |
907 | +#include <linux/vs_base.h> | |
908 | ||
909 | #include <asm/asi.h> | |
910 | #include <asm/pgtable.h> | |
911 | diff -NurpP --minimal linux-2.6.27.33/arch/sparc64/kernel/sys_sparc32.c linux-2.6.27.33-vs2.3.0.36.6/arch/sparc64/kernel/sys_sparc32.c | |
912 | --- linux-2.6.27.33/arch/sparc64/kernel/sys_sparc32.c 2008-10-13 14:51:58.000000000 +0200 | |
913 | +++ linux-2.6.27.33-vs2.3.0.36.6/arch/sparc64/kernel/sys_sparc32.c 2008-10-13 14:54:20.000000000 +0200 | |
914 | @@ -532,7 +532,7 @@ asmlinkage long sys32_gettimeofday(struc | |
915 | { | |
916 | if (tv) { | |
917 | struct timeval ktv; | |
918 | - do_gettimeofday(&ktv); | |
919 | + vx_gettimeofday(&ktv); | |
920 | if (put_tv32(tv, &ktv)) | |
921 | return -EFAULT; | |
922 | } | |
923 | diff -NurpP --minimal linux-2.6.27.33/arch/sparc64/kernel/systbls.S linux-2.6.27.33-vs2.3.0.36.6/arch/sparc64/kernel/systbls.S | |
924 | --- linux-2.6.27.33/arch/sparc64/kernel/systbls.S 2009-09-13 16:16:51.000000000 +0200 | |
925 | +++ linux-2.6.27.33-vs2.3.0.36.6/arch/sparc64/kernel/systbls.S 2009-02-22 22:58:32.000000000 +0100 | |
50e68740 JR |
926 | @@ -71,7 +71,7 @@ sys_call_table32: |
927 | /*250*/ .word sys32_mremap, sys32_sysctl, sys32_getsid, sys_fdatasync, sys32_nfsservctl | |
928 | .word sys32_sync_file_range, compat_sys_clock_settime, compat_sys_clock_gettime, compat_sys_clock_getres, sys32_clock_nanosleep | |
929 | /*260*/ .word compat_sys_sched_getaffinity, compat_sys_sched_setaffinity, sys32_timer_settime, compat_sys_timer_gettime, sys_timer_getoverrun | |
930 | - .word sys_timer_delete, compat_sys_timer_create, sys_ni_syscall, compat_sys_io_setup, sys_io_destroy | |
931 | + .word sys_timer_delete, compat_sys_timer_create, sys32_vserver, compat_sys_io_setup, sys_io_destroy | |
932 | /*270*/ .word sys32_io_submit, sys_io_cancel, compat_sys_io_getevents, sys32_mq_open, sys_mq_unlink | |
933 | .word compat_sys_mq_timedsend, compat_sys_mq_timedreceive, compat_sys_mq_notify, compat_sys_mq_getsetattr, compat_sys_waitid | |
934 | /*280*/ .word sys32_tee, sys_add_key, sys_request_key, sys_keyctl, compat_sys_openat | |
bd427b06 | 935 | @@ -145,7 +145,7 @@ sys_call_table: |
50e68740 JR |
936 | /*250*/ .word sys_64_mremap, sys_sysctl, sys_getsid, sys_fdatasync, sys_nfsservctl |
937 | .word sys_sync_file_range, sys_clock_settime, sys_clock_gettime, sys_clock_getres, sys_clock_nanosleep | |
938 | /*260*/ .word sys_sched_getaffinity, sys_sched_setaffinity, sys_timer_settime, sys_timer_gettime, sys_timer_getoverrun | |
939 | - .word sys_timer_delete, sys_timer_create, sys_ni_syscall, sys_io_setup, sys_io_destroy | |
940 | + .word sys_timer_delete, sys_timer_create, sys_vserver, sys_io_setup, sys_io_destroy | |
941 | /*270*/ .word sys_io_submit, sys_io_cancel, sys_io_getevents, sys_mq_open, sys_mq_unlink | |
942 | .word sys_mq_timedsend, sys_mq_timedreceive, sys_mq_notify, sys_mq_getsetattr, sys_waitid | |
943 | /*280*/ .word sys_tee, sys_add_key, sys_request_key, sys_keyctl, sys_openat | |
bd427b06 AM |
944 | diff -NurpP --minimal linux-2.6.27.33/arch/sparc64/kernel/traps.c linux-2.6.27.33-vs2.3.0.36.6/arch/sparc64/kernel/traps.c |
945 | --- linux-2.6.27.33/arch/sparc64/kernel/traps.c 2009-09-13 16:16:51.000000000 +0200 | |
946 | +++ linux-2.6.27.33-vs2.3.0.36.6/arch/sparc64/kernel/traps.c 2009-03-25 14:32:29.000000000 +0100 | |
947 | @@ -2201,7 +2201,8 @@ void die_if_kernel(char *str, struct pt_ | |
948 | " /_| \\__/ |_\\\n" | |
949 | " \\__U_/\n"); | |
950 | ||
951 | - printk("%s(%d): %s [#%d]\n", current->comm, task_pid_nr(current), str, ++die_counter); | |
952 | + printk("%s(%d[#%u]): %s [#%d]\n", current->comm, | |
953 | + task_pid_nr(current), current->xid, str, ++die_counter); | |
954 | notify_die(DIE_OOPS, str, regs, 0, 255, SIGSEGV); | |
955 | __asm__ __volatile__("flushw"); | |
956 | show_regs(regs); | |
957 | diff -NurpP --minimal linux-2.6.27.33/arch/sparc64/mm/fault.c linux-2.6.27.33-vs2.3.0.36.6/arch/sparc64/mm/fault.c | |
958 | --- linux-2.6.27.33/arch/sparc64/mm/fault.c 2008-10-13 14:51:58.000000000 +0200 | |
959 | +++ linux-2.6.27.33-vs2.3.0.36.6/arch/sparc64/mm/fault.c 2008-10-13 14:54:20.000000000 +0200 | |
960 | @@ -452,7 +452,8 @@ handle_kernel_fault: | |
961 | out_of_memory: | |
962 | insn = get_fault_insn(regs, insn); | |
963 | up_read(&mm->mmap_sem); | |
964 | - printk("VM: killing process %s\n", current->comm); | |
965 | + printk("VM: killing process %s(%d:#%u)\n", | |
966 | + current->comm, current->pid, current->xid); | |
967 | if (!(regs->tstate & TSTATE_PRIV)) | |
968 | do_group_exit(SIGKILL); | |
969 | goto handle_kernel_fault; | |
970 | diff -NurpP --minimal linux-2.6.27.33/arch/um/Kconfig linux-2.6.27.33-vs2.3.0.36.6/arch/um/Kconfig | |
971 | --- linux-2.6.27.33/arch/um/Kconfig 2008-07-13 23:51:29.000000000 +0200 | |
972 | +++ linux-2.6.27.33-vs2.3.0.36.6/arch/um/Kconfig 2008-10-13 14:54:20.000000000 +0200 | |
973 | @@ -245,6 +245,8 @@ source "drivers/connector/Kconfig" | |
974 | ||
975 | source "fs/Kconfig" | |
976 | ||
977 | +source "kernel/vserver/Kconfig" | |
978 | + | |
979 | source "security/Kconfig" | |
980 | ||
981 | source "crypto/Kconfig" | |
982 | diff -NurpP --minimal linux-2.6.27.33/arch/um/kernel/trap.c linux-2.6.27.33-vs2.3.0.36.6/arch/um/kernel/trap.c | |
983 | --- linux-2.6.27.33/arch/um/kernel/trap.c 2008-07-13 23:51:29.000000000 +0200 | |
984 | +++ linux-2.6.27.33-vs2.3.0.36.6/arch/um/kernel/trap.c 2008-10-13 14:54:20.000000000 +0200 | |
985 | @@ -215,7 +215,8 @@ unsigned long segv(struct faultinfo fi, | |
986 | current->thread.arch.faultinfo = fi; | |
987 | force_sig_info(SIGBUS, &si, current); | |
988 | } else if (err == -ENOMEM) { | |
989 | - printk(KERN_INFO "VM: killing process %s\n", current->comm); | |
990 | + printk(KERN_INFO "VM: killing process %s(%d:#%u)\n", | |
991 | + current->comm, task_pid_nr(current), current->xid); | |
992 | do_exit(SIGKILL); | |
993 | } else { | |
994 | BUG_ON(err != -EFAULT); | |
995 | diff -NurpP --minimal linux-2.6.27.33/arch/x86/ia32/ia32entry.S linux-2.6.27.33-vs2.3.0.36.6/arch/x86/ia32/ia32entry.S | |
996 | --- linux-2.6.27.33/arch/x86/ia32/ia32entry.S 2009-09-13 16:16:51.000000000 +0200 | |
997 | +++ linux-2.6.27.33-vs2.3.0.36.6/arch/x86/ia32/ia32entry.S 2009-03-25 14:32:29.000000000 +0100 | |
998 | @@ -774,7 +774,7 @@ ia32_sys_call_table: | |
2380c486 JR |
999 | .quad sys_tgkill /* 270 */ |
1000 | .quad compat_sys_utimes | |
1001 | .quad sys32_fadvise64_64 | |
1002 | - .quad quiet_ni_syscall /* sys_vserver */ | |
1003 | + .quad sys32_vserver | |
1004 | .quad sys_mbind | |
1005 | .quad compat_sys_get_mempolicy /* 275 */ | |
1006 | .quad sys_set_mempolicy | |
bd427b06 AM |
1007 | diff -NurpP --minimal linux-2.6.27.33/arch/x86/Kconfig linux-2.6.27.33-vs2.3.0.36.6/arch/x86/Kconfig |
1008 | --- linux-2.6.27.33/arch/x86/Kconfig 2009-09-13 16:16:51.000000000 +0200 | |
1009 | +++ linux-2.6.27.33-vs2.3.0.36.6/arch/x86/Kconfig 2009-02-22 22:58:32.000000000 +0100 | |
1010 | @@ -1811,6 +1811,8 @@ source "fs/Kconfig" | |
d337f35e | 1011 | |
2380c486 | 1012 | source "arch/x86/Kconfig.debug" |
d337f35e JR |
1013 | |
1014 | +source "kernel/vserver/Kconfig" | |
1015 | + | |
1016 | source "security/Kconfig" | |
1017 | ||
1018 | source "crypto/Kconfig" | |
bd427b06 AM |
1019 | diff -NurpP --minimal linux-2.6.27.33/arch/x86/kernel/syscall_table_32.S linux-2.6.27.33-vs2.3.0.36.6/arch/x86/kernel/syscall_table_32.S |
1020 | --- linux-2.6.27.33/arch/x86/kernel/syscall_table_32.S 2009-09-13 16:16:51.000000000 +0200 | |
1021 | +++ linux-2.6.27.33-vs2.3.0.36.6/arch/x86/kernel/syscall_table_32.S 2009-02-03 17:59:04.000000000 +0100 | |
2380c486 JR |
1022 | @@ -272,7 +272,7 @@ ENTRY(sys_call_table) |
1023 | .long sys_tgkill /* 270 */ | |
1024 | .long sys_utimes | |
1025 | .long sys_fadvise64_64 | |
1026 | - .long sys_ni_syscall /* sys_vserver */ | |
1027 | + .long sys_vserver | |
1028 | .long sys_mbind | |
1029 | .long sys_get_mempolicy | |
1030 | .long sys_set_mempolicy | |
bd427b06 AM |
1031 | diff -NurpP --minimal linux-2.6.27.33/Documentation/vserver/debug.txt linux-2.6.27.33-vs2.3.0.36.6/Documentation/vserver/debug.txt |
1032 | --- linux-2.6.27.33/Documentation/vserver/debug.txt 1970-01-01 01:00:00.000000000 +0100 | |
1033 | +++ linux-2.6.27.33-vs2.3.0.36.6/Documentation/vserver/debug.txt 2008-10-13 14:54:20.000000000 +0200 | |
2380c486 | 1034 | @@ -0,0 +1,154 @@ |
d337f35e | 1035 | + |
2380c486 | 1036 | +debug_cvirt: |
d337f35e | 1037 | + |
2380c486 JR |
1038 | + 2 4 "vx_map_tgid: %p/%llx: %d -> %d" |
1039 | + "vx_rmap_tgid: %p/%llx: %d -> %d" | |
d337f35e | 1040 | + |
2380c486 | 1041 | +debug_dlim: |
d337f35e | 1042 | + |
2380c486 JR |
1043 | + 0 1 "ALLOC (%p,#%d)%c inode (%d)" |
1044 | + "FREE (%p,#%d)%c inode" | |
1045 | + 1 2 "ALLOC (%p,#%d)%c %lld bytes (%d)" | |
1046 | + "FREE (%p,#%d)%c %lld bytes" | |
1047 | + 2 4 "ADJUST: %lld,%lld on %ld,%ld [mult=%d]" | |
1048 | + 3 8 "ext3_has_free_blocks(%p): %lu<%lu+1, %c, %u!=%u r=%d" | |
1049 | + "ext3_has_free_blocks(%p): free=%lu, root=%lu" | |
1050 | + "rcu_free_dl_info(%p)" | |
1051 | + 4 10 "alloc_dl_info(%p,%d) = %p" | |
1052 | + "dealloc_dl_info(%p)" | |
1053 | + "get_dl_info(%p[#%d.%d])" | |
1054 | + "put_dl_info(%p[#%d.%d])" | |
1055 | + 5 20 "alloc_dl_info(%p,%d)*" | |
1056 | + 6 40 "__hash_dl_info: %p[#%d]" | |
1057 | + "__unhash_dl_info: %p[#%d]" | |
1058 | + 7 80 "locate_dl_info(%p,#%d) = %p" | |
1059 | + | |
1060 | +debug_misc: | |
1061 | + | |
1062 | + 0 1 "destroy_dqhash: %p [#0x%08x] c=%d" | |
1063 | + "new_dqhash: %p [#0x%08x]" | |
1064 | + "vroot[%d]_clr_dev: dev=%p[%lu,%d:%d]" | |
1065 | + "vroot[%d]_get_real_bdev: dev=%p[%lu,%d:%d]" | |
1066 | + "vroot[%d]_set_dev: dev=%p[%lu,%d:%d]" | |
1067 | + "vroot_get_real_bdev not set" | |
1068 |