summaryrefslogtreecommitdiffstats
path: root/hw/ppc/spapr.c
diff options
context:
space:
mode:
authorAlexey Kardashevskiy2014-05-27 07:36:30 +0200
committerAlexander Graf2014-06-16 13:24:39 +0200
commitda95324ebe462b14a3507af02eb4a689c8a1619f (patch)
tree246278f453437fa1e744a1c02869710006554c74 /hw/ppc/spapr.c
parentspapr: Enable dynamic change of the supported hypercalls list (diff)
downloadqemu-da95324ebe462b14a3507af02eb4a689c8a1619f.tar.gz
qemu-da95324ebe462b14a3507af02eb4a689c8a1619f.tar.xz
qemu-da95324ebe462b14a3507af02eb4a689c8a1619f.zip
spapr_iommu: Enable multiple TCE requests
Currently only single TCE entry per request is supported (H_PUT_TCE). However PAPR+ specification allows multiple entry requests such as H_PUT_TCE_INDIRECT and H_STUFF_TCE. Having less transitions to the host kernel via ioctls, support of these calls can accelerate IOMMU operations. This implements H_STUFF_TCE and H_PUT_TCE_INDIRECT. This advertises "multi-tce" capability to the guest if the host kernel supports it (KVM_CAP_SPAPR_MULTITCE) or guest is running in TCG mode. Signed-off-by: Alexey Kardashevskiy <aik@ozlabs.ru> Signed-off-by: Alexander Graf <agraf@suse.de>
Diffstat (limited to 'hw/ppc/spapr.c')
-rw-r--r--hw/ppc/spapr.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/hw/ppc/spapr.c b/hw/ppc/spapr.c
index 39f196304d..8f612c9347 100644
--- a/hw/ppc/spapr.c
+++ b/hw/ppc/spapr.c
@@ -537,6 +537,9 @@ static void *spapr_create_fdt_skel(hwaddr initrd_base,
/* RTAS */
_FDT((fdt_begin_node(fdt, "rtas")));
+ if (!kvm_enabled() || kvmppc_spapr_use_multitce()) {
+ add_str(hypertas, "hcall-multi-tce");
+ }
_FDT((fdt_property(fdt, "ibm,hypertas-functions", hypertas->str,
hypertas->len)));
g_string_free(hypertas, TRUE);