log 49 kernel/log.c struct log log; log 60 kernel/log.c initlock(&log.lock, "log"); log 61 kernel/log.c log.start = sb->logstart; log 62 kernel/log.c log.size = sb->nlog; log 63 kernel/log.c log.dev = dev; log 73 kernel/log.c for (tail = 0; tail < log.lh.n; tail++) { log 74 kernel/log.c struct buf *lbuf = bread(log.dev, log.start+tail+1); // read log block log 75 kernel/log.c struct buf *dbuf = bread(log.dev, log.lh.block[tail]); // read dst log 89 kernel/log.c struct buf *buf = bread(log.dev, log.start); log 92 kernel/log.c log.lh.n = lh->n; log 93 kernel/log.c for (i = 0; i < log.lh.n; i++) { log 94 kernel/log.c log.lh.block[i] = lh->block[i]; log 105 kernel/log.c struct buf *buf = bread(log.dev, log.start); log 108 kernel/log.c hb->n = log.lh.n; log 109 kernel/log.c for (i = 0; i < log.lh.n; i++) { log 110 kernel/log.c hb->block[i] = log.lh.block[i]; log 121 kernel/log.c log.lh.n = 0; log 129 kernel/log.c acquire(&log.lock); log 131 kernel/log.c if(log.committing){ log 132 kernel/log.c sleep(&log, &log.lock); log 133 kernel/log.c } else if(log.lh.n + (log.outstanding+1)*MAXOPBLOCKS > LOGSIZE){ log 135 kernel/log.c sleep(&log, &log.lock); log 137 kernel/log.c log.outstanding += 1; log 138 kernel/log.c release(&log.lock); log 151 kernel/log.c acquire(&log.lock); log 152 kernel/log.c log.outstanding -= 1; log 153 kernel/log.c if(log.committing) log 155 kernel/log.c if(log.outstanding == 0){ log 157 kernel/log.c log.committing = 1; log 162 kernel/log.c wakeup(&log); log 164 kernel/log.c release(&log.lock); log 170 kernel/log.c acquire(&log.lock); log 171 kernel/log.c log.committing = 0; log 172 kernel/log.c wakeup(&log); log 173 kernel/log.c release(&log.lock); log 183 kernel/log.c for (tail = 0; tail < log.lh.n; tail++) { log 184 kernel/log.c struct buf *to = bread(log.dev, log.start+tail+1); // log block log 185 kernel/log.c struct buf *from = bread(log.dev, log.lh.block[tail]); // cache block log 196 kernel/log.c if (log.lh.n > 0) { log 200 kernel/log.c log.lh.n = 0; log 219 kernel/log.c acquire(&log.lock); log 220 kernel/log.c if (log.lh.n >= LOGSIZE || log.lh.n >= log.size - 1) log 222 kernel/log.c if (log.outstanding < 1) log 225 kernel/log.c for (i = 0; i < log.lh.n; i++) { log 226 kernel/log.c if (log.lh.block[i] == b->blockno) // log absorption log 229 kernel/log.c log.lh.block[i] = b->blockno; log 230 kernel/log.c if (i == log.lh.n) { // Add new block to log? log 232 kernel/log.c log.lh.n++; log 234 kernel/log.c release(&log.lock);