summaryrefslogtreecommitdiff
path: root/console.c
diff options
context:
space:
mode:
authorRuss Cox <[email protected]>2009-08-30 23:02:08 -0700
committerRuss Cox <[email protected]>2009-08-30 23:02:08 -0700
commit48755214c9a02d6249caf3126d3b41d67eda4730 (patch)
tree2edc8b996fd7c3ef2da8876d657140e242999d93 /console.c
parent0aef8914959af9e472852611eb6352c211093d35 (diff)
downloadxv6-labs-48755214c9a02d6249caf3126d3b41d67eda4730.tar.gz
xv6-labs-48755214c9a02d6249caf3126d3b41d67eda4730.tar.bz2
xv6-labs-48755214c9a02d6249caf3126d3b41d67eda4730.zip
assorted fixes:
* rename c/cp to cpu/proc * rename cpu.context to cpu.scheduler * fix some comments * formatting for printout
Diffstat (limited to 'console.c')
-rw-r--r--console.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/console.c b/console.c
index 9d2ef60..0613a47 100644
--- a/console.c
+++ b/console.c
@@ -59,7 +59,7 @@ cprintf(char *fmt, ...)
if(locking)
acquire(&cons.lock);
- argp = (uint*)(void*)&fmt + 1;
+ argp = (uint*)(void*)(&fmt + 1);
state = 0;
for(i = 0; (c = fmt[i] & 0xff) != 0; i++){
if(c != '%'){
@@ -106,7 +106,7 @@ panic(char *s)
cli();
cons.locking = 0;
- cprintf("cpu%d: panic: ", cpu());
+ cprintf("cpu%d: panic: ", cpu->id);
cprintf(s);
cprintf("\n");
getcallerpcs(&s, pcs);
@@ -229,7 +229,7 @@ consoleread(struct inode *ip, char *dst, int n)
acquire(&input.lock);
while(n > 0){
while(input.r == input.w){
- if(cp->killed){
+ if(proc->killed){
release(&input.lock);
ilock(ip);
return -1;