while (TRUE) {
struct proc *restarting;
-#if 0
-if(!(n++ % 100000)) {
- int i;
- kprintf("switch %8d reload %8d\n", cr3switch, cr3reload);
-}
-#endif
-
restarting = vmrestart_check(&m);
softnotify_check();
if(softnotify)
/* Block needed has been found. */
if (bp->b_count == 0) rm_lru(bp);
bp->b_count++; /* record that block is in use */
+ ASSERT(bp->b_bytes == fs_block_size);
ASSERT(bp->b_dev == dev);
ASSERT(bp->b_dev != NO_DEV);
ASSERT(bp->bp);
if(bp->b_bytes < fs_block_size) {
static int n = 0;
phys_bytes ph;
- if(bp->b_bytes > 0)
- printf("MFS: WARNING: throwing away %d bytes!\n",
- bp->b_bytes);
+ ASSERT(!bp->bp);
+ ASSERT(bp->b_bytes == 0);
if(!(bp->bp = alloc_contig(fs_block_size, 0, &ph)))
panic(__FILE__,"couldn't allocate FS buffer", n);
bp->b_bytes = fs_block_size;