diff options
author | Robert Morris <[email protected]> | 2017-08-09 06:54:45 -0400 |
---|---|---|
committer | Robert Morris <[email protected]> | 2017-08-09 06:54:45 -0400 |
commit | 70705966adb7a055582f76f2ecdb5ce9cd3c8a85 (patch) | |
tree | 9c1938e1a71740a3d98b0eed6e66169fc70ecf75 /bio.c | |
parent | da3b931ddbc66da95b916b95e5258f3a506ac521 (diff) | |
download | xv6-labs-70705966adb7a055582f76f2ecdb5ce9cd3c8a85.tar.gz xv6-labs-70705966adb7a055582f76f2ecdb5ce9cd3c8a85.tar.bz2 xv6-labs-70705966adb7a055582f76f2ecdb5ce9cd3c8a85.zip |
comment fixes
Diffstat (limited to 'bio.c')
-rw-r--r-- | bio.c | 6 |
1 files changed, 3 insertions, 3 deletions
@@ -75,9 +75,9 @@ bget(uint dev, uint blockno) } } - // Not cached; recycle some unused buffer and clean buffer - // "clean" because B_DIRTY and not locked means log.c - // hasn't yet committed the changes to the buffer. + // Not cached; recycle an unused buffer. + // Even if refcnt==0, B_DIRTY indicates a buffer is in use + // because log.c has modified it but not yet committed it. for(b = bcache.head.prev; b != &bcache.head; b = b->prev){ if(b->refcnt == 0 && (b->flags & B_DIRTY) == 0) { b->dev = dev; |