diff options
Diffstat (limited to 'memide.c')
-rw-r--r-- | memide.c | 4 |
1 files changed, 2 insertions, 2 deletions
@@ -39,8 +39,8 @@ iderw(struct buf *b) { uchar *p; - if(!(b->flags & B_BUSY)) - panic("iderw: buf not busy"); + if(!holdingsleep(&b->lock)) + panic("iderw: buf not locked"); if((b->flags & (B_VALID|B_DIRTY)) == B_VALID) panic("iderw: nothing to do"); if(b->dev != 1) |