Go to file
Ben Gras d844d2a547 Fixed nasty bug that would cause FS to loop forever in rw_scattered (while
syncing, for instance) if blocks are unwritable. This could happen if:

  . write goes beyond device boundary to a block device
  . write is done for a complete block or more; thus the
    block is not retrieved first (at which point it would be noticed
    it doesn't exist), but the buffer is simply allocated
  . at write time, the device i/o doesn't succeed, but rw_scattered
    doesn't understand this and loops forever trying to get the block
    written.

Currently, if no blocks can be written, the loop aborts, leaving all
buffers intact but potentially dirty. When invalidate() is called on the
device, the buffers will disappear (even if dirty). Same story for if
the buffer is removed due to rmed from lru chain. There's not much we
can do about this, however - we can't keep these blocks around, forever
occupying a buffer in the buffer cache.

The second part of the solution is not to let unwritable buffers be
created in the first place. How to do this, however, without doing a
wasteful read first?

It looks like this code was in 2.0.4 too.
2005-06-19 22:33:49 +00:00
boot Updated boot monitor help menu. 2005-06-17 11:52:55 +00:00
commands Made mkfs a little smarter about how to report empty devices. 2005-06-19 22:28:05 +00:00
drivers Made libpci recognize my pci controller at home (again) 2005-06-19 22:11:04 +00:00
etc Fixes for /root homedir. 2005-06-17 13:48:16 +00:00
include Various select() support flags, prototypes, definitions. 2005-06-17 13:34:47 +00:00
kernel Changed arguments of timer library functions. 2005-06-17 13:36:01 +00:00
lib Added (fake) readlink(). 2005-06-17 13:47:29 +00:00
man Started select() manpage. 2005-06-17 13:35:21 +00:00
servers Fixed nasty bug that would cause FS to loop forever in rw_scattered (while 2005-06-19 22:33:49 +00:00
test Select test-set imported from the minix contributions, with permission 2005-06-17 13:45:40 +00:00
tools Fixed various nits in the make/release process. 2005-06-17 16:28:36 +00:00
LICENSE Initial revision 2005-04-21 14:53:53 +00:00
Makefile Fixed various nits in the make/release process. 2005-06-17 16:28:36 +00:00