diff options
author | Alexey Kardashevskiy <aik@ozlabs.ru> | 2019-02-27 19:51:45 +1100 |
---|---|---|
committer | David Gibson <david@gibson.dropbear.id.au> | 2019-03-12 10:50:59 +1100 |
commit | 16107998761c1ce97d5c1d56a3e7092acb27d8d1 (patch) | |
tree | 9d40ef4049bcf7036fcab0e40855700438b65517 /COPYING.LIB | |
parent | 377b155bde451d5ac545fbdcdfbf6ca17a4228f5 (diff) |
vfio/spapr: Fix indirect levels calculation
The current code assumes that we can address more bits on a PCI bus
for DMA than we really can but there is no way knowing the actual limit.
This makes a better guess for the number of levels and if the kernel
fails to allocate that, this increases the level numbers till succeeded
or reached the 64bit limit.
This adds levels to the trace point.
This may cause the kernel to warn about failed allocation:
[65122.837458] Failed to allocate a TCE memory, level shift=28
which might happen if MAX_ORDER is not large enough as it can vary:
https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/tree/arch/powerpc/Kconfig?h=v5.0-rc2#n727
Signed-off-by: Alexey Kardashevskiy <aik@ozlabs.ru>
Message-Id: <20190227085149.38596-3-aik@ozlabs.ru>
Signed-off-by: David Gibson <david@gibson.dropbear.id.au>
Diffstat (limited to 'COPYING.LIB')
0 files changed, 0 insertions, 0 deletions