ECRecPred assumes recovering any number of chunk is possible as long as
at least K chunks are available. It builds the want() set accordingly in
the constructor and arbitrarily set the first K chunks. But it would be
the same if it set the last K chunks.
While this is correct for jerasure and isa plugins, it is not true in
general. The predicate should assume that all chunks are going to be
recovered and return true if they can all be recovered. Otherwise, the
following can happen:
* a PG has chunks 0,1,2,3 for K=2, M=2
* ECRecPred is initialized a set want to 0,1 because K=2
* ECRecPred claims the plugin can recover when provided 0,1
* the plugin is then required to recover 0,1 using 2,3 and fails
This can happen for the LRC plugin with k=4,m=2,l=3 which is
01234567
DDc_DDc_
DDDc____
____DDDc
and if chunks 0,1,2,3 are missing there is no way to recover chunks
4,5,6,7.
Signed-off-by: Loic Dachary <loic-201408@dachary.org>