On 16.09.20 11:43, Paul Durrant wrote:
Hi all.
-----Original Message-----
From: Julien Grall <[email protected]>
Sent: 16 September 2020 09:39
To: [email protected]; 'Jan Beulich' <[email protected]>; 'Oleksandr Tyshchenko'
<[email protected]>
Cc: [email protected]; 'Oleksandr Tyshchenko'
<[email protected]>; 'Stefano
Stabellini' <[email protected]>; 'Volodymyr Babchuk'
<[email protected]>; 'Andrew
Cooper' <[email protected]>; 'Wei Liu' <[email protected]>; 'Roger Pau Monné'
<[email protected]>;
'Julien Grall' <[email protected]>
Subject: Re: [PATCH V1 11/16] xen/ioreq: Introduce hvm_domain_has_ioreq_server()
On 16/09/2020 09:13, Paul Durrant wrote:
-----Original Message-----
From: Jan Beulich <[email protected]>
Sent: 16 September 2020 09:05
To: Oleksandr Tyshchenko <[email protected]>; Paul Durrant <[email protected]>
Cc: [email protected]; Oleksandr Tyshchenko
<[email protected]>; Stefano
Stabellini <[email protected]>; Julien Grall <[email protected]>; Volodymyr
Babchuk
<[email protected]>; Andrew Cooper <[email protected]>; Wei Liu
<[email protected]>;
Roger
Pau Monné <[email protected]>; Julien Grall <[email protected]>
Subject: Re: [PATCH V1 11/16] xen/ioreq: Introduce hvm_domain_has_ioreq_server()
On 10.09.2020 22:22, Oleksandr Tyshchenko wrote:
From: Oleksandr Tyshchenko <[email protected]>
This patch introduces a helper the main purpose of which is to check
if a domain is using IOREQ server(s).
On Arm the benefit is to avoid calling handle_hvm_io_completion()
(which implies iterating over all possible IOREQ servers anyway)
on every return in leave_hypervisor_to_guest() if there is no active
servers for the particular domain.
Is this really worth it? The limit on the number of ioreq serves is small...
just 8.
When I suggested this, I failed to realize there was only 8 IOREQ
servers available. However, I would not be surprised if this increase
long term as we want to use
If that happens then we'll probably want to move (back to) a list rather than
an array...
I doubt you'd be able measure the difference.
Bear in mind that entry/exit to the hypervisor is pretty "cheap" on Arm
compare to x86. So we want to avoid doing extra work if it is not necessary.
... which will seamlessly deal with this issue.
Please note that in addition to benefit for the exit part on Arm we
could also use this helper to check if domain is using IOREQ here [1]
to avoid an extra action (send_invalidate_req() call).
[1] https://patchwork.kernel.org/patch/11769143/
--
Regards,
Oleksandr Tyshchenko