aboutsummaryrefslogtreecommitdiff
path: root/pk/syscall.c
diff options
context:
space:
mode:
authorAndrew Waterman <waterman@s144.Millennium.Berkeley.EDU>2011-11-11 03:40:24 -0800
committerAndrew Waterman <waterman@s144.Millennium.Berkeley.EDU>2011-11-11 03:40:24 -0800
commit8717517e048ff866167d6eee6c6d97225f0cd169 (patch)
treeab36a881f5f6700fb5d30e3abc5580be0c088002 /pk/syscall.c
parent2f5776b244a4a2a8297fee9e0160c835430e1f06 (diff)
downloadpk-8717517e048ff866167d6eee6c6d97225f0cd169.zip
pk-8717517e048ff866167d6eee6c6d97225f0cd169.tar.gz
pk-8717517e048ff866167d6eee6c6d97225f0cd169.tar.bz2
Synced up PK with supervisor changes/asm syntax
You must upgrade to the latest compiler and ISA simulator to build and run this version of the PK.
Diffstat (limited to 'pk/syscall.c')
-rw-r--r--pk/syscall.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/pk/syscall.c b/pk/syscall.c
index 85c853b..f4c4f92 100644
--- a/pk/syscall.c
+++ b/pk/syscall.c
@@ -95,7 +95,7 @@ sysret_t sys_unlink(const char* name, size_t len)
sysret_t sys_brk(size_t pos)
{
- if(pos > (mfpcr(PCR_MEMSIZE) << MEMSIZE_SHIFT))
+ if(pos / (1024 * 1024) >= mem_mb)
return (sysret_t){-1, ENOMEM};
return (sysret_t){0,0};
}