[xen master] x86/HVM: tighten re-issue check in hvmemul_do_io()

classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view
|

[xen master] x86/HVM: tighten re-issue check in hvmemul_do_io()

patchbot
commit f9a98780491e1a4a31adfe02fefc0892f880552e
Author:     Jan Beulich <[hidden email]>
AuthorDate: Tue Dec 5 17:18:37 2017 +0100
Commit:     Jan Beulich <[hidden email]>
CommitDate: Tue Dec 5 17:18:37 2017 +0100

    x86/HVM: tighten re-issue check in hvmemul_do_io()
   
    I'm not sure why we had left out the address check in case of indirect
    accesses (where "data" holds a guest physical address).
   
    Signed-off-by: Jan Beulich <[hidden email]>
    Reviewed-by: Paul Durrant <[hidden email]>
---
 xen/arch/x86/hvm/emulate.c | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/xen/arch/x86/hvm/emulate.c b/xen/arch/x86/hvm/emulate.c
index e924ce0..b8c94c9 100644
--- a/xen/arch/x86/hvm/emulate.c
+++ b/xen/arch/x86/hvm/emulate.c
@@ -163,7 +163,8 @@ static int hvmemul_do_io(
              (p.count > *reps) ||
              (p.dir != dir) ||
              (p.df != df) ||
-             (p.data_is_ptr != data_is_addr) )
+             (p.data_is_ptr != data_is_addr) ||
+             (data_is_addr && (p.data != data)) )
             domain_crash(currd);
 
         if ( data_is_addr )
--
generated by git-patchbot for /home/xen/git/xen.git#master

_______________________________________________
Xen-changelog mailing list
[hidden email]
https://lists.xenproject.org/xen-changelog