summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRobert Morris <[email protected]>2022-08-10 06:00:57 -0400
committerRobert Morris <[email protected]>2022-08-10 06:00:57 -0400
commit7d573bae2ab70f0d0bd1807f0099c00e8f9e24f2 (patch)
tree22d29d4a7687dc05ad6785ca46a317848ca269a8
parentf4b3edf5ab211c6dfbb2befb1a4c1b6bd26e4222 (diff)
parent2462656f215822ffb3bcd854ddc68b3894058c59 (diff)
downloadxv6-labs-7d573bae2ab70f0d0bd1807f0099c00e8f9e24f2.tar.gz
xv6-labs-7d573bae2ab70f0d0bd1807f0099c00e8f9e24f2.tar.bz2
xv6-labs-7d573bae2ab70f0d0bd1807f0099c00e8f9e24f2.zip
Merge branch 'riscv' of g.csail.mit.edu:xv6-dev into riscv
-rw-r--r--kernel/kalloc.c2
-rw-r--r--kernel/printf.c1
-rw-r--r--mkfs/mkfs.c2
-rw-r--r--user/ls.c1
4 files changed, 4 insertions, 2 deletions
diff --git a/kernel/kalloc.c b/kernel/kalloc.c
index fa6a0ac..0699e7e 100644
--- a/kernel/kalloc.c
+++ b/kernel/kalloc.c
@@ -39,7 +39,7 @@ freerange(void *pa_start, void *pa_end)
kfree(p);
}
-// Free the page of physical memory pointed at by v,
+// Free the page of physical memory pointed at by pa,
// which normally should have been returned by a
// call to kalloc(). (The exception is when
// initializing the allocator; see kinit above.)
diff --git a/kernel/printf.c b/kernel/printf.c
index e1347de..1a50203 100644
--- a/kernel/printf.c
+++ b/kernel/printf.c
@@ -109,6 +109,7 @@ printf(char *fmt, ...)
break;
}
}
+ va_end(ap);
if(locking)
release(&pr.lock);
diff --git a/mkfs/mkfs.c b/mkfs/mkfs.c
index 9ad4abb..1ec326b 100644
--- a/mkfs/mkfs.c
+++ b/mkfs/mkfs.c
@@ -42,7 +42,7 @@ uint ialloc(ushort type);
void iappend(uint inum, void *p, int n);
void die(const char *);
-// convert to intel byte order
+// convert to riscv byte order
ushort
xshort(ushort x)
{
diff --git a/user/ls.c b/user/ls.c
index b54d951..c67b84b 100644
--- a/user/ls.c
+++ b/user/ls.c
@@ -42,6 +42,7 @@ ls(char *path)
}
switch(st.type){
+ case T_DEVICE:
case T_FILE:
printf("%s %d %d %l\n", fmtname(path), st.type, st.ino, st.size);
break;