Make out-of-swap checks more robust.
Consider that the swap space is full when 99% of it is filled with pages that
are no longer present in memory. This prevents deadlocks when out-of-swap if
some swap ranges had I/O errors and have been marked as 'bad', or if some
pages are unreachable by the pagedaemon and still holding some slots.
Also introduce uvm_swapisfilled() to check if there are some free slots in
the swap. Note that we consider the swap space completly filled if it is not
possible to write a full cluster. This prevents deadlocks if a few slots are
never allocated.
ok miod@