summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAlexey Kardashevskiy2019-02-27 09:51:46 +0100
committerDavid Gibson2019-03-12 00:50:59 +0100
commit3cdd801b0b65ec3fbb9280a2fa22976ad96645b0 (patch)
tree8a0033c0240ab8d93d27da262a8bef9f821fd308
parentvfio/spapr: Fix indirect levels calculation (diff)
downloadqemu-3cdd801b0b65ec3fbb9280a2fa22976ad96645b0.tar.gz
qemu-3cdd801b0b65ec3fbb9280a2fa22976ad96645b0.tar.xz
qemu-3cdd801b0b65ec3fbb9280a2fa22976ad96645b0.zip
vfio/spapr: Rename local systempagesize variable
The "systempagesize" name suggests that it is the host system page size while it is the smallest page size of memory backing the guest RAM so let's rename it to stop confusion. This should cause no behavioral change. Signed-off-by: Alexey Kardashevskiy <aik@ozlabs.ru> Message-Id: <20190227085149.38596-4-aik@ozlabs.ru> Signed-off-by: David Gibson <david@gibson.dropbear.id.au>
-rw-r--r--hw/vfio/spapr.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/hw/vfio/spapr.c b/hw/vfio/spapr.c
index 88437a79e6..57fe758e54 100644
--- a/hw/vfio/spapr.c
+++ b/hw/vfio/spapr.c
@@ -148,14 +148,14 @@ int vfio_spapr_create_window(VFIOContainer *container,
uint64_t pagesize = memory_region_iommu_get_min_page_size(iommu_mr);
unsigned entries, bits_total, bits_per_level, max_levels;
struct vfio_iommu_spapr_tce_create create = { .argsz = sizeof(create) };
- long systempagesize = qemu_getrampagesize();
+ long rampagesize = qemu_getrampagesize();
/*
* The host might not support the guest supported IOMMU page size,
* so we will use smaller physical IOMMU pages to back them.
*/
- if (pagesize > systempagesize) {
- pagesize = systempagesize;
+ if (pagesize > rampagesize) {
+ pagesize = rampagesize;
}
pagesize = 1ULL << (63 - clz64(container->pgsizes &
(pagesize | (pagesize - 1))));