diff options
| author | Frans Kaashoek <kaashoek@mit.edu> | 2019-07-02 20:52:30 -0400 | 
|---|---|---|
| committer | Frans Kaashoek <kaashoek@mit.edu> | 2019-07-02 20:52:30 -0400 | 
| commit | ccf299850b51bb6f899765cc41a826d903e9e885 (patch) | |
| tree | e29a70fbb50897dd71547624422fe7ab694b6c93 /kernel | |
| parent | 26f306113a1b4057ac1f59050213c8f62c3a211a (diff) | |
| download | xv6-labs-ccf299850b51bb6f899765cc41a826d903e9e885.tar.gz xv6-labs-ccf299850b51bb6f899765cc41a826d903e9e885.tar.bz2 xv6-labs-ccf299850b51bb6f899765cc41a826d903e9e885.zip | |
Remove some debugging code
Diffstat (limited to 'kernel')
| -rw-r--r-- | kernel/spinlock.c | 9 | 
1 files changed, 1 insertions, 8 deletions
| diff --git a/kernel/spinlock.c b/kernel/spinlock.c index 1d0b16a..5a44a46 100644 --- a/kernel/spinlock.c +++ b/kernel/spinlock.c @@ -47,16 +47,9 @@ acquire(struct spinlock *lk)  void  release(struct spinlock *lk)  { -  uint64 x; -  asm volatile("mv %0, ra" : "=r" (x) ); -  if(!holding(lk)) { -    printf("%p: !holding %d %s %p %p %p %p\n", mycpu(), lk->locked, lk->name, lk->cpu, -           lk->last_release, lk->last_pc, x); +  if(!holding(lk))      panic("release"); -  } -  lk->last_release = lk->cpu; -  lk->last_pc  = x;    lk->cpu = 0;    // Tell the C compiler and the CPU to not move loads or stores | 
