Remove all inclusions of <linux/config.h>
[pandora-kernel.git] / arch / um / kernel / skas / tlb.c
index 6230999..27eb29c 100644 (file)
@@ -6,7 +6,6 @@
 
 #include "linux/stddef.h"
 #include "linux/sched.h"
-#include "linux/config.h"
 #include "linux/mm.h"
 #include "asm/page.h"
 #include "asm/pgtable.h"
 #include "os.h"
 #include "tlb.h"
 
-static void do_ops(union mm_context *mmu, struct host_vm_op *ops, int last)
+static int do_ops(union mm_context *mmu, struct host_vm_op *ops, int last,
+                 int finished, void **flush)
 {
        struct host_vm_op *op;
-       int i;
+        int i, ret = 0;
 
-       for(i = 0; i <= last; i++){
+        for(i = 0; i <= last && !ret; i++){
                op = &ops[i];
                switch(op->type){
                case MMAP:
-                        map(&mmu->skas.id, op->u.mmap.addr, op->u.mmap.len,
-                           op->u.mmap.r, op->u.mmap.w, op->u.mmap.x,
-                           op->u.mmap.fd, op->u.mmap.offset);
+                       ret = map(&mmu->skas.id, op->u.mmap.addr,
+                                 op->u.mmap.len, op->u.mmap.r, op->u.mmap.w,
+                                 op->u.mmap.x, op->u.mmap.fd,
+                                 op->u.mmap.offset, finished, flush);
                        break;
                case MUNMAP:
-                        unmap(&mmu->skas.id, (void *) op->u.munmap.addr,
-                             op->u.munmap.len);
+                       ret = unmap(&mmu->skas.id,
+                                   (void *) op->u.munmap.addr,
+                                   op->u.munmap.len, finished, flush);
                        break;
                case MPROTECT:
-                        protect(&mmu->skas.id, op->u.mprotect.addr,
-                                op->u.mprotect.len, op->u.mprotect.r,
-                                op->u.mprotect.w, op->u.mprotect.x);
+                       ret = protect(&mmu->skas.id, op->u.mprotect.addr,
+                                     op->u.mprotect.len, op->u.mprotect.r,
+                                     op->u.mprotect.w, op->u.mprotect.x,
+                                     finished, flush);
                        break;
                default:
                        printk("Unknown op type %d in do_ops\n", op->type);
                        break;
                }
        }
+
+       return ret;
 }
 
 extern int proc_mm;