Merge branch 'master' into upstream
[pandora-kernel.git] / arch / x86_64 / mm / init.c
index 4c0c00e..ec31534 100644 (file)
@@ -711,33 +711,44 @@ int kern_addr_valid(unsigned long addr)
 extern int exception_trace, page_fault_trace;
 
 static ctl_table debug_table2[] = {
-       { 99, "exception-trace", &exception_trace, sizeof(int), 0644, NULL,
-         proc_dointvec },
-       { 0, }
+       {
+               .ctl_name       = 99,
+               .procname       = "exception-trace",
+               .data           = &exception_trace,
+               .maxlen         = sizeof(int),
+               .mode           = 0644,
+               .proc_handler   = proc_dointvec
+       },
+       {}
 }; 
 
 static ctl_table debug_root_table2[] = { 
-       { .ctl_name = CTL_DEBUG, .procname = "debug", .mode = 0555, 
-          .child = debug_table2 }, 
-       { 0 }, 
+       {
+               .ctl_name = CTL_DEBUG,
+               .procname = "debug",
+               .mode = 0555,
+               .child = debug_table2
+       },
+       {}
 }; 
 
 static __init int x8664_sysctl_init(void)
 { 
-       register_sysctl_table(debug_root_table2, 1);
+       register_sysctl_table(debug_root_table2);
        return 0;
 }
 __initcall(x8664_sysctl_init);
 #endif
 
-/* A pseudo VMAs to allow ptrace access for the vsyscall page.   This only
+/* A pseudo VMA to allow ptrace access for the vsyscall page.  This only
    covers the 64bit vsyscall page now. 32bit has a real VMA now and does
    not need special handling anymore. */
 
 static struct vm_area_struct gate_vma = {
        .vm_start = VSYSCALL_START,
-       .vm_end = VSYSCALL_END,
-       .vm_page_prot = PAGE_READONLY
+       .vm_end = VSYSCALL_START + (VSYSCALL_MAPPED_PAGES << PAGE_SHIFT),
+       .vm_page_prot = PAGE_READONLY_EXEC,
+       .vm_flags = VM_READ | VM_EXEC
 };
 
 struct vm_area_struct *get_gate_vma(struct task_struct *tsk)