> [...] You will obviously _not_ shoot down allocated and still used
> bios, no matter how long they are going to take. So your fixed size
> pool will run out in certain (maybe weird) conditions. If you cannot
> resize (alloc additional mem from standard VM) you are just dead.
sure, the pool will run out under heavy VM load. Will it stay empty
forever? Nope, because all mempool users are *required* to deallocate the
buffer after some (reasonable) timeout. (such as IO latency.) This is
pretty much by definition. (Sure there might be weird cases like IO
failure timeouts, but sooner or later the buffer will be returned, and it
will be reused.)
(by the way, this is true for every other reservation solution as well,
just look at the patches. You wont resize on the fly whenever there is
shortage - thats the problem with shortages, there just wont be more RAM.
If anyone uses reserved pools and doesnt release those buffers then we are
deadlocked. Memory reserves *must not* be used as a kmalloc pool. Doing
that can be considered an advanced form of a 'memory leak'.)
(and there is mempool_resize() if some aspect of the device is changed.)
Ingo
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/