mirror_qemu/include/hw/ppc
David Gibson 715c54071a pseries: Simplify handling of the hash page table fd
When migrating the 'pseries' machine type with KVM, we use a special fd
to access the hash page table stored within KVM.  Usually, this fd is
opened at the beginning of migration, and kept open until the migration
is complete.

However, if there is a guest reset during the migration, the fd can become
stale and we need to re-open it.  At the moment we use an 'htab_fd_stale'
flag in sPAPRMachineState to signal this, which is checked in the migration
iterators.

But that's rather ugly.  It's simpler to just close and invalidate the
fd on reset, and lazily re-open it in migration if necessary.  This patch
implements that change.

This requires a small addition to the machine state's instance_init,
so that htab_fd is initialized to -1 (telling the migration code it
needs to open it) instead of 0, which could be a valid fd.

Signed-off-by: David Gibson <david@gibson.dropbear.id.au>
Reviewed-by: Alexey Kardashevskiy <aik@ozlabs.ru>
2016-02-17 09:59:30 +11:00
..
mac_dbdma.h macio: remove remainder_len DBDMA_io property 2015-06-04 20:25:39 -04:00
openpic.h intc/openpic_kvm: Fix QOM and build issues 2013-07-01 01:11:15 +02:00
ppc.h PPC: mac99: Move NVRAM to page boundary when necessary 2014-09-08 12:50:47 +02:00
ppc4xx.h hw: move headers to include/ 2013-04-08 18:13:10 +02:00
ppc_e500.h intc/openpic: Build openpic only once 2013-07-09 21:33:02 +02:00
spapr.h pseries: Simplify handling of the hash page table fd 2016-02-17 09:59:30 +11:00
spapr_drc.h spapr_drc: use RTAS return codes for methods called by RTAS 2015-09-23 10:51:10 +10:00
spapr_vio.h spapr vio: fix to incomplete QOMify 2016-01-11 15:29:05 +11:00
xics.h xics_kvm: Don't enable KVM_CAP_IRQ_XICS if already enabled 2015-07-07 17:44:52 +02:00