]> Zhao Yanbai Git Server - minix.git/commitdiff
VM: mem_shared: allow re-pagefault 08/2808/1
authorBen Gras <ben@minix3.org>
Wed, 3 Sep 2014 11:42:30 +0000 (13:42 +0200)
committerBen Gras <ben@minix3.org>
Wed, 3 Sep 2014 12:32:54 +0000 (14:32 +0200)
Change-Id: Iffd0e265c03f064545c9689ac204c58335d32c9a

minix/servers/vm/mem_shared.c

index d51029111f41fde1393be14c3e57837cd1c4d32b..93e791dc48158c6081fc791deaf00c567624abbb 100644 (file)
@@ -131,7 +131,11 @@ static int shared_pagefault(struct vmproc *vmp, struct vir_region *region,
                return EINVAL;
        }
 
-       assert(ph->ph->phys == MAP_NONE);
+       if(ph->ph->phys != MAP_NONE) {
+               /* memory is there - pagefault does not need handling */
+               return OK;
+       }
+
        pb_free(ph->ph);
 
        if(!(pr = physblock_get(src_region, ph->offset))) {