xen/ioreq: Make x86's send_invalidate_req() common
authorOleksandr Tyshchenko <oleksandr_tyshchenko@epam.com>
Fri, 29 Jan 2021 01:48:49 +0000 (03:48 +0200)
committerJulien Grall <jgrall@amazon.com>
Fri, 29 Jan 2021 16:55:41 +0000 (16:55 +0000)
commitf677df3111aa272f70dcfddcc4e666875366ebdf
tree5ccc71cc373346eed5ff01a3b5b3a307011e55fb
parentec1635ed877783911f0eda1b0ab10f00474b3db2
xen/ioreq: Make x86's send_invalidate_req() common

As the IOREQ is a common feature now and we also need to
invalidate qemu/demu mapcache on Arm when the required condition
occurs this patch moves this function to the common code
(and remames it to ioreq_signal_mapcache_invalidate).
This patch also moves per-domain qemu_mapcache_invalidate
variable out of the arch sub-struct (and drops "qemu" prefix).

We don't put this variable inside the #ifdef CONFIG_IOREQ_SERVER
at the end of struct domain, but in the hole next to the group
of 5 bools further up which is more efficient.

The subsequent patch will add mapcache invalidation handling on Arm.

Signed-off-by: Oleksandr Tyshchenko <oleksandr_tyshchenko@epam.com>
CC: Julien Grall <julien.grall@arm.com>
Reviewed-by: Paul Durrant <paul@xen.org>
Acked-by: Jan Beulich <jbeulich@suse.com>
[On Arm only]
Tested-by: Wei Chen <Wei.Chen@arm.com>
xen/arch/x86/hvm/hypercall.c
xen/arch/x86/hvm/io.c
xen/common/ioreq.c
xen/include/asm-x86/hvm/domain.h
xen/include/asm-x86/hvm/io.h
xen/include/xen/ioreq.h
xen/include/xen/sched.h